The calculus of variations has not only made a full application in physics, mathematics or engineering, but many other fields of scientists or experts have also used it solve the problems they face by building mathematical models. This paper first introduces the history of calculus of variations, and then explains the Euler equations which are needed to solve the simplest functional extreme problem. Finally we use it to solve five problems: 1. The mechanical problem of swinging and vibrating of a suspended spring; 2. The "two" basic experimental law in the geometric optics - law of reflection and the law of refraction both in a curved interface; 3. How to arrange speed distribution of a sprinter for the best running performance; 4. In the consideration of both production and storage costs, a mathematical model is proposed to produce a specific number of products within a deadline and to minimize costs.