[petsc-users] PetscOptionsGetRealArray command line format

Xiangdong epscodes at gmail.com
Fri Feb 14 12:18:38 CST 2014


I tired that, however it does not work either.

I  call the function like this:
double myarray[10];
int nmax=10;
PetscOptionsGetRealArray(PETSC_NULL,'-myarray', myarray, &nmax,&flg);

Thanks.

Xiangdong


On Fri, Feb 14, 2014 at 1:08 PM, Jed Brown <jed at jedbrown.org> wrote:

> Xiangdong <epscodes at gmail.com> writes:
>
> > Hello everyone,
> >
> > I want to pass a array into petsc through command line. What is the
> correct
> > format for PetscOptionsGetRealArray?
>
>   -myarray 1,2,3,4,5
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20140214/cdf1d3b6/attachment.html>


More information about the petsc-users mailing list