Subject: [FEniCS-users] function class

From: Patrick Riesen <[email-masked]>
Date: Fri, 9 Oct 2009 09:26:50 +0200

hi,

i'm upgrading my code to the development version of dolfin.
now it's not possible to create a function without functionspace anymore.
i have an abstract class for different problems which returns the 
solution function. in another class i retrieve this solution function, 
but there i don't want to deal/know a priori what functionspace the 
function has, so in that class i just initialized a pointer as

_retrieved_solution = new Function;

and then assigned the solution function with

*_retrieved _solution = Problem.return_solution();

how can i do something similar now?

thanks for the help,

patrick

---

From: Anders Logg <[email-masked]>
Date: Fri, 9 Oct 2009 12:26:05 +0200

> how can i do something similar now?

Function* _retrieved_solution = 0;

_retrieved_solution = new Function(*Problem.return_solution());

--
Anders

---

From: Patrick Riesen <[email-masked]>
Date: Fri, 9 Oct 2009 12:39:14 +0200

> _retrieved_solution = new Function(*Problem.return_solution());

ai, thanks for the lesson :-)

> 
> --
> Anders
> 
> 
> ------------------------------------------------------------------------
> 
> _______________________________________________
> FEniCS-users mailing list
> [email-masked]
> http://fenics.org/mailman/listinfo/fenics-users