Numerical techniques for solving solidification and melting phase change problems