[Dune] passing functions as arguments
Aleksejs Fomins
aleksejs.fomins at lspr.ch
Mon Aug 11 10:06:38 CEST 2014
Dear Jayesh,
Thank you for your link. I will read through it closer today.
I would still like to know if there is really a problem with simply
passing functions as arguments, before I go into more complicated stuff
Cheers,
Aleksejs
On 08/08/2014 06:10 PM, Jayesh Badwaik wrote:
> Hi,
>
> You have to use functors. You can see this for a basic reference:
> http://web.stanford.edu/class/cs106l/course-reader/Ch13_Functors.pdf
>
-------------------------------
Dear Dune,
I have decided to implement an approximate integration method
alternative to the Quadrature Rule. For that, the integrator procedure
needs to sample from some function decided at runtime.
How would you approach such a construction?
As in, should I pass function/object as parameter? Also, I was told that
I should avoid using virtual functions when doing this.
Regards,
Aleksejs
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 551 bytes
Desc: OpenPGP digital signature
URL: <https://lists.dune-project.org/pipermail/dune/attachments/20140811/30e6c8a9/attachment.sig>
More information about the Dune
mailing list