aglo

Exercises:  
d. Introduction to 3D magnetic forward & inverse modelling


 

Page contents: | Introduction |Forward modelling | Inversion | Data/noise | Invert | Result |
For printing: expand / collapse all questions.

Introduction

data This exercise is an introduction to 3D forward modelling and inversion of magnetic data. You will generate a synthetic data set from a known, synthetic model of the earth, then those data will be inverted. It should take 1-2hrs to work through these steps, and at the end you will know how to use the tools, and you should have some intuition about what kind of model to expect from such an inversion.

Click " Questions to consider ... " to reveal questions that you should be able to answer if you understand what is going on. If this worksheet is an assignment for a course, your instructor may require answers to these questions for marking. It should take students who have never used the codes before roughly 3hrs to complete.

Setting up the codes:

For installation see Chapter 10, Section d.2, the MAG3D QuickStart page. On that page, the test steps that follow installation instructions are recommended, but optional if you are going to complete the exercises below.


Notes about software (click to expand). Programs, file names, and directories (ie "folders").
  • All executable program files must be in the one subdirectory.
  • The forward modelling calculations are carried out by magfor3d.exe BUT this code is usually run from within the MeshTools3D.exe utility.
  • The file containing calculated data will always be called "model.sus". You must change this file name (in Window's explorer or equivalent) before running a new forward calculation otherwise the previous calculated data set will be lost.
  • Use links in Chapter 10, Section d for full instructions on graphical interface programs and modelling/inversion codes.

A synthetic model must be placed on your computer in a new subdirectory directly under the downloaded codes. Right click these two links to obtain the mesh and synthetic model files.


Forward modelling to generate data

We begin by familiarizing with the 3D volume viewing tool, examining the 3-block model of the earth, then calculating total field magnetic anomaly data over this model.

  • Start MeshTools3D.exe and load (File => Open) the synthetic data set by opening the mesh.dat file and model.sus files in the "Mesh" and "Model" boxes of the Load dialogue. (You can drag and drop files from Windows explorer into the dialogue box.)
  • Examine the model using all the capabilities of the 3D model viewer. Click and drag with the mouse to rotate, and explore the menus to try slicing, and generating isosurface views using Options => cutoff.
  • To learn of all the capabilities, the MeshTools3D manual should be examined if you have never used this tool.
  • The following question set will help guide your exploration of the tool, and the synthetic 3-block model of the earth.

Questions to consider ...
  1. What is the width, length, depth, of the whole volume of our model?
  2. How many susceptible zones are there?
  3. What is the susceptibility of each of these zones?
  4. SIDEBAR:  Saving images:
    - This can be done directly using the copy button of the viewing tool and pasting into the document. However the result is a large file size.
    - Final document size will be significantly reduced if you copy the image into an image editor (MS Paint is OK) and save the image in a *.GIF format. The *.jpg format is OK too but is better for photographs. *.GIF's are best for diagrams..
    What is the susceptibility of the host rocks?
  5. Slice through the zone by selecting one of the W E S N T B buttons then pressing SHIFT-up and SHIFT-down keys.
  6. Select Options = > Cutoff, and change min to .01. This hides all susceptible zones with value less than 0.01. Rotate the volume (rightclick and hold while moving the mouse) until all 3 zones are visible. Make the image small (to minimize the size of your final document), then copy this image and paste into your working document.

Calculate data by selecting Forward Model => magnetics and enter (I, D, F) = (20, 10, 33000). Specify data spacing so stations are 20m apart along E-W lines (X) and lines are 75m apart. If you ask the program to calculate more than 200 data points, it will quite with a message noting you have exceeded the limits of this educational version of the codes.


Questions to consider ...
  1. What location on the earth is implied by the I=inclination and D=declination used to specify the ambient (inducing) magnetic field at the field site's location on Earth? (Refer to images of Earth's field components.)
  2. The resulting data map is displayed by the utility gm-data-viewer.exe (which must be in the same directory as all the other executable codes.) See the gm-data-viewer manual for details about using this simple plotting tool.
  3. To practice generating line profiles through this data set, draw a line pointing direction towards magnetic north, which crosses over the feature with the strongest anomalous values.
  4. Copy the image with the data map and the line profile into your answer document.
  5. Sketch the surface projection of the buried targets on this data map.

Inverting a magnetic data set

We want to learn what kind of model the UBC-GIF inversion algorithm will produce from this synthetic data set. First, here is a 4-point outline of the steps we will follow - detailed instructions are given after the outline .

  1. Examine the data, characterize the noise level, and gain an initial impression of what these data are telling you about what's underground.
  2. Set up the program to run a preliminary default inversion.
  3. Investigate the result and consider whether it is a sensible model.
  4. Try alternative inversions.

Start the user interface by running MAG3Dgui.exe. You should see the user interface window, similar to the illustration below right.

