Calculate tank volume?

Need advice on recreational gear configurations? Look no further than this equipment forum.
User avatar
BDub
I've Got Gills
Posts: 1327
Joined: Thu Jun 08, 2006 2:39 pm

Re: Calculate tank volume?

Post by BDub »

dsteding wrote:
BDub wrote:
dsteding wrote:
BDub wrote:
As far as your tanks, Sean. I've had my double lp95's pumped up to 3700 before. Just dive em.
You know they are too full when champagne bubbles are coming out of the burst disc . . .
Minor details
Breathe it down, the bubbles go away . . .
Amazing how that works every time!
http://www.frogkickdiving.com/

"It's a lot easier when you're not doing it" - CaseyB449

"There needs to be more strawberry condoms. Just not on my regulator" - DSteding
User avatar
Pez7378
I've Got Gills
Posts: 3256
Joined: Wed Jun 21, 2006 11:09 am

Re: Calculate tank volume?

Post by Pez7378 »

dsteding wrote:
BDub wrote:
dsteding wrote:
BDub wrote:
As far as your tanks, Sean. I've had my double lp95's pumped up to 3700 before. Just dive em.
You know they are too full when champagne bubbles are coming out of the burst disc . . .
Minor details
Breathe it down, the bubbles go away . . .
Sean, and Paul,

ignore the guy behind the curtain.......
User avatar
spatman
I've Got Gills
Posts: 10881
Joined: Wed May 30, 2007 7:06 am

Re: Calculate tank volume?

Post by spatman »

Pez7378 wrote:
dsteding wrote:
BDub wrote:
dsteding wrote:
BDub wrote:
As far as your tanks, Sean. I've had my double lp95's pumped up to 3700 before. Just dive em.
You know they are too full when champagne bubbles are coming out of the burst disc . . .
Minor details
Breathe it down, the bubbles go away . . .
Sean, and Paul,

ignore the guy behind the curtain.......
because he's Doing It Wrong.
Image
User avatar
CaptnJack
I've Got Gills
Posts: 7776
Joined: Fri Jul 07, 2006 2:29 pm

Re: Calculate tank volume?

Post by CaptnJack »

Pez7378 wrote:Since were on the topic, and well, most of us involved in this conversation don't have much experience with this stuff, I'd like to hear some stories of tanks gone bad. Bob, CaptJack, Matthew, Romer, Steding, BDub, DMitchell? Anyone? What are some stories that PSI is telling? What have you witnessed?
1) PSi is paranoid about >10% overfills. Not legal blah blah blah. If its not spelled out in compressed gas association (CGA) guidance or DOT rules they will not go there.
2) On 6351 AL tanks they follow the DOT rules and will not admit that just taking all these 20+yo tanks (that you can buy new for $150) out of service might be a plausible risk management approach. Doing eddy currents on these and more frequent VIPs, they are all over those concepts (kaching$$)

I have condemned only a couple AL tanks that I have seen in the past ~4yrs of doing my own VIPs. One for pitting (corrosion), one for a suspected neck crack (6061 AL btw). I have never seen a steel tank with a crack or excess pitting, although I have seen quite a few manufacturing folds which look like cracks.
Sounder wrote:Under normal circumstances, I would never tell another man how to shave his balls... but this device should not be kept secret.
User avatar
CaptnJack
I've Got Gills
Posts: 7776
Joined: Fri Jul 07, 2006 2:29 pm

Re: Calculate tank volume?

Post by CaptnJack »

Pez7378 wrote:
CaptnJack wrote:For me using stuff like 2.5 vs 2.6 adds up to 3cf in an AL80, no big deal and trivial compared to gauge variation anyway. These numbers a little easier to work in your head.
This is helpful for me. I generally use a calculator for all numbers that add up to more than 1 so any little trick that makes it easier to add is great!
YW.

E.g. lp85s and hp100s are not exactly the same cf/psi
85cf/26.4 (100s of psi) = 3.21 cf/100psi

100/34.42 = 2.91

But for all practical purposes you can round both to "3" and its totally adequate for the purpose. Tank manufacturing tolerances aren't that great anyway, some are 1/4" taller or shorter etc.
Sounder wrote:Under normal circumstances, I would never tell another man how to shave his balls... but this device should not be kept secret.
Dmitchell
Perma Narc'd
Posts: 762
Joined: Sun Oct 29, 2006 6:53 pm

Re: Calculate tank volume?

Post by Dmitchell »

As far as tanks gone bad-

Steel - Rarely any problems even when rusty they tumble out and usually come out fine. The instance of steel tanks exploding around the world is very low and those that have were generally badly neglected. I just had 4 tanks come in the other day, ancient old st72's they had a little water in them and enough rust to require tumbling. Tumbled (or my wife did) them and sent them to hydro all 4 passed no problem.

