1d Finite Element Method Matlab Code