Post Reply 
(42S) Area and Eccentricity of an Ellipse
07-10-2016, 02:01 AM
Post: #1
(42S) Area and Eccentricity of an Ellipse
HP 42S: Area and Eccentricity of an Ellipse

The program ELLIPSE calculates the area and eccentricity of an ellipse.

Formulas:
Assume a>b, where a and b represent the lengths of semi-diameters, respectively
Area: A = π*a*b
Eccentricity: ϵ = √(1 – (b/a)^2)

Code:
00 {76-Byte Prgm}
01 LBL “ELLIPSE”
02 “LARGE S-D:”  \\ S-D:  semi-diameter
03 PROMPT
04 STO “A”
05 “SMALL S-D:”  
06 PROMPT
07 STO “B”
08 RCL “A”
09 RCL* “B”
10 PI  \\ π 
11 *
12 “AREA:”
13 AVIEW
14 PSE
15 STOP \\ R/S
16 1
17 RCL “B”
18 RCL÷ “A”
19 X^2
20 –
21 SQRT
22 “ECC:”
23 AVIEW
24 PSE
25 END
Visit this user's website Find all posts by this user
Quote this message in a reply
Post Reply 




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