When I remove or comment the line containing \draw (ptad1)--(ptg1);, I don't obtain any error.
I think that the error is due to the "foreach" command: when I suppress the \foreach command and I write the command manually (for each step of the foreach command), I don't have any error.

Please reduce your code to something more readable, i.e. a MWE. Typically this lets you discover your own mistakes. But the error stems from \foreach not expanding the arguments of the macros, thus it searches for a point named iteru\nuuu and not iteru0, iteru1 etc. There are several similar questions on this site. And welcome!
–
zerothJul 12 '13 at 12:29

I get several errors before the Undefined control sequence one; please, fix the code.
–
egregJul 12 '13 at 12:36

@zeroth both points (ptad1) and (ptg1) don't depend of the content of the \foreach command and without the \draw (ptad1) -- (ptg1). So I don't understand why tikz crashes in this case. I will try to simplify my code but currently the easiest solution is to suppress the \foreachcommand.
–
GuukJul 12 '13 at 12:40