On Tue, Jan 20, 2009 at 4:22 PM, Raouf <raouf.o...@gmail.com> wrote: > > Hi, > Recently, i wrote this program to Sage vmware-Windows, but i have the > error Traceback (most recent call last)!!! >
Can you please attach the code in a .txt file as an email attachment, or attach a sage worksheet? I tried just pasting the code into notebook, and just get a syntax error. > " > > borneSup=103196184763 > > S=0 > Bm=0 > > alpha=1 > p=2 > m1=2 > > while (p^alpha)<=borneSup: > > while (p^alpha) <=borneSup: > > m1=p^alpha > if gcd(m1,6)==1: > > > mangoldt=ln(p)/( m1^(3/2) ) > > > x=PolynomialRing(QQ,'x').gen() > f=gen_laguerre(n-1,1,x) > j=log(m1) > Lg=float(f(j)) > > > M = ModularSymbols(6,2) > > if gcd(p,6)==1: > > if alpha ==1: > T1 = M.hecke_operator(p) > Bm=T1.trace() > > if alpha>=2: > > T1 = M.hecke_operator(p^alpha) > trace1=T1.trace() > T2 = M.hecke_operator(p^(alpha-2)) > trace2=T2.trace() > > Bm=trace1-((p)*trace2) > > > S=S+(mangoldt*Bm*Lg) > > > alpha=alpha + 1 > Bm=0 > > alpha=1 > p=next_prime(p) > > > print "S=",float(S) > > " > p= 571 ^ 3=186169411 > > Traceback (most recent call last): alpha=alpha + 1 > File "/usr/local/sage/local/lib/python2.5/site-packages/sage/ > calculus/calculus.py", line 4797, in __float__ > return self._convert(float) > File "/usr/local/sage/local/lib/python2.5/site-packages/sage/ > calculus/calculus.py", line 4777, in _convert > fops = [typ(op) for op in self._operands] > File "/usr/local/sage/local/lib/python2.5/site-packages/sage/ > calculus/calculus.py", line 4797, in __float__ > return self._convert(float) > File "/usr/local/sage/local/lib/python2.5/site-packages/sage/ > calculus/calculus.py", line 4777, in _convert > fops = [typ(op) for op in self._operands] > File "/usr/local/sage/local/lib/python2.5/site-packages/sage/ > calculus/calculus.py", line 4797, in __float__ > return self._convert(float) > File "/usr/local/sage/local/lib/python2.5/site-packages/sage/ > calculus/calculus.py", line 4777, in _convert > fops = [typ(op) for op in self._operands] > File "/usr/local/sage/local/lib/python2.5/site-packages/sage/ > calculus/calculus.py", line 4797, in __float__ > return self._convert(float) > File "/usr/local/sage/local/lib/python2.5/site-packages/sage/ > calculus/calculus.py", line 4777, in _convert > fops = [typ(op) for op in self._operands] > File "/usr/local/sage/local/lib/python2.5/site-packages/sage/ > calculus/calculus.py", line 4797, in __float__ > return self._convert(float) > File "/usr/local/sage/local/lib/python2.5/site-packages/sage/ > calculus/calculus.py", line 4777, in _convert > fops = [typ(op) for op in self._operands] > File "/usr/local/sage/local/lib/python2.5/site-packages/sage/ > calculus/calculus.py", line 4797, in __float__ > return self._convert(float) > File "/usr/local/sage/local/lib/python2.5/site-packages/sage/ > calculus/calculus.py", line 4777, in _convert > fops = [typ(op) for op in self._operands] > File "/usr/local/sage/local/lib/python2.5/site-packages/sage/ > calculus/calculus.py", line 4797, in __float__ > return self._convert(float) > File "/usr/local/sage/local/lib/python2.5/site-packages/sage/ > calculus/calculus.py", line 4777, in _convert > fops = [typ(op) for op in self._operands] > File "/usr/local/sage/local/lib/python2.5/site-packages/sage/ > calculus/calculus.py", line 4797, in __float__ > return self._convert(float) > . > . > . > . > . > " > > :-( > ??? > > > > > -- William Stein Associate Professor of Mathematics University of Washington http://wstein.org --~--~---------~--~----~------------~-------~--~----~ To post to this group, send email to sage-support@googlegroups.com To unsubscribe from this group, send email to sage-support-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/sage-support URLs: http://www.sagemath.org -~----------~----~----~----~------~----~------~--~---