Analysis and modelling of plasma response to pellet injection in RFX