update calc_jphi in gs_solver.cc