How to add discrete function constraints to a calculus of variations problem

43 Views Asked by At

Suppose that $L$ is the Lagrangian of a system and $f$ is a function of $x$. The objective is to find a function $f$ that optimises:

$J[f] = \int{L(x, f, f')}dx$

How do you fix the value of $f(x)$ at certain values of $x$ for a variational problem? I want the solution $f$ to have certain pre-determined values: $f(x_i)=y_i$ for defined values of $x_i$ and $y_i$.

It seems that the Lagrange multiplier method is mainly used for continuous constraints.

1

There are 1 best solutions below

0
On

You can implement those constraints as boundary conditions. If you have $n\geq 2$ constraints $f(x_i)=y_i$ $(x_1<x_2<\ldots<x_n)$, write the functional as $$ J[f]=\sum_{i=1}^{n-1}J_i[f]=\sum_{i=1}^{n-1}\int_{x_i}^{x_{i+1}}L(x,f,f')\,dx, $$ and for each $J_i[f]$ solve the Euler-Lagrange equation subject to the boundary conditions $f(x_i)=y_i,$ $f(x_{i+1})=y_{i+1}$.