PDA

View Full Version : Calculating no-stop times for Haldane/Buhlman equations


sijomon
10-07-2011, 15:29
Hi,

I am playing around trying to get a better understanding of how dive computers work by implementing a simulation of one myself. I have started with the Buhlman ZH-L16 alogrithm. I am restricting myself to nitrogen as the only inert gas, and am using the A version of the a/b values. I have the basic compartment pressure calculations done, I think correctly, and can therefore calculate the insert gas loading in each compartment as the simulated dive progresses. I have also got the minimum tolerated inspired gas pressure calculations sorted, so now I can calculate the ascent ceiling for each compartment. What I am currently having trouble with is calculating the 'no stop limit' for each compartment.

I am using the equation:

t = (-1/k)*ln[(Pi - Mo)/(Pi - Po)]

where:

t = the no-stop time for the compartment
k = ln(2) / compartment half life
Pi = pressure of inert gas inspired
Mo = surfacing M value for compartment
Po = current compartment inert gas pressure

all of this I have got from some papers by Erik Baker (you can find the no-stop time one here (http://www.ddplan.com/reference/ndl.pdf)). I shoud note that I am limiting the application of this equation to the cases where 0 < (Pi - Mo)/(Pi - Po) <= 1 ( I default it to 0 otherwise) as specified in the Baker paper.

What I'm expecting is that the no-stop time reaches 0 at exactly the same time that the minimum tolerated inspired gas pressure becomes greater than 1bar (i.e. the ascent ceiling is below the surface). This is working fine for the descents. However when I start to ascend the no-stop time sometimes becomes positive again even when the ascent ceiling is still below the surface.

My maths is nowhere near good enough to resolve this issue thorugh analysis of the equations, so I was hoping someone here has sufficient knowlegde of this subject, and can explain things in sufficiently simple terms to help me identify what I'm doing wrong.

I appreciate there may well not be enopugh information here to resolve the problem and am happy to provide more details as neccessary.

The current version of my simulation is avaiable at:

http://bsac.sijomon.com/labs.jsp

many thanks for any help anyone can provide, it will be appreciated.

Simon.

ChristianG
10-07-2011, 16:44
NigelH, are you out there? ;)

neil_richardson
10-07-2011, 18:01
some information that might help you.. .

http://www.ddplan.com/reference/mvalues.pdf

and you might want to read some of these articles :-)

N

sijomon
10-07-2011, 18:07
Than ks for the recomendation, but I've already read that one, can't claim to have digested it all, but I've read it at least. Is there some particular bit that you think would shed light on the behaviour of the NDL equation during ascent?

My reading so far has been:

http://www.duikresearch.org/documenten/SSH-SDR_HaLenBellen_sep06.pdf
(the Neo-Haldanian theory chapter)

http://www.ddplan.com/reference/ndl.pdf
(from whoch I have copiued the NDL equations quote in my first post)

http://www.ddplan.com/reference/mvalues.pdf
(from which I otained the equivalentce formulae for a/b to M0 values)


I'm currentyl workign my way 9slowly) through:
http://www.ddplan.com/reference/decolessons.pdf

and two of the papers recommended there, namely:

" A.E., Damant, G.C.C., & Haldane, J.S. "The Prevention
of Compressed Air Illness"

and

"Workman, Robert D. "Calculation of Decompression Schedules for
Nitrogen-Oxygen and Helium-Oxygen Dives"

neil_richardson
10-07-2011, 20:05
oops in my last post, i thought i'd posted this link:

http://www.gap-software.com/support/documents.html


this might be of some use??

sijomon
10-07-2011, 20:59
Looks like those resources will be excellent when I move onto the RGBM algorithm, thanks :)

Further investigation on the NDL value in my simulation seems to show that the NDL value during ascent, when it swicthes (I don't understand the trigger for this) from 0 to >0, corresponds to the stop time for that compartment, i.e. the time when that compartment's ascent ceiling will go above the surface at the current depth.

This would be quite usefull, the NDL value giving the maximum no stop time during descent and the required stop time during ascent; is this an artifact of my implementation or is this a recognised feature of the algorithm?

Thanks again for any help.

Simon.