Dear Cactus users,
It is introduced in the UsersGuide of Cactus that the grid arrays can only be determined by function calls, rather than the quicker methods available for GFs. But is there a better way to deal with the grid arrays so far?
I am trying to analyze some physical quantities in equatorial plane, and get the grid function in spherical coordinates by interpolation. It doesn't seem so convenient, if I define this new variable as grid arrays,
Thank you best regards --------------------------- Yu Liu PhD Student Department of Astronomy Beijing Normal University
Hello Yu Liu,
It is introduced in the UsersGuide of Cactus that the grid arrays can only be determined by function calls, rather than the quicker methods available for GFs. But is there a better way to deal with the grid arrays so far?
I am trying to analyze some physical quantities in equatorial plane, and get the grid function in spherical coordinates by interpolation. It doesn't seem so convenient, if I define this new variable as grid arrays,
In C code there is no other way to get the exact shape of the arrays. In Fortran code the shape is passed as usual to Fortran and the grid arrays appear as regular multi-D Fortran arrays.
In C what is often done is that the arrays are shaped based on some parameters eg Npoints_theta, Npoints_phi and then code uses those as the array bounds. This only works for DISTRIB=const arrays which are the same size on each MPI rank and not for DISTRIB=default arrays which are split among the MPI ranks and distributed that way. For those latter ones I do not think that there is any way to get at the shape other than calling GroupDynamicData (http://einsteintoolkit.org/referencemanual/ReferenceManualch2.html#x4-77000A...) on them.
Yours, Roland
users@lists.einsteintoolkit.org