Description of Matlab script

Important: Although this page appears to be boring I recommend that you read it. It is best not to use the script without knowing what it is doing!

The Matlab script for visualising structure contours is written in a very simple way, using standard Matlab functions and without graphical user interfaces. Consequently there shouldn't be version incompatibilities (I use version 6.5, release 13) and the user should be able to follow the script step by step. I commented the script thoroughly and divided it into four parts:

PART 1: Model definition
In this section the model dimensions are defined. The lateral dimensions of the model are Lx and Ly and the spacing of the grid is s. With these values the matrices X and Y are created and contain the lateral coordinates of the model. The matrices Z, G and O are also created, with initial values of zero.

PART 2: User's input
I have decided to give the user three options for topography, either a valley (option 1) or a ridge (option 2) or both (option 3). The geological surface is either a plane (option 1) or a sinusoidal fold train (option 2). If you have chosen a plane you will be asked to enter first the dip direction α and then the dip, δ. If you have chosen a fold train you will be asked to enter the plunge of the fold, φ.

PART 3: Calculations of topography (Z), geology (G) and outcrop pattern (O)
This part calculates the elevations of the topography and geology. The topography of the Earth's surface is defined using cosine functions:


equation for topography


where A is the amplitude, W is the wavelength, Φ is the phase shift and E is the mean elevation. The planar structure is calculated using


equation for plane


and the fold train is calculated using


equation for folds


The elevations in Z and G are substracted from each other to check whether the geological surface is below or above the Earth's surface, the latter means that the geological surface has been eroded.

PART 4: Plotting
The diagram below illustrates the objects plotted: The topography is plotted using shades of yellow and green and contours as black lines. The geology is plotted as a blue, transparent object with structure contours shown as white lines. The outcrop pattern is shown in map view as a red line.


Plotting scheme

NEXT


BACK