| 36 | 
  | 
 * [1]  Meineke, et al., J. Comp. Chem. 26, 252-271 (2005).              | 
| 37 | 
  | 
 * [2]  Fennell & Gezelter, J. Chem. Phys. 124, 234104 (2006).           | 
| 38 | 
  | 
 * [3]  Sun, Lin & Gezelter, J. Chem. Phys. 128, 24107 (2008).           | 
| 39 | 
< | 
 * [4]  Vardeman & Gezelter, in progress (2009).                         | 
| 39 | 
> | 
 * [4]  Kuang & Gezelter,  J. Chem. Phys. 133, 164101 (2010). | 
| 40 | 
> | 
 * [5]  Vardeman, Stocker & Gezelter, J. Chem. Theory Comput. 7, 834 (2011). | 
| 41 | 
  | 
 */ | 
| 42 | 
  | 
 | 
| 43 | 
  | 
#include "applications/hydrodynamics/ApproximationModel.hpp"  | 
| 72 | 
  | 
   | 
| 73 | 
  | 
  bool ApproximationModel::calcHydroProps(Shape* shape, RealType viscosity, RealType temperature) { | 
| 74 | 
  | 
     | 
| 74 | 
– | 
    bool ret = true; | 
| 75 | 
  | 
    HydroProp* cr = new HydroProp(); | 
| 76 | 
  | 
    HydroProp* cd = new HydroProp(); | 
| 77 | 
  | 
    calcHydroPropsAtCR(beads_, viscosity, temperature, cr); | 
| 83 | 
  | 
   | 
| 84 | 
  | 
  bool ApproximationModel::calcHydroPropsAtCR(std::vector<BeadParam>& beads, RealType viscosity, RealType temperature, HydroProp* cr) { | 
| 85 | 
  | 
     | 
| 86 | 
< | 
    int nbeads = beads.size(); | 
| 86 | 
> | 
    unsigned int nbeads = beads.size(); | 
| 87 | 
  | 
    DynamicRectMatrix<RealType> B(3*nbeads, 3*nbeads); | 
| 88 | 
  | 
    DynamicRectMatrix<RealType> C(3*nbeads, 3*nbeads); | 
| 89 | 
  | 
    Mat3x3d I; | 
| 120 | 
  | 
     | 
| 121 | 
  | 
    //prepare U Matrix relative to arbitrary origin O(0.0, 0.0, 0.0) | 
| 122 | 
  | 
    std::vector<Mat3x3d> U; | 
| 123 | 
< | 
    for (int i = 0; i < nbeads; ++i) { | 
| 123 | 
> | 
    for (unsigned int i = 0; i < nbeads; ++i) { | 
| 124 | 
  | 
      Mat3x3d currU; | 
| 125 | 
  | 
      currU.setupSkewMat(beads[i].pos); | 
| 126 | 
  | 
      U.push_back(currU); | 
| 151 | 
  | 
    } | 
| 152 | 
  | 
 | 
| 153 | 
  | 
    // add the volume correction | 
| 154 | 
< | 
    Xiorr += (6.0 * viscosity * volume) * I;     | 
| 154 | 
> | 
    Xiorr += (RealType(6.0) * viscosity * volume) * I;     | 
| 155 | 
  | 
     | 
| 156 | 
  | 
    Xiott *= PhysicalConstants::viscoConvert; | 
| 157 | 
  | 
    Xiotr *= PhysicalConstants::viscoConvert; | 
| 256 | 
  | 
   | 
| 257 | 
  | 
  bool ApproximationModel::calcHydroPropsAtCD(std::vector<BeadParam>& beads, RealType viscosity, RealType temperature, HydroProp* cd) { | 
| 258 | 
  | 
     | 
| 259 | 
< | 
    int nbeads = beads.size(); | 
| 259 | 
> | 
    unsigned int nbeads = beads.size(); | 
| 260 | 
  | 
    DynamicRectMatrix<RealType> B(3*nbeads, 3*nbeads); | 
| 261 | 
  | 
    DynamicRectMatrix<RealType> C(3*nbeads, 3*nbeads); | 
| 262 | 
  | 
    Mat3x3d I; | 
| 293 | 
  | 
     | 
| 294 | 
  | 
    //prepare U Matrix relative to arbitrary origin O(0.0, 0.0, 0.0) | 
| 295 | 
  | 
    std::vector<Mat3x3d> U; | 
| 296 | 
< | 
    for (int i = 0; i < nbeads; ++i) { | 
| 296 | 
> | 
    for (unsigned int i = 0; i < nbeads; ++i) { | 
| 297 | 
  | 
      Mat3x3d currU; | 
| 298 | 
  | 
      currU.setupSkewMat(beads[i].pos); | 
| 299 | 
  | 
      U.push_back(currU); | 
| 323 | 
  | 
      } | 
| 324 | 
  | 
    } | 
| 325 | 
  | 
    // add the volume correction here: | 
| 326 | 
< | 
    Xirr += (6.0 * viscosity * volume) * I;     | 
| 326 | 
> | 
    Xirr += (RealType(6.0) * viscosity * volume) * I;     | 
| 327 | 
  | 
     | 
| 328 | 
  | 
    Xitt *= PhysicalConstants::viscoConvert; | 
| 329 | 
  | 
    Xitr *= PhysicalConstants::viscoConvert; |