AL - I for on treat the 6351's with caution but think that mass hysteria about the issue is unwarranted. We've condemned our fair share, but we also pass many of them every year. I mean come on - 19 or 20 out of something like 4 million have exploded. To me that means more careful checking but not mass hysteria. How many cars have had worse safety records and are still on the roads. Otherwise, I've failed AL tanks for ridiculous corrosion or thread problems or pits (internal and external) beyond spec. I've got a 13 in the shop that some commercial guy used for a bailout. It was about 2/3 full of saltwater for 6 years - Fail

I agree that PSI can get a little over the top from time to time but they have been there and in some court sometime, I don't want to find myself sitting across from them.

DM
Dave Mitchell
_______________________________
It's OK to hijack my threads!
Great Sites - Flickr and NSOP
defied
I've Got Gills
Posts: 2057
Joined: Wed Sep 17, 2008 8:14 pm

Re: Calculate tank volume?

Post by defied »

Bash shell calculator:

[root@Deathbydoornails ~]# sh tankVolume.sh 95 3000 2640
107.7000 cf
[root@Deathbydoornails ~]# cat tankVolume.sh

Code: Select all

#!/bin/bash
if [ "$1" == '' ]
then
        echo "Usage - tankVolume.sh <cf> <maxPsi> <actualPsi>"
        exit 1
else
        run=$1/$3
        cfPsi=$(echo "scale=4; ${run}" | bc)
        run1=$2*$cfPsi
        CF=$(echo "scale=4; ${run1}" | bc)
        echo $CF "cf"
fi
[root@Deathbydoornails ~]#
User avatar
Pez7378
I've Got Gills
Posts: 3256
Joined: Wed Jun 21, 2006 11:09 am

Re: Calculate tank volume?

Post by Pez7378 »

defied wrote:Bash shell calculator:

[root@Deathbydoornails ~]# sh tankVolume.sh 95 3000 2640
107.7000 cf
[root@Deathbydoornails ~]# cat tankVolume.sh

Code: Select all

#!/bin/bash
if [ "$1" == '' ]
then
        echo "Usage - tankVolume.sh <cf> <maxPsi> <actualPsi>"
        exit 1
else
        run=$1/$3
        cfPsi=$(echo "scale=4; ${run}" | bc)
        run1=$2*$cfPsi
        CF=$(echo "scale=4; ${run1}" | bc)
        echo $CF "cf"
fi
[root@Deathbydoornails ~]#
Well that makes sense......... :evil4:
defied
I've Got Gills
Posts: 2057
Joined: Wed Sep 17, 2008 8:14 pm

Re: Calculate tank volume?

Post by defied »

It's friday. I was bored. Makes me look busy while waiting for the important stuff to come.

D(B)
User avatar
sunnydude
Extreme Diving Machine
Posts: 408
Joined: Thu Sep 25, 2008 10:12 am

Re: Calculate tank volume?

Post by sunnydude »

defied wrote:Bash shell calculator:

[root@Deathbydoornails ~]# sh tankVolume.sh 95 3000 2640
107.7000 cf
[root@Deathbydoornails ~]# cat tankVolume.sh

Code: Select all

#!/bin/bash
if [ "$1" == '' ]
then
        echo "Usage - tankVolume.sh <cf> <maxPsi> <actualPsi>"
        exit 1
else
        run=$1/$3
        cfPsi=$(echo "scale=4; ${run}" | bc)
        run1=$2*$cfPsi
        CF=$(echo "scale=4; ${run1}" | bc)
        echo $CF "cf"
fi
[root@Deathbydoornails ~]#
And I thought you had just crashed the thread. :computersmash:
Sean
defied
I've Got Gills
Posts: 2057
Joined: Wed Sep 17, 2008 8:14 pm

Re: Calculate tank volume?

Post by defied »

Nah, I've been contemplating writing a script to maintain a bunch of dive math, so as convos come up, I figure I'll make little snippets, and eventually lump them all together in to one big script I may even Gui-ize, and maybe build out for the iphone, or G1, or hell, maybe even java.

D(B)
User avatar
Grateful Diver
I've Got Gills
Posts: 5322
Joined: Mon May 15, 2006 7:52 pm

Re: Calculate tank volume?

Post by Grateful Diver »

Techies and cavers routinely overfill cylinders ... and I've read that it's common practice in Europe.

In fact, a common rule of thumb in tech/cave circles is that "when your tanks are full, it's time to turn the dive" ...

... Bob (Grateful Diver)
Threats and ultimatums are never the best answer. Public humiliation via Photoshop is always better - airsix

Come visit me at http://www.nwgratefuldiver.com/
User avatar
sunnydude
Extreme Diving Machine
Posts: 408
Joined: Thu Sep 25, 2008 10:12 am

Re: Calculate tank volume?

Post by sunnydude »

