The script steepestdescent.m optimizes a general multi variable real valued function using steepest descent method. During the iterations if optimum step length is not possible then it takes a fixed step length as 0.001. For the theory any good book on optimization techniques can be consulted. This script is also useful in checking whether a given function is convex or concave and hence globally optimizable.

I am new to MatLab and was wondering how would I enter the following function in "proper format" since I try with no avail. I could appreciate some idea on how to do that. The functions itself is:

Not a function, so it pollutes the Command Window workspace. Prompts the user for all input including the function to be optimized! Does not require symbolic math toolbox as stated. Has at least one triple nested For loop. Does not appear to use any vectorization.

Why not write this as an m file? I'm not sure what the symbolic toolbox buys you. 3 stars only because you used a toolbox I have no need for and no intention of buying.