Won't fix for 1.0.
Could possibly be fixed locally by specifying each matrix entry separately.
In general, optimizations like this are not done in UFL for good reasons, UFL is really careful about not modifying the input expressions.
In the future, this particular case ((n*x)/n) _may_ be a candidate for automatic simplification, along with other similar cases.
Have you actually profiled code with and without this though? I would half expect (or hope) that the optimizing C++ compiler picked this up.
Won't fix for 1.0.
Could possibly be fixed locally by specifying each matrix entry separately.
In general, optimizations like this are not done in UFL for good reasons,
UFL is really careful about not modifying the input expressions.
In the future, this particular case ((n*x)/n) _may_ be a candidate for
automatic simplification, along with other similar cases.
Have you actually profiled code with and without this though?
I would half expect (or hope) that the optimizing C++ compiler picked this up.