1) Examine data and set noise levels

  • Load the data file that you just created into the "Mag observations file" field using the Browse button. It is called magfor3d.mag. (Recall you can drag-and-drop the file from a Windows™ Explorer window into this entry field.)
  • Press the View Data button, and you should get the same contour map of data seen earlier. These are perfect data because they were calculated from a synthetic scenario.
  • For synthetic data, add and assign error statistics ...
    • In the data viewing window, click the E button to display a plot of errors associated with each data point. It should be blank.
    • Select the Edit menu, Add Gaussien Noise option (NOT the "Assign ..." option). Enter 5 for %. For the "+minimum" vlaue, enter a number which is roughly 3% of the maximum anomaly seen on this data set. This latter value is a "floor" for the errors, necessary because data values that are close to zero are never as reliable as larger voltages (owing to instrumentation limitations). This actually addes a random component to each datum so don't do this with real data!
    • Now the Errors plot should be no longer blank.
  • (For real field data, instead of Adding noise, you must Assign noise using similar steps. With this option no additional randomness is added to each datum.)
  • Save work (File => Save), taking care to note the following ...
    • make a new subdirectory with a name that tells what will be there - "invn1" for example.
    • Save this "noisey" data set, giving it a new file name (such as magdata-n.dat).
    • Read the popup window, then close the data viewer.
  • Make sure the correct (noisy) data set is specifed at "observations" - use the "Browse" button to find the newly saved file.

2) Default Inversion

Now we will set up and run an inversion using default parameters. The earth is modelled using a mesh of cells. This mesh can either be pre-defined or we can create one for this inversion.

  • Click the Create mesh button and specify 25m wide cells, with elevation at 0. We can not use smaller cells because of the limits imposed by the educational version of these codes.
  • All parameters in the user interface will be left at their default values for the first inversion attempt. They will be modified for generating alternative models later.
  • Before an inversion can be run, this parameter set must be saved using File => Save.

Important : you should save each new run into a new subdirectory. This prevents overwriting previous work. Click the new directory button in the save dialogue, name the directory as you like, then go to this new directory and save the parameter file. The run button should now become active.

  • Click the run button to start the inversion.
  • You should see a command line window pop up (like a DOS session), and the program's progress should be displayed as the sequence of operations proceeds.

While the processing is working, you can use the tool bar buttons to observe progress, and the history of this run. These are:

  • The logs button shows results of generating the sensitivity matrix (compression ratio, etc.). This is a matrix containing the relationship between each data point and every model cell. It is large!
  • The logi button shows the history of the actual inversion (parameters at each iteration, etc.).
  • The pre button displays the data viewing window. This window can display either a map of errors, or a map of predicted data, or a map of the difference between observed and predicted data. The gm-dataviewer manual is referred to under NOTES above.
  • The model button brings up the 3-D imaging program for displaying the recovered model. The manual for MeshTools3D was referenced under NOTES above.

The next set of questions can be considered while the inversion is progressing. Answers are in the inversion log file (logi). The sensitivity log file (logs) will NOT be considered.


Questions to consider ...
  1. How many data points are there?
  2. How many cells are there in the digitized representation of the earth (ie. the model)?
  3. The "target misfit" for the inversion is a number specifying how close the data predicted by the model should match the observed (measured) data. It's value, called the target misfit = ( Chifact )*( number of data ). What is the value of this "target misfit"?
  4. What are the default model objective function parameters (the Alpha's ( s, n, e, z )? These specify to what extent the program tries to find a model that is "small" (ie close to a reference model) and "smooth" in the north, east, and Z (down) directions respectively. Their relative values are more important than their absolute values.

3) Investigate the result

modelWhen the inversion is complete, the program will tell you it is done. In order to understand what has been done, you should be able to address these questions:


Questions to consider ...
  1. From the logi file identify
    1. what the total cpu time was for this job,
    2. the total number of iterations required, and
    3. the achieved misfit at the final iteration. (You do not need the values that follow "Summary of line search with positivity".)
  2. Does the achieved misfit correspond to the target value you identified above? If not, it is worth considering if a different set of inversion parameters might cause the program to produce a more acceptable result.
  3. Plot the observed data and predicted data together (the pre button). Explain briefly what this predicted data set is.
  4. Qualitatively what are some differences in appearance of predicted data compared to the observed data?
  5. Change the second data plot to a data difference map by clicking the diff button. Does this difference map look random?
  6. Explain which portion of the data set appears to have been the most difficult to reproduce. In other words, identify which data points have the largest difference between predicted and observed data values.

Plot the model and use rotate, slice and cutoff to get a feel of the model. Answer the following questions:


Questions to consider ...
  1. Compare the susceptibility values in this inversion result to the "true" values you know from the original synthetic model.
  2. Explain why the recovered physical property values are less than the "known" true values.
  3. Describe the most significant difference between the character of the recovered model and the true geologic features.
  4. Try a range of isosurface cutoff values to obtain the most representative image for geological interpretation. Copy this image into your working document.
  5. Explain in only a few sentences why the model recovered by this process involves smoothly varying zones of susceptibility instead of isolated blocks with single values of susceptibility. This style of outcome must be understood because it is a result of the algorithm's attempt to automatically recover one sensible model when there are in fact an infinite number of possible distributions of susceptibility that could explain the data.

4) Alternative models

We will not do this here, but it is necessary when you work on a real data set. This ends the practice session. You should now be familiar enough with the tools to work on a real data set.