Module:Sequence: Difference between revisions

Plumtree (talk | contribs)
m Typo
ArrowHead294 (talk | contribs)
mNo edit summary
 
(8 intermediate revisions by 2 users not shown)
Line 1: Line 1:
local p = {}
local p = {}
local getArgs = require('Module:Arguments').getArgs


function p.contains(seq, n)
function p.contains(seq, n)
Line 12: Line 14:
return false
return false
end
end
function p.get_term(frame)
local args = getArgs(frame)
return p._get_term(args[1], tonumber (args[2]))
end
function p._get_term(seq, n)
local sequences = {
["odd_limit_diff"] = p.odd_limit_diff,
["zeta_peak"] = p.zeta_peak,
["zeta_integral"] = p.zeta_integral,
["zeta_gap"] = p.zeta_gap,
["square_superparticulars"] = p.square_superparticulars
}
return sequences[seq][n]
end
-- OEIS A072451
-- Number of odd terms in the reduced residue system of 2*n-1
-- Corresponds to the number of new interval pairs between the (2n-3)-odd-limit
-- and the (2n-1)-odd-limit, assuming the 1-odd-limit has 1 "pair" of intervals.
p.odd_limit_diff = {
1, 1, 2, 3, 3, 5, 6, 4, 8, 9,
6, 11, 10, 9, 14, 15, 10, 12, 18, 12,
20, 21, 12, 23, 21, 16, 26, 20, 18, 29,
30, 18, 24, 33, 22, 35, 36, 20, 30, 39,
27, 41, 32, 28, 44, 36, 30, 36, 48, 30,
50, 51, 24, 53, 54, 36, 56, 44, 36, 48,
55, 40, 50, 63, 42, 65, 54, 36, 68, 69,
46, 60, 56
}


-- OEIS A117536
-- OEIS A117536
Line 20: Line 53:
1012, 1106, 1178, 1236, 1395, 1448, 1578, 2460, 2684, 3395, 5585, 6079, 7033, 8269, 8539,
1012, 1106, 1178, 1236, 1395, 1448, 1578, 2460, 2684, 3395, 5585, 6079, 7033, 8269, 8539,
11664, 14348, 16808, 28742, 34691,
11664, 14348, 16808, 28742, 34691,
-- unconfirmed data from [[The Riemann zeta function and tuning#Zeta EDO lists]]
-- unconfirmed data from [[The Riemann zeta function and tuning #Zeta EDO lists]]
36269, 57578, 58973, 95524,
36269, 57578, 58973, 95524,
102557, 112985, 148418, 212147, 241200
102557, 112985, 148418, 212147, 241200
}
p.zeta_peak_integer = {
0, 1, 2, 3, 5, 7,
10, 12, 19, 22, 31, 41, 53, 87,
118, 130, 171, 224, 270, 311, 472, 494, 742,
1065, 1106, 1395, 1578, 2460, 2684, 3566, 4231, 4973, 5585, 8269, 8539,
14124, 14348, 16808, 28742, 30631, 34691, 36269, 57578, 58973
}
}