PSCF v1.3
rpc/environment/FilmEnvironment.h
1#ifndef RPC_FILM_ENVIRONMENT_H
2#define RPC_FILM_ENVIRONMENT_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/*
12* NOTE: In this file, we break from PSCF's conventional coding standards.
13* Specifically, any subclass of MixAndMatchEnv in the Rpc namespace should
14* be declared in this header file, and the methods should be defined in
15* the class declaration rather than in a .tpp file. This is simply for the
16* sake of conciseness. These subclasses of MixAndMatchEnv require very
17* little code to declare and define, so we opt to consolidate the code
18* into a single file rather than spreading it across many small files.
19*/
20
21#include "FilmFieldGenMask.h"
22#include "FilmFieldGenExt.h"
23#include <prdc/environment/MixAndMatchEnv.h>
24
25namespace Pscf {
26namespace Rpc {
27
28 using namespace Util;
29
30 template <int D>
31 class System;
32
38 template <int D>
40 {
41
42 public:
43
51 sysPtr_(&sys)
52 { ParamComposite::setClassName("FilmEnvironment"); }
53
59
60 private:
61
63 System<D>* sysPtr_;
64
74 void createGenerators()
75 {
76 MixAndMatchEnv::fieldGenPtr1_ = new FilmFieldGenMask<D>(*sysPtr_);
77 MixAndMatchEnv::fieldGenPtr2_ = new FilmFieldGenExt<D>(*sysPtr_);
78 }
79
80 };
81
82 // Suppress implicit instantiation
83 extern template class FilmEnvironment<1>;
84 extern template class FilmEnvironment<2>;
85 extern template class FilmEnvironment<3>;
86
87} // namespace Rpc
88} // namespace Pscf
89#endif
FilmEnvironment(System< D > &sys)
Constructor.
Field Generator for external fields in thin-film systems.
Field Generator for thin-film masks.
Main class, representing one complete system.
void setClassName(const char *className)
Set class name string.
Real periodic fields, SCFT and PS-FTS (CPU).
Definition param_pc.dox:2
PSCF package top-level namespace.
Definition param_pc.dox:1