[petsc-users] template function as argument to MatShellSetOperation

Matthew Knepley knepley at gmail.com
Mon Jan 12 09:40:43 CST 2015


On Mon, Jan 12, 2015 at 7:59 AM, Marco Cisternino <
marco.cisternino at optimad.it> wrote:

> Hi PETSc users,
> I'm trying to set my matrix multiplication with MatShellSetOperation.
> The question is: is it possible to pass a c++ template function as my
> matrix multiplication to MatShellSetOperation?
>

No. You will need to write a C wrapper.

  Thanks,

    Matt


> And if yes, how?
> Thanks for any suggestions.
>
> Marco
>
>


-- 
What most experimenters take for granted before they begin their
experiments is infinitely more interesting than any results to which their
experiments lead.
-- Norbert Wiener
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20150112/8dbaa319/attachment.html>


More information about the petsc-users mailing list