I keep getting a syntax error on line 7 of my code and I can't see why.

- Code: Select all
`import math`

total = 0

sign = math.atan(math.sqrt(2) - 1)

for n in xrange(0, 500):

t = (math.pow(sign, ((n * 2) + 1)) / ((n * 2) + 1)

total = total + t

sign = sign * -1

print total * 8

Any help you can give would be appreciated,

lorentz.