|
PSCF v1.5.0
|
FieldState for fields in symmetry-adapted basis format. More...
#include <BasisFieldState.h>
Public Member Functions | |
| BasisFieldState () | |
| Default constructor. | |
| BasisFieldState (System< D, T > &system) | |
| Constructor, create association with a parent system. | |
| void | allocate () |
| Allocate all fields. | |
| void | read (const std::string &filename) |
| Read state from file. | |
| void | write (const std::string &filename) |
| Write state to file. | |
| void | getSystemState () |
| Store the current state of the associated system. | |
| void | setSystemState (bool newCellParams) |
| Set the state of the associated system to this state. | |
| const DArray< FT > & | fields () const |
| Get array of all fields by const reference. | |
| DArray< FT > & | fields () |
| Get array of all chemical potential fields (non-const reference). | |
| const DArray< double > & | field (int monomerId) const |
| Get a field for a single monomer type by const reference. | |
| DArray< double > & | field (int monomerId) |
| Get field for a specific monomer type (non-const reference). | |
| const UnitCell< D > & | unitCell () const |
| Get UnitCell (i.e., lattice type and parameters) by const reference. | |
| UnitCell< D > & | unitCell () |
| Get the UnitCell by non-const reference. | |
| System< D, T > & | system () |
| Get associated System by reference. | |
| Public Member Functions inherited from Pscf::FieldState< D, DArray< double >, System< D, T > > | |
| FieldState () | |
| Default constructor. | |
| FieldState (System< D, T > &system) | |
| Constructor, creates association with a System. | |
| ~FieldState () | |
| Destructor. | |
| void | setSystem (System< D, T > &system) |
| Set association with System, after default construction. | |
| const DArray< FT > & | fields () const |
| Get array of all fields by const reference. | |
| DArray< FT > & | fields () |
| Get array of all chemical potential fields (non-const reference). | |
| const DArray< double > & | field (int monomerId) const |
| Get a field for a single monomer type by const reference. | |
| DArray< double > & | field (int monomerId) |
| Get field for a specific monomer type (non-const reference). | |
| const UnitCell< D > & | unitCell () const |
| Get UnitCell (i.e., lattice type and parameters) by const reference. | |
| UnitCell< D > & | unitCell () |
| Get the UnitCell by non-const reference. | |
Additional Inherited Members | |
| Protected Member Functions inherited from Pscf::FieldState< D, DArray< double >, System< D, T > > | |
| bool | hasSystem () |
| Has a system been set? | |
| System< D, T > & | system () |
| Get associated System by reference. | |
FieldState for fields in symmetry-adapted basis format.
Template parameters:
Definition at line 40 of file BasisFieldState.h.
| Pscf::Rp::BasisFieldState< D, T >::BasisFieldState | ( | ) |
Default constructor.
Definition at line 30 of file BasisFieldState.tpp.
| Pscf::Rp::BasisFieldState< D, T >::BasisFieldState | ( | System< D, T > & | system | ) |
Constructor, create association with a parent system.
| system | associated parent system |
Definition at line 38 of file BasisFieldState.tpp.
References system().
| void Pscf::Rp::BasisFieldState< D, T >::allocate | ( | ) |
Allocate all fields.
Precondition: hasSystem() == true
Definition at line 46 of file BasisFieldState.tpp.
Referenced by Pscf::Rp::Sweep< D, T >::checkAllocation(), getSystemState(), and read().
| void Pscf::Rp::BasisFieldState< D, T >::read | ( | const std::string & | filename | ) |
Read state from file.
| filename | name of input w-field file, in basis format |
Definition at line 75 of file BasisFieldState.tpp.
References allocate().
Referenced by pscfpp.command.Script::__init__(), pscfpp.field.Field::__init__(), pscfpp.output.Thermo::__init__(), pscfpp.param.Array::__init__(), pscfpp.param.Composite::__init__(), and pscfpp.param.Matrix::__init__().
| void Pscf::Rp::BasisFieldState< D, T >::write | ( | const std::string & | filename | ) |
Write state to file.
| filename | name of output w-field file, in basis format |
Definition at line 86 of file BasisFieldState.tpp.
References fields(), system(), unitCell(), and Pscf::Rp::FieldIo< D, T >::writeFieldsBasis().
| void Pscf::Rp::BasisFieldState< D, T >::getSystemState | ( | ) |
Store the current state of the associated system.
Copy the fields and the unit cell.
Definition at line 96 of file BasisFieldState.tpp.
References allocate(), field(), system(), and unitCell().
| void Pscf::Rp::BasisFieldState< D, T >::setSystemState | ( | bool | newCellParams | ) |
Set the state of the associated system to this state.
| newCellParams | update unit cell parameters iff true |
Definition at line 119 of file BasisFieldState.tpp.
References fields(), system(), and unitCell().
| const DArray< FT > & Pscf::FieldState< D, DArray< double >, System< D, T > >::fields | ( | ) | const |
Get array of all fields by const reference.
The array capacity is equal to the number of monomer types.
Referenced by setSystemState(), and write().
| DArray< FT > & Pscf::FieldState< D, DArray< double >, System< D, T > >::fields | ( | ) |
Get array of all chemical potential fields (non-const reference).
The array capacity is equal to the number of monomer types.
| const DArray< double > & Pscf::FieldState< D, DArray< double >, System< D, T > >::field | ( | int | monomerId | ) | const |
Get a field for a single monomer type by const reference.
| monomerId | integer monomer type index |
Referenced by getSystemState().
| DArray< double > & Pscf::FieldState< D, DArray< double >, System< D, T > >::field | ( | int | monomerId | ) |
Get field for a specific monomer type (non-const reference).
| monomerId | integer monomer type index |
| const UnitCell< D > & Pscf::FieldState< D, DArray< double >, System< D, T > >::unitCell | ( | ) | const |
Get UnitCell (i.e., lattice type and parameters) by const reference.
Referenced by Pscf::Rp::Sweep< D, T >::checkAllocation(), getSystemState(), setSystemState(), and write().
| UnitCell< D > & Pscf::FieldState< D, DArray< double >, System< D, T > >::unitCell | ( | ) |
Get the UnitCell by non-const reference.
| System< D, T > & Pscf::FieldState< D, DArray< double >, System< D, T > >::system | ( | ) |
Get associated System by reference.
Referenced by BasisFieldState(), getSystemState(), setSystemState(), and write().