Skip to content

Commit

Permalink
Remove HarmonicDumbbell.
Browse files Browse the repository at this point in the history
  • Loading branch information
KaiSzuttor committed Oct 26, 2020
1 parent fbbddd2 commit 12e4de8
Show file tree
Hide file tree
Showing 11 changed files with 0 additions and 338 deletions.
28 changes: 0 additions & 28 deletions doc/sphinx/inter_bonded.rst
Original file line number Diff line number Diff line change
Expand Up @@ -87,34 +87,6 @@ The third, optional parameter defines a cutoff radius. Whenever a
harmonic bond gets longer than :math:`r_\mathrm{cut}`, the bond will be reported as broken,
and a background error will be raised.

.. _Harmonic Dumbbell Bond:

Harmonic Dumbbell Bond
~~~~~~~~~~~~~~~~~~~~~~

.. note::

Requires ``ROTATION`` feature.


A harmonic Dumbbell bond can be instantiated via
:class:`espressomd.interactions.HarmonicDumbbellBond`::

from espressomd.interactions import HarmonicDumbbellBond
hdb = HarmonicDumbbellBond(k1=<float>, k2=<float>, r_0=<float>, r_cut=<float>)


This bond is similar to the normal harmonic bond in such a way that it
sets up a harmonic potential, i.e. a spring, between the two particles.
Additionally the orientation of the first particle in the bond will be aligned along
the distance vector between both particles. This alignment can be
controlled by the second harmonic constant :math:`k_2`. Keep in mind that orientation will
oscillate around the distance vector and some kind of
friction needs to be present for it to relax.

The roles of the parameters :math:`k_1, r_0, r_\mathrm{cut}` are exactly the same as for the
harmonic bond.

.. _Quartic bond:

