ROUTINE
-------

INT_ ug_sort_double_list (INT_ m,
                          INT_ n,
                          DOUBLE_1D * double_values,
                          INT_1D * list)

DESCRIPTION
-----------

Sort a list of values and create a corresponding index.

INPUT ARGUMENTS
---------------

m                        : Mode flag.
                           If m = 0 then leave the list of values alone.
                           If m = 1 then change the order of the list of values.
n                        : Number of values.
double_values            : List of values.

RETURN VALUE
---------------

0                        : No errors occurred.
>0                       : Errors occurred.
                           The return value will be between 400 and 499 or
                           the return value will be between 100400 and 100499

OUTPUT ARGUMENTS
----------------

double_values            : List of sorted values if m = 1.
list                     : Index list of sorted values.
