Line data Source code
1 : /* +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 2 : Copyright (c) 2011-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 : #include "core/ActionShortcut.h" 23 : #include "core/ActionRegister.h" 24 : #include "MultiColvarShortcuts.h" 25 : 26 : //+PLUMEDOC MCOLVAR UWALLS 27 : /* 28 : Add lower walls to a vector of quantities 29 : 30 : Depracated action: use [UPPER_WALLS](UPPER_WALLS.md) 31 : 32 : */ 33 : //+ENDPLUMEDOC 34 : 35 : namespace PLMD { 36 : namespace multicolvar { 37 : 38 : class UWalls : public ActionShortcut { 39 : public: 40 : static void registerKeywords(Keywords& keys); 41 : explicit UWalls(const ActionOptions&); 42 : }; 43 : 44 : PLUMED_REGISTER_ACTION(UWalls,"UWALLS") 45 : 46 2 : void UWalls::registerKeywords(Keywords& keys) { 47 2 : ActionShortcut::registerKeywords( keys ); 48 4 : keys.setDeprecated("UPPER_WALLS"); 49 2 : keys.add("compulsory","DATA","the values you want to restrain"); 50 2 : keys.add("compulsory","AT","the radius of the sphere"); 51 2 : keys.add("compulsory","KAPPA","the force constant for the wall. The k_i in the expression for a wall."); 52 2 : keys.add("compulsory","OFFSET","0.0","the offset for the start of the wall. The o_i in the expression for a wall."); 53 2 : keys.add("compulsory","EXP","2.0","the powers for the walls. The e_i in the expression for a wall."); 54 2 : keys.add("compulsory","EPS","1.0","the values for s_i in the expression for a wall"); 55 2 : keys.add("atoms","CATOMS","all the angles between the bonds that radiate out from these central atom are computed"); 56 2 : keys.add("atoms","GROUP","a list of angls between pairs of bonds connecting one of the atoms specified using the CATOM command and two of the atoms specified here are computed"); 57 2 : keys.add("compulsory","SWITCH","the switching function specifies that only those bonds that have a length that is less than a certain threshold are considered"); 58 4 : keys.addOutputComponent("bias","default","scalar","the instantaneous value of the bias potential"); 59 4 : keys.addOutputComponent("force2","default","scalar","the instantaneous value of the squared force due to this bias potential"); 60 2 : keys.needsAction("UPPER_WALLS"); 61 2 : } 62 : 63 0 : UWalls::UWalls(const ActionOptions& ao): 64 : Action(ao), 65 0 : ActionShortcut(ao) { 66 : std::string data; 67 0 : parse("DATA",data); 68 0 : readInputLine( getShortcutLabel() + ": UPPER_WALLS ARG=" + data + " " + convertInputLineToString() ); 69 0 : } 70 : 71 : } 72 : }