Ignore:
Timestamp:
Aug 20, 2014, 1:09:40 PM (11 years ago)
Author:
Frederik Heber <heber@…>
Branches:
Action_Thermostats, Add_AtomRandomPerturbation, Add_FitFragmentPartialChargesAction, Add_RotateAroundBondAction, Add_SelectAtomByNameAction, Added_ParseSaveFragmentResults, AddingActions_SaveParseParticleParameters, Adding_Graph_to_ChangeBondActions, Adding_MD_integration_tests, Adding_ParticleName_to_Atom, Adding_StructOpt_integration_tests, AtomFragments, Automaking_mpqc_open, AutomationFragmentation_failures, Candidate_v1.5.4, Candidate_v1.6.0, Candidate_v1.6.1, ChangeBugEmailaddress, ChangingTestPorts, ChemicalSpaceEvaluator, CombiningParticlePotentialParsing, Combining_Subpackages, Debian_Package_split, Debian_package_split_molecuildergui_only, Disabling_MemDebug, Docu_Python_wait, EmpiricalPotential_contain_HomologyGraph, EmpiricalPotential_contain_HomologyGraph_documentation, Enable_parallel_make_install, Enhance_userguide, Enhanced_StructuralOptimization, Enhanced_StructuralOptimization_continued, Example_ManyWaysToTranslateAtom, Exclude_Hydrogens_annealWithBondGraph, FitPartialCharges_GlobalError, Fix_BoundInBox_CenterInBox_MoleculeActions, Fix_ChargeSampling_PBC, Fix_ChronosMutex, Fix_FitPartialCharges, Fix_FitPotential_needs_atomicnumbers, Fix_ForceAnnealing, Fix_IndependentFragmentGrids, Fix_ParseParticles, Fix_ParseParticles_split_forward_backward_Actions, Fix_PopActions, Fix_QtFragmentList_sorted_selection, Fix_Restrictedkeyset_FragmentMolecule, Fix_StatusMsg, Fix_StepWorldTime_single_argument, Fix_Verbose_Codepatterns, Fix_fitting_potentials, Fixes, ForceAnnealing_goodresults, ForceAnnealing_oldresults, ForceAnnealing_tocheck, ForceAnnealing_with_BondGraph, ForceAnnealing_with_BondGraph_continued, ForceAnnealing_with_BondGraph_continued_betteresults, ForceAnnealing_with_BondGraph_contraction-expansion, FragmentAction_writes_AtomFragments, FragmentMolecule_checks_bonddegrees, GeometryObjects, Gui_Fixes, Gui_displays_atomic_force_velocity, ImplicitCharges, IndependentFragmentGrids, IndependentFragmentGrids_IndividualZeroInstances, IndependentFragmentGrids_IntegrationTest, IndependentFragmentGrids_Sole_NN_Calculation, JobMarket_RobustOnKillsSegFaults, JobMarket_StableWorkerPool, JobMarket_unresolvable_hostname_fix, MoreRobust_FragmentAutomation, ODR_violation_mpqc_open, PartialCharges_OrthogonalSummation, PdbParser_setsAtomName, PythonUI_with_named_parameters, QtGui_reactivate_TimeChanged_changes, Recreated_GuiChecks, Rewrite_FitPartialCharges, RotateToPrincipalAxisSystem_UndoRedo, SaturateAtoms_findBestMatching, SaturateAtoms_singleDegree, StoppableMakroAction, Subpackage_CodePatterns, Subpackage_JobMarket, Subpackage_LinearAlgebra, Subpackage_levmar, Subpackage_mpqc_open, Subpackage_vmg, Switchable_LogView, ThirdParty_MPQC_rebuilt_buildsystem, TrajectoryDependenant_MaxOrder, TremoloParser_IncreasedPrecision, TremoloParser_MultipleTimesteps, TremoloParser_setsAtomName, Ubuntu_1604_changes, stable
Children:
fc3aff
Parents:
2a03b0 (diff), 343c5a (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

Merge branch 'EnhancingHydrogenSaturation' into stable

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/Fragmentation/Exporters/SaturatedFragment.hpp

    r2a03b0 ree4f2d  
    1818#include <string>
    1919
     20#include "Atom/atom_bondedparticleinfo.hpp"
    2021#include "Bond/bond.hpp"
    2122#include "Fragmentation/KeySet.hpp"
    2223#include "Fragmentation/HydrogenSaturation_enum.hpp"
    2324#include "Parser/FormatParserStorage.hpp"
     25
     26#include "LinearAlgebra/Vector.hpp"
    2427
    2528class atom;
     
    4245  typedef std::set<KeySet> KeySetsInUse_t;
    4346
     47  //!> List of points giving saturation positions for a single bond neighbor
     48  typedef std::list<Vector> SaturationsPositions_t;
     49  //!> map for one atom, containing the saturation points for all its neighbors
     50  typedef std::map<int, SaturationsPositions_t> SaturationsPositionsPerNeighbor_t;
     51  //!> containing the saturation points over all desired atoms required
     52  typedef std::map<int, SaturationsPositionsPerNeighbor_t> GlobalSaturationPositions_t;
     53
    4454  /** Constructor of SaturatedFragment requires \a set which we are tightly
    4555   * associated.
     
    4858   * \param _container container to add KeySet as in-use
    4959   * \param _hydrogens pool with hydrogens for saturation
     60   * \param _globalsaturationpositions saturation positions to be used
    5061   */
    5162  SaturatedFragment(
     
    5465      HydrogenPool &_hydrogens,
    5566      const enum HydrogenTreatment _treatment,
    56       const enum HydrogenSaturation saturation);
     67      const enum HydrogenSaturation saturation,
     68      const GlobalSaturationPositions_t &_globalsaturationpositions);
    5769
    5870  /** Destructor of class SaturatedFragment.
     
    100112  /** Helper function to lease and bring in place saturation hydrogens.
    101113   *
     114   * Here, we use local information to calculate saturation positions.
     115   *
    102116   */
    103117  void saturate();
     118
     119  /** Helper function to lease and bring in place saturation hydrogens.
     120   *
     121   * Here, saturation positions have to be calculated before and are fully
     122   * stored in \a _globalsaturationpositions.
     123   *
     124   * \param_globalsaturationpositions
     125   */
     126  void saturate(const GlobalSaturationPositions_t &_globalsaturationpositions);
     127
     128  /** Replaces all cut bonds with respect to the given atom by hydrogens.
     129   *
     130   * \param _atom atom whose cut bonds to saturate
     131   * \param _cutbonds list of cut bonds for \a _atom
     132   * \return true - bonds saturated, false - something went wrong
     133   */
     134  bool saturateAtom(atom * const _atom, const BondList &_cutbonds);
    104135
    105136  /** Helper function to get a hydrogen replacement for a given \a replacement.
     
    109140   */
    110141  atom * const getHydrogenReplacement(atom * const replacement);
     142
     143  /** Sets a saturation hydrogen at the given position in place of \a _father.
     144   *
     145   * \param _OwnerAtom atom "owning" the hydrogen (i.e. the one getting saturated)
     146   * \param _position new position relative to \a _OwnerAtom
     147   * \param _distance scale factor to the distance (default 1.)
     148   * \param _father bond partner of \a _OwnerAtom that is replaced
     149   */
     150  const atom& setHydrogenReplacement(
     151      const atom * const _OwnerAtom,
     152      const Vector &_position,
     153      const double _distance,
     154      atom * const _father);
    111155
    112156  /** Leases and adds a Hydrogen atom in replacement for the given atom \a *partner in bond with a *origin.
Note: See TracChangeset for help on using the changeset viewer.