Tuesday, August 14, 2018

HP Prime and TI-84 Plus CE: Tetration, Iterated Exponentiation


HP Prime and TI-84 Plus CE: Tetration, Iterated Exponentiation

Introduction

Tetration is iterated exponentiation.  A common notation of tetration is the use of two upward arrows, known as Knuth’s up-arrow notation.  In general:

‘x y = x ^ x ^ x ^ … ^ x   (y times)

Take the x to its own power y times. 

For example:

2 2 = 2 ^ 2 ^ 2 = 2 ^ 4 = 16

3 2 = 3 ^ 3 ^ 3 = 3 ^ 27 = 7625597484987

 4 2 = 4 ^ 4 ^ 4 = 4 ^ 256 =
13407807929942597099574024998205846127479365820592393377723561443721764030073546976801874298166903427690031858186486050853753882811946569946433649006084096
≈ 1.34078078079299 * 10^154

First, thank goodness that the HP Prime can handle really long integers in CAS mode.  Second, you can quickly see how fast the results grow in tetration calculations. 

In order to allow for a larger set of calculations, the programs are provided, where we break down the mantissa and exponents of each result. 

HP Prime Program TETRATION

EXPORT TETRATION(X,Y)
BEGIN
// 2018-08-14 EWS
LOCAL I,M,E,S;
// X^^Y, Y is an integer
M:=MANT(X);
E:=XPON(X);
FOR I FROM 1 TO Y DO
S:=M*ALOG(E)*LOG(X);
M:=ALOG(FP(S));
E:=IP(S);
END;
RETURN {M,E};
END;
  
TI-84 Plus CE Program TETRATION

"EWS 2018-08-14"
Disp "TETRATION X^^Y","Y: INTEGER"
Prompt X,Y
10^(fPart(X))→M
iPart(log(X))→E
For(I,1,Y)
M*10^(E)*log(X)→S
10^(fPart(S))→M
iPart(S)→E
End
Disp M,"*10^",E


Source:

“Knuth’s Up-Arrow Notation” Wikipedia.  Last edited August 9, 2018.  Retrieved August 14, 2018.  https://en.wikipedia.org/wiki/Knuth%27s_up-arrow_notation

Eddie

All original content copyright, © 2011-2018.  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.  Please contact the author if you have questions.

Monday, August 13, 2018

HP 35S: Trapezoid Analysis (Daniel Pedro Levia)


HP 35S: Trapezoid Analysis (Daniel Pedro Levia)

Have some time to squeeze in a post.  Much thanks to Daniel Pedro Levia.

Introduction

Given the trapezoid below:






The following are calculated:

Midsegment length:  (A + B)/2

Height: √( (-A+B+C+D)(A-B+C+D)(A-B+C-D)(A-B-C+D) )/(2 * abs(B-A))

Area:  M * H

You can see the HP Prime and Casio fx-CG50 programs here:  https://edspi31415.blogspot.com/2017/06/


HP 35S Program: Trapezoid – Pedro Daniel Leiva

Here is the program for the HP 35S, written by Pedro Daniel Levia.   The program is listed with permission of the author.

Variables Used:

R_A = length of side A
R_B = length of side B
R_C = length of side C
R_D = length of side D
R_H = height
R_M = mid-length
R_K = area
R_P = perimeter

Program:

T001 LBL T
T002 STO D
T003 R ↓
T004 STO C
T005 R ↓
T006 STO B
T007 R ↓
T008 STO A
T009 SQRT((-A+B+C+D)*(A-B+C+D)*(A-B+C-D)*(A-B-C+D))/(2*ABS(B-A)) // EQN
T010 STO H
T011 (A+B)/2  // EQN
T012 STO M
T013 STOP   // R/S
T014 RCL M
T015 RCL H
T016 ×
T017 STO K
T018 A+B+C+D  // EQN
T019 STO P
T020 RTN

20 steps

Instructions:  Enter the length of all four sides then run the program.

A [ENTER] B [ENTER] C [ENTER] D [XEQ] T [ENTER]

