ADAS Subroutine xxordr
subroutine xxordr(n, lup, xa, ia, iinva) c----------------------------------------------------------------------- c c ****************** fortran77 subroutine: xxordr ******************* c c purpose: sorts a real*8 array xa. This is a bubble sort designed for c small arrays. c c c calling program: general use c c c subroutine: c c input : (i*4) n = size of input arrays c input : (l*4) lup = .true. sort in ascending order c .false. descending order c input/output: (r*8) xa = array to be sorted c output : (i*4) ia = original index of sorted xa members c output : (i*4) iinva = inverse of ia c c routines: none c c notes: based on nsort. subroutine sets ia(i)=i before sorting c c author: Susan Turnbull c c date: 22/08/01 c c version: 1.1 c c----------------------------------------------------------------------- INTEGER IA(*), IINVA(*), N LOGICAL LUP REAL*8 XA(*)