Post Reply 
New Sum of Powers Log Function
04-01-2021, 11:05 PM
Post: #19
RE: New Sum of Powers Log Function
(04-01-2021 06:05 PM)Namir Wrote:  Does any of your previous analysis and approximations work on the following variants of the SopLog summations?

It depends on the function, and its argument. Euler–Maclaurin might not work.

Example, on your sdSum (I think you meant range(n,1,-1), or range(2,n+1) in reverse)
Code:
exact = lambda x,n,scale: 1 + fsum(k**(x*scale**(n-k)) for k in xrange(2,n+1))
guess = lambda x,n,scale: 1 + sumem(lambda k: k**(x*scale**(n-k)), [2,n])

>>> x, n, scale = 0.5, 100000, 0.5
>>> exact(x,n,scale), guess(x,n,scale)
(100337.09650943844, 100318.790872778)

Try a big x, guess is so wrong, it "sumed" negative !

>>> x = 1.5
>>> exact(x,n,scale), guess(x,n,scale)
(31728482.871558648, -38398120.2216635)
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
New Sum of Powers Log Function - Namir - 03-29-2021, 04:53 PM
RE: New Sum of Powers Log Function - C.Ret - 03-29-2021, 08:39 PM
RE: New Sum of Powers Log Function - Namir - 03-30-2021, 11:05 AM
RE: New Sum of Powers Log Function - Gene - 03-30-2021, 01:43 PM
RE: New Sum of Powers Log Function - C.Ret - 03-30-2021, 04:01 PM
RE: New Sum of Powers Log Function - Namir - 03-30-2021, 05:56 PM
RE: New Sum of Powers Log Function - Namir - 03-31-2021, 01:27 PM
RE: New Sum of Powers Log Function - Namir - 03-31-2021, 02:19 PM
RE: New Sum of Powers Log Function - Namir - 04-01-2021, 06:05 PM
RE: New Sum of Powers Log Function - Albert Chan - 04-01-2021 11:05 PM
RE: New Sum of Powers Log Function - Namir - 04-01-2021, 11:55 PM
RE: New Sum of Powers Log Function - Namir - 04-04-2021, 03:41 PM



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