|
PSCF v1.4.0
|
Intramolecular correlation analysis for one polymer Species. More...
#include <Polymer.h>
Public Member Functions | |
| Polymer () | |
| Default constructor. | |
| Polymer (PolymerSpecies< WT > const &polymer) | |
| Constructor (creates association with a PolymerSpecies). | |
| ~Polymer () | |
| Destructor. | |
| void | associate (PolymerSpecies< WT > const &polymer) |
| Create association with a PolymerSpecies. | |
| void | allocate (int nMonomer) |
| Allocate memory and initialize immutable data. | |
| void | setup (Array< double > const &kuhn) |
| Set private mutable data. | |
| double | computeOmega (int ia, int ib, double prefactor, double kSq) const |
| Compute intramolecular correlation function for a pair of blocks. | |
| void | computeOmega (int ia, int ib, double prefactor, Array< double > const &kSq, Array< double > &correlation) const |
| Compute intramolecular correlation function for a pair of blocks. | |
| void | computeOmegaTotal (double prefactor, Array< double > const &kSq, Array< double > &correlations) const |
| Compute total intramolecular correlation function. | |
| double | phi () const |
| Return the volume fraction of this polymer species. | |
| double | totalLength () const |
| Return the sum of lengths of all blocks in this polymer species. | |
| int | nBlock () const |
| Get the number of blocks in the associated polymer species. | |
| GArray< int > const & | blockIds (int i) const |
| Get a GArray of block ids for all blocks of one monomer type. | |
| double | length (int i) const |
| Get the length of each block. | |
| double | rSq (int i, int j) const |
| Get the mean-squared length of path between blocks i and j. | |
Intramolecular correlation analysis for one polymer Species.
Definition at line 32 of file pscf/correlation/Polymer.h.
| Pscf::Correlation::Polymer< WT >::Polymer | ( | ) |
Default constructor.
Definition at line 31 of file pscf/correlation/Polymer.tpp.
| Pscf::Correlation::Polymer< WT >::Polymer | ( | PolymerSpecies< WT > const & | polymer | ) |
Constructor (creates association with a PolymerSpecies).
| polymer | associated PolymerSpecies object |
Definition at line 42 of file pscf/correlation/Polymer.tpp.
| Pscf::Correlation::Polymer< WT >::~Polymer | ( | ) |
Destructor.
Definition at line 53 of file pscf/correlation/Polymer.tpp.
| void Pscf::Correlation::Polymer< WT >::associate | ( | PolymerSpecies< WT > const & | polymer | ) |
Create association with a PolymerSpecies.
| polymer | associated PolymerSpecies object |
Definition at line 60 of file pscf/correlation/Polymer.tpp.
| void Pscf::Correlation::Polymer< WT >::allocate | ( | int | nMonomer | ) |
Allocate memory and initialize immutable data.
This function must be called exactly once, at any time after the Mixture block of the parameter file has been processes. It performs memory allocation and initialization operations that require knowlege of the number of monomer types in the mixture, as well as the number of blocks and the monomer type index of each block in the associated polymer species.
| nMonomer | number of monomer types in the mixture |
Definition at line 67 of file pscf/correlation/Polymer.tpp.
References UTIL_CHECK.
| void Pscf::Correlation::Polymer< WT >::setup | ( | Array< double > const & | kuhn | ) |
Set private mutable data.
This function must be called after allocate and before performing any computations of correlation functions. It sets internal variables that depend on the polymer volume fraction phi, block lengths and statistical segment lengths. These variables are all mutable insofar as they may all change during a SCFT sweep or FTS ramp, and phi may change in an open statistical ensemble. This function may be called multiple times.
| kuhn | array of kuhn lengths, indexed by monomer type id |
Definition at line 94 of file pscf/correlation/Polymer.tpp.
References Util::Array< Data >::capacity(), Pscf::PolymerModel::isThread(), Pscf::Edge::length(), Pscf::Edge::monomerId(), Pscf::Edge::nBead(), and UTIL_CHECK.
| double Pscf::Correlation::Polymer< WT >::computeOmega | ( | int | ia, |
| int | ib, | ||
| double | prefactor, | ||
| double | kSq ) const |
Compute intramolecular correlation function for a pair of blocks.
This function evaluates and returns the intramolecular correlation function Omega(k) for a pair of blocks with block indices ia and ib at a value of the squared wavenumber given by parameter "kSq". Monomer type indexes ia and ib may be either equal or unequal. The return value is given by the product of a dimensionless single-chain correlation function omega(k) and the input parameter "prefactor". To obtain the contribution of this function to a correlation function for a homogeneous ideal gas mixture, set the prefactor parameter equal to the species chain concentration, prefactor = phi/(v*totalLength), where v is the monomer reference volume.
| ia | block index of first block |
| ib | block index of second block |
| prefactor | prefactor multiplying omega(k) |
| kSq | squared wavenumber value |
Definition at line 184 of file pscf/correlation/Polymer.tpp.
| void Pscf::Correlation::Polymer< WT >::computeOmega | ( | int | ia, |
| int | ib, | ||
| double | prefactor, | ||
| Array< double > const & | kSq, | ||
| Array< double > & | correlation ) const |
Compute intramolecular correlation function for a pair of blocks.
This function evaluates the intramolecular correlation function Omega for a pair of blocks with block indices ia and ib at a list of values for the squared wavenumber given by values of elements of input array parameter "kSq". Results are added to corresponding elements of array "correlations". The value for each wavenumber is given by the product of a dimensionless single-chain correlation function omega(k) and the input parameter "prefactor". To obtain the contribution of this species to a correlation function for an ideal gas mixture, set prefactor = phi/(v*totalLength), where v is the monomer reference volume.
Resulting values of Omega are added to prior values of elements of the array correlation. This is done to simplify calculations in which results of multiple polymer species are added to obtain a correlation function for a mixture. All elements of the array correlations should thus be set to zero at the beginning any such calculation.
| ia | block index of first block |
| ib | block index of second block |
| prefactor | prefactor multiplying omega(q) |
| kSq | array of squared wavenumbers (in) |
| correlation | array of correlation function values (out) |
Definition at line 227 of file pscf/correlation/Polymer.tpp.
References Util::Array< Data >::capacity(), Pscf::Correlation::db(), Pscf::Correlation::dt(), Pscf::Correlation::eb(), Pscf::Correlation::et(), Pscf::PolymerModel::isThread(), and UTIL_CHECK.
| void Pscf::Correlation::Polymer< WT >::computeOmegaTotal | ( | double | prefactor, |
| Array< double > const & | kSq, | ||
| Array< double > & | correlations ) const |
Compute total intramolecular correlation function.
This function computes the a total density-density correlation function for a list of values for the squared wavenumber given as elements of input array parameter "kSq". Results are added to corresponding elements of array parameter "correlations". On entry, the arrays kSq and correlations must be allocated and equal capacities.
Each computed value is given by the product of a dimensionless single-chain correlation function omega(k) and the "prefactor" input parameter. To obtain the contribution of this species to the total density-density correlation function for an ideal gas mixture, set prefactor = phi/(v*totalLength), where v is the monomer reference volume. The zero wavenumber limiting value is given by prefactor*totalLength*totalLength.
Resulting values of Omega are added to elements of output array correlation, as for the function computeOmega.
| prefactor | prefactor of single-chain correlation functions |
| kSq | array of squared wavenumbers (in) |
| correlations | array of correlation function values (out) |
Definition at line 285 of file pscf/correlation/Polymer.tpp.
References Util::Array< Data >::capacity(), Pscf::Correlation::db(), Pscf::Correlation::dt(), Pscf::Correlation::eb(), Pscf::Correlation::et(), Pscf::PolymerModel::isThread(), and UTIL_CHECK.
|
inline |
Return the volume fraction of this polymer species.
Definition at line 316 of file pscf/correlation/Polymer.h.
|
inline |
Return the sum of lengths of all blocks in this polymer species.
Definition at line 321 of file pscf/correlation/Polymer.h.
|
inline |
Get the number of blocks in the associated polymer species.
Definition at line 326 of file pscf/correlation/Polymer.h.
|
inline |
Get a GArray of block ids for all blocks of one monomer type.
This function returns a GArray<int> container that contains a list of block indices for all blocks of the specified monomer type i. The number of blocks of a monomer type i is given by the return value of the "size()" member function of this container. If this polymer species does not contain any blocks of monomer type i, this size will be zero.
| i | monomer type index |
Definition at line 331 of file pscf/correlation/Polymer.h.
|
inline |
Get the length of each block.
This function returns the length of block i for the thread model, or the floating point representation of nBead for the the bead model.
| i | block index |
Definition at line 336 of file pscf/correlation/Polymer.h.
|
inline |
Get the mean-squared length of path between blocks i and j.
This function returns the sum of the mean-squared end-to-end lengths of all of the blocks (for the thread model) or bonds (for the bead model) along the path connecting the two blocks with block indices i and j. For the bead model, this includes the two "half bonds" that connect adjacent bonds along this path to each shared vertex.
| i | block index of 1st block. |
| j | block index of 2nd block. |
Definition at line 341 of file pscf/correlation/Polymer.h.