Suppose I have an array:
REAL,TARGET :: X(3,3)
I would like to use a pointer array like:
REAL,POINTER :: P(:)
To sequentially access the data stored in X
How can I do this?
Pointer rank remapping allows an array pointer to reference a simply contiguous or rank one target, that is of a different rank to the pointer, using a form of the pointer association statement. For the example in the question:
P(1:9) => X