MAINT: speed up the expm frechet by not checking the rate matrix form every time in the inner loop