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] [ 10.5.p1 ] [ 10.6 ] [ 10.6.p1 ] [ 10.6.p2 ] [ 10.6.p3 ] [ 10.7 ] [ 10.7.p1 ] [ 10.7.p2 ] [ 10.7.p3 ] [ 10.7.p4 ] [ 11.0 ] [ 11.0.p1 ] [ 11.0.p2 ] [ 11.0.p3, ] [ 11.0.p4 ] [ 11.1 ] [ 11.1.1 ] [ 11.1.2 ] [ 11.1.3 ] [ 11.2 ] [ 11.2.1 ] [ 11.2.2 ] [ 11.3.0 ]

Diff markup

Differences between /processes/hadronic/models/lend/include/ptwX.h (Version 11.3.0) and /processes/hadronic/models/lend/include/ptwX.h (Version 11.1.2)


  1 /*                                                  1 /*
  2 # <<BEGIN-copyright>>                               2 # <<BEGIN-copyright>>
  3 # <<END-copyright>>                                 3 # <<END-copyright>>
  4 */                                                  4 */
  5                                                     5 
  6 #ifndef ptwX_h_included                             6 #ifndef ptwX_h_included
  7 #define ptwX_h_included                             7 #define ptwX_h_included
  8                                                     8 
  9 #include <stdio.h>                                  9 #include <stdio.h>
 10 #include <stdint.h>                                10 #include <stdint.h>
 11                                                    11 
 12 #include <nf_utilities.h>                          12 #include <nf_utilities.h>
 13                                                    13 
 14 #if defined __cplusplus                            14 #if defined __cplusplus
 15     extern "C" {                                   15     extern "C" {
 16     namespace GIDI {                               16     namespace GIDI {
 17 #endif                                             17 #endif
 18                                                    18 
 19 #define ptwX_minimumSize 10                        19 #define ptwX_minimumSize 10
 20                                                    20 
 21 enum ptwX_sort_order { ptwX_sort_order_descend     21 enum ptwX_sort_order { ptwX_sort_order_descending, ptwX_sort_order_ascending };
 22                                                    22 
 23 typedef                                            23 typedef
 24     struct ptwXPoints_s {                          24     struct ptwXPoints_s {
 25         nfu_status status;                         25         nfu_status status;
 26         int64_t length;                            26         int64_t length;
 27         int64_t allocatedSize;                     27         int64_t allocatedSize;
 28         int64_t mallocFailedSize;                  28         int64_t mallocFailedSize;
 29         double *points;                            29         double *points;
 30     } ptwXPoints;                                  30     } ptwXPoints;
 31                                                    31 
 32 /*                                                 32 /*
 33 * Routines in ptwX_core.c                          33 * Routines in ptwX_core.c
 34 */                                                 34 */
 35 ptwXPoints *ptwX_new( int64_t size, nfu_status     35 ptwXPoints *ptwX_new( int64_t size, nfu_status *status );
 36 nfu_status ptwX_setup( ptwXPoints *ptwX, int64     36 nfu_status ptwX_setup( ptwXPoints *ptwX, int64_t size );
 37 ptwXPoints *ptwX_create( int64_t size, int64_t     37 ptwXPoints *ptwX_create( int64_t size, int64_t length, double const *xs, nfu_status *status );
 38 ptwXPoints *ptwX_createLine( int64_t size, int     38 ptwXPoints *ptwX_createLine( int64_t size, int64_t length, double slope, double offset, nfu_status *status );
 39 nfu_status ptwX_copy( ptwXPoints *dest, ptwXPo     39 nfu_status ptwX_copy( ptwXPoints *dest, ptwXPoints *src );
 40 ptwXPoints *ptwX_clone( ptwXPoints *ptwX, nfu_     40 ptwXPoints *ptwX_clone( ptwXPoints *ptwX, nfu_status *status );
 41 ptwXPoints *ptwX_slice( ptwXPoints *ptwX, int6     41 ptwXPoints *ptwX_slice( ptwXPoints *ptwX, int64_t index1, int64_t index2, nfu_status *status );
 42 nfu_status ptwX_reallocatePoints( ptwXPoints *     42 nfu_status ptwX_reallocatePoints( ptwXPoints *ptwX, int64_t size, int forceSmallerResize );
 43 nfu_status ptwX_clear( ptwXPoints *ptwX );         43 nfu_status ptwX_clear( ptwXPoints *ptwX );
 44 nfu_status ptwX_release( ptwXPoints *ptwX );       44 nfu_status ptwX_release( ptwXPoints *ptwX );
 45 ptwXPoints *ptwX_free( ptwXPoints *ptwX );         45 ptwXPoints *ptwX_free( ptwXPoints *ptwX );
 46                                                    46 
 47 int64_t ptwX_length( ptwXPoints *ptwX );           47 int64_t ptwX_length( ptwXPoints *ptwX );
 48 nfu_status ptwX_setData( ptwXPoints *ptwX, int     48 nfu_status ptwX_setData( ptwXPoints *ptwX, int64_t length, double const *xs );
 49 nfu_status ptwX_deletePoints( ptwXPoints *ptwX     49 nfu_status ptwX_deletePoints( ptwXPoints *ptwX, int64_t i1, int64_t i2 );
 50 double *ptwX_getPointAtIndex( ptwXPoints *ptwX     50 double *ptwX_getPointAtIndex( ptwXPoints *ptwX, int64_t index );
 51 double ptwX_getPointAtIndex_Unsafely( ptwXPoin     51 double ptwX_getPointAtIndex_Unsafely( ptwXPoints *ptwX, int64_t index );
 52 nfu_status ptwX_setPointAtIndex( ptwXPoints *p     52 nfu_status ptwX_setPointAtIndex( ptwXPoints *ptwX, int64_t index, double x );
 53 nfu_status ptwX_insertPointsAtIndex( ptwXPoint     53 nfu_status ptwX_insertPointsAtIndex( ptwXPoints *ptwX, int64_t index, int64_t n1, double const *xs );
 54 int ptwX_ascendingOrder( ptwXPoints *ptwX );       54 int ptwX_ascendingOrder( ptwXPoints *ptwX );
 55 ptwXPoints *ptwX_fromString( char const *str,      55 ptwXPoints *ptwX_fromString( char const *str, char **endCharacter, nfu_status *status );
 56 nfu_status ptwX_countOccurrences( ptwXPoints *     56 nfu_status ptwX_countOccurrences( ptwXPoints *ptwX, double value, int *count );
 57 nfu_status ptwX_reverse( ptwXPoints *ptwX );       57 nfu_status ptwX_reverse( ptwXPoints *ptwX );
 58 nfu_status ptwX_sort( ptwXPoints *ptwX, enum p     58 nfu_status ptwX_sort( ptwXPoints *ptwX, enum ptwX_sort_order order );
 59 nfu_status ptwX_closesDifference( ptwXPoints *     59 nfu_status ptwX_closesDifference( ptwXPoints *ptwX, double value, int64_t *index, double *difference );
 60 nfu_status ptwX_closesDifferenceInRange( ptwXP     60 nfu_status ptwX_closesDifferenceInRange( ptwXPoints *ptwX, int64_t i1, int64_t i2, double value, int64_t *index, double *difference );
 61 ptwXPoints *ptwX_unique( ptwXPoints *ptwX, int     61 ptwXPoints *ptwX_unique( ptwXPoints *ptwX, int order, nfu_status *status );
 62                                                    62 
 63 nfu_status ptwX_abs( ptwXPoints *ptwX );           63 nfu_status ptwX_abs( ptwXPoints *ptwX );
 64 nfu_status ptwX_neg( ptwXPoints *ptwX );           64 nfu_status ptwX_neg( ptwXPoints *ptwX );
 65 nfu_status ptwX_add_double( ptwXPoints *ptwX,      65 nfu_status ptwX_add_double( ptwXPoints *ptwX, double value );
 66 nfu_status ptwX_mul_double( ptwXPoints *ptwX,      66 nfu_status ptwX_mul_double( ptwXPoints *ptwX, double value );
 67 nfu_status ptwX_slopeOffset( ptwXPoints *ptwX,     67 nfu_status ptwX_slopeOffset( ptwXPoints *ptwX, double slope, double offset );
 68 nfu_status ptwX_add_ptwX( ptwXPoints *ptwX1, p     68 nfu_status ptwX_add_ptwX( ptwXPoints *ptwX1, ptwXPoints *ptwX2 );
 69 nfu_status ptwX_sub_ptwX( ptwXPoints *ptwX1, p     69 nfu_status ptwX_sub_ptwX( ptwXPoints *ptwX1, ptwXPoints *ptwX2 );
 70                                                    70 
 71 nfu_status ptwX_xMinMax( ptwXPoints *ptwX, dou     71 nfu_status ptwX_xMinMax( ptwXPoints *ptwX, double *xMin, double *xMax );
 72                                                    72 
 73 nfu_status ptwX_compare( ptwXPoints *ptwX1, pt     73 nfu_status ptwX_compare( ptwXPoints *ptwX1, ptwXPoints *ptwX2, int *comparison );
 74 int ptwX_close( ptwXPoints *ptwX1, ptwXPoints      74 int ptwX_close( ptwXPoints *ptwX1, ptwXPoints *ptwX2, int epsilonFactor, double epsilon, nfu_status *status );
 75                                                    75 
 76 /*                                                 76 /*
 77 * Routines in ptwX_misc.c                          77 * Routines in ptwX_misc.c
 78 */                                                 78 */
 79 void ptwX_simpleWrite( ptwXPoints const *ptwX,     79 void ptwX_simpleWrite( ptwXPoints const *ptwX, FILE *f, char const *format );
 80 void ptwX_simplePrint( ptwXPoints const *ptwX,     80 void ptwX_simplePrint( ptwXPoints const *ptwX, char const *format );
 81                                                    81 
 82 #if defined __cplusplus                            82 #if defined __cplusplus
 83     }                                              83     }
 84     }                                              84     }
 85 #endif                                             85 #endif
 86                                                    86 
 87 #endif          /* End of ptwX_h_included. */      87 #endif          /* End of ptwX_h_included. */
 88                                                    88