I am new to Mathcad, and trying to determine how to calculate a lagrange function. Is there an automatic way to determine all the partials or do I have to calculate them separately? Can anyone point me to an example.
Although I owned an ancient version of MathCad (Windows 3.1), I find that much about the new version is very different. I am still experimenting.
Here is an idea that might help. I am not sure that I have deduced the formula that you are trying to work with, but the method may work for whatever you have in mind.
If, by a Lagrange function, you mean the method of Lagrange multiplies, then the "naive" approach seems to work just fine:
1 - define an operator "Lagrange" on two symbols, f and phi 2 - when you have a function f to optimize with constraint phi, you ask for the symbolic version of the result of substituting f and phi into the Lagrange operator 3 - you may also ask to solve the result for lambda.