I am new to optimization in particular so I think what I am looking for is vocabulary to describe a particular area of problems. In many (all?) optimization algorithms you need to take the gradient of the objective function at various points in the algorithm.
Many examples I find assume you already know the objective function, but, I assume, in most interesting problems you only have resultsinputs and outputs of the objective function (trainingtesting and training data set). So how do you go from just the results of the function to the gradient of a function? I guess you could use regression analysis or slope of data points, but what are the common techniques (pros and cons) in optimization?