Index: src/Potentials/Specifics/PairPotential_LennardJones.hpp
===================================================================
--- src/Potentials/Specifics/PairPotential_LennardJones.hpp	(revision 1413f4555b944ca972d0d485541e58d325f62feb)
+++ src/Potentials/Specifics/PairPotential_LennardJones.hpp	(revision 1413f4555b944ca972d0d485541e58d325f62feb)
@@ -0,0 +1,204 @@
+/*
+ * PairPotential_LennardJones.hpp
+ *
+ *  Created on: Jul 05, 2013
+ *      Author: heber
+ */
+
+#ifndef PAIRPOTENTIAL_LENNARDJONES_HPP_
+#define PAIRPOTENTIAL_LENNARDJONES_HPP_
+
+
+// include config.h
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <limits>
+
+#include "Potentials/EmpiricalPotential.hpp"
+
+class PotentialFactory;
+class TrainingData;
+
+/** This is the implementation of a constant potential to adapt to any offset
+ * in the potential energy.
+ *
+ * This evaluates \f$ k \f$.
+ *
+ */
+class PairPotential_LennardJones :
+  public EmpiricalPotential
+{
+  //!> grant unit test access to internal parts
+  friend class PairPotential_LennardJonesTest;
+  //!> grant PotentialFactory access to default cstor
+  friend class PotentialFactory;
+  // some repeated typedefs to avoid ambiguities
+  typedef FunctionModel::arguments_t arguments_t;
+  typedef FunctionModel::result_t result_t;
+  typedef FunctionModel::results_t results_t;
+  typedef EmpiricalPotential::derivative_components_t derivative_components_t;
+  typedef FunctionModel::parameters_t parameters_t;
+private:
+  /** Private default constructor.
+   *
+   * This prevents creation of potential without set ParticleTypes_t.
+   *
+   * \note PotentialFactory may use this default cstor
+   *
+   */
+  PairPotential_LennardJones();
+
+public:
+  PairPotential_LennardJones(const ParticleTypes_t &_ParticleTypes);
+  PairPotential_LennardJones(
+      const ParticleTypes_t &_ParticleTypes,
+      const double _epsilon,
+      const double _sigma
+      );
+  virtual ~PairPotential_LennardJones() {}
+
+  /** Setter for parameters as required by FunctionModel interface.
+   *
+   * \param _params given set of parameters
+   */
+  void setParameters(const parameters_t &_params);
+
+  /** Getter for parameters as required by FunctionModel interface.
+   *
+   * \return set of parameters
+   */
+  parameters_t getParameters() const
+  {
+    return params;
+  }
+
+  /** Sets the parameter randomly within the sensible range of each parameter.
+   *
+   * \param data container with training data for guesstimating range
+   */
+  void setParametersToRandomInitialValues(const TrainingData &data);
+
+  /** Getter for the number of parameters of this model function.
+   *
+   * \return number of parameters
+   */
+  size_t getParameterDimension() const
+  {
+    return 2;
+  }
+
+  /** Evaluates the harmonic potential function for the given arguments.
+   *
+   * @param arguments single distance
+   * @return value of the potential function
+   */
+  results_t operator()(const arguments_t &arguments) const;
+
+  /** Evaluates the derivative of the potential function.
+   *
+   * @param arguments single distance
+   * @return vector with derivative with respect to the input degrees of freedom
+   */
+  derivative_components_t derivative(const arguments_t &arguments) const;
+
+  /** Evaluates the derivative of the function with the given \a arguments
+   * with respect to a specific parameter indicated by \a index.
+   *
+   * \param arguments set of arguments as input variables to the function
+   * \param index derivative of which parameter
+   * \return result vector containing the derivative with respect to the given
+   *         input
+   */
+  results_t parameter_derivative(const arguments_t &arguments, const size_t index) const;
+
+  /** Return the token name of this specific potential.
+   *
+   * \return token name of the potential
+   */
+  const std::string& getToken() const
+  { return potential_token; }
+
+  /** Returns a vector of parameter names.
+   *
+   * This is required from the specific implementation
+   *
+   * \return vector of strings containing parameter names
+   */
+  const ParameterNames_t& getParameterNames() const
+  { return ParameterNames; }
+
+  /** States whether lower and upper boundaries should be used to constraint
+   * the parameter search for this function model.
+   *
+   * \return true - constraints should be used, false - else
+   */
+  bool isBoxConstraint() const {
+    return true;
+  }
+
+  /** Returns a vector which are the lower boundaries for each parameter_t
+   * of this FunctionModel.
+   *
+   * \return vector of parameter_t resembling lowest allowed values
+   */
+  parameters_t getLowerBoxConstraints() const {
+    parameters_t lowerbound(getParameterDimension(), 0.);
+    return lowerbound;
+  }
+
+  /** Returns a vector which are the upper boundaries for each parameter_t
+   * of this FunctionModel.
+   *
+   * \return vector of parameter_t resembling highest allowed values
+   */
+  parameters_t getUpperBoxConstraints() const {
+    return parameters_t(getParameterDimension(), std::numeric_limits<double>::max());
+  }
+
+  /** Returns a bound function to be used with TrainingData, extracting distances
+   * from a Fragment.
+   *
+   * \return bound function extracting distances from a fragment
+   */
+  FunctionModel::extractor_t getSpecificExtractor() const;
+
+  /** Returns a bound function to be used with TrainingData, extracting distances
+   * from a Fragment.
+   *
+   * \return bound function extracting distances from a fragment
+   */
+  FunctionModel::filter_t getSpecificFilter() const;
+
+  /** Returns the number of arguments the underlying function requires.
+   *
+   * \return number of arguments of the function
+   */
+  size_t getSpecificArgumentCount() const
+  { return 0; }
+
+  enum parameter_enum_t {
+    epsilon=0,
+    sigma=1,
+    MAXPARAMS
+  };
+
+private:
+  /** Sets some sensible default parameter values.
+   *
+   */
+  void setDefaultParameters();
+
+private:
+  //!> parameter vector with parameters as in enum parameter_enum_t
+  parameters_t params;
+
+  //!> static definitions of the parameter name for this potential
+  static const ParameterNames_t ParameterNames;
+
+  //!> static token of this potential type
+  static const std::string potential_token;
+};
+
+#endif /* PAIRPOTENTIAL_LENNARDJONES_HPP_ */
