Go to the documentation of this file.
84 const base&
init = base())
100 base&
operator()(
size_t page = 0,
size_t row = 0,
size_t col = 0) {
116 size_t page = 0)
const {
134 const GridPos& row = {0, {0, 1}},
135 const GridPos& col = {0, {0, 1}})
const {
136 const size_t pos[8] = {
146 const Numeric w[8] = {page.fd[1] * row.
fd[1] * col.
fd[1],
147 page.fd[1] * row.
fd[1] * col.
fd[0],
148 page.fd[1] * row.
fd[0] * col.
fd[1],
149 page.fd[1] * row.
fd[0] * col.
fd[0],
150 page.fd[0] * row.
fd[1] * col.
fd[1],
151 page.fd[0] * row.
fd[1] * col.
fd[0],
152 page.fd[0] * row.
fd[0] * col.
fd[1],
153 page.fd[0] * row.
fd[0] * col.
fd[0]};
155 bool any_base =
false;
157 for (
size_t i = 0; i < 8; i++) {
160 out +=
w[i] *
data[pos[i]];
162 out =
w[i] *
data[pos[i]];
180 template <
class base>
182 for (
size_t i = 0; i < v.
npages(); i++)
183 for (
size_t j = 0; j < v.
nrows(); j++)
184 for (
size_t k = 0; k < v.
ncols(); k++) os << v(i, j, k) <<
'\n';
188 #endif // FIELD_HEADER
Field3D(size_t pages=0, size_t rows=0, size_t cols=0, const base &init=base())
Construct a new Field 3 D object.
Complex w(Complex z) noexcept
The Faddeeva function.
Field3D(const Field3D &g)=default
Construct a new Field3D object.
Header file for interpolation.cc.
void std(VectorView std, const Vector &y, const ArrayOfVector &ys, const Index start=0, const Index end=-1)
Compute the standard deviation of the ranged ys.
Field3D< base > & operator=(const Field3D &g)=default
Default assignment operator.
size_t npages() const
Number of pages.
Workspace & init(Workspace &ws)
NUMERIC Numeric
The type to use for all floating point numbers.
base & operator()(size_t page=0, size_t row=0, size_t col=0)
Access operator.
size_t nrows() const
Number of rows.
std::ostream & operator<<(std::ostream &os, const Field3D< base > &v)
Output operator.
size_t ncols() const
Number of columns.
Structure to store a grid position.
Field3D< base > & operator=(Field3D &&g)=default
Default move operator.
Creates a 3D field of a base unit.
Field3D(Field3D &&g)
Construct a new Field3D object.
base operator()(const GridPos &page={0, {0, 1}}, const GridPos &row={0, {0, 1}}, const GridPos &col={0, {0, 1}}) const
Weighted access operator by GridPos.
const base & operator()(size_t col=0, size_t row=0, size_t page=0) const
Access operator.