A targeted heterogeneous medium in the form of an underground layered
formation is gridded into a layered structured grid or a layered
semi-unstructured grid. The structured grid can be of the irregular
corner-point-geometry grid type or the simple Cartesian grid type. The
semi-unstructured grid is really unstructured, formed by arbitrarily
connected control-volumes derived from the dual grid of a suitable
triangulation; but the connectivity pattern does not change from layer to
layer. Problems with determining fluid movement and other state changes
in the formation are solved by exploiting the layered structure of the
medium. The techniques are particularly suited for large-scale simulation
by parallel processing on a supercomputer with multiple central
processing units (CPU's).