1-Visitor
September 10, 2011
Solved
Unexpected 'undefined variable' error?
- September 10, 2011
- 1 reply
- 1623 views
I expect this is something stupid I've done, but I can't see what.The attached file accepts the variable 'z until the last line. Why?
Prior to your problem with z; x and y are predefine vectors, but z was always input as a scalar in the functions.
Up to the point of your problem, the variable z was never assigned a value, out side of an argument list.
In the last equation cf does not have an argument list (x,y,z), which I think you want. At least you need cf(z)=
Since the vectors x and y were defined prior to the function definition, they do not actually have to be in the argument list, unless you want to use the functions again with different x and y vectors.
No account yet? Create an account
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.