|
From: | marco Vassallo |
Subject: | RE: dolfin function to octave function |
Date: | Thu, 12 Sep 2013 13:36:32 +0200 |
> From: address@hidden > Subject: dolfin function to octave function > Date: Thu, 12 Sep 2013 13:29:10 +0200 > To: address@hidden > CC: address@hidden > > Marco, > > The following code in the "AD_time" example > > --------------------------------------------------------------- > U = lsode (@(u, t) f(u, t, A, ML), u, time); > > for ii = 1:1:numel (time) > name = sprintf ("u_%3.3d", ii); > delete ([name ".vtu"]); > fpl_vtk_write_field (name, msho, {U(ii,:)', 'u'}, {}, 1); > endfor > --------------------------------------------------------------- > > is a very dirty hack of extremely limited use, it only happens to work > because the function space you are using for this problem has lagrangian > degrees of freedom located at the vertices of the tetrahedra. Hi, I do it only to use the pkg fpl. This should work U = lsode (@(u, t) f(u, t, A, ML), u, time); for ii = 1:1:numel (time) name = sprintf ("u_%3.3d", ii); delete ([name ".vtu"]); u = Function ('u', V, U(ii,:)); save (name, u); endfor > > It will fail for higher order elements that have more degrees of freedom per element, > and it will also fail for elements where the dofs are not collocated at the element vertices, > like e.g. raviart-thomas. > > What is really needed is a method to evaluate the problem solution at a set of points > defined by their coordinates. > > you should add this to the todo list for project completion. > > c. |
[Prev in Thread] | Current Thread | [Next in Thread] |