Statistical Thermodynamics and Rate Theories/Lagrange multipliers

From Wikibooks, open books for an open world
Jump to navigation Jump to search

Constrained Optimization[edit]

When constraints are imposed on a system, Lagrange multipliers can be incorporated to determine the maximum of the multivariable function. The new process for determining maximum of this function within the constraint becomes:

  1. Write the constraint as a function. i.e.,
  2. Define a new equation. where is an undefined constant
  3. Solve this set of equations to find the maximum, using the previous three steps for determining the maximum of an unconstrained system.

For example, suppose we have a function and we impose the following constraint upon the function:

The constraint would be written as

We would then define the new equation following the constraint as

Next, we take the partial derivative with respect for both x and y, set it to zero, and solve for x and y.

First of all taking the partial derivative with respect for x set to zero:

Evaluating this will give:

Now, the partial derivative with respect for y set to zero will be taken:

This leads to the following system of equations that can be solved to determine the maximum:

From Solving this set of equations the maximum subjected to the constraint of is found to be:

Unconstrained Optimization[edit]

Determining the maximum of an unconstrained system follows very similar steps it just will not have a lagrange multiplier as the system is not subjected to the

maximum along a given line, rather the maximum of the system itself. The steps to solve an unconstrained system becomes:

  1. Calculate the partial derivatives
  2. set them to zero
  3. solve for the variables

For example given the same function of first the partial derivatives will be calculated to be:

Let both partial derivatives be zero:

Finally the variables will be solved for. Giving a maximum that is different than that of the constrained system: