Numerical model framework of power quality events