The height and midlength are shown first (Y and X stack, respectively).  Press [R/S] to get the area and perimeter.

Example:

A = 400
B = 350
C = 125
D = 106

Results:

Height:  104.3032
Midlength: 375.0000
Area:  39113.7186
Perimeter:  981.0000

  
Eddie


 All original content copyright, © 2011-2018.  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.  Please contact the author if you have questions.

Thursday, August 9, 2018

HP Prime and TI-84 Plus CE: Mercator Sailing Course and Distance

HP Prime and TI-84 Plus CE: Mercator Sailing Course and Distance

Introduction

The following program MERCATOR calculates the course direction and distance in miles given two pairs of latitude (north/south) and longitude (east/west).  Conversion to arc minutes will be required during calculation.

Formulas Used:

Course:

C = atan ( | λ2 – λ1 | * 60 / | M2 – M1 | )
Where:
M1 = 7915.7045 * log ( tan (45° + L1 / 2 ) ) – 23.2689 * sin L1
M2 = 7915.7045 * log ( tan (45° + L2 / 2 ) ) – 23.2689 * sin L2

Direction:


D = | L2 – L1 | * 60 / cos C

HP Prime MERCATOR

EXPORT MERCATOR()
BEGIN
// EWS 2018-08-10
// The Calculator Afloat

HAngle:=1; // degrees
LOCAL L1,L2,λ1,λ2,M1,M2;
LOCAL C,D;

INPUT({L1,λ1,L2,λ2},"Mercator",
{"L1:","λ1:","L2:","λ2:"},
{"Latitude 1",
"Longitude 1",
"Latitude 2",
"Longitude 2"});

M1:=7915.7045*LOG(TAN(45+L1/2))
-23.2689*SIN(L1);
M2:=7915.7045*LOG(TAN(45+L2/2))
-23.2689*SIN(L2);

LOCAL M;
C:=ABS(λ1-λ2)*60;
M:=ABS(M2-M1);
C:=ATAN(C/M);

D:=ABS(L2-L1)*60/COS(C);

RETURN {C,D};

END;

TI-84 Plus CE Program MERCATOR

Degree
Input "LATITUDE 1:",A
Input "LONGITUDE 1:",B
Input "LATITUDE 2:",C
Input "LONGITUDE 2:",D
7915.7045*log(tan(45+A/2))-23.2689*sin(A)→E
7915.7045*log(tan(45+C/2))-23.2689*sin(C)→F
abs(D-B)*60→R
abs(F-E)→M
tan^-1(R/M)→R
abs(C-A)*60/cos(R)→S
Disp "COURSE:",R,"DISTANCE:",S

Example

Latitude 1:  102° 54’ 16” W = 102.9044444444°
Longitude 1: 43° 21’ 16” N = 43.3544444444°
Latitude 2:  106° 3’ 8” W = 106.0522222222°
Longitude 2: 42° 4’ 30” N = 42.075°

Results:

Course:  5.782390957°

Distance:  189.832588 mi

Source: 

Henry H. Shufeldt and Kenneth E. Newcomer  The Calculator Afloat: A Mariner’s Guide to the Electronic Calculator Naval Institute Press:  Annapolis, Maryland.  1980


I will be taking a few weeks off this August, it will be part vacation, part math research.  I plan to come back during the week of 8/20/2018.  I may have one more post before the break, especially if a calculator I ordered comes in time for a review.  Anyway, stay safe, sane, and for those of you in the Northern Hemisphere, cool.  Weather wise, this summer has been bonkers.

Eddie

All original content copyright, © 2011-2018.  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.  Please contact the author if you have questions.

Wednesday, August 8, 2018

HP 35S: Intersection Point of a Quadrilateral


HP 35S: Intersection Point of a Quadrilateral

Introduction

Let A, B, C, and D be four vertices of a quadrilateral, with two lines:

Line AC connects points A and C.
Line BC connects points B and D.



Designate the following points as:

A:  (ax, ay)
B:  (bx, by)
C:  (cx, cy)
D:  (dx, dy)

The center point (px, py) can be found by the following formulas:

