Index: src/Dynamics/BondVectors.cpp
===================================================================
--- src/Dynamics/BondVectors.cpp	(revision 8f50b4adab0382b92f8e46cd26895315f53857e7)
+++ src/Dynamics/BondVectors.cpp	(revision 8f50b4adab0382b92f8e46cd26895315f53857e7)
@@ -0,0 +1,77 @@
+/*
+ * Project: MoleCuilder
+ * Description: creates and alters molecular systems
+ * Copyright (C)  2017 Frederik Heber. All rights reserved.
+ *
+ *
+ *   This file is part of MoleCuilder.
+ *
+ *    MoleCuilder is free software: you can redistribute it and/or modify
+ *    it under the terms of the GNU General Public License as published by
+ *    the Free Software Foundation, either version 2 of the License, or
+ *    (at your option) any later version.
+ *
+ *    MoleCuilder is distributed in the hope that it will be useful,
+ *    but WITHOUT ANY WARRANTY; without even the implied warranty of
+ *    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ *    GNU General Public License for more details.
+ *
+ *    You should have received a copy of the GNU General Public License
+ *    along with MoleCuilder.  If not, see <http://www.gnu.org/licenses/>.
+ */
+
+/*
+ * BondVectors.cpp
+ *
+ *  Created on: Jun 13, 2017
+ *      Author: heber
+ */
+
+
+// include config.h
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+//#include "CodePatterns/MemDebug.hpp"
+
+#include "BondVectors.hpp"
+
+#include <algorithm>
+#include <iterator>
+
+#include "Atom/atom.hpp"
+
+BondVectors::mapped_t BondVectors::getBondVectorsAtStep(
+    const size_t &_step) const
+{
+  mapped_t returnlist;
+
+  ASSERT( !container.empty(),
+      "BondVectors::getBondVectors() - container empty, not set properly?");
+  for (container_t::const_iterator iter = container.begin();
+      iter != container.end(); ++iter) {
+    const bond::ptr &current_bond = *iter;
+    Vector BondVector = current_bond->leftatom->getPositionAtStep(_step)
+        - current_bond->rightatom->getPositionAtStep(_step);
+    BondVector.Normalize();
+    returnlist.insert( std::make_pair(current_bond, BondVector) );
+  }
+  ASSERT( returnlist.size() == container.size(),
+      "BondVectors::getBondVectors() - not same amount of bond vectors as bonds?");
+
+  return returnlist;
+}
+
+size_t BondVectors::getIndexForBond(const bond::ptr &_bond) const
+{
+  std::pair<
+      container_t::const_iterator,
+      container_t::const_iterator> iters =
+          std::equal_range(container.begin(), container.end(), _bond);
+  if (iters.first != container.end())
+    return std::distance(container.begin(), iters.first);
+  else
+    return (size_t)-1;
+}
+
Index: src/Dynamics/BondVectors.hpp
===================================================================
--- src/Dynamics/BondVectors.hpp	(revision 8f50b4adab0382b92f8e46cd26895315f53857e7)
+++ src/Dynamics/BondVectors.hpp	(revision 8f50b4adab0382b92f8e46cd26895315f53857e7)
@@ -0,0 +1,84 @@
+/*
+ * BondVectors.hpp
+ *
+ *  Created on: Jun 13, 2017
+ *      Author: heber
+ */
+
+
+#ifndef DYNAMICS_BONDVECTORS_HPP_
+#define DYNAMICS_BONDVECTORS_HPP_
+
+// include config.h
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <map>
+#include <vector>
+
+#include "CodePatterns/Assert.hpp"
+
+#include "LinearAlgebra/Vector.hpp"
+
+#include "Bond/bond.hpp"
+
+/** This class represents all bond vectors, i.e. the normalized direction
+ * along a list of bonds, and provides means to extract them from a set of
+ * atoms such that for an arbitrary bond the vector can be quickly retrieved.
+ */
+class BondVectors
+{
+public:
+  //!> typedef for the internal container of the bonds
+  typedef std::vector<bond::ptr> container_t;
+
+  //!> typedef for the association of bonds to bond vectors
+  typedef std::map<bond::ptr, Vector> mapped_t;
+
+  /** Prepares the internal container from the bonds of a range of atoms.
+   *
+   * \param _start start of range
+   * \param _end end of range
+   * \param _step time step to request bonds for
+   */
+  template <class T>
+  void setFromAtomRange(
+      typename T::iterator _start,
+      typename T::iterator _end,
+      const size_t &_step);
+
+  /** Getter for the sorted bonds.
+   *
+   * \return const ref to internal container
+   */
+  const container_t& getSorted() const
+  {
+    ASSERT( !container.empty(),
+        "BondVectors::getSorted() - empty internal container, not set properly?");
+    return container;
+  }
+
+  /** Calculates the bond vector for each bond in the internal container and
+   * returns them in same order as the internal container.
+   *
+   * \param _step time step for which the bond vector is request
+   * \return a map from bond to bond vector
+   */
+  mapped_t getBondVectorsAtStep(const size_t &_step) const;
+
+  /** Get the position in the internal container for a specific bond.
+   *
+   * \param _bond given bond
+   * \return position in the vector, -1 if not present
+   */
+  size_t getIndexForBond(const bond::ptr &_bond) const;
+
+private:
+  //!> internal container for sorted bonds
+  container_t container;
+};
+
+#include "BondVectors_impl.hpp"
+
+#endif /* DYNAMICS_BONDVECTORS_HPP_ */
Index: src/Dynamics/BondVectors_impl.hpp
===================================================================
--- src/Dynamics/BondVectors_impl.hpp	(revision 8f50b4adab0382b92f8e46cd26895315f53857e7)
+++ src/Dynamics/BondVectors_impl.hpp	(revision 8f50b4adab0382b92f8e46cd26895315f53857e7)
@@ -0,0 +1,41 @@
+/*
+ * BondVectors_impl.hpp
+ *
+ *  Created on: Jun 13, 2017
+ *      Author: heber
+ */
+
+
+#ifndef DYNAMICS_BONDVECTORS_IMPL_HPP_
+#define DYNAMICS_BONDVECTORS_IMPL_HPP_
+
+// include config.h
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include "BondVectors.hpp"
+
+#include <algorithm>
+
+#include "Atom/atom.hpp"
+
+template <class T>
+void BondVectors::setFromAtomRange(
+    typename T::iterator _start,
+    typename T::iterator _end,
+    const size_t &_step)
+{
+  container.clear();
+  for (typename T::iterator iter = _start; iter != _end; ++iter) {
+    const atom &walker = **iter;
+    const BondList &ListOfBonds = walker.getListOfBondsAtStep(_step);
+    container.insert(container.end(), ListOfBonds.begin(), ListOfBonds.end());
+  }
+  // sort and make unique
+  std::sort(container.begin(), container.end());
+  container.erase(std::unique(container.begin(), container.end()), container.end());
+}
+
+
+#endif /* DYNAMICS_BONDVECTORS_IMPL_HPP_ */
Index: src/Makefile.am
===================================================================
--- src/Makefile.am	(revision 971b2fa4c465ad133c9674de63f884d1675180df)
+++ src/Makefile.am	(revision 8f50b4adab0382b92f8e46cd26895315f53857e7)
@@ -108,8 +108,11 @@
 
 DYNAMICSSOURCE = \
+	Dynamics/BondVectors.cpp \
 	Dynamics/MinimiseConstrainedPotential.cpp
 
 DYNAMICSHEADER = \
 	Dynamics/AtomicForceManipulator.hpp \
+	Dynamics/BondVectors.hpp \
+	Dynamics/BondVectors_impl.hpp \
 	Dynamics/ForceAnnealing.hpp \
 	Dynamics/LinearInterpolationBetweenSteps.hpp \
