source: src/Actions/FragmentationAction/AddSelectedAtomsAsFragmentAction.def

Candidate_v1.7.1 stable v1.7.1
Last change on this file was dce5a3, checked in by Frederik Heber <frederik.heber@…>, 6 weeks ago

Adds AddSelectedAtomsAsFragmentAction.

  • this action allows calculating the energy of an entire molecule without relying on BOSSANOVA/fragmentation. This allows to compute small molecules which are not saturated other well-captured by the fragmentation scheme.
  • DOC: Adds entry in userguide.
  • TEST: Adds regresssion test case.
  • Property mode set to 100644
File size: 2.1 KB
RevLine 
[dce5a3]1/*
2 * AddSelectedAtomsAsFragmentAction.def
3 *
4 * Created on: Nov 20, 2025
5 * Author: heber
6 */
7
8// all includes and forward declarations necessary for non-integral types below
9#include <boost/assign.hpp>
10#include <string>
11#include <vector>
12
13#include "Parameters/Validators/DummyValidator.hpp"
14#include "Parameters/Validators/RangeValidator.hpp"
15#include "Parameters/Validators/STLVectorValidator.hpp"
16#include "Parameters/Validators/Specific/BoxLengthValidator.hpp"
17#include "Parameters/Validators/Specific/ParserTypeValidator.hpp"
18
19// i.e. there is an integer with variable name Z that can be found in
20// ValueStorage by the token "Z" -> first column: int, Z, "Z"
21// "undefine" if no parameters are required, use (NOPARAM_DEFAULT) for each (undefined) default value
22#define paramtypes (std::string)(std::vector<std::string>)(double)(unsigned int)
23#define paramtokens ("add-selected-atoms-as-fragment")("output-types")("max-meshwidth")("grid-level")
24#define paramdescriptions ("prefix of each fragment file")("type(s) of parsers that output fragment config files")("maximum allowed mesh width, i.e. discrete points may be at most that far apart on the fragment grids")("resolution of density sampling multigrid")
25#define paramdefaults (PARAM_DEFAULT("BondFragment"))(PARAM_DEFAULT(std::vector<std::string>()))(PARAM_DEFAULT(0.))(PARAM_DEFAULT(5))
26#define paramreferences (prefix)(types)(max_meshwidth)(level)
27#define paramvalids \
28(DummyValidator< std::string >()) \
29(STLVectorValidator< std::vector<std::string> >(0, 10, ParserTypeValidator())) \
30(BoxLengthValidator()) \
31(RangeValidator< unsigned int >(1, 10))
32
33#undef statetypes
34#undef statereferences
35
36// some defines for all the names, you may use ACTION, STATE and PARAMS
37#define CATEGORY Fragmentation
38#define MENUNAME "fragmentation"
39#define MENUPOSITION 9
40#define ACTIONNAME AddSelectedAtomsAsFragment
41#define TOKEN "add-selected-atoms-as-fragment"
42
43// finally the information stored in the ActionTrait specialization
44#define DESCRIPTION "This adds all currently selected atoms as one single fragment to the job queue"
45#undef SHORTFORM
Note: See TracBrowser for help on using the repository browser.