px = (IBD – IAC)/(SAC – SBD)
py = SAC * px + IAC

Where:

Slope:
SAC = (cy – ay) / (cx – ax)
SBD = (dy – by) / (dx – bx)

Intercept:
IAC = ay – SAC * ax
IBD = by – SBD * bx

You can see the derivation of these formulas here:  https://edspi31415.blogspot.com/2017/08/geometry-intersection-point-of.html

Program  (Pedro Daniel Leiva)

The following program calculates the point – developed by Pedro Daniel Leiva. I used the recall arithmetic available on the HP 35S to shorten the program.  Program listed here with permission. 

Variables Used:

R_A = ax
R_B = ay
R_C = bx
R_D = by
R_E = cx
R_F = cy
R_G = dx
R_H = dy
R_I = SAC
R_J = SBD
R_K = IAC
R_L = IBD
R_P = px
R_Y = py

Program:

I001 LBL I
I002 SF 10
I003 ENTER XA^YA  \\ EQN
I004 STO B
I005 x<>y
I006 STO A
I007 ENTER XB^YB  \\ EQN
I008 STO D
I009 x<>y
I010 STO C
I011 ENTER XC^YC \\ EQN
I012 STO F
I013 x<>y
I014 STO E
I015 ENTER XD^YD  \\ EQN
I016 STO H
I017 x<>y
I018 STO G
I019 CF 10
I020 RCL F
I021 RCL - B     \\ [RCL] [ - ] ( B )
I022 RCL E
I023 RCL - A  \\ [RCL] [ - ]  ( A ) 
I024 ÷
I025 STO I
I026 STO P  \\ advanced storage to calculate px to save steps
I027 RCL× A
I028 +/-
I029 RCL+ B
I030 STO K
I031 RCL H
I032 RCL - D
I033 RCL G
I034 RCL – C
I035 ÷
I036 STO J
I037 STO – P
I038 RCL × C
I039 +/-
I040 RCL + D
I041 STO L
I042 RCL – K
I043 RCL ÷ P
I044 STO P
I045 ENTER
I046 RCL × I
I047 RCL + K
I048 STO Y
I049 x<>y
I050 RTN

50 steps

Instructions:

At each prompt, enter the x point, press [ENTER], enter the y point, press [ R/S ].  The result shows py on the Y stack, and px on the X stack.

Example:

A:  (0, 8)
B:  (11, 12)
C:  (10, 4)
D:  (3, 5)

Results:

py = 6.2353
px = 4.4118

Eddie


 All original content copyright, © 2011-2018.  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.  Please contact the author if you have questions.

Saturday, August 4, 2018

Mental Math and Some Numerical Musings


Mental Math and Some Numerical Musings

Working with mathematics for a real long time, everything from doing this blog, programming, watching a lot of game shows, and being asked about prices after discounts, I picked up a few mental math pointers.  I don’t claim to be a mental math prodigy (those kids that get featured who are, are amazing).

Mentally Adding 9

Mentally adding 9 involves one of two cases:

If the last digit is 0, change it to a 9. 

Example:  1820 + 9.  The last digit now becomes a 9.  Hence: 1820 + 9 = 1829.

If the last digit isn’t a 0, then add 10, then subtract 1. 

Example:  1821 + 9 = 1821 + 10 – 1 = 1831 – 1 = 1830

Example:  1827 + 9 = 1827 + 10 – 1 = 1837 – 1 = 1836

You can do a similar trick with adding 18 and 27.  To add 18:  add 20 then subtract 2.  To add 27:  add 30 then subtract 3. 

Example: Add 18 to 1827, then 27 to the resulting sum. 

(mentally) 1827 + 18 + 27 = 1827 + 20 – 2 + 30 – 3 = 1847 – 2 + 30 – 3 = 1845 + 30 – 3 = 1875 – 3 = 1872

It’s like give to the tens digit, take from the ones digit.

Mentally Multiplying and Dividing by 10

Mentally, it’s a matter of moving the decimal point.  When multiplying by 10, move the decimal right (and fill in a zero if necessary).  Dividing by 10 will cause the decimal point to move to the left. 


