Legendre's Condition/Lemma 2
 == Lemma == Let $ h$ be a real function such that: :$h \in C^1 \openint a b$ :$\map h a = 0$ :$\map h b = 0$ Let: :$\displaystyle \delta^2 J \sqbrk {y; h} = \int_a^b \paren {\map P {x, \map y x} h'^2 + \map Q {x, \map y x} h^2} \rd x$ where $P \in C^0 \closedint a b$.  Then a necessary condition for: :$\delta^2 J \sqbrk {y; h} \ge 0$  is: :$\forall x\in\closedint a b: \map P {x, \map y x} \ge 0$ == Proof == Assume that above is not true. Then: :$\paren {\exists x_0 \in \closedint a b} \land \paren {\exists \beta \in \R_{<0} }: \map P {x_0} = -2 \beta$ $P$ is continuous. Thus: :$\exists \alpha \in \R_{>0}: \paren {a \ge x_0 - \alpha} \land \paren {x_0 + \alpha \ge b}$ and: :$\forall x \in \openint {x_0 - \alpha} {x_0 + \alpha}: \map P x < -\beta$ In other words: $\map P x \begin {cases} = 0 & : x \in \closedint a {x_0 - \alpha} \lor \closedint {x_0 + \alpha} b \\ < 0 & : x \in \closedint {x_0 - \alpha} {x_0 + \alpha} \end {cases}$ Let :$h = \begin {cases} \sin^2 \paren {\dfrac {\map \pi {x - x_0} } \alpha} & : x_0 - \alpha \ge x \ge x_0 + \alpha \\ 0 & : \text {otherwise} \end{cases}$ It belongs to $C^1 \openint a b$ because: {{explain|The derivation and significance of all the below: what they mean, what depends on what, etc.}} {{begin-eqn}} {{eqn | l = \lim_{x \to x_0 - \alpha + 0^+} h       | r = \lim_{x \to x_0 - \alpha + 0^+} \map {\sin^2} {\frac {\map \pi {x - x_0} } \alpha} }} {{eqn | r = \map {\sin^2} {\map \pi {\frac {0^+} \alpha - 1} } }} {{eqn | r = 0 }} {{end-eqn}} {{begin-eqn}} {{eqn | l = \lim_{x \to x_0 - \alpha + 0^+}h'       | r = \lim_{x \to x_0 - \alpha + 0^+} \map \sin {\frac {2 \map \pi {x - x_0} } \alpha} \frac \pi \alpha }} {{eqn | r = \map \sin {2 \map \pi {\frac {0^+} \alpha - 1} } \frac \pi \alpha }} {{eqn | r = 0 }} {{end-eqn}} {{begin-eqn}} {{eqn | l = \lim_{x \to x_0 - \alpha + 0^+}h''       | r = \lim_{x \to x_0 - \alpha + 0^+} \map \cos {\frac {2 \map \pi {x - x_0} } \alpha} \frac {2 \pi^2} {\alpha^2} }} {{eqn | r = \map \cos {2 \map \pi {\frac {0^+} \alpha - 1} } \frac {2 \pi^2} {\alpha^2} }} {{eqn | r = \frac {2 \pi^2} {\alpha^2} }} {{end-eqn}} {{begin-eqn}} {{eqn | l = \lim_{x \to x_0 + \alpha + 0^-} h       | r = \lim_{x \to x_0 + \alpha + 0^-} \map {\sin^2} {\frac {\map \pi {x - x_0} } \alpha} }} {{eqn | r = \map {\sin^2} {\map \pi {\frac {0^-} \alpha + 1} } }} {{eqn | r = 0 }} {{end-eqn}} {{begin-eqn}} {{eqn | l = \lim_{x \to x_0 + \alpha + 0^-}h'       | r = \lim_{x \to x_0 - \alpha + 0^-} \map \sin {\frac {2 \map \pi {x - x_0} } \alpha} \frac \pi \alpha }} {{eqn | r = \map \sin {2 \map \pi {\frac {0^-} \alpha + 1} } \frac \pi \alpha }} {{eqn | r = 0 }} {{end-eqn}} {{begin-eqn}} {{eqn | l = \lim_{x \to x_0 + \alpha + 0^-}h''       | r = \lim_{x \to x_0 - \alpha + 0^-} \map \cos {\frac {2 \map \pi {x - x_0} } \alpha} \frac {2 \pi^2} {\alpha^2} }} {{eqn | r = \map \cos {2 \map \pi {\frac {0^-} \alpha + 1} } \frac {2 \pi^2} {\alpha^2} }} {{eqn | r = \frac {2\pi^2} {\alpha^2} }} {{end-eqn}} In other words, only $h$ and $h'$ are continuous in $\closedint a b$ Then: {{begin-eqn}} {{eqn | l = \int_a^b \paren {P h'^2 + Q h^2} \rd x       | r = \int_{x_0 - \alpha}^{x_0 + \alpha} P \frac {\pi^2} {\alpha^2} \map {\sin^2} {\frac {2 \map \pi {x - x_0} } \alpha} \rd x + \int_{x_0 - \alpha}^{x_0 + \alpha} Q \map {\sin^4} {\frac {\map \pi {x - x_0} } \alpha} \rd x }} {{eqn | o = <       | r = -\beta \frac {\pi^2} {\alpha^2} \int_{x_0 - \alpha}^{x_0 + \alpha} \map {\sin^2} {\frac {2 \map \pi {x - x_0} } \alpha} \rd x + \max_{a \le x \le b} \size {\map Q x} \int_{x_0 - \alpha}^{x_0 + \alpha} \map {\sin^4} {\frac {\map \pi {x - x_0} } \alpha}\rd x       | c = as $\displaystyle \map P x < -\beta, \quad \map Q x < \max_{a \mathop \le x \mathop \le b} \size {\map Q x}$ }} {{eqn | r = -\beta \frac {\pi^2} \alpha + \max_{a \mathop \le x \mathop \le b} \size {\map Q x} \int_{x_0 - \alpha}^{x_0 + \alpha} \map {\sin^4} {\frac {\map \pi {x - x_0} } \alpha} \rd x }} {{eqn | r = -\beta \frac {\pi^2} \alpha + \frac 3 4 \alpha M  }} {{end-eqn}} where: :$\displaystyle M = \max_{a \mathop \le x \mathop \le b} \size {\map Q x}$ For sufficiently small $\alpha$ the  is negative. Hence, $\delta^2 J$ is negative for the corresponding $h$. To conclude, it has been shown that :$P \ge 0 \quad \neg \forall x \in \closedint a b \implies \delta^2 J<0$ Then, by contrapositive statement this is equivalent to: :$\forall x \in \closedint a b: \delta^2 J \ge 0 \implies P \ge 0$  == Sources == {{BookReference|Calculus of Variations|1963|I.M. Gelfand|author2 = S.V. Fomin|prev = Legendre's Condition/Lemma 1|next = Definition:Conjugate Point}}: $\S 5.25$: The Formula for the Second Variation. Legendre's Condition