Given a functional
$$J(y)=\int_a^b F(x,y,y')dx, \tag{1}$$

where $y$ is a function of $x$, and a constraint
$$\int_a^b K(x,y,y')dx=l, \tag{2}$$
if $y=y(x)$ is an extreme of (1) under the constraint (2), then there exists a constant $\lambda$ such that $y=y(x)$ is also an extreme of the functional
$$\int_a^b [F(x,y,y')+\lambda K(x,y,y')]dx. \tag{3}$$
Similarly, if the constraint is
$$g(x,y,y')=0, \tag{4}$$
then there exists a function $\lambda(x)$ such that the extreme also holds for the functional
$$\int_a^b [F(x,y,y')+\lambda(x)g(x,y,y')]dx. \tag{5}$$

This is known as the Lagrange multiplier rule for calculus of variations. However, I have two questions about this statement.

- If the functional (1) has two constraints (2) and (4), does the extreme also hold for the functional $$\int_a^b [F(x,y,y')+\lambda K(x,y,y') +\lambda(x) g(x,y,y')]dx ? \tag{6}$$
- Is this statement also valid for multiple variable case? For example, if $J=\iint F(x_1,x_2,y(x_1,x_2))dx_1 dx_2$, and $\iint K(x_1,x_2,y(x_1,x_2))dx_1 dx_2=l$, is this equivalent to $J=\iint F(x_1,x_2,y(x_1,x_2))+\lambda K(x_1,x_2,y(x_1,x_2))dx_1 dx_2$?

Thanks in advance and any suggestion will be appreciated. It is better if you have any reference.