Actual source code: ad_deriv.h

  1: /************************** DISCLAIMER ********************************/
  2: /*                                                                    */
  3: /*   This file was generated on 05/07/01 08:45:14 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: #include "ad_grad.h"

 19: #if !defined(AD_DERIV_H)
 20: #define AD_DERIV_H

 22: typedef double InactiveDouble;
 23: typedef float InactiveFloat;

 25: #if defined(__cplusplus)
 27: #endif

 29: #if !defined(ad_GRAD_PTR) 
 30: #define ad_GRAD_PTR 0
 31: #endif

 33: /* since ad_GRAD_MAX is set dynamically by the application (that automatically includes 
 34:    this file) this is here so that the regular library compile can compile this file */
 35: #if !defined(ad_GRAD_MAX)
 36: #define ad_GRAD_MAX 64
 37: #endif

 39: #define AD_INIT_MAP()
 40: #define AD_CLEANUP_MAP()
 41: #define AD_GET_DERIV_OBJ(x) ((void*)(&x.value+1))
 42: #define AD_FREE_DERIV_OBJ(x)
 43: typedef struct {
 44:         double value;
 45:         double  grad[ad_GRAD_MAX];
 46: } DERIV_TYPE;

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

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

 52: /* _FLOAT_INITIALIZER_ is currently incorrect */
 53: #define _FLOAT_INITIALIZER_(x) { x, 0.0 }

 55: #define nullFunc(x) 0

 57: #if defined(__cplusplus)
 58: }
 59: #endif

 61: #endif