initial commit for version 1.6.x patch release
[OpenFOAM-1.6.x.git] / src / lagrangian / molecularDynamics / potential / potential / potential.H
blob32f9b2a1d29d98b82af3b4e760910f0548a057b2
1 /*---------------------------------------------------------------------------*\
2   =========                 |
3   \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox
4    \\    /   O peration     |
5     \\  /    A nd           | Copyright (C) 2008-2009 OpenCFD Ltd.
6      \\/     M anipulation  |
7 -------------------------------------------------------------------------------
8 License
9     This file is part of OpenFOAM.
11     OpenFOAM is free software; you can redistribute it and/or modify it
12     under the terms of the GNU General Public License as published by the
13     Free Software Foundation; either version 2 of the License, or (at your
14     option) any later version.
16     OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
17     ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
18     FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
19     for more details.
21     You should have received a copy of the GNU General Public License
22     along with OpenFOAM; if not, write to the Free Software Foundation,
23     Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
25 Class
26     Foam::potential
28 Description
30 SourceFiles
31     potentialI.H
32     potential.C
34 \*---------------------------------------------------------------------------*/
36 #ifndef potential_H
37 #define potential_H
39 #include "polyMesh.H"
40 #include "IOdictionary.H"
41 #include "Time.H"
42 #include "pairPotentialList.H"
43 #include "electrostaticPotential.H"
44 #include "tetherPotentialList.H"
46 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
48 namespace Foam
51 /*---------------------------------------------------------------------------*\
52                          Class potential Declaration
53 \*---------------------------------------------------------------------------*/
55 class potential
57     // Private data
59         const polyMesh& mesh_;
61         List<word> idList_;
63         List<word> siteIdList_;
65         label nPairPotIds_;
67         scalar potentialEnergyLimit_;
69         labelList removalOrder_;
71         pairPotentialList pairPotentials_;
73         tetherPotentialList tetherPotentials_;
75         vector gravity_;
78     // Private Member Functions
80         void setSiteIdList(const IOdictionary& moleculePropertiesDict);
82         void readPotentialDict();
84         void readMdInitialiseDict
85         (
86             const IOdictionary& mdInitialiseDict,
87             IOdictionary& idListDict
88         );
90         //- Disallow default bitwise copy construct
91         potential(const potential&);
93         //- Disallow default bitwise assignment
94         void operator=(const potential&);
97 public:
99     // Constructors
101         //- Construct from mesh reference
102         potential(const polyMesh& mesh);
104         //- Construct from mdInitialiseDict
105         potential
106         (
107             const polyMesh& mesh,
108             const IOdictionary& mdInitialiseDict,
109             IOdictionary& idListDict
110         );
113     // Destructor
115         ~potential();
118     // Member Functions
120         // Access
122             inline label nIds() const;
124             inline const List<word>& idList() const;
126             inline const List<word>& siteIdList() const;
128             inline scalar potentialEnergyLimit() const;
130             inline label nPairPotentials() const;
132             inline const labelList& removalOrder() const;
134             inline const pairPotentialList& pairPotentials() const;
136             inline const tetherPotentialList& tetherPotentials() const;
138             inline const vector& gravity() const;
142 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
144 } // End namespace Foam
146 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
148 #include "potentialI.H"
150 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
152 #endif
154 // ************************************************************************* //