LCOV - code coverage report
Current view: top level - core - FlexibleBin.h (source / functions) Hit Total Coverage
Test: plumed test coverage Lines: 1 1 100.0 %
Date: 2018-12-19 07:49:13 Functions: 1 1 100.0 %

          Line data    Source code
       1             : /* +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
       2             :    Copyright (c) 2012-2018 The plumed team
       3             :    (see the PEOPLE file at the root of the distribution for a list of names)
       4             : 
       5             :    See http://www.plumed.org for more information.
       6             : 
       7             :    This file is part of plumed, version 2.
       8             : 
       9             :    plumed is free software: you can redistribute it and/or modify
      10             :    it under the terms of the GNU Lesser General Public License as published by
      11             :    the Free Software Foundation, either version 3 of the License, or
      12             :    (at your option) any later version.
      13             : 
      14             :    plumed is distributed in the hope that it will be useful,
      15             :    but WITHOUT ANY WARRANTY; without even the implied warranty of
      16             :    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
      17             :    GNU Lesser General Public License for more details.
      18             : 
      19             :    You should have received a copy of the GNU Lesser General Public License
      20             :    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
      21             : +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
      22             : #ifndef __PLUMED_core_FlexibleBin_h
      23             : #define __PLUMED_core_FlexibleBin_h
      24             : 
      25             : #include<vector>
      26             : 
      27             : namespace PLMD {
      28             : 
      29             : class ActionWithArguments;
      30             : 
      31          21 : class FlexibleBin {
      32             : private:
      33             :   const int type;
      34             :   // this contains all the infos about the CVs including periodicity
      35             :   ActionWithArguments *paction;
      36             :   double sigma;
      37             :   // variance is the matrix that really matters
      38             :   std::vector<double> variance;
      39             :   // this is only there
      40             :   std::vector<double> average;
      41             :   // minimum and maximum values
      42             :   std::vector<double> sigmamin;
      43             :   std::vector<double> sigmamax;
      44             :   std::vector<bool>  limitmax;
      45             :   std::vector<bool>  limitmin;
      46             : public:
      47             :   /// a constructor that takes the pointer of the action that contains it
      48             :   FlexibleBin(int type,ActionWithArguments *paction, double const &d, std::vector<double> &sigmamin, std::vector<double> &sigmamax );
      49             :   /// update the average (always for diffusion) or calculate the geom covariance (  only when do_when_zero is zero)
      50             :   void update(bool nowAddAHill );
      51             :   std::vector<double> getMatrix() const;
      52             :   std::vector<double> getInverseMatrix() const;
      53             :   enum AdaptiveHillsType { none, diffusion, geometry };
      54             : };
      55             : 
      56             : 
      57             : 
      58             : }
      59             : #endif

Generated by: LCOV version 1.13