As an update...the LDS didn't fill the tanks to just 3000psi, when I hooked it up on Monday it was at 3400psi! A 119! I needed the extra air as I was all over the place.
Sean
User avatar
airsix
I've Got Gills
Posts: 3049
Joined: Mon Jan 22, 2007 7:38 pm

Re: Calculate tank volume?

Post by airsix »

Defied, there's a slight error in your script.
Here's an example. Notice the cf for an overpressurized 130 is showing low.

Code: Select all

ben@phoenix:~$ ./tankVolume.sh 130 3442 3600
124.2562 cf
ben@phoenix:~$
I think you accidentally processed variables in the wrong order. I've edited lines 7 and 9.
Try it like this and I think you'll get the correct values:

Code: Select all

#!/bin/bash
if [ "$1" == '' ]
then
        echo "Usage - tankVolume.sh <cf> <maxPsi> <actualPsi>"
        exit 1
else
        run=$1/$2
        cfPsi=$(echo "scale=4; ${run}" | bc)
        run1=$3*$cfPsi
        CF=$(echo "scale=4; ${run1}" | bc)
        echo $CF "cf"
fi
Sample output:

Code: Select all

ben@phoenix:~$ ./tankVolume.sh 130 3442 3600
135.7200 cf
ben@phoenix:~$
ps - Thanks for posting this by the way. I do not have your scripting skills and you just showed me how to use bc to do floating-point math with bash. Cool! I've only used bash to work with integers.
Last edited by airsix on Wed Mar 25, 2009 3:54 pm, edited 1 time in total.
"The place looked like a washing machine full of Josh's carharts. I was not into it." --Sockmonkey
User avatar
cardiver
I've Got Gills
Posts: 3898
Joined: Sun Sep 17, 2006 10:43 am

Re: Calculate tank volume?

Post by cardiver »

airsix wrote:Defied, there's a slight error in your script.
Here's an example. Notice the cf for an overpressurized 130 is showing low.

Code: Select all

ben@phoenix:~$ ./tankVolume.sh 130 3442 3600
124.2562 cf
ben@phoenix:~$
I think you accidentally processed variables in the wrong order. I've edited lines 7 and 9.
Try it like this and I think you'll get the correct values:

Code: Select all

#!/bin/bash
if [ "$1" == '' ]
then
        echo "Usage - tankVolume.sh <cf> <maxPsi> <actualPsi>"
        exit 1
else
        run=$1/$2
        cfPsi=$(echo "scale=4; ${run}" | bc)
        run1=$3*$cfPsi
        CF=$(echo "scale=4; ${run1}" | bc)
        echo $CF "cf"
fi
Sample output:

Code: Select all

ben@phoenix:~$ ./tankVolume.sh 130 3442 3600
135.7200 cf
ben@phoenix:~$
That looks right to me, Ben! :pacing:
-Ron T.
"When I'm 80 I'll take up real diving, which is done in a pub..." Ray Ives.
253-227-0856
My Dive Pics...
https://www.facebook.com/RETOPPPHOTOGRAPHY
defied
I've Got Gills
Posts: 2057
Joined: Wed Sep 17, 2008 8:14 pm

Re: Calculate tank volume?

Post by defied »

I based it off of this:
spatman wrote:
95cf divided by 2640psi = roughly .036 cf/psi

so 3000psi x .036cf/psi = 108cf


yay, scuba math!

Code: Select all

[root@Deathbydoornails ~]# ./tankVolume.sh 95 3000 2640
107.7000 cf
[root@Deathbydoornails ~]# ./tankVolume.sh
Usage - tankVolume.sh <cf> <maxPsi> <actualPsi>
You're doing it wrong. :spatman:

You were placing the actualPSI before the maxpsi. That is if 3442 is your actual, and 3600 is your max.

If you're overfilling to 3600, and your max is 3442, then that could require more math, I'm sure.

D(B)
Notice the flip. You:

Code: Select all

ben@phoenix:~$ ./tankVolume.sh 130 3442 3600
124.2562 cf
ben@phoenix:~$
Me:

Code: Select all

[root@Deathbydoornails ~]# ./tankVolume.sh 130 3600 3442
135.7200 cf
[root@Deathbydoornails ~]#
User avatar
airsix
I've Got Gills
Posts: 3049
Joined: Mon Jan 22, 2007 7:38 pm

Re: Calculate tank volume?

Post by airsix »

Code: Select all

Usage - tankVolume.sh <cf> <maxPsi> <actualPsi>
$cf = tank capacity at maxPsi

You have to divide capacity by rated pressure, then multiply by actual pressure. Your original script divided by actual pressure, then multiplied by rated pressure.

Spatman's example was showing that a LP95 rated at 2640psi has a capacity of 108 when overfilled to 3000psi.
2640 = maxPsi
3000 = actualPsi

