Revision 1110 trunk/src/df1b2-separable/df1b2f21.cpp

df1b2f21.cpp (revision 1110)
20 20
 * Description not yet available.
21 21
 * \param
22 22
 */
23
int df1b2_gradlist::write_pass1(const df1b2variable * _px, 
23
int df1b2_gradlist::write_pass1(const df1b2variable * _px,
24 24
  df1b2variable * pz, double df, double d2f, double d3f)
25 25
{
26 26
  ADUNCONST(df1b2variable*,px)
......
77 77
/**
78 78
 * Description not yet available.
79 79
 * \param
80
 */ 
80
 */
81 81
void ad_read_pass1_der_values(void)
82 82
{
83 83
  switch(df1b2variable::passnumber)
......
92 92
    read_pass1_3_dv();
93 93
    break;
94 94
  default:
95
    cerr << "illegal value for df1b2variable::pass = " 
95
    cerr << "illegal value for df1b2variable::pass = "
96 96
         << df1b2variable::passnumber << endl;
97 97
    exit(1);
98 98
  }
......
101 101
/**
102 102
 * Description not yet available.
103 103
 * \param
104
 */    
104
 */
105 105
void read_pass1_1_dv(void)
106 106
{
107 107
  // We are going backword for bptr and forward for bptr2
108 108
  // the current entry+2 in bptr is the size of the record i.e
109 109
  // points to the next record
110 110
  int nvar=df1b2variable::nvar;
111
  fixed_smartlist & nlist=f1b2gradlist->nlist; 
112
  test_smartlist& list=f1b2gradlist->list; 
111
  fixed_smartlist & nlist=f1b2gradlist->nlist;
112
  test_smartlist& list=f1b2gradlist->list;
113 113
   // nlist-=sizeof(int);
114 114
  // get record size
115 115
  int num_bytes=nlist.bptr->numbytes;
......
143 143
  xdot=(double*)list.bptr;
144 144
  list.restoreposition(); // save pointer to beginning of record;
145 145
  int i;
146
  
146

  
147 147
  // Do first reverse paSS calculations
148 148
  // ****************************************************************
149 149
  // turn this off if no third derivatives are calculated
......
151 151
  // {
152 152
  // save for second reverse pass
153 153
  // save identifier 1
154
     fixed_smartlist2& nlist2=f1b2gradlist->nlist2; 
155
     test_smartlist& list2=f1b2gradlist->list2; 
154
     fixed_smartlist2& nlist2=f1b2gradlist->nlist2;
155
     test_smartlist& list2=f1b2gradlist->list2;
156 156

  
157 157

  
158 158
  int total_bytes=2*nvar*sizeof(double);
......
165 165

  
166 166
  list2.check_buffer_size(total_bytes);
167 167
  void * tmpptr2=list2.bptr;
168
  
168

  
169 169
#if defined(SAFE_ALL)
170 170
  memcpy(list2,ids,slen);
171 171
#endif
......
178 178
  //
179 179
  // ****************************************************************
180 180
#if defined(PRINT_DERS)
181
 print_derivatives(pz,"z"); 
182
 print_derivatives(px,"x"); 
181
 print_derivatives(pz,"z");
182
 print_derivatives(px,"x");
183 183
#endif
184
 
184

  
185 185
  //double df=(pf->df)(xu);
186 186
  //double d2f=(pf->d2f)(xu);
187 187
  //double d3f=(pf->d3f)(xu);
......
201 201
    //px->u_dot_bar[i]+=(pf->df)(xu)*pz->u_dot_bar[i];
202 202
    px->u_dot_bar[i]+=df*pz->u_dot_bar[i];
203 203
  }
204
  
204

  
205 205
  // !!!!!!!!!!!!!!!!!!!!!!
206 206
  for (i=0;i<nvar;i++)
... This diff was truncated because it exceeds the maximum size that can be displayed.

Also available in: Unified diff