Hypergeometric function – Perimeter of an Ellipse and other applications (wp34s)
|
12-10-2019, 11:50 PM
(This post was last modified: 12-10-2019 11:55 PM by Gerson W. Barbosa.)
Post: #1
|
|||
|
|||
Hypergeometric function – Perimeter of an Ellipse and other applications (wp34s)
001:LBL A ; Hypergeometric function –> F(a, b; c; z)
002:STOS 01 003:x⇆ Y 004:/ 005:× 006:× 007:RCL X 008:1 009:STO+ Y 010:x⇆ T 011:⇆ ZTYX 012:INC 04 013:INC 03 014:INC 02 015:INC Y 016:RCL× 04 017:RCL/ 02 018:RCL× 03 019:RCL/ Y 020:RCL× 01 021:RCL Z 022:R↓ 023:STO+ Z 024:⇆ TZXY 025:x≠? Y 026:BACK 015 027:RTN 028:LBL B ; Gauss-Kummer –> P = π(a + b)F(-1/2, -1/2; 1; h²) 029:©CONJ ; where h = (a - b)/(a + b) 030:©RCL L 031:x⇆ Y 032:©+ 033:STO I 034:/ 035:x² 036:# 1/2L 037:+/- 038:RCL X 039:# 001 040:R↑ 041:XEQ A 042:RCL× I 043:# π 044:× π 045:RTN 046:LBL C ; Approximation formula using AGM 047:©ENTER; P ~ 2π{a + b - a*b/AGM(a,b) - 2[AGM(a,b) - √(a*b)]} 048:STO+ T 049:RCL× Y 050:√ 051:STO I 052:x⇆ L 053:⇆ ZYXT 054:AGM 055:STO/ Y 056:RCL- I 057:STO+ X 058:+ 059:- 060:# π 061:× 062:STO+ X 063:END Examples: 8 ENTER 9 B -> 53.45328500297187553380768922447455 8 ENTER 9 C -> 53.45328500297(5636) 2 ENTER 3 B -> 15.86543958929058979133166302778306 2 ENTER 3 C -> 15.865439(6104) Note: if a/b > 3, where a is the semi-major axis, then Cayley’s method (not implemented here) is more efficient. Please refer to this paper for more details: http://web.tecnico.ulisboa.pt/~mcasquilh...llipse.pdf —— A couple of hypergeometric function identities: ln(1 + x) = xF(1, 1; 2; -x) arcsin(x) = xF(1/2, 1/2; 3/2; x²) Examples: 1 ENTER ENTER 2 ENTER 0.5 A 0.5 +/- * -> -0.69314718056 2 LN + -> 6e-34 0.5 ENTER ENTER 1.5 ENTER 0.25 A 0.5 * -> 0.5235987756 6 * π - -> 1e-32 |
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 2 Guest(s)