Example:  58.238 * 10

Move the decimal point to the right and get the answer:  582.38 

Example:  58.238 ÷ 10

Move the decimal point to the left and get the answer:  5.8238

The 10% Discount

Need to find out the discount when something is 10% off?  Fairly simple, just recognize that 10% is multiplying by 0.1, which is dividing by 10.  Mentally, move one decimal point to the left.

Example:  What is 10% of $38.99?   Multiplying by 10% is the same as dividing by 10, hence move the decimal point to the left, and we get the answer:  $3.899 or rounding to the nearest cent, $3.90. 

The 10% Tip

How about if we add 10% to an amount?  Note that adding 10% is equivalent to multiplying the number by 1.10.  Let n be the number, and:

n + 10% = n * 1.1 = n * 1 + n * 0.1 = n + n ÷ 10

Example:  If a restaurant bill is $32.00 and we needed to find the total cost after adding 10% tip:

32.00 + 10% = 32.00 + 32.00 ÷ 10 = 32.00 + 3.20 = 35.20

Dividing a Number by 5

To mentally divide a number by 5, double the number and divide the result by 10.  Why does this work? 

n ÷ 5 = n * (2 ÷ 10) because the fraction 2/10 is equal to 1/5. 

Example:  Divide 64 by 5. 

Step 1:  Double 64.  Now we have 128.
Step 2:  Divide by 10.  Move the decimal point left.  (think that we starting with 128.0).  The result is 12.8.

Multiplying a Number by 5

To mentally multiply a number by 5, multiply the number by 10 and then half the result.  Observe that for any number n:

n * 5 = n * (10 ÷ 2) = (n * 10) ÷ 2

Example:  Multiply 753 by 5.

(mentally) 753 * 5 =  753 * 10 ÷ 2 = 7530 ÷ 2 = 3765



Dividing Whole Numbers by 3, Will It Divide Evenly?

The way we can tell if a whole number divides by 3 evenly (no remainder, the quotient is also a whole number) is that if the sum of all its digits is also divisible by 3.

Example:  780, 1959, 4839, and 55101 are all divisible by 3.  Why?

780:  7 + 8 + 0 = 15; 15 is divisible by 3.  Also, 1 + 5 = 6.  (780 ÷ 3 = 360)

1959: 1 + 9 + 5 + 9 = 24; 2 + 4 = 6.  Divisible by 3.  (1959 ÷ 3 = 653)

4839: 4 + 8 + 3 + 9 = 24.   Divisible by 3.  (4839 ÷ 3 = 1613)

55101: 5 + 5 + 1 + 0 + 1 = 12  (1 + 2 = 3).  Divisible by 3.  (55101 ÷ 3 = 18367)

Dividing by 7

I have not memorized this.  However, something interesting when you divide numbers that are not multiples of 7 happens: 

1/7 = 0.142857142…
2/7 = 0.285714285…
3/7 = 0.428571428…
4/7 = 0.571428571…
5/7 = 0.714285714…
6/7 = 0.857142857…

8/7 = 1.142857142…
9/7 = 1.285714285…
10/7 = 1.428571428…
11/7 = 1.571428571…
12/7 = 1.714285714…
13/7 = 1.857142857…

The decimal portion always follows the pattern 1, 4, 2, 8, 5, 7.  So the next time you divide a whole number by 7 and figure the remainder, you can figure out which part of the pattern to attach if your answer is required as a decimal answer:

If R* = 1; the pattern starts at 1:  142857 142857 142857… (and repeat)
If R = 2; the pattern starts at 2:  2857 142857 142857…
If R = 3; the pattern starts at 4:  42857 142857 142857…
If R = 4; the pattern starts at 5:  57 142857 142857…
If R = 5; the pattern starts at 7:  7 142857 142857…
If R = 6; the pattern starts at 8:  857 142857 142857…

* R: remainder

Example:  1720 ÷ 7.  The division results as 245 with the remainder of 5.  The decimal patter starts at 7, hence 1720 ÷ 7 = 245.7142857142857…

Squaring Any Integer That Ends in 5

