a fem and sem implement for wave propagation