Non-linear MHD simulations of pellet triggered ELMs in JET and ASDEX upgrade tokamaks