← Back to team overview

dolfin team mailing list archive

Re: Plot a constant Expression with different values in the x and y directions

 

Anna Blechingberg wrote:
Hi,

Anna Blechingberg wrote:

[..]

Do the Constant definition of g also work in dolfin version 0.9.4 even
if I can't plot it?
The function interface has changed a bit in 0.9.4, such that you don't
define Constant function any longer with a mesh, you just pass in the
desired value.

If you want to plot it, just used the mesh argument of the plot
function, e.g.

c = Constant((0,1))
m = UnitSquare(3,3)
plot(c,mesh=m)

I'm sorry, but it doesn't work. I have tried with your and several other
different versions of defining a Constant:

Oops, my fault, I mixed up version 0.9.4 with 0.9.5, sorry!
Andre






References