bugfix: calculating the derivatives w.r.t parameters in jotf_x_p and mB_p.