| Last change
 on this file since cfaf42 was             a0bcf1, checked in by Frederik Heber <heber@…>, 18 years ago | 
        
          | 
-initial commit-Minimum set of files needed from ESPACK SVN repository
 -Switch to three tantamount package parts instead of all relating to pcp (as at some time Ralf's might find inclusion as well)
 
 | 
        
          | 
              
Property                 mode
 set to                 100644 | 
        
          | File size:
            522 bytes | 
      
      
| Rev | Line |  | 
|---|
| [a0bcf1] | 1 | #ifndef mergesort_h | 
|---|
|  | 2 | #define mergesort_h | 
|---|
|  | 3 | /* | 
|---|
|  | 4 | Project: CP | 
|---|
|  | 5 | Jan Hamaekers | 
|---|
|  | 6 | 2000 | 
|---|
|  | 7 |  | 
|---|
|  | 8 | File: Mergesort | 
|---|
|  | 9 | Usage: | 
|---|
|  | 10 | Insert in your Code | 
|---|
|  | 11 | #include"mergesort.h" | 
|---|
|  | 12 | double GetKey(void *Element) { } ... | 
|---|
|  | 13 |  | 
|---|
|  | 14 |  | 
|---|
|  | 15 | Use: | 
|---|
|  | 16 | naturalmergesort(a,l,r,&GetKey) | 
|---|
|  | 17 | struct Element** a | 
|---|
|  | 18 | int l,r | 
|---|
|  | 19 |  | 
|---|
|  | 20 | See also: GetCrd.c | 
|---|
|  | 21 | */ | 
|---|
|  | 22 |  | 
|---|
|  | 23 | #include<stdlib.h> | 
|---|
|  | 24 |  | 
|---|
|  | 25 | void naturalmergesort(void **a, int l, int r, double (*GetKey)(void *)); | 
|---|
|  | 26 | /* sort a[l]...a[r] | 
|---|
|  | 27 | !!! Nutzt vorhandenen Teilfolgen aus !!! | 
|---|
|  | 28 | C_min = O(N) | 
|---|
|  | 29 | C_max = O(N) | 
|---|
|  | 30 | */ | 
|---|
|  | 31 |  | 
|---|
|  | 32 | #endif | 
|---|
       
      
  Note:
 See   
TracBrowser
 for help on using the repository browser.