PSCF v1.4.0
fts/compressor/IntraCorrelation.h
1#ifndef RP_INTRACORRELATION_H
2#define RP_INTRACORRELATION_H
3
4/*
5* PSCF - Polymer Self-Consistent Field
6*
7* Copyright 2015 - 2025, The Regents of the University of Minnesota
8* Distributed under the terms of the GNU General Public License.
9*/
10
11#include <pscf/math/IntVec.h> // member
12#include <util/containers/DArray.h> // member
13
14// Forward declaration
15namespace Pscf {
16 namespace Correlation {
17 template <typename WT> class Mixture;
18 }
19}
20
21namespace Pscf {
22namespace Rp {
23
24 using namespace Util;
25
31 template <int D, class T>
33 {
34
35 public:
36
43
44 protected:
45
51 IntraCorrelation(typename T::System const & system);
52
57
64
70 void computeGsq();
71
72 /*
73 * Get the size of the k-space mesh.
74 */
75 int kSize() const;
76
80 typename T::System const & system() const;
81
82 private:
83
84 using RealT = typename T::Real;
85
87 typename T::System const * systemPtr_;
88
90 Correlation::Mixture<RealT>* correlationMixturePtr_;
91
93 DArray<RealT> Gsq_;
94
96 IntVec<D> meshDimensions_;
97
99 IntVec<D> kMeshDimensions_;
100
102 int kSize_;
103
104 using FFTT = typename T::FFT;
105
106 };
107
108 // Get the number of wavevectors in the k-space mesh.
109 template <int D, class T> inline
110 int IntraCorrelation<D,T>::kSize() const
111 { return kSize_; }
112
113 // Get the parent system by const reference.
114 template <int D, class T> inline
115 typename T::System const & IntraCorrelation<D,T>::system() const
116 { return *systemPtr_; }
117
118} // namespace Rp
119} // namespace Pscf
120#endif
Correlations in a homogeneous ideal gas mixture.
An IntVec<D, T> is a D-component vector of elements of integer type T.
Definition IntVec.h:27
IntraCorrelation(typename T::System const &system)
Constructor.
Types< D >::System const & system() const
void computeGsq()
Compute array of squared wavevectors.
void computeOmegaTotal(Array< typename T::Real > &correlations)
Compute total intramolecular correlation function (all blocks).
void getMeshDimensions()
Get and store r-grid and kgrid-mesh dimensions.
Array container class template.
Definition Array.h:40
Dynamically allocatable contiguous array template.
Definition DArray.h:32
Intramolecular correlations in homogeneous systems.
Class templates for real-valued periodic fields.
PSCF package top-level namespace.