The equations which involve an integral isare called a functional functional and for extremum of functional, euler lagrangeEuler Lagrange equations are used. For example the functional could be integral√(1-(dy/dx)^2dx$\int \sqrt{(1-(dy/dx)^2}dx$ which is the functional for a length of any curve y, using euler lagrangeEuler Lagrange equations,we we can show that the equation is a straight line which means the extromumextremum for distance is a straight line.