Why does squaring every whole number ending in 5 results in the square ending with 25?

Check it out:

5^2 = 25
15^2 = 225
25^2 = 625
35^2 = 1225
45^2 = 2025
55^2 = 3025
65^2 = 4225
185^2 = 34225
(feel free to use a calculator to check for other numbers)

Let n be a whole number whose last digit is 5.  (n = {5, 15, 25, 35, 45, ... 155 … }).  Then:

n^2
= (n – 5 + 5)^2

Let ϕ = n – 5.   Observe that ϕ is multiple of 10.  (Example:  If n = 25, then ϕ = 25 – 5 = 20)

Then:
n^2
= (ϕ + 5)^2
= ϕ^2 + 10 * ϕ + 25

Note that ϕ^2 and 10*ϕ will be multiples of 100.

The mental trick given when squaring a whole number ending in 5 is:

Step 1: Spilt the number into two parts, separating the last digit 5 from the rest of the number.  Treat the detached as a separate number. 

Step 2:  Square the detached number and the detached number to the result.

Step 3:   “Attach” a 25 to the right side of the result.

Example:  25^2. 

Step 1: “Split and detach” the number:  2 | 5

Step 2:  Square the detached number and add the detached number to the result: 
2^2 + 2 = 6

Step 3:  “Attach” a 25 to the right side of result:  625

Hence:  25^2 = 625

If we use the formula:  n = 25, ϕ = 25 – 5 = 20:

Then 25^2 = 20^2 + 10 * 20 + 25 = 400 + 200 + 25 = 625

Example:  215^2

Step 1:  “Detach”:  21 | 5

Step 2:  Square detached, add the detached to the result:  21^2 + 21 = 441 + 21 = 462

Step 3:  “Attach” a 25 to the right end:  46225

215^2 = 46225

If we use the formula:  n = 215, ϕ = 215 – 5 = 210

Then 215^2 = 210^2 + 10 * 210 + 25 = 44100 + 2100 + 25 = 46225

I hope you find this helpful.  This is some of the math I can do mentally (except I haven’t memorized the 142857 pattern when dividing numbers by 7), it comes with practice and patience.  Of course, it doesn’t hurt to check for accuracy.

Happy August,

Eddie


 All original content copyright, © 2011-2018.  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.  Please contact the author if you have questions.

Friday, July 27, 2018

HP Prime: 3D Graphs July 2018 Gallery


HP Prime:  3D Graphs July 2018 Gallery

All graphs are made with the initial rangers x = [-4, 4], y = [-4, 4], and z = [-4, 4] rotated at different angles.  The function variable for 3D graphs for the HP Prime is FZ# (# is 0-9).  


 z = cos (xy) * cos(2xy) * cos(3xy)

z = e^(-sin(2xy)*cos(xy)/2)

z = cos y * (e^(-x^2/2) – e^(x^2/8))

z = sin(x*y) * cos(x*y) + sin(x*y)^2 * cos(x*y)

z = x^4 * y * cos(x*y) * e^(x*y)

z = ± (x^2 – y^2)

z = ± |sin(x*y) – cos(x*y) + x* e^y| 
z = y^2 * sin x * Γ(x/6)

z = x * sin(|x^2 + y^2|)
Until next time, have a great weekend and see in you August!

Eddie


 All original content copyright, © 2011-2018.  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.  Please contact the author if you have questions.


Wednesday, July 25, 2018

HP Prime: Firmware Update (13865, date 2018.07.06)


HP Prime:  Firmware Update (13865, date 2018.07.06)




There is a new update to the HP Prime firmware.  The new version is 13865. 

You can find the file and details here:

Details and file: 




I haven’t had much chance to work with the new firmware, however according to the release information, some of the highlights are:

* There is a new red indicator when the HP Prime’s power reaches below 10%.

* All integrals in HOME mode will calculate numerical results.  Previously results are returned in either numerical or exact answers.  Exact answers will still be provided in CAS mode.

