Is it possible to define a max as in:
V = FunctionSpace(mesh, 'DG', 1) f = Function(V) m = max(f('+'),f('-'))
You probably want to use the ufl Max instead of python builtin max.
Mikael
How can I do that in a python script ? I cannot find the function Max. Thanks
Perhaps you have an older ufl version and Max is not avaiable yet? In that case you can define it yourself as
def Max(x, y): return conditional(gt(x, y), x, y)
I will use your function. Thanks a lot.