Several years ago I asked a similar question and this is what Barry told me:
>>
Randy,
Take a look at DMDAGetRay() in src/dm/impls/da/dasub.c (now called
DMDACreateRay()) this takes a row or column from a 2d DADM. You can use the
same kind of approach to get a slice from a 3d
Hi PETSc-developers,
For an application, I'd like to extract a 2D slice from a 3D DMDA vector,
perform a `MatMult` on it (a discretized rotation on the 2D vector) and
place the resulting vector back into the 3D vector. The approach I'd taken
was to use `DMDACreatePatchIS` to create an IS that