Question: Procedure inside for loop

Hi, I've this problem with maple11; when I try to assigne the elements of any array (Tent in this case) using a procedure inside a for loop: Tent:= array(1..7); for i from 1 to 7 do Tent[i]:= proc(v) global i; christoffel[i] + v^i; end proc; end do; Maple dont understand that the 'i' inside the procedure is the same of the for loop. So after I've execute the for, i is actually 8, and if I write Tent[3](p); maple return christoffel[8]+ p^8 instead I would christoffel[3]+p^3 I've undersand that when I invoke Tent[3] (or Tent[2], etc) maple control the actual value of i (that is 8), so I think this is a problem of scope of the i variable. Someone can tell me how I must do? Tk you S.
Please Wait...