Community Tip - Want the oppurtunity to discuss enhancements to PTC products? Join a working group! X
I need some help with a code I am writing.
I am getting an error
"This array index is invalid for this array"
attached is the code
Solved! Go to Solution.
Attached is that sheet. Could you please look through it. I think I am doing something wrong with the for loop but I might be wrong.
It's only a simple typo. At the begin of your i-loop you have written Y[i+i which should be Y[i+1.
I think it might be because you have assigned the new value to Δudotdoti instead of udotdoti at the end of the for loop.
Stuart
You were right Stuart.
The reason I got confused was that I had a similar mathcad sheet (actually a complex version of what I sent earlier) which did not have the "udotdoti "error you caught but still showed similar error "This array index is invalid for this array"
Attached is that sheet. Could you please look through it. I think I am doing something wrong with the for loop but I might be wrong.
Appreciate your help.
For what ever reason, changing the range variable in your uuu() function from i to something else let the program work. (I don't understand why.)
Attached is that sheet. Could you please look through it. I think I am doing something wrong with the for loop but I might be wrong.
It's only a simple typo. At the begin of your i-loop you have written Y[i+i which should be Y[i+1.