From: Bertrand <bco...@us...> - 2016-05-23 17:23:39
|
Update of /cvsroot/jsbsim/JSBSim/src/models In directory sfp-cvs-1.v30.ch3.sourceforge.com:/tmp/cvs-serv32182/src/models Modified Files: FGAerodynamics.cpp Log Message: Bug fix for the SF bug #115 Index: FGAerodynamics.cpp =================================================================== RCS file: /cvsroot/jsbsim/JSBSim/src/models/FGAerodynamics.cpp,v retrieving revision 1.58 retrieving revision 1.59 diff -C2 -r1.58 -r1.59 *** FGAerodynamics.cpp 22 May 2016 17:02:13 -0000 1.58 --- FGAerodynamics.cpp 23 May 2016 17:23:36 -0000 1.59 *************** *** 148,151 **** --- 148,158 ---- const double twovel=2*in.Vt; + // Calculate lift coefficient squared + // Make sure that aero/cl-squared is computed with the current qbar + if ( in.Qbar > 0) { + clsq = (vFw(eLift) + vFwAtCG(eLift))/ (in.Wingarea*in.Qbar); + clsq *= clsq; + } + RunPreFunctions(); *************** *** 249,258 **** } - // Calculate lift coefficient squared - if ( in.Qbar > 0) { - clsq = (vFw(eLift) + vFwAtCG(eLift))/ (in.Wingarea*in.Qbar); - clsq *= clsq; - } - // Calculate lift Lift over Drag if ( fabs(vFw(eDrag) + vFwAtCG(eDrag)) > 0.0) --- 256,259 ---- |