Question: I am attempting to set up a loop for a summation, but result is always zero!



y = 0;

0 = 0

 

`\`if'`(0 = 0, x, 0 = Float(infinity))

 

0, 0

 

`\`if'`(1 = 0, x, 0 = -1.)

 

1, 0

 

`\`if'`(2 = 0, x, 0 = .5000000000)

 

2, 0

 

0.

(1)

``



Download lattsum1.mw

In preparation for a more extensive 3D lattice summation, I have set up the simple loop above.  But this always evaluates to zero!  What is my fault?

Leslie

Please Wait...