* You can control the amount of time until the HP Prime dims its screen.  The screen is dimmed when you do nothing on the calculator after a set amount of time.  The time is set in milliseconds as a base integer (30,000 in decimal or 7530_16 in hexadecimal).  The variable is TDim found in the Vars-Setting menu. 

* The command EVAL is said to now help INPUT with local variables.  I haven’t played around with this yet. 

* Updated CAS and improvements


As a note, there the HP Prime now gets a new processor G2.   To find out what hardware version you have, press [Help], press the soft key (Tree), scroll up, select About HP Prime.  I have hardware revision C.  The threads on the MoHPC site goes into more details.  The reason why I mention this is if you have trouble updating your HP Prime, the firmware files may need to be in a new folder.  The folder is:

Hardware C (and I’m assuming this will work for A):
(your drive) \HP Connectivity Kit\Firmware\PrimeG1

Thank you to HP and HP Museum of Calculators! 

Happy Computing,

Eddie

All original content copyright, © 2011-2018.  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.  Please contact the author if you have questions.

Monday, July 23, 2018

Algebra: Multiplying a * b Trick (Using the Difference between a and b)


Algebra:  Multiplying a * b Trick (Using the Difference between a and b)

Can we find a formula to find products where two values are an equal-distant apart

The Values of a and b Differ by 2

Let a and b be real numbers which differ by 2, that is b – a = 2.  Here I am assuming that b > a. 

Let n be the midpoint between a and b.  That is:

n = b – 1 and
n = a + 1

Therefore:

b = n + 1
a = n - 1

Then:

a * b
= (n - 1) * (n + 1)
= n^2 - n + n – 1
= n^2 - 1

Example:  51 * 49

Notice that:

51 – 49 = 2, and
51 - 1 = 50
49 + 1 = 50

Hence:

51 * 49 = 50^2 – 1 = 2499

Can we expand this included products of a * b, where the difference is b – a = 2 * w

The Values of a and b Differ by 2*w

Let’s look at a more general case. 

Let b – a = 2*w

Then:

b = n + w and a = n – w

Then:

a * b
= (n – w) * (n + w)
= n^2 – n*w + n*w – w^2
= n^2 – w^2

Example:  37 * 43.

43 – 37 = 6
w = 6/2 = 3
Then:
n = 43 – 3 = 37 + 3 = 40

Then:

37 * 43 = 40^2 – 3^2 = 1600 – 9 = 1591


Try another example:  57 * 49

57 – 49 = 8
8 / 2 = 4
57 – 4 = 53, 49 + 4 = 53

Then:

57 * 49 = 53^2 – 4^2 = 2809 – 16 = 2793


In summary for a * b with b > a.

Let w = (b – a)/2 and n = a + w or n = b – w

Then a * b = n^2 – w^2

Eddie

All original content copyright, © 2011-2018.  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.  Please contact the author if you have questions.

Wednesday, July 18, 2018

Fun with the FX-603P Emulator


Fun with the FX-603P Emulator





Author for the Emulator:  Martin Krischik



Cost: $5.99 (there is an fx-602P scientific calculator emulator for $4.99, similar programming language but only 10 programming spaces instead of 20)

The app is emulates the 1990 Casio fx-603P calculator.


[up to five/six programs]

Decibels to Pressure

Program: (29 steps)

“DB?”  HLT  ÷ 20  = 10^x  *  2E-5  = “Pressure:” HLT

Examples:

DB = 30 dB; Result:  6.32455532 * 10^-4 N/m^2

DB = 120 dB; Result:  20 N/m^2

Turn Performance

Given a plane’s true air speed (TAS in knots), stall speed (in knots), and required bank turn (in degrees), the following are calculated:

1. G force
2.  Normal stall speed for the plane during the turn (knots)
3.  Turn diameter (nautical miles)
4.  Time it takes for the turn to be complete (in minutes)

Formulas:

G = 1/(cos(bank))

Stall speed = normal stall speed * G

Diameter = TAS^2 / (34208 * tan(bank))

Time = (0.0055 * TAS) / tan(bank)

Memory Registers:

Input:

M00 = TAS, M01 = Stall speed, M02 = Bank

Output:

