calc_pP_resid
Called by: calc_depdp
Includes: iscloc.h
Input arguments:
Pointer to solution structure.
Array of phase structures.
Calls:
Function read_pP_P
add_to_error and handle_error from utils
Structure members updated: pP_resid in phase structure.
Return: 0/1 for success/failure.
This function calculates a pP - P residual for each arrival with a phase
of pP that was reported in a reading with a P phase. It does this
by calculating the difference in arrival times for the two phases and subtracting
the theoretical difference returned by function read_pP_P, which looks it up in tables. The resulting residual is stored in the phase structure as member pP_resid.