Tampilkan postingan dengan label HP 32S. Tampilkan semua postingan
Tampilkan postingan dengan label HP 32S. Tampilkan semua postingan

HP 32S and HP 32SII Week: Maximum, Minimum , Histogram

HP 32S and HP 32SII Week:  Maximum, Minimum , Histogram 





Introduction


The program takes data and determines:


*  maximum of the data set (X)

*  minimum of the data set (Y)

*  bin width using Scott's normal rule (h, see formula below)

*  number of bins (k, rounding is not included)


Scott's normal rule:

h = 3.49 * sx / (n^(1/3))


Number of bins:

k = (max - min) / h

In practice, take the ceiling of k.


Instructions


1.  Enter the first data point.

2.  Press XEQ D  (execute label D)

3.  Enter the next data point, press R/S.  Repeat until the last data point.

4.  Press XEQ C 


HP 32S/32SII Program:  Maximum, Minimum, Bin Width, Number of Bins

Total Size (labels D, S, C): 61.5, plus 48 bytes for statistical data

(D: 6.0, S: 18.0, C:  37.5)



D01 LBL D  // data

D02 CLΣ

D03 STO X

D04 STO Y


S01 LBL S

S02 RCL X

S03 x<>y

S04 x>y?

S05 STO X

S06 RCL Y

S07 x<>y

S08 x<y?

S09 STO Y

S10 Σ+

S11 STOP

S12 GTO S


C01 LBL C

C02 RCL X

C03 STOP

C04 RCL Y

C05 STOP

C06 -

C07 49

C08 1

C09 %   // C07 - C09: build 0.49 in 4.5 bytes instead of 9.5 bytes

C10 3

C11 +

C12 Sx

C13 ×

C14 n

C15 3

C16 1/x

C17 y^x

C18 ÷

C19 STO H

C20 STOP

C21 RCL X

C22 RCL- Y

C23 RCL÷ H

C24 STO K

C25 STOP


Example


Data Set:

4.0

5.8

5.7

5.2

4.6

4.9

6.3

7.1

6.6

6.4


4 XEQ D

5.8 R/S

5.7 R/S

...

6.4 R/S

XEQ C


X:  max:  7.1

Y:  min:  4

h:  1.58387549541

k:  1.95722454763  (2 bins)


Source:


"Histogram"  Wikipedia.  Last Updated March 28, 2022. https://en.wikipedia.org/wiki/Histogram  Last Accessed March 31, 2022.  


Up next:  a review of the HP 45 - May 9, 2022


Eddie 


All original content copyright, © 2011-2022.  Edward Shore.   Unauthorized use and/or unauthorized distribution for commercial purposes without express and written permission from the author is strictly prohibited.  This blog entry may be distributed for noncommercial purposes, provided that full credit is given to the author. 


HP 32S and HP 32SII Week: Jurin's Law - Capillary Rise

HP 32S and HP 32SII Week:  Jurin's Law - Capillary Rise 





Capillary Motion 


Jurin's law describes the motion of liquid in small tubes, as the height is inversely proportional to the tube's diameter (and radius).  Factors include the contact angle and the density of the liquid.


The height of the liquid is determined by:


h = (2 * σ * cos θ) / (ρ * g * r)


σ = surface tension of the liquid (N/m)  (T)

θ = the angle of liquid in degrees, from adhesive (0° to 90°) to cohesive (90° to 180°) (B)

ρ = density of liquid (kg/m^3) (D)

r = radius of the tube (m) (R)


HP 32S and HP 32SII: Jurin's Law

Size:  33.5 bytes


J01 LBL J

J02 DEG

J03 INPUT T

J04 INPUT B

J05 INPUT D

J06 INPUT R

J07 2

J08 RCL× T

J09 RCL B

J10 COS

J11 ×

J12 RCL D

J13 RCL× R

J14 9.80665

J15 ×

J16 ÷

J17 STOP


Example:

Find the capillary rise of water in a tube with radius of 0.1 m.   

Data:  σ = 0.0728 N/m, θ = 0°, and ρ = 1000 kg/m^3


Inputs:

T = 0.0728

B = 0

