__getitem__()#
- Grid.__getitem__(key: int | slice | ellipsis | tuple[int | slice | ellipsis, ...] | ndarray[Any, dtype[_ScalarType_co]]) DataArraySource#
Return grid coordinates indexed by (l, m, n, RZ).
Returned grid coordinates are in \((R, Z)\) which can be specified by
l: radial,m: poloidal,n: torodial index.Examples
>>> grid = Grid("zone0") >>> grid[0, 0, 0, :].data # (l=0, m=0, n=0) array([3.593351e+00, 0.000000e+00]) # (R, Z) coordinates
>>> grid[:, -10, 0, :].data # (radial coords at m=-10, n=0) array([[3.600000e+00, 0.000000e+00], [3.593494e+00, 3.076000e-03], [3.560321e+00, 1.875900e-02], ..., [3.267114e+00, 1.573770e-01]])