dolfin team mailing list archive
-
dolfin team
-
Mailing list archive
-
Message #06860
Re: Saving UserFunction to vtk format
On Thu, Mar 27, 2008 at 03:57:37PM +0100, Kristen Kaasbjerg wrote:
> I was wondering if it is possible to save a user defined function (such
> as the source term in poissons equation) to vtk format ?
>
> A discrete functions can be saved simply by:
>
> file = File("file.pvd")
> file << u
>
> but that works only for discrete functions.
>
> Any suggestions ?
>
> Kristen
Should be fixed now.
I just needed to remove these lines:
if ( u.type() != Function::discrete )
error("Only discrete functions can be saved in VTK format.");
--
Anders
References