D = 1000

R = 0.1


Result:  1.48470681E-4 m  (height)


Source:


"Jurin's law" Wikipedia.  Last updated February 11, 2022.  https://en.wikipedia.org/wiki/Jurin%27s_law  Last Accessed April 1, 2022.  


Lindeburg, Michael R. PE   Civil Engineering Reference Manual for the PE Exam 14th Edition  Professional Publications, Inc:  Belmont, CA.  pp. 14-11 to 14-13


Eddie


All original content copyright, © 2011-2022.  Edward Shore.   Unauthorized use and/or unauthorized distribution for commercial purposes without express and written permission from the author is strictly prohibited.  This blog entry may be distributed for noncommercial purposes, provided that full credit is given to the author. 


HP 32S and HP 32SII Week: Total Drag

HP 32S and HP 32SII Week:  Total Drag





Introduction


The following equation calculates the total drag force applied to parallel to an area in the opposite direction of the object's motion.  


Fd = 1/2 * ρ * v^2 * Cd * A,   ρ = P / (R * T)


ρ = air pressure 

P = absolute pressure (101,325 Pa, 14.696 psi, 2116.224 lb/ft^2)

R = specific gas constant (287.03 J/(kg k), 53.3533 (ft lbf/lb °R))

T = temperature (K = °C + 273.15, °R = °F + 459.67)


A = cross area that the drag force is applied (m^2, ft^2)

V = velocity of the object (m/s, ft/s)

Cd = drag coefficient (unitless)


The program gives outputs:


ρ = air pressure (kg/m^3, lb/ft^3)

Fd = total drag (kg*m/s^2, lb*ft/s^2)


HP 32S/32SII Program:  Total Drag, SI Units

Size: 55.5 bytes


F01 LBL F

F02 INPUT C

F03 INPUT A

F04 INPUT V

F05 INPUT T

F06 273.15

F07 +

F08 287.03

F09 ×

F10 1/x

F11 101,325

F12 ×

F13 STOP

F14 RCL× C

F15 RCL× A

F16 RCL V

F17 x^2

F18 ×

F19 2

F20 ÷

F21 STOP


Example:

C = drag coefficient = 0.31

A = area =7.0686 m^2

T = temperature = 18.8 °C

V = velocity = 3 m/s


Results:

ρ = 1.20915184207 kg/m^3

Fd = 11.9230799416 kg*m/s^2


HP 32S/32SII Program:  Total Drag, US Units

Size: 55.5 bytes


F01 LBL F

F02 INPUT C

F03 INPUT A

F04 INPUT V

F05 INPUT T

F06 459.67

F07 +

F08 53.3533

F09 ×

F10 1/x

F11 2116.224

F12 ×

F13 STOP

F14 RCL× C

F15 RCL× A

F16 RCL V

F17 x^2

F18 ×

F19 2

F20 ÷

F21 STOP


Example:

C = drag coefficient = 0.31

A = area =76.0868 ft^2

T = temperature = 65.84 °F

V = velocity = 9.84252 ft/s


Results:

ρ = 7.54778228E-2 lb/ft^3

Fd = 86.232900381 lb*ft/s^2



Source:


Lindeburg, Michael R. PE   Civil Engineering Reference Manual for the PE Exam 14th Edition  Professional Publications, Inc:  Belmont, CA.  pp. 17-41 and 17-42


All original content copyright, © 2011-2022.  Edward Shore.   Unauthorized use and/or unauthorized distribution for commercial purposes without express and written permission from the author is strictly prohibited.  This blog entry may be distributed for noncommercial purposes, provided that full credit is given to the author. 


HP 32S and HP 32SII Week: Hypergeometric Distribution

 HP 32S and HP 32SII Week:  Hypergeometric Distribution





What are the Odds?


The hypergeometric probably function deals with taking samples without replacement.  The trials are not independent.  The probability formula is:


G(S; N, T, M) =

1 ÷ nCr(N, M) * nCr(T, S) * nCr(N-T, M-S)


S = number of successes

N = main population size

T = target's population size

M = sample size


nCr(x, y) = x! ÷ ( y! * (x - y)!)


