Computational Statics and Dynamics: An Introduction Based on the Finite Element Method