The following warnings occurred:
Warning [2] count(): Parameter must be an array or an object that implements Countable - Line: 795 - File: showthread.php PHP 7.4.33 (FreeBSD)
File Line Function
/showthread.php 795 errorHandler->error





Post Reply 
(12C+) Bernoulli Number
07-27-2019, 06:41 AM (This post was last modified: 07-28-2019 06:08 AM by Gamo.)
Post: #1
(12C+) Bernoulli Number
In need of the Bernoulli Number using HP-12C ?

Here is an attempt to generate a Bernoulli Number constant using 12C

Without a Pi function this program use 355/113 which give out about

4 to 5 digits precision.

-------------------------------------------------
To run:
If you need to know B10 divide it by 2 is 5

5 [R/S] display 0.07576 [R/S] 5 [X<>Y] 66

Answer: B10 is 0.07576 or in fraction is 5/66
--------------------------------------------------
B12

12 ÷ 2 = 6

6 [R/S] display 0.25311 [R/S] 61 [X<>Y] 241

Answer:
B12 since 12 is divisible by 4 answer is Negative

-0.25311 in fraction is -61/241
--------------------------------------------------
Remark:
To find B(n) divide it by 2 and calculate.
This program do not give answer of the alternate negative value
such as B2 = 1/6 where B4 = -1/30
For B(n) that divisible by 4 answer is "Negative"
--------------------------------------------------
Program:
Code:

2
x
STO 2
355
ENTER
113
÷
STO 3
1
STO 0
STO 1
-----------------
RCL 0  // line 16
2 x 1 +
RCL 2
CHS
Y^X
RCL 1
+
RCL 1
X<>Y
X≤Y
GTO 34
STO 1
1
STO+0
GTO 16
RCL 2  // Line 34
n!
2 x
RCL 1
x 2
RCL 2
Y^X
1 -
RCL 2
RCL 3
X<>Y
Y^X
x ÷  // B(n) constant end here
----------------
R/S  // Line 51
STO 0  // Decimal to Fraction start here
STO 1
0
STO 2
1
RCL 0
INTG  // Line 58
RCL 2
x +
STO 2
RCL 0
x
. 5 // decimal and five // Line 66
+
INTG
STO 3
RCL 2
÷
RND
RCL 0
RND
-  // Subtract sign
X=0
GTO 86
Rv  // Roll Down
RCL 2
X<>Y
RCL 1
FRAC
1/x
STO 1
GTO 58
RCL 2  // Line 86
RCL 3
GTO 00  // Line 88

Formula use to calculate Bernoulli Number

B(n) = [2(2n)! ÷ ((2^2n) - 1)(Pi^2n)] [1 + (1/3^2n) + (1/5^2n) + ...]

Gamo
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
(12C+) Bernoulli Number - Gamo - 07-27-2019 06:41 AM
RE: (12C+) Bernoulli Number - Albert Chan - 07-27-2019, 12:41 PM
RE: (12C+) Bernoulli Number - Gamo - 07-27-2019, 01:40 PM
RE: (12C+) Bernoulli Number - John Keith - 07-27-2019, 07:49 PM
RE: (12C+) Bernoulli Number - Albert Chan - 07-28-2019, 12:02 AM
RE: (12C+) Bernoulli Number - John Keith - 07-28-2019, 11:21 AM
RE: (12C+) Bernoulli Number - Albert Chan - 08-30-2023, 09:46 PM
RE: (12C+) Bernoulli Number - Albert Chan - 09-11-2023, 03:48 PM
RE: (12C+) Bernoulli Number - Albert Chan - 07-28-2019, 01:08 AM
RE: (12C+) Bernoulli Number - Gamo - 07-28-2019, 02:29 AM
RE: (12C+) Bernoulli Number - Albert Chan - 07-31-2019, 05:14 PM
RE: (12C+) Bernoulli Number - Albert Chan - 09-12-2023, 05:59 PM



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