[petsc-users] How to get a duoble array into petsc Vec?
Dürrwang, Jürgen
Juergen.Duerrwang at iosb.fraunhofer.de
Fri May 20 03:13:09 CDT 2011
Thanks for your reply, it works fine!
Jürgen
You could use VecCreateSeqWithArray()
http://www.mcs.anl.gov/petsc/petsc-as/snapshots/petsc-current/docs/manualpages/Vec/VecCreateSeqWithArray.html
Shri
________________________________
Hi,
I am trying to put data form a double c array to an petsc vector. I tried to loop over each element like this petsc Vec[i] = double array[i], but I need a cast for that….has anybody an idea?
Thanks Jürgen
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20110520/a0c8cc13/attachment.htm>
More information about the petsc-users
mailing list