00001 /* 00002 * $Id$ 00003 * 00004 * Author: David Fournier 00005 * Copyright (c) 2008-2012 Regents of the University of California 00006 */ 00011 // file: fvar_ops.cpp 00012 // operators involving prevariables 00013 00014 #include "fvar.hpp" 00015 00016 #ifdef __TURBOC__ 00017 #pragma hdrstop 00018 #include <iostream.h> 00019 #endif 00020 00021 #ifdef __ZTC__ 00022 #include <iostream.hpp> 00023 #endif 00024 00025 #include <stdio.h> 00026 #include <math.h> 00027 00028 void df_minus_eq_pvpv(void); 00029 00034 void prevariable::operator-=(const prevariable& v1) 00035 { 00036 (*v).x-=(*v1.v).x; 00037 gradient_structure::GRAD_STACK1->set_gradient_stack(df_minus_eq_pvpv,&(v->x), 00038 &(v1.v->x)); 00039 } 00040 00045 void df_minus_eq_pvpv(void) 00046 { 00047 * gradient_structure::GRAD_STACK1->ptr->ind_addr1 00048 -= * gradient_structure::GRAD_STACK1->ptr->dep_addr; 00049 }
Generated on Tue Mar 8 2016 19:51:34 for ADMB Documentation by 1.8.0 |