Understanding and Implementing the Finite Element Method