[petsc-users] how to get the input value from the input command

Barry Smith bsmith at mcs.anl.gov
Mon Aug 5 22:03:00 CDT 2013


On Aug 5, 2013, at 9:53 PM, 丁老师 <ztdepyahoo at 163.com> wrote:

> i need to get the number of processor in the command line as the input of my function.for example,
> mpiexec -np 4 
> i need the " 4" as the input number of my function. how to get it.

   MPI_Comm_rank(MPI_COMM_WORLD,&rank);

> 
> 
> 



More information about the petsc-users mailing list