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 
(42S) OEIS A228297: Generalized meta-Fibonacci Sequence & Others of that Family
09-20-2017, 05:35 AM
Post: #1
(42S) OEIS A228297: Generalized meta-Fibonacci Sequence & Others of that Family
For natural number input N the programme A228297 returns the Nth element of the series

https://oeis.org/A228297

The value 5 should be stored in the variable "5".

The programme calls the two sub-programmes below.

Code:
0.    { 45-Byte Prgm }
1.    LBL “A228297”
2.    ENTER
3.    ENTER
4.    XEQ "IQT5"
5.    - 
6.    LBL 00
7.    ENTER
8.    ENTER
9.    XEQ "A27868"
10.    +
11.    RCL- ST Z
12.    X≥0?
13.    GTO 01
14.    SIGN
15.    -
16.    GTO 00
17.    LBL 01
18.    R↓
19.    END

For natural number input N the programme A27868 returns the Nth element of the series

https://oeis.org/A027868

Code:
0.    { 29-Byte Prgm }
1.    LBL “A27868”
2.    X<> 00
3.    CLX
4.    X<> 00
5.    LBL 00
6.    XEQ "IQT5"
7.    STO+ 00
8.    X≠0
9.    GTO 00
10.    X<> 00
11.    END

For natural number input N the programme IQT5 returns the integer quotient on division by 5.

Code:
0.    { 27-Byte Prgm }
1.    LBL “IQT5”
2.    R↑
3.    STO 01
4.    R↓
5.    STO 02
6.    RCL "5"
7.    MOD
8.    +/-
9.    RCL+ 02
10.    RCL/ "5"
11.    R↑
12.    X<> 01
13.    R↓
14.    END

Storing values other than 5 in "5" produces sequences of the same family, eg

value 2 produces A046699
value 3 produces A120503
value 4 produces A120507
value 7 produces A022898.
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
(42S) OEIS A228297: Generalized meta-Fibonacci Sequence & Others of that Family - Gerald H - 09-20-2017 05:35 AM



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