I wonder how one can do foo in FEniCS

20 views
Skip to first unread message

Johan Hake

unread,
Jun 5, 2013, 8:03:20 AM6/5/13
to
I have always wondered how I can assemble a vector in FEniCS. I thought:

mesh =UnitCube(10,10,10)
V
= FunctionSpace(mesh, "CG", 1)
u
= Function(V)
v = assemble(u)

would work, but it doesn't.

Johan Hake

unread,
Jun 5, 2013, 7:49:34 AM6/5/13
to myd...@googlegroups.com
Well have you tried:

v = TestFunction(V)
b
= assemble(u*v*dx)




ha...@simula.no

unread,
Jun 5, 2013, 8:13:20 AM6/5/13
to myd...@googlegroups.com

You can only assemble forms.

chris.n.r...@googlemail.com

unread,
Jun 5, 2013, 8:27:00 AM6/5/13
to myd...@googlegroups.com, ha...@simula.no

What do you mean, forms?

Johan Hake

unread,
Jun 5, 2013, 8:28:47 AM6/5/13
to chris.n.r...@googlemail.com, myd...@googlegroups.com

ander...@gmail.com

unread,
Jun 5, 2013, 2:05:35 PM6/5/13
to myd...@googlegroups.com
Hmm... I'm not impressed by this interface...
Reply all
Reply to author
Forward
0 new messages