11#include "Propagator.h"
12#include <pscf/solvers/BlockTmpl.h>
13#include <pspg/field/RDField.h>
14#include <pspg/field/RDFieldDft.h>
15#include <pspg/field/FFT.h>
16#include <pspg/field/FFTBatched.h>
17#include <util/containers/FArray.h>
18#include <pscf/crystal/UnitCell.h>
19#include <pspg/solvers/WaveList.h>
24 template <
int D>
class Mesh;
103 void step(cudaReal
const * q, cudaReal* qNew);
207 cudaComplex* qkBatched_;
208 cudaComplex* qk2Batched_;
217 cudaReal* expKsq_host;
218 cudaReal* expKsq2_host;
249 {
return *unitCellPtr_; }
253 {
return *waveListPtr_; }
261 void computeExpKsq();
280 {
return stress_[n]; }
290 #ifndef PSPG_BLOCK_TPP
double length() const
Get the length (number of monomers) in this block.
int vertexId(int i) const
Get id of an associated vertex.
void setId(int id)
Set the id for this block.
int monomerId() const
Get the monomer type id.
const Pair< int > & vertexIds() const
Get the pair of associated vertex ids.
virtual void setLength(double length)
Set the length of this block.
void setVertexIds(int vertexAId, int vertexBId)
Set indices of associated vertices.
int id() const
Get the id of this block.
void setMonomerId(int monomerId)
Set the monomer id.
Class template for a block in a block copolymer.
double kuhn() const
Get monomer statistical segment length.
Propagator< D > & propagator(int directionId)
Get a Propagator for a specified direction.
TP::CField & cField()
Get the associated monomer concentration field.
An IntVec<D, T> is a D-component vector of elements of integer type T.
Description of a regular grid of points in a periodic domain.
Block within a branched polymer.
double stress(int n)
Get derivative of free energy w/ respect to a unit cell parameter.
void computeConcentration(double prefactor)
Compute unnormalized concentration for block by integration.
void setKuhn(double kuhn)
Set or reset monomer statistical segment length.
double length() const
Get the length (number of monomers) in this block.
void computeStress(WaveList< D > const &waveList, double prefactor)
Compute derivatives of free energy w/ respect to cell parameters.
void setupSolver(RDField< D > const &w)
Set solver for this block.
void setDiscretization(double ds, const Mesh< D > &mesh)
Initialize discretization and allocate required memory.
double ds() const
Contour length step size.
Mesh< D > const & mesh() const
Return associated spatial Mesh by const reference.
void setupUnitCell(UnitCell< D > const &unitCell, WaveList< D > const &waveList)
Setup parameters that depend on the unit cell.
void setupFFT()
Initialize FFT and batch FFT classes.
void setLength(double length)
Set or reset block length.
void step(cudaReal const *q, cudaReal *qNew)
Compute step of integration loop, from i to i+1.
int ns() const
Number of contour length steps.
Fourier transform wrapper for real data.
Fourier transform wrapper for real data.
MDE solver for one-direction of one block.
Discrete Fourier Transform (DFT) of a real field on an FFT mesh.
Field of real single precision values on an FFT mesh on a device.
Container for wavevector data.
Base template for UnitCell<D> classes, D=1, 2 or 3.
A fixed size (static) contiguous array template.
#define UTIL_ASSERT(condition)
Assertion macro suitable for debugging serial or parallel code.
C++ namespace for polymer self-consistent field theory (PSCF).
Utility classes for scientific computation.