Actual source code: ad_deriv.h

      1: /************************** DISCLAIMER ********************************/
      2: /*                                                                    */
      3: /*   This file was generated on 08/09/02 09:55:56 by the version of   */
      4: /*   ADIC compiled on  08/07/00 18:06:31                              */
      5: /*                                                                    */
      6: /*   ADIC was prepared as an account of work sponsored by an          */
      7: /*   agency of the United States Government and the University of     */
      8: /*   Chicago.  NEITHER THE AUTHOR(S), THE UNITED STATES GOVERNMENT    */
      9: /*   NOR ANY AGENCY THEREOF, NOR THE UNIVERSITY OF CHICAGO, INCLUDING */
     10: /*   ANY OF THEIR EMPLOYEES OR OFFICERS, MAKES ANY WARRANTY, EXPRESS  */
     11: /*   OR IMPLIED, OR ASSUMES ANY LEGAL LIABILITY OR RESPONSIBILITY FOR */
     12: /*   THE ACCURACY, COMPLETENESS, OR USEFULNESS OF ANY INFORMATION OR  */
     13: /*   PROCESS DISCLOSED, OR REPRESENTS THAT ITS USE WOULD NOT INFRINGE */
     14: /*   PRIVATELY OWNED RIGHTS.                                          */
     15: /*                                                                    */
     16: /**********************************************************************/
     17: #if !defined(AD_DERIV_H)
     18: #define AD_DERIV_H

     20: typedef double InactiveDouble;
     21: typedef float InactiveFloat;

     23: #if !defined(ad_GRAD_PTR)
     24: #define ad_GRAD_PTR 0
     25: #endif

     27: #if !defined(ad_GRAD_MAX)
     28: #define ad_GRAD_MAX 5
     29: #endif

     31: #define AD_INIT_MAP()
     32: #define AD_CLEANUP_MAP()
     33: #define AD_GET_DERIV_OBJ(x) ((void*)(&x.value+1))
     34: #define AD_FREE_DERIV_OBJ(x)
     35: typedef struct {
     36:         double value;
     37:         double  grad[ad_GRAD_MAX];
     38: } DERIV_TYPE;

     40: #define DERIV_val(a) ((a).value)

     42: #define DERIV_grad(a) ((a).grad)

     44: #define _FLOAT_INITIALIZER_(x) { x, 0.0 }

     46: void ad_AD_Init(int);
     47: void ad_AD_Final();
     48: #include "ad_grad.h"

     50: #define nullFunc(x) 0

     52: #endif