Subroutine */
| 16337 | } /* slalsd_ */ |
| 16338 | |
| 16339 | /* Subroutine */ int slamrg_(integer *n1, integer *n2, real *a, integer * |
| 16340 | strd1, integer *strd2, integer *index) |
| 16341 | { |
| 16342 | /* System generated locals */ |
| 16343 | integer i__1; |
| 16344 | |
| 16345 | /* Local variables */ |
| 16346 | static integer i__, ind1, ind2, n1sv, n2sv; |
| 16347 | |
| 16348 | |
| 16349 | /* |
| 16350 | -- LAPACK routine (version 3.2) -- |
| 16351 | -- LAPACK is a software package provided by Univ. of Tennessee, -- |
| 16352 | -- Univ. of California Berkeley, Univ. of Colorado Denver and NAG Ltd..-- |
| 16353 | November 2006 |
| 16354 | |
| 16355 | |
| 16356 | Purpose |
| 16357 | ======= |
| 16358 | |
| 16359 | SLAMRG will create a permutation list which will merge the elements |
| 16360 | of A (which is composed of two independently sorted sets) into a |
| 16361 | single set which is sorted in ascending order. |
| 16362 | |
| 16363 | Arguments |
| 16364 | ========= |
| 16365 | |
| 16366 | N1 (input) INTEGER |
| 16367 | N2 (input) INTEGER |
| 16368 | These arguments contain the respective lengths of the two |
| 16369 | sorted lists to be merged. |
| 16370 | |
| 16371 | A (input) REAL array, dimension (N1+N2) |
| 16372 | The first N1 elements of A contain a list of numbers which |
| 16373 | are sorted in either ascending or descending order. Likewise |
| 16374 | for the final N2 elements. |
| 16375 | |
| 16376 | STRD1 (input) INTEGER |
| 16377 | STRD2 (input) INTEGER |
| 16378 | These are the strides to be taken through the array A. |
| 16379 | Allowable strides are 1 and -1. They indicate whether a |
| 16380 | subset of A is sorted in ascending (STRDx = 1) or descending |
| 16381 | (STRDx = -1) order. |
| 16382 | |
| 16383 | INDEX (output) INTEGER array, dimension (N1+N2) |
| 16384 | On exit this array will contain a permutation such that |
| 16385 | if B( I ) = A( INDEX( I ) ) for I=1,N1+N2, then B will be |
| 16386 | sorted in ascending order. |
| 16387 | |
| 16388 | ===================================================================== |
| 16389 | */ |
| 16390 | |
| 16391 | |
| 16392 | /* Parameter adjustments */ |
| 16393 | --index; |
| 16394 | --a; |
| 16395 | |
| 16396 | /* Function Body */ |