There are indeed more efficient computations; the best so far is one that avoids factoring. If mertens0 is the expression in the appended msg and mertens2 is the one that avoids factoring, then the time-space numbers are:
mertens0 1e6 6.68734 8.59231e7 mertens2 1e6 0.183586 1.20705e7 http://www.jsoftware.com/jwiki/Essays/Mertens_Function ----- Original Message ----- From: Roger Hui <[EMAIL PROTECTED]> Date: Monday, September 17, 2007 13:55 Subject: Re: [Jprogramming] Mobius function To: Programming forum <[email protected]> > The Mertens function of n is the sum of Mobius k for k from 1 to n. > There should be a more efficient computation of it than > > +/ @: (mobius"0) @: >: @ i. > > http://en.wikipedia.org/wiki/Mertens_function > http://en.wikipedia.org/wiki/Mobius_function ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm
