(12C) Body Surface Area
07-28-2021, 04:34 AM (This post was last modified: 07-28-2021 12:32 PM by Gamo.)
Post: #1
 Gamo Senior Member Posts: 713 Joined: Dec 2016
(12C) Body Surface Area
This program should be useful for nursing and medical stuff to measure BSA

Program is adapted from HP-46 Sample Applications Section Medicine Page 66

The calculation is from the formula of DuBois D, DuBois EF. 1916
A formula to estimate the approximate surface area if height and weight be known.

Formula: LogA = (0.425 LogW) + (0.725 LogH) - 2.144

A = Body Surface Area in m²
W = Weight in kg.
H = Height in cm.

Weight - 4 kg.
Height - 35 cm.

[ BSA (Child) = 0.170 m² ]

Steps: W [R/S] H [R/S] display A in m²

Program:
Code:
 01    LN 02    1 03    0 04    LN 05    STO 0    // Store Log Base Constant 06    ÷ 07    STO 1   // Store LogW 08    R/S 09    LN 10    RCL 0 11    ÷ 12    . 13    7 14    2 15    5 16    x     // Calculate (0.725 LogH) 17    RCL 1 18    .     // Decimal Point 19    4 20    2 21    5 22    x    // Calculate (0.425 LogW) 23    +   // Add both side together 24    2 25    .    // Decimal Point 26    1 27    4 28    4 29    -    // Subtraction Sign 30    1 31    0 32    X<>Y 33     Y^X    // Calculate LogA 34    GTO 00

Remark:
Today the easiest to calculate and remember is the Mosteller Formula by
taking the square root of the height (cm) mutiplied by the weight (kg) divided by 3600

BSA (m²) = √[ ( height x weight ) ÷ 3600 ]

The answer result accuracy from this formula almost comparible from DuBois formula.

Extra Examples:

What is the BSA for Mr. Joe weighing 210 pounds with a height of 6 feet, 3 inches?

►Calculate weight in kilograms: 210 pounds ÷ 2.2 = 95.45 kg

►Calculate height in centimeters: 6 feet, 3 inches = 75 inches x 2.54 cm/inch = 190.5 cm

95.45 [R/S] 190.5 [R/S] Display Result 2.24 m²

Gamo 7/2021
07-28-2021, 09:01 PM (This post was last modified: 07-28-2021 09:22 PM by C.Ret.)
Post: #2
 C.Ret Member Posts: 218 Joined: Dec 2013
RE: (12C) Body Surface Area
(07-28-2021 04:34 AM)Gamo Wrote:  The calculation is from the formula of DuBois D, DuBois EF. 1916
A formula to estimate the approximate surface area if height and weight be known.

Formula: LogA = (0.425 LogW) + (0.725 LogH) - 2.144

Effectively, the original formula from Delafield DuBois et Eugene F. DuBois publication is $$A = 0.007184 \times H^{0.725} \times W^{0.425}$$.

If we are looking for the decimal logarithm of $$A$$ we get the exact formula that Gamo indicates ; $$\log(A) = 0.425\times\log(W)+0.725\times\log(H)-2.14363$$ where $$-2.14363 \approx \log(0.007184)$$

The only problem here is that there is no decimal logarithm on the HP-12C keyboard. So in the code proposed by Gamo, several divisions by natural logarithm $$\ln(10)$$ are used as a turn around to get the expected $$A = 10^{(0.425\frac{\ln(W)}{\ln 10 }+0.725\frac{\ln(H)}{\ln 10 }- 2.144)}$$.

In order to spare steps and ease computation, I propose to directly compute the body area using the original formula.

Code:
Code:
001-   .725  y^x 006-   x<->y 007-   .425  y^x 012-   × 013-   7184 EEX 6 CHS 020-   ×

Usage:
Press P/R to type the code in program memory. Go back to run mode and reset program to the start by pressing [GTO] 00 or [f][Program].

For each computation :
Type in Weight (in Kg) and press the [ENTER^] key.
Type in Height (in cm) and presse the [ R/S ] key to run code.
The HP-12C display the corresponding Body Surface Area in m².

This shorter code don't use any register or any logarithms. In fact, the logarithms stuff is done secretly by the y^x instructions.
Notice how old style RPN code are strange and 'reversed' as the second entered argument is treated first in the beginning of the code and the first entered argument is used last !
07-29-2021, 12:24 AM (This post was last modified: 07-29-2021 09:23 AM by Gamo.)
Post: #3
 Gamo Senior Member Posts: 713 Joined: Dec 2016
RE: (12C) Body Surface Area
C. Ret
The original formula is really shorter in comparison.
This formula have been modify according to the HP-46 Applications Book.
So I just use that formula but the original formula is more compact.
In the pass, couple user here not recommend to use the [Y^X] if possible becuase
of high risk of accuracy error due to the limit digits on the Voyager series calculator.
But your recommended formula and program is really good short and easy to use.

This program is for the HP-11C or 15C

LBL A LOG .425 x RTN // Enter Weight
LBL B LOG .725 x RTN // Enter Height
LBL C + 2.144 - 10^X RTN // BSA answer in m²

Usage:

Weight [A]
Height [B]

Gamo
07-29-2021, 10:38 AM
Post: #4
 Albert Chan Senior Member Posts: 2,103 Joined: Jul 2018
RE: (12C) Body Surface Area
(07-29-2021 12:24 AM)Gamo Wrote:  In the pass, couple user here not recommend to use the [Y^X] if possible becuase
of high risk of accuracy error due to the limit digits on the Voyager series calculator.

I would have guessed Y^X is more accurate than 10^(X*LOG10(Y)), (or EXP/LN equivalent)
07-30-2021, 02:10 PM (This post was last modified: 07-30-2021 02:16 PM by C.Ret.)
Post: #5
 C.Ret Member Posts: 218 Joined: Dec 2013
RE: (12C) Body Surface Area
(07-29-2021 12:24 AM)Gamo Wrote:  In the pass, couple user here not recommend to use the [Y^X] if possible because of high risk of accuracy error.

That's really true, I remember being trapped by a lost of accuracy of the x^y function last year when trying to adapt a specific algorithm for the HP-65 in a friendly challenge to enumerate rationals as Calkin Wilf Suites at the french Silicium.org forum.

I have had a hard time understanding why a code that was running correctly on my HP-15C Voyager didn't run correctly on Danny's HP-65 calculator.

I like the dynamic of your program for the Voyager series (as well as any HP RPN calculator with user short label A through C :

Code
LBL A LOG .425 x RTN // Enter Weight in Kg
LBL B LOG .725 x RTN // Enter Height in cm
LBL C + 2.144 - 10^X RTN // Display BSA answer in m²

Usage:
Enter Weight and press [A], enter Height and press [B], then [C] display the corresponding BSA
OR
Enter Height and press [B], enter Weight and press [A], then [C] display the corresponding BSA

I like the way parameters are entered with labels A & B (or b & A) filling the stack with parameters and how the computation is achieved by label C. There no mix up with the order the user have to enter Weight or Height. Both order produce the correct answer.
 « Next Oldest | Next Newest »

User(s) browsing this thread: 1 Guest(s)