VTK  9.3.20240720
vtkDGInterpolateCalculator.h
Go to the documentation of this file.
1// SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2// SPDX-License-Identifier: BSD-3-Clause
11#ifndef vtkDGInterpolateCalculator_h
12#define vtkDGInterpolateCalculator_h
13
14#include "vtkCellAttribute.h" // For CellTypeInfo.
15#include "vtkDGCell.h" // For ivar.
16#include "vtkDGOperatorEntry.h" // For ivar.
18#include "vtkSmartPointer.h" // For ivar.
19#include "vtkStringToken.h" // For ivar.
20
21VTK_ABI_NAMESPACE_BEGIN
22
25class vtkDataArray;
26class vtkTypeInt64Array;
27
31class VTKFILTERSCELLGRID_EXPORT vtkDGInterpolateCalculator : public vtkInterpolateCalculator
32{
33public:
36 void PrintSelf(ostream& os, vtkIndent indent) override;
37
38 void Evaluate(vtkIdType cellId, const vtkVector3d& rst, std::vector<double>& value) override;
39 void Evaluate(vtkIdTypeArray* cellIds, vtkDataArray* rst, vtkDataArray* result) override;
40
41 bool AnalyticDerivative() const override;
42 void EvaluateDerivative(vtkIdType cellId, const vtkVector3d& rst, std::vector<double>& jacobian,
43 double neighborhood) override;
45 vtkIdTypeArray* cellIds, vtkDataArray* rst, vtkDataArray* result) override;
46
48 vtkCellMetadata* cell, vtkCellAttribute* field) override;
49
50protected:
51 friend class vtkDGRangeResponder;
53 ~vtkDGInterpolateCalculator() override = default;
54
55 template <bool UseShape>
57 vtkIdType cellId, const vtkVector3d& rst, std::vector<double>& jacobian, double neighborhood);
58
67
68 vtkCellAttribute* Field{ nullptr };
69
71 int Dimension{ 3 };
74
79
83
86
90
91private:
93 void operator=(const vtkDGInterpolateCalculator&) = delete;
94};
95
96VTK_ABI_NAMESPACE_END
97#endif // vtkDGInterpolateCalculator_h
RealT rst
Definition TetF2Basis.h:17
A function defined over the physical domain of a vtkCellGrid.
Metadata for a particular type of cell (finite element).
Shape
All possible shapes for DG cells.
Definition vtkDGCell.h:70
@ None
A placeholder for an indeterminate or invalid shape.
Definition vtkDGCell.h:80
Calculate field values at a point in a cell's parametric space.
void EvaluateDerivative(vtkIdTypeArray *cellIds, vtkDataArray *rst, vtkDataArray *result) override
Subclasses may override this method to perform multiple derivative-evaluations at a time.
void EvaluateDerivative(vtkIdType cellId, const vtkVector3d &rst, std::vector< double > &jacobian, double neighborhood) override
Return the derivative of the function at rst.
bool AnalyticDerivative() const override
Return true if the function has an analytic derivative.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
static vtkDGInterpolateCalculator * New()
vtkDGInterpolateCalculator()=default
void Evaluate(vtkIdTypeArray *cellIds, vtkDataArray *rst, vtkDataArray *result) override
Subclasses may override this method to perform multiple evaluations at a time.
vtkSmartPointer< vtkDataArray > ShapeValues
void InternalDerivative(vtkIdType cellId, const vtkVector3d &rst, std::vector< double > &jacobian, double neighborhood)
vtkDGOperatorEntry ShapeBasisOp
The shape-basis operators (if any are needed).
vtkSmartPointer< vtkDataArray > FieldConnectivity
Array pointers populated by PrepareForGrid.
void Evaluate(vtkIdType cellId, const vtkVector3d &rst, std::vector< double > &value) override
Subclasses may override this method to perform multiple evaluations at a time.
vtkSmartPointer< vtkDataArray > ShapeConnectivity
vtkCellAttribute::CellTypeInfo FieldCellInfo
The function space, basis, etc.
vtkCellAttribute::CellTypeInfo ShapeCellInfo
The function space, basis, etc. of the shape attribute.
~vtkDGInterpolateCalculator() override=default
vtkSmartPointer< vtkCellAttributeCalculator > PrepareForGrid(vtkCellMetadata *cell, vtkCellAttribute *field) override
vtkDGOperatorEntry FieldBasisOp
The basis-function operator to use.
vtkSmartPointer< vtkDataArray > FieldValues
A record for a basis in a function space that is specific to one cell shape.
Compute the range of a cell-attribute over any vtkDGCell.
abstract superclass for arrays of numeric data
dynamic, self-adjusting array of vtkIdType
a simple class to control print indentation
Definition vtkIndent.h:108
Calculate field values at a point in a cell's parametric space.
Hold a reference to a vtkObjectBase instance.
int vtkIdType
Definition vtkType.h:315