Numerical simulations of waves in a magnetically structured atmosphere