9#include <rpg/fts/montecarlo/McSimulator.h>
10#include <rpg/system/System.h>
11#include <rpg/solvers/Mixture.h>
12#include <rpg/field/Domain.h>
13#include <rpg/field/WFields.h>
15#include <rp/fts/montecarlo/ShiftMove.tpp>
22 using namespace Prdc::Cuda;
29 : RpShiftMove(simulator)
41 if (!wOld_.isAllocated()) {
43 const int meshSize = system().domain().mesh().size();
44 wOld_.allocate(meshSize);
45 wNew_.allocate(meshSize);
54 IntVec<D> const& dimensions = system().domain().mesh().dimensions();
55 const int nMonomer = system().mixture().nMonomer();
57 for (
int j = 0; j< nMonomer; ++j) {
58 wOld_ = system().w().rgrid(j);
70 template class Rp::ShiftMove<1, Rpg::Types<1> >;
71 template class Rp::ShiftMove<2, Rpg::Types<2> >;
72 template class Rp::ShiftMove<3, Rpg::Types<3> >;
An IntVec<D, T> is a D-component vector of elements of integer type T.
DArray< typename Types< D >::RField > w_
void shiftField(Array< double > &out, Array< double > const &in, IntVec< D > shift, IntVec< D > dimensions) const
Monte Carlo simulator for PS-FTS.
void shiftFields(IntVec< D > const &shift) override
Compute and store shifted w fields.
ShiftMove(McSimulator< D > &simulator)
Constructor.
void setup() override
Setup before simulation.
#define UTIL_CHECK(condition)
Assertion macro suitable for serial or parallel production code.
Periodic fields and crystallography.
SCFT and PS-FTS with real periodic fields (GPU)
PSCF package top-level namespace.