HP Forums
(27S) OEIS A137442 & A167390 - Printable Version

+- HP Forums (https://www.hpmuseum.org/forum)
+-- Forum: HP Software Libraries (/forum-10.html)
+--- Forum: General Software Library (/forum-13.html)
+--- Thread: (27S) OEIS A137442 & A167390 (/thread-17894.html)



(27S) OEIS A137442 & A167390 - Gerald H - 01-05-2022 11:44 AM

A137442 is the series starting with 1 of alternating smallest previously unlisted square followed by smallest previously unlisted integer, ie

1,2,4,3,9,5,16,6,25,7,36,8,49,10......

A167390 gives the partial sums of A137442, ie

1,3,7,10,19......

Enter the equation below in Solver: enter an integer N & actuate key NTH, the nth member of the series will be displayed.

RCL ∑1toN to see the partial sum of the first N members of A137442.

Do not actuate key ∑1toN, it can only be used to RCL a value.

Code:
NTH = IF(L(H:MOD(N:2))+
0*L(C:L(M:IDIV(N:2))+
RND(SQRT(G(M)):0)) = 1:
SQ(G(M)+1):
G(C))+
0*(L(∑1toN:L(F:L(G(M)+G(H))*
(1+G(F)*(3+2*G(F)))/6+
G(C)*(G(C)+1)/2-
L(E:IP(SQRT(G(C))))*
(G(E)+1)*(G(E)+0.5)/3))*∑1toN