Why am i get Undefined function or variable 'm'. ERROR ?
Best Answer
The syntax you used is not correct. You can only assign values to variables, not to transformed variables. You have to do your calculation in two steps. First introduce a new variable logm and calculate logm = (log(n)-log(k))/a, then calculate m = exp(logm).
The function was defined before k. When the anonymous function is created, it grabs a static snapshot of the workspace and does not update. To incorporate k, just rerun the command to create the function handle.
Best Answer