HP 32S/32SII Program:  Hypergeometric Distribution Probability

Size: 30 bytes


H01 LBL H

H02 INPUT S

H03 INPUT N

H04 INPUT T

H05 INPUT M

H06 RCL N

H07 RCL M

H08 Cn,r

H09 1/x

H10 RCL T

H11 RCL S

H12 Cn,r

H13 ×

H14 RCL N

H15 RCL- T

H16 RCL M

H17 RCL-S

H18 Cn,r

H19 ×

H20 STOP


Examples:


What are the odds that four hearts are dealt out of a five card hand?  Assume a standard, 52 card deck.


S = 4 (4 hearts)

N = 52 (52 cards)

T = 13 (13 hearts)

M = 5 (5 card hand)


Result:  1.07292917E-2 (≈1.07%)


What are the odds that a pair of Kings are dealt out of a five card hand?  Assume a standard, 52 card deck.


S = 2 (2 Kings)

N = 52 (52 cards)

T = 13 (13 hearts)

M = 5 (5 card hand)


Result:  3.99298181E-2 (≈3.99%)


Source:


"Hypergeometric Distribution"  Texas Instruments Programmable Slide-Rule SR-56 Applications Library  pp. 58-59 Texas Instruments, 1976


Download the document here, with gratitude to Datamath:

http://www.datamath.net/Manuals/SR-56_AL_US.pdf


Eddie



All original content copyright, © 2011-2022.  Edward Shore.   Unauthorized use and/or unauthorized distribution for commercial purposes without express and written permission from the author is strictly prohibited.  This blog entry may be distributed for noncommercial purposes, provided that full credit is given to the author. 


HP 32S and HP 32SII Week: Richter Scale

HP 32S and HP 32SII Week:  Richter Scale





Richter Scale


The equation calculates the massive energy given by a earthquake given the earthquake's magnitude by the Richter scale:


E = 10^(11.3 + 1.8 * M), where E is in ergs

 

with conversions:


Ergs to Joules:  multiply by 1 * 10^-7


Ergs to ft-lbs:  multiply by 7.3756 * 10^-8




Equation Modifications



Energy of an earthquake, given by Richter scale, in Joules (SI units):


E = 10^(4.3 + 1.8 * M)




Energy of an earthquake, given by Richter scale, in Foot-Pounds (US units):


E ≈ 10^(4.1678 + 1.8 * M)




HP 32S/32SII Program:  Earthquake Energy - SI Units

Size: 13.5 bytes


R01 LBL R

R02 18

R03 ×

R04 43

R05 +

R06 10

R07 ÷

R08 10^x

R09 STOP


Example:  3.4 Magnitude


Result:  26,302,679,919 J


Notes:


*  In general, each step takes 1.5 bytes.  


*  Integers 0 to 99 (HP 32S) and 0 to 254 (HP 32SII) takes 1.5 bytes while all other real numbers takes 9.5 bytes.  It could be advantageous to build numbers out of small integers than enter real number constants.  Using a real constant uses 6 steps.  


* It's supposed to be advantageous to end programs with STOP (R/S) than RTN. 



HP 32S/32SII Program:  Earthquake Energy - US Units

Size: 21.5 bytes


R01 LBL R

R02 18

R03 ×

R04 10

R05 ÷

R06 4.1678

R07 +

R08 10^x

R09 STOP


Example:  3.4 Magnitude


Result:  19,399,922,723.9 ft-lbs



Source:


Young, G.B.  "Earthquake Magnitude - Energy Conversation"  Hewlett-Packard HP-674/HP-97 User's Library Solutions:  Earth Sciences  Hewlett Packard:  Corvallis, OR.  pp. 1-4 February 1978


Download the document here, with gratitude to hpcalc.org:

https://literature.hpcalc.org/items/1015


Eddie


All original content copyright, © 2011-2022.  Edward Shore.   Unauthorized use and/or unauthorized distribution for commercial purposes without express and written permission from the author is strictly prohibited.  This blog entry may be distributed for noncommercial purposes, provided that full credit is given to the author. 

 

Backlink 9999 Traffic Super

Order Now...!!!!