SOLVE PHASE

###
SOLVE PHASE

            CLIC\SOLVE PHASE [/PLOT] [/BREAK kind time [kind time ...]]
            [/POLYNOMIAL degree] [/WEIGHT] [/RESET]

        This  will  fit  a mathematical function into the measured phases of the
        sources in the current index (presumably calibrators).  This  data  must
        have  been selected and plotted in axes : SET X TIME and SET Y PHASE for
        the baselines and bands of interest, specified by the corresponding  SET
        commands.  Phases should be continuous (SET PHASE CONTINUOUS). The cali-
        bration function is kept in memory. Command STORE should be used next to
        store this function in the header of source observations, after a change
        in the index to select the appropriate scans.

        SOLVE PHASE internally and temporarily resets  SET  PHASE  to  ABSOLUTE.
        The INTERNAL|EXTERNAL mode is kept to allow determining a phase curve on
        top of an external receiver reference.

        In antenna mode (selected by SET PHASE ANTENNA), the averaged phase  and
        amplitude  closures  are computed, as well as their standard deviations.
        The phase closures should be close to zero, while the amplitude closures
        should be close to 100%.

        Option  /PLOT  will  plot  the fitted curve over the data. Option /RESET
        will reset the calibration curve in memory.

        Fitted curves may be of two kinds:

          - Cubic splines (the default).  By default knots are regularly  spaced
            with  an  interval between knots set by the SET STEP command.  Addi-
            tional knots may be introduced with the  option  "/BREAK  kind  time
            [kind  time  ...]"   which  introduces  a  break at abscissa 'time';
            'kind' is an integer in the range 0-3; 0 means that a  discontinuity
            will  be present, 1 that the first derivative will be discontinuous,
            and so on.  Several breaks may be introduced. The program  will  de-
            tect  an  error  if  too many breaks are introduced, compared to the
            density of data points.
          - Polynomial curves may be used instead.   For  this  the  option  is:
            /POLYNOMIAL  [degree]  indicating  the degree of the polynomial (de-
            fault 0).

        Normally the data points are all assigned the same weight for  the  fit.
        With option /WEIGHT, the data points are weighted according to their er-
        rors.