Quartic bond
Expand Down
1 change: 0 additions & 1 deletion src/core/bonded_interactions/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ target_sources(
${CMAKE_CURRENT_SOURCE_DIR}/dihedral.cpp
${CMAKE_CURRENT_SOURCE_DIR}/fene.cpp
${CMAKE_CURRENT_SOURCE_DIR}/harmonic.cpp
${CMAKE_CURRENT_SOURCE_DIR}/harmonic_dumbbell.cpp
${CMAKE_CURRENT_SOURCE_DIR}/quartic.cpp
${CMAKE_CURRENT_SOURCE_DIR}/thermalized_bond.cpp
${CMAKE_CURRENT_SOURCE_DIR}/umbrella.cpp)
2 changes: 0 additions & 2 deletions src/core/bonded_interactions/bonded_interaction_data.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,6 @@ auto cutoff(int type, Bond_parameters const &bp) {
return bp.fene.cutoff();
case BONDED_IA_HARMONIC:
return bp.harmonic.cutoff();
case BONDED_IA_HARMONIC_DUMBBELL:
return bp.harmonic_dumbbell.cutoff();
case BONDED_IA_QUARTIC:
return bp.quartic.cutoff();
case BONDED_IA_BONDED_COULOMB:
Expand Down
1 change: 0 additions & 1 deletion src/core/bonded_interactions/bonded_interaction_data.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -367,7 +367,6 @@ union Bond_parameters {
Oif_global_forces_bond_parameters oif_global_forces;
Oif_local_forces_bond_parameters oif_local_forces;
Harmonic_bond_parameters harmonic;
Harmonic_dumbbell_bond_parameters harmonic_dumbbell;
Quartic_bond_parameters quartic;
Bonded_coulomb_bond_parameters bonded_coulomb;
Bonded_coulomb_sr_bond_parameters bonded_coulomb_sr;
Expand Down
52 changes: 0 additions & 52 deletions src/core/bonded_interactions/harmonic_dumbbell.cpp

This file was deleted.

102 changes: 0 additions & 102 deletions src/core/bonded_interactions/harmonic_dumbbell.hpp

This file was deleted.

5 changes: 0 additions & 5 deletions src/core/energy_inline.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,6 @@
#include "bonded_interactions/dihedral.hpp"
#include "bonded_interactions/fene.hpp"
#include "bonded_interactions/harmonic.hpp"
#include "bonded_interactions/harmonic_dumbbell.hpp"
#include "bonded_interactions/quartic.hpp"
#include "bonded_interactions/umbrella.hpp"
#include "errorhandling.hpp"
Expand Down Expand Up @@ -219,10 +218,6 @@ calc_bonded_energy(Bonded_ia_parameters const &iaparams, Particle const &p1,
switch (type) {
case BONDED_IA_FENE:
return fene_pair_energy(iaparams, dx);
#ifdef ROTATION
case BONDED_IA_HARMONIC_DUMBBELL:
return harmonic_dumbbell_pair_energy(p1.r.calc_director(), iaparams, dx);
#endif
case BONDED_IA_HARMONIC:
return harmonic_pair_energy(iaparams, dx);
case BONDED_IA_QUARTIC:
Expand Down
13 changes: 0 additions & 13 deletions src/core/forces_inline.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@
#include "bonded_interactions/dihedral.hpp"
#include "bonded_interactions/fene.hpp"
#include "bonded_interactions/harmonic.hpp"
#include "bonded_interactions/harmonic_dumbbell.hpp"
#include "bonded_interactions/quartic.hpp"
#include "bonded_interactions/thermalized_bond.hpp"
#include "bonded_interactions/umbrella.hpp"
Expand Down Expand Up @@ -311,18 +310,6 @@ calc_bond_pair_force(Particle const &p1, Particle const &p2,
switch (iaparams.type) {
case BONDED_IA_FENE:
return fene_pair_force(iaparams, dx);
#ifdef ROTATION
case BONDED_IA_HARMONIC_DUMBBELL: {
auto values =
harmonic_dumbbell_pair_force(p1.r.calc_director(), iaparams, dx);
if (values) {
torque = std::get<1>(values.get());
return boost::optional<Utils::Vector3d>(std::get<0>(values.get()));
}

return {};
}
#endif
case BONDED_IA_HARMONIC:
return harmonic_pair_force(iaparams, dx);
case BONDED_IA_QUARTIC:
Expand Down
6 changes: 0 additions & 6 deletions src/python/espressomd/interactions.pxd
Original file line number Diff line number Diff line change
Expand Up @@ -482,7 +482,6 @@ cdef extern from "bonded_interactions/bonded_interaction_data.hpp":
Bonded_coulomb_bond_parameters bonded_coulomb
Bonded_coulomb_sr_bond_parameters bonded_coulomb_sr
Harmonic_bond_parameters harmonic
Harmonic_dumbbell_bond_parameters harmonic_dumbbell
Angle_harmonic_bond_parameters angle_harmonic
Angle_cosine_bond_parameters angle_cosine
Angle_cossquare_bond_parameters angle_cossquare
Expand Down Expand Up @@ -550,10 +549,6 @@ cdef extern from "immersed_boundary/ibm_triel.hpp":
cdef extern from "immersed_boundary/ibm_tribend.hpp":
int IBM_Tribend_SetParams(const int bond_type, const int ind1, const int ind2, const int ind3, const int ind4, const double kb, const cbool flat)

IF ROTATION:
cdef extern from "bonded_interactions/harmonic_dumbbell.hpp":
int harmonic_dumbbell_set_params(int bond_type, double k1, double k2, double r, double r_cut)

cdef extern from "bonded_interactions/bonded_interaction_data.hpp":
cdef enum TabulatedBondedInteraction:
TAB_UNKNOWN = 0, TAB_BOND_LENGTH, TAB_BOND_ANGLE, TAB_BOND_DIHEDRAL
Expand All @@ -576,7 +571,6 @@ cdef extern from "bonded_interactions/bonded_interaction_data.hpp":
BONDED_IA_NONE = -1,
BONDED_IA_FENE,
BONDED_IA_HARMONIC,
BONDED_IA_HARMONIC_DUMBBELL,
BONDED_IA_BONDED_COULOMB,
BONDED_IA_BONDED_COULOMB_SR,
BONDED_IA_DIHEDRAL,
Expand Down
Loading

0 comments on commit 12e4de8

Please sign in to comment.