-Ben
"The place looked like a washing machine full of Josh's carharts. I was not into it." --Sockmonkey
defied
I've Got Gills
Posts: 2057
Joined: Wed Sep 17, 2008 8:14 pm

Re: Calculate tank volume?

Post by defied »

Then I'm doing it wrong. :spatman:

I wonder if maybe it's the terminology that I need to replace, and not the code.

echo "Usage - tankVolume.sh <cf> <maxPsi> <actualPsi>"

should probably be:

echo "Usage - tankVolume.sh <cf> <actualPSI> <ratedPSI>"
Rofl.. Same as what you were saying... but easier to one line it.

I misunderstood his intentions.. oops... Where's the dunce cap smiley? :defied:

Thanks for the fix!

D(B)
User avatar
airsix
I've Got Gills
Posts: 3049
Joined: Mon Jan 22, 2007 7:38 pm

Re: Calculate tank volume?

Post by airsix »

No dunce cap. I was sitting here thinking I probably misunderstood and was making a fool of myself.

I suggest naming the variables something like:

$ratedCapacity
$ratedPressure
$actualPressure
"The place looked like a washing machine full of Josh's carharts. I was not into it." --Sockmonkey
defied
I've Got Gills
Posts: 2057
Joined: Wed Sep 17, 2008 8:14 pm

Re: Calculate tank volume?

Post by defied »

airsix wrote:No dunce cap. I was sitting here thinking I probably misunderstood and was making a fool of myself.

I suggest naming the variables something like:

$ratedCapacity
$ratedPressure
$actualPressure
$1, $2, and $3 don't work for you? 0]
So set the <cf> to be the ratedCapacity? That makes sense. I will be able to fit this into a case structure better depending on command line variables given.

Here, this should be a little cleaner:

Code: Select all

[root@Deathbydoornails ~]# ./tankVolume.sh 95 3000 2640
Actual Capacity is: 107.7000 Cubic feet.
[root@Deathbydoornails ~]# cat tankVolume.sh
#!/bin/bash
if [ "$1" == '' ]
then
        echo "Usage - tankVolume.sh <rateCapacity> <actualPressure> <ratedPressure>"
        exit 1
else
        ratedCapacity=$1
        actualPressure=$2
        ratedPressure=$3
        run=$ratedCapacity/$ratedPressure
        cfPsi=$(echo "scale=4; ${run}" | bc)
        run1=$actualPressure*$cfPsi
        actualCapacity=$(echo "scale=4; ${run1}" | bc)
        echo "Actual Capacity is: "$actualCapacity" Cubic feet."
fi
[root@Deathbydoornails ~]#
Thanks Ben!

D(B)
User avatar
airsix
I've Got Gills
Posts: 3049
Joined: Mon Jan 22, 2007 7:38 pm

Re: Calculate tank volume?

Post by airsix »

Code: Select all

"Usage - tankVolume.sh <rateCapacity> <actualPressure> <ratedPressure>"
That's cool. I like that what you see in the usage statement makes sense to the user, and it does the math correct. That's all that counts. : )

-Ben
"The place looked like a washing machine full of Josh's carharts. I was not into it." --Sockmonkey
User avatar
lamont
I've Got Gills
Posts: 1212
Joined: Thu Jul 20, 2006 7:00 pm

Re: Calculate tank volume?

Post by lamont »

Pez7378 wrote:
Paulicarp wrote:is it safe to overfill that tank to 3000psi, or did that shop make a dangerous mistake?

I've read that some tanks marked with a + are safe to overfill by 10% why is that true for some tanks and not others?
I've seen tanks filled to 3900 psi before. :pale: I'm not too keen on the Hydro test, but I bet it's way above and beyond anything the shops can do to them. Sean, they're fine.
I've had my low-pressure aluminum 14 that has a rated fill pressure of 2050 psi filled to 3000 psi before.

That's like filling an LP steel (2640) tank to 4000 psi or a standard Al80 to 4500 psi.

Still that is just a hydro test pressure and tanks should be able to take even that a few times accidentally, and a 2650 service pressure tank filled to 3000 psi isn't really going to matter (particularly with steel tanks):
(iii) Cycle Test. Three cylinders must be cycle
tested to destruction to an upper cyclic pressure
of 1.5 times service pressure. The successive
hydrostatic pressurizations from the lower cyclic
pressure to the upper cyclic pressure must not
exceed a rate of ten cycles per minute. Adequate
recording instrumentation must be provided if
equipment is to be left unattended for any period
of time. Lower cyclic pressure must not exceed 10
percent of the upper cyclic pressure. Cylinders
must withstand at least 10,000 cyclic
pressurizations without distortion or failure.
The failure must occur in the sidewall and the
failure mode must be leak before burst (LBB). At
least one cylinder must be cycled using water as
the pressurizing medium.
Post Reply