unfinished testing code, implemented tps_fit_decomp which evaluates the tps cost plus a linear term