Commit 9a5d8fd1 authored by Anne Gunn's avatar Anne Gunn
Browse files

Manually resolve two rebase conflicts.

parent 50b80e07
Loading
Loading
Loading
Loading
+25 −25
Original line number Diff line number Diff line
@@ -30,26 +30,26 @@ namespace ATC {
    useFeMdMassMatrix_(false),
    trackCharge_(false),
    temperatureDef_(NONE),
    prescribedDataMgr_(NULL),
    physicsModel_(NULL),
    prescribedDataMgr_(nullptr),
    physicsModel_(nullptr),
    extrinsicModelManager_(this),
    atomicRegulator_(NULL),
    atomicRegulator_(nullptr),
    atomQuadForInternal_(true),
    elementMask_(NULL),
    elementMaskMass_(NULL),
    elementMaskMassMd_(NULL),
    nodalAtomicMass_(NULL),
    nodalAtomicCount_(NULL),
    nodalAtomicHeatCapacity_(NULL),
    internalToMask_(NULL),
    internalElement_(NULL),
    ghostElement_(NULL),
    nodalGeometryType_(NULL),
    elementMask_(nullptr),
    elementMaskMass_(nullptr),
    elementMaskMassMd_(nullptr),
    nodalAtomicMass_(nullptr),
    nodalAtomicCount_(nullptr),
    nodalAtomicHeatCapacity_(nullptr),
    internalToMask_(nullptr),
    internalElement_(nullptr),
    ghostElement_(nullptr),
    nodalGeometryType_(nullptr),
    bndyIntType_(NO_QUADRATURE),
    bndyFaceSet_(NULL),
    atomicWeightsMask_(NULL),
    shpFcnMask_(NULL),
    shpFcnDerivsMask_(NULL),
    bndyFaceSet_(nullptr),
    atomicWeightsMask_(nullptr),
    shpFcnMask_(nullptr),
    shpFcnDerivsMask_(nullptr),
    sourceIntegration_(FULL_DOMAIN)
  {
    // size the field mask
@@ -68,7 +68,7 @@ namespace ATC {
  ATC_Coupling::~ATC_Coupling()
  {
    interscaleManager_.clear(); 
    if (feEngine_) { delete feEngine_; feEngine_ = NULL; } 
    if (feEngine_) { delete feEngine_; feEngine_ = nullptr; } 
    if (physicsModel_) delete physicsModel_;
    if (atomicRegulator_) delete atomicRegulator_;
    if (prescribedDataMgr_) delete prescribedDataMgr_;
@@ -127,7 +127,7 @@ namespace ATC {
        argIdx++;
        parse_field(arg,argIdx,thisField,thisIndex);
        string nsetName(arg[argIdx++]);
        XT_Function * f = NULL;
        XT_Function * f = nullptr;
        // parse constant
        if (narg == argIdx+1) {
          f = XT_Function_Mgr::instance()->constant_function(atof(arg[argIdx]));
@@ -164,7 +164,7 @@ namespace ATC {
        argIdx++;
        parse_field(arg,argIdx,thisField,thisIndex);
        string nsetName(arg[argIdx++]);
        XT_Function * f = NULL;
        XT_Function * f = nullptr;
        // fix current value 
        if (narg == argIdx) {
          set<int> nodeSet = (feEngine_->fe_mesh())->nodeset(nsetName);
@@ -258,7 +258,7 @@ namespace ATC {
        argIdx++;
        parse_field(arg,argIdx,thisField,thisIndex);
        string esetName(arg[argIdx++]);
        XT_Function * f = NULL;
        XT_Function * f = nullptr;
        // parse constant
        if (narg == argIdx+1) {
          string a(arg[argIdx]);
@@ -367,7 +367,7 @@ namespace ATC {
        argIdx++;
        parse_field(arg,argIdx,thisField,thisIndex);
        string fsetName(arg[argIdx++]);
        XT_Function * f = NULL;
        XT_Function * f = nullptr;
        // parse constant
        if (narg == argIdx+1) {
          f = XT_Function_Mgr::instance()->constant_function(atof(arg[argIdx]));
@@ -529,7 +529,7 @@ namespace ATC {
        argIdx++;
        parse_field(arg,argIdx,thisField,thisIndex);
        string fsetName(arg[argIdx++]);
        UXT_Function * f = NULL;
        UXT_Function * f = nullptr;
        // parse linear
        if (narg == argIdx+2) {
          f = UXT_Function_Mgr::instance()->linear_function(atof(arg[argIdx]),atof(arg[argIdx+1]));
@@ -760,7 +760,7 @@ namespace ATC {
   WeakEquation::PDE_Type ATC_Coupling::pde_type(const FieldName fieldName) const
   {
     const WeakEquation * weakEq = physicsModel_->weak_equation(fieldName);
     if (weakEq == NULL) return WeakEquation::PROJECTION_PDE; 
     if (weakEq == nullptr) return WeakEquation::PROJECTION_PDE; 
     return weakEq->type();
   }
  //--------------------------------------------------
@@ -768,7 +768,7 @@ namespace ATC {
   bool ATC_Coupling::is_dynamic(const FieldName fieldName) const
   {
     const WeakEquation * weakEq = physicsModel_->weak_equation(fieldName);
     if (weakEq == NULL) return false; 
     if (weakEq == nullptr) return false; 
     return (physicsModel_->weak_equation(fieldName)->type() == WeakEquation::DYNAMIC_PDE);
   }

+12 −12
Original line number Diff line number Diff line
@@ -114,10 +114,10 @@ namespace ATC {
                               FIELDS &rhs,
                               const Array< std::set <int> > atomMaterialGroups,
                               const VectorDependencyManager<SPAR_MAT * > * shpFcnDerivs,
                               const SPAR_MAN * shpFcn = NULL,
                               const DIAG_MAN * atomicWeights = NULL,
                               const MatrixDependencyManager<DenseMatrix, bool> * elementMask = NULL,
                               const SetDependencyManager<int> * nodeSet = NULL);
                               const SPAR_MAN * shpFcn = nullptr,
                               const DIAG_MAN * atomicWeights = nullptr,
                               const MatrixDependencyManager<DenseMatrix, bool> * elementMask = nullptr,
                               const SetDependencyManager<int> * nodeSet = nullptr);
    /** access to full right hand side / forcing vector */
    FIELDS &rhs() {return rhs_;};
    Array2D <bool> rhs_mask() const {
@@ -152,14 +152,14 @@ namespace ATC {
                            const FIELDS &fields, 
                            FIELDS &rhs,
                            const IntegrationDomainType domain, // = FULL_DOMAIN
                            const PhysicsModel * physicsModel=NULL);
                            const PhysicsModel * physicsModel=nullptr);
   /** wrapper for FE_Engine's compute_tangent_matrix */
   void compute_rhs_tangent(const std::pair<FieldName,FieldName> row_col,
                            const RHS_MASK & rhsMask,      
                            const FIELDS & fields,                  
                            SPAR_MAT & stiffness,
                            const IntegrationDomainType integrationType,
                            const PhysicsModel * physicsModel=NULL);
                            const PhysicsModel * physicsModel=nullptr);
   void tangent_matrix(const std::pair<FieldName,FieldName> row_col,
                            const RHS_MASK & rhsMask,      
                            const PhysicsModel * physicsModel,
@@ -197,7 +197,7 @@ namespace ATC {
          return & (it->second).quantity();
        }
        else {
          return NULL;
          return nullptr;
        }
      }
      else {
@@ -206,7 +206,7 @@ namespace ATC {
          return & (it->second).quantity();
        }
        else {
          return NULL;
          return nullptr;
        }
      }
    }
@@ -233,7 +233,7 @@ namespace ATC {
    /** access to time integrator */
    const TimeIntegrator * time_integrator(const FieldName & field) const {
      _ctiIt_ = timeIntegrators_.find(field);
      if (_ctiIt_ == timeIntegrators_.end()) return NULL;
      if (_ctiIt_ == timeIntegrators_.end()) return nullptr;
      return _ctiIt_->second;
    };

@@ -322,7 +322,7 @@ namespace ATC {
    void compute_flux(const Array2D<bool> & rhs_mask,
                      const FIELDS &fields, 
                      GRAD_FIELD_MATS &flux,
                      const PhysicsModel * physicsModel=NULL,
                      const PhysicsModel * physicsModel=nullptr,
                      const bool normalize = false);
    /** evaluate rhs on the atomic domain which is near the FE region */
    void masked_atom_domain_rhs_integral(const Array2D<bool> & rhs_mask,
@@ -334,7 +334,7 @@ namespace ATC {
                           const FIELDS &fields, 
                           FIELDS &rhs,
                           const IntegrationDomainType domain,
                           const PhysicsModel * physicsModel=NULL);
                           const PhysicsModel * physicsModel=nullptr);
    /** access to boundary fluxes */
    DENS_MAT &get_boundary_flux(FieldName thisField){return boundaryFlux_[thisField].set_quantity();};
    DENS_MAN &boundary_flux(FieldName thisField){return boundaryFlux_[thisField];};
@@ -352,7 +352,7 @@ namespace ATC {
    // mass matrix filtering
    void delete_mass_mat_time_filter(FieldName thisField);
    /** compute mass matrix for requested field */
    void compute_mass_matrix(FieldName thisField, PhysicsModel * physicsModel = NULL);
    void compute_mass_matrix(FieldName thisField, PhysicsModel * physicsModel = nullptr);
    /** updates filtering of MD contributions */
    void update_mass_matrix(FieldName thisField);
    /** compute the mass matrix components coming from MD integration */
+3 −3
Original line number Diff line number Diff line
@@ -30,8 +30,8 @@ namespace ATC {
                                         string matParamFile,
                                         ExtrinsicModelType extrinsicModel)
    : ATC_Coupling(groupName,perAtomArray,thisFix),
      nodalAtomicKineticTemperature_(NULL),
      nodalAtomicConfigurationalTemperature_(NULL)
      nodalAtomicKineticTemperature_(nullptr),
      nodalAtomicConfigurationalTemperature_(nullptr)
  {
    // Allocate PhysicsModel 
    create_physics_model(THERMAL, matParamFile);
@@ -103,7 +103,7 @@ namespace ATC {

    // always need kinetic energy
    AtomicEnergyForTemperature * atomicTwiceKineticEnergy = new TwiceKineticEnergy(this);
    AtomicEnergyForTemperature * atomEnergyForTemperature = NULL;
    AtomicEnergyForTemperature * atomEnergyForTemperature = nullptr;

    // Appropriate per-atom quantity based on desired temperature definition
    if (temperatureDef_==KINETIC) {
+3 −3
Original line number Diff line number Diff line
@@ -32,8 +32,8 @@ namespace ATC {
                                                         string matParamFile,
                                                         ExtrinsicModelType extrinsicModel)
    : ATC_Coupling(groupName,perAtomArray,thisFix),
      nodalAtomicKineticTemperature_(NULL),
      nodalAtomicConfigurationalTemperature_(NULL),
      nodalAtomicKineticTemperature_(nullptr),
      nodalAtomicConfigurationalTemperature_(nullptr),
      refPE_(0)
  {
    // Allocate PhysicsModel 
@@ -190,7 +190,7 @@ namespace ATC {
    FieldManager fieldManager(this);
    PerAtomQuantity<double> * fluctuatingAtomicVelocity = fieldManager.per_atom_quantity("AtomicFluctuatingVelocity"); // also creates ProlongedVelocity
    AtomicEnergyForTemperature * atomicTwiceKineticEnergy = new TwiceKineticEnergy(this,fluctuatingAtomicVelocity);
    AtomicEnergyForTemperature * atomEnergyForTemperature = NULL;
    AtomicEnergyForTemperature * atomEnergyForTemperature = nullptr;

    // Appropriate per-atom quantity based on desired temperature definition
    if (temperatureDef_==KINETIC) {
+26 −26
Original line number Diff line number Diff line
@@ -35,37 +35,37 @@ using std::pair;
namespace ATC {

  ATC_Method::ATC_Method(string groupName, double ** & perAtomArray, LAMMPS_NS::Fix * thisFix) :
    nodalAtomicVolume_(NULL),
    nodalAtomicVolume_(nullptr),
    needReset_(true),
    lammpsInterface_(LammpsInterface::instance()),
    interscaleManager_(this),
    timeFilterManager_(this),
    integrateInternalAtoms_(false),
    atomTimeIntegrator_(NULL),
    atomTimeIntegrator_(nullptr),
    ghostManager_(this),
    feEngine_(NULL),
    feEngine_(nullptr),
    initialized_(false),
    meshDataInitialized_(false),
    localStep_(0),
    sizeComm_(8), // 3 positions + 1 material id * 2 for output
    atomCoarseGrainingPositions_(NULL),
    atomGhostCoarseGrainingPositions_(NULL),
    atomProcGhostCoarseGrainingPositions_(NULL),
    atomReferencePositions_(NULL),
    atomCoarseGrainingPositions_(nullptr),
    atomGhostCoarseGrainingPositions_(nullptr),
    atomProcGhostCoarseGrainingPositions_(nullptr),
    atomReferencePositions_(nullptr),
    nNodes_(0),
    nsd_(lammpsInterface_->dimension()),
    xref_(NULL),
    xref_(nullptr),
    readXref_(false),
    needXrefProcessorGhosts_(false),
    trackDisplacement_(false),
    needsAtomToElementMap_(true),
    atomElement_(NULL),
    atomGhostElement_(NULL),
    atomElement_(nullptr),
    atomGhostElement_(nullptr),
    internalElementSet_(""),
    atomMasses_(NULL),
    atomPositions_(NULL),
    atomVelocities_(NULL),
    atomForces_(NULL),
    atomMasses_(nullptr),
    atomPositions_(nullptr),
    atomVelocities_(nullptr),
    atomForces_(nullptr),
    parallelConsistency_(true),
    outputNow_(false),
    outputTime_(true),
@@ -79,13 +79,13 @@ namespace ATC {
    sizeVector_(0),
    scalarVectorFreq_(0),
    sizePerAtomCols_(4), 
    perAtomOutput_(NULL),
    perAtomOutput_(nullptr),
    perAtomArray_(perAtomArray),
    extScalar_(0),
    extVector_(0),
    extList_(NULL),
    extList_(nullptr),
    thermoEnergyFlag_(0),
    atomVolume_(NULL),
    atomVolume_(nullptr),
    atomicWeightsWriteFlag_(false),
    atomicWeightsWriteFrequency_(0),
    atomWeightType_(LATTICE),
@@ -103,12 +103,12 @@ namespace ATC {
    mdMassNormalization_(false),
    kernelBased_(false),
    kernelOnTheFly_(false),
    kernelFunction_(NULL),
    kernelFunction_(nullptr),
    bondOnTheFly_(false),
    accumulant_(NULL),
    accumulantMol_(NULL),
    accumulantMolGrad_(NULL),
    accumulantWeights_(NULL),
    accumulant_(nullptr),
    accumulantMol_(nullptr),
    accumulantMolGrad_(nullptr),
    accumulantWeights_(nullptr),
    accumulantInverseVolumes_(&invNodeVolumes_),
    accumulantBandwidth_(0),
    useRestart_(false),
@@ -117,7 +117,7 @@ namespace ATC {
    setRefPEvalue_(false),
    refPEvalue_(0.),
    readRefPE_(false),
    nodalRefPotentialEnergy_(NULL),
    nodalRefPotentialEnergy_(nullptr),
    simTime_(0.0),
    stepCounter_(0)
  {
@@ -1122,7 +1122,7 @@ pecified
                           FieldName & thisField, int & thisIndex)
  {
    string thisName = args[argIdx++];
    if (args[argIdx] == NULL) {
    if (args[argIdx] == nullptr) {
      throw ATC_Error("Need to give field '"+thisName+"' more args");
    }
    thisField = string_to_field(thisName);
@@ -1282,7 +1282,7 @@ pecified
    if (this->reset_methods()) {
      // clear memory manager
      interscaleManager_.clear_temporary_data();
      atomVolume_ = NULL;
      atomVolume_ = nullptr;

      // reference positions and energy
      if (!initialized_) {
@@ -1517,7 +1517,7 @@ pecified
    }
    else {
      // set variables to compute atomic weights
      DENS_MAN * nodalVolume(NULL);
      DENS_MAN * nodalVolume(nullptr);
      switch (atomWeightType_) {
      case USER:
        atomVolume_ = new AtomVolumeUser(this,Valpha_);
Loading