Using the Multigas Version of the VPM Program
in Mathematica

 

Copyright 1996-2004 by Eric Maiken

 

GENERAL COMMENTS
 

The VPM algorithm that is used in this code is obsolete (it predates the Yount / Maiken / Baker (YMB) algorithm of 2000, and also Baker's VPM-B extension to the YMB algorithm, released in 2003).


The Mathematica notebook VPM.nb implements the VPM model employing Keller and Bühlmann's method of 1/2-time scaling for mixed gasses in Yount and Hoffman's algorithm.
An example of an ascent profile, calculated by this program, is shown on the VPM Trimix page

The choices I've made for the O2 window, compartment 1/2 times, definition of decompression time, etc. are certainly open for debate. Most of the settings are discussed in the first few VPMechanics notebooks I put together for the Reverse Dive Profiles Workshop during the fall of 1999.

Unlike the BASIC language nitrox programs, this program does not iterate the calculation of stop times. The iterative calculation is really only important for no-deco diving --it was Yount and Hoffman's way of getting the no-stop times to be consistant with US Navy field experience in their 1986 paper. Of course, the same structure can be carried over to the Mathematica program if you want. 

The main purposes of this Mathematica program are to:

1) Apply a simple method (Hannes Keller's) for tracking combinations of inert gasses (see comments on mixed gas and repetitive diving)
2) Show how a calculation is done for a dive in the impermeable range (deeper than about 85 meters)
3) Provide a quantitative and streamlined programming interface 


RUNNING THE PROGRAM

VPM.nb should run in Mathematica version 5.0. 

All cells are collapsed except for the first, which contains some notes, and the last, which displays the output decompression table. You can expand (or collapse) the other cells by double clicking the downward-facing arrows on the right hand side.

When you first open the program, I suggest expanding all the cells, and then printing out a copy. I also recommend making an electronic back-up copy before running the program.

If you have trouble getting the program to run, try removing the line terminators " ; " at strategic locations to check the output starting from the top and heading down the notebook. 


MATHEMATICA

I presume familiarity with the somewhat arcane Mathematica programming language --nonetheless, here are some notes to help you read the program:

The program is in notebook format, so you either need the Mathematica program, or the free Mathematica reader to view the code. If you don't own Mathematica, then you can download MathReader, which will allow you to view and print the code. I'm not sure if MathReader includes the e-version of the Mathematica manual

General Mathematica questions can be answered through this well done e-manual. You can use this resource to check the syntax of commands by typing the command (For example: "If") into the textbox, and then using the Lookup button to get documentation.