Cache the result of _hecke_tp_psum_alst and _hecke_tp2_sum_alst.
Modified partition_weighted.