Simplest Variational Problem

Problem
Let $\map F {x, y, z}$ be a function of a differentiability class $C^2$ all its arguments.

Let $y: \R \to \R$ be a continuously differentiable function for $x \in \sqbrk {a, b}$ such that


 * $\map y a = A$


 * $\map y b = B$

Then among all functions $y$ find the one for which the functional


 * $\displaystyle J \sqbrk y = \int_a^b \map F {x, y, y'} \rd x$

has a weak extremum.