M03 = G force, M04 = resulting stall speed, M05 = diameter, M06 = time

Program: (110 steps)

DEG “TAS?” HLT Min00
 “Norm. Stall?” HLT  Min01
 “Bank?” HLT Min02
MR02 cos 1/x Min03 “G:” HLT
MR03 √ * MR01 = “Stall Speed:” HLT
MR00 x^2 ÷ ( MR02 tan * 34208 ) = Min05 “Diameter:” HLT
0.0055 * MR00 ÷ MR02 tan “Time:” HLT Min06

Notes: 
DEG:  [ MODE ] [ 4 ]


Example:

Inputs:
TAS: 123 knots
Norm. Stall:  60 knots
Bank:  44.8°

Results:
G:  1.409302674
Stall Speed: 71.22843498 knots
Diameter:  0.445363387 n.m.
Time: 0.681239424 minutes (about 40.87 seconds)

Source:  “Turn Performance” HP 65 Aviation Pac-1 Hewlett Packard.  1974
.

Sum of a Function

This program uses the subroutine (under P9 with the variable MinF, or any register M04 or after) to calculate the summation:

Σ f(x) for x = a to b

The sum is stored in M03.

Note: when entering a new f(x), clear P9 (MODE, 3, P9, AC) first before entering the new function.  It’s a lot cleaner.

Main Program:  (34 bytes)

0 Min03
“a?” HLT Min01
“b?” HLT Min02
MR02 – MR01 + 1 = Min00
Lbl0
MR01 GSBP9 M+03
1 M+01
DSZ Goto0
MR03 “Σ=”

Note: 
Lbl0:  [ LBL] [ 0 ]
GSBP9: [GSB] [ P9 ]
Goto0:  [ GOTO ] [ 0 ]
The character Σ:  (in ALPHA) [SHIFT] [ 7 ]
Memory F:  [ Min ], [ MR ], etc.  [EXE] for F.

Examples:

Σ n^2 + 3*n – 6 for n = 1 to 8 
Subroutine:
Min0F x^2 + 3 * MR0F – 6 =

Result:  264

Σ (n^3 – 1)/(n^2 + 1) for n = 0 to 11
Subroutine:
( Min0F x^y 3 – 1 ) /div (MR0F x^2 + 1 ) =

Result: 61.6582396282

Combinations: where Repetition is allowed

The program calculates the number of combinations where repeats are allowed.

nHr = (n + r – 1)! / (r! * (n -1)!)

Program:  (39 steps)

“n?” HLT Min01
“r?” HLT Min02
( MR01 + MR02 – 1) x!
÷ ( MR02 x! * ( MR01 – 1 ) x! )
= “nHr=”

Examples:

Input: n = 5, r = 3.  Result:  35

Input: n = 12, r = 6.  Result:  12376

Aviation:  Rate of Climb

This program calculates the rate-of-climb (ft/min) when plane increases the elevation (in feet) given the distance to the mountain (in nautical miles, n.m.) and the true air speed (TAS, in knots). 

Formula:

ROC = ( TAS * ΔALT  ) / (60 * (dist^2 + (ΔALT/6077.1155)^2) )

Program: (88 steps)

6077.1155 Min0F
“TAS (knots)?” HLT Min01
“CHG ALT (ft)?” HLT Min02
“DIST (n.m.)?” HLT Min03
( MR01 * MR02 ) ÷
( 60 * ( MR03 x^2 + (
MR02 ÷ MR0F ) x^2
)   √ = “ROC:”

Example:

Input:
TAS = 87 knots
CHG ALT = 4800 ft
DIST = 13.3 n.m.

Result:
522.3878955 ft/min

Source:  “Rate of Climb and Descent” HP 65 Aviation Pac-1 Hewlett Packard.  1974

Eddie


All original content copyright, © 2011-2018.  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.  Please contact the author if you have questions.

HP Prime and TI-84 Plus CE: Tetration, Iterated Exponentiation

HP Prime and TI-84 Plus CE: Tetration, Iterated Exponentiation Introduction Tetration is iterated exponentiation.   A common nota...