Go to the documentation of this file.
54 #ifndef vtkLagrangianBasicIntegrationModel_h
55 #define vtkLagrangianBasicIntegrationModel_h
57 #include "vtkFiltersFlowPathsModule.h"
72 class vtkDataSetsType;
79 class vtkLocatorsType;
94 SURFACE_TYPE_MODEL = 0,
95 SURFACE_TYPE_TERM = 1,
96 SURFACE_TYPE_BOUNCE = 2,
97 SURFACE_TYPE_BREAK = 3,
103 VARIABLE_STEP_PREV = -1,
104 VARIABLE_STEP_CURRENT = 0,
105 VARIABLE_STEP_NEXT = 1,
134 vtkGetMacro(LocatorsBuilt,
bool);
135 vtkSetMacro(LocatorsBuilt,
bool);
154 unsigned int surfaceFlatIndex = 0);
162 vtkSetMacro(UseInitialIntegrationTime,
bool);
163 vtkGetMacro(UseInitialIntegrationTime,
bool);
164 vtkBooleanMacro(UseInitialIntegrationTime,
bool);
178 vtkGetMacro(Tolerance,
double);
199 std::queue<vtkLagrangianParticle*>& particles,
208 int fieldAssociation,
const char*
name);
232 vtkPointData* vtkNotUsed(particleData),
int vtkNotUsed(maxTuples) = 0) {}
240 vtkPointData* vtkNotUsed(particleData),
int vtkNotUsed(stepEnum)) {}
288 vtkSetMacro(NonPlanarQuadSupport,
bool);
289 vtkGetMacro(NonPlanarQuadSupport,
bool);
290 vtkBooleanMacro(NonPlanarQuadSupport,
bool);
346 vtkGetMacro(WeightsSize,
int);
372 double t,
double& delT,
double& delTActual,
373 double minStep,
double maxStep,
374 double maxError,
double& error,
int& integrationResult);
394 virtual void PreIntegrate(std::queue<vtkLagrangianParticle*>& vtkNotUsed(particles)){}
411 double * x,
double * f) = 0;
457 double tol,
double& t,
double x[3]);
463 double interpolationFactor,
bool forceInside =
false);
486 vtkIdType tupleId,
double* weights,
double*&
data,
int& nComponents);
503 int nComponent,
double* defaultValues);
528 } SurfaceArrayDescription;
virtual vtkIdType FindInLocator(vtkDataSet *dataSet, vtkAbstractCellLocator *locator, double *x, vtkGenericCell *cell, double *weights)
Look in the given dataset and associated locator to see if it contains the point x,...
vtkLocatorsType * SurfaceLocators
virtual bool BounceParticle(vtkLagrangianParticle *particle, vtkDataSet *surface, vtkIdType cellId)
Bounce a particle, using the normal of the cell it bounces on.
virtual void InitializeVariablesParticleData(vtkPointData *vtkNotUsed(particleData), int vtkNotUsed(maxTuples)=0)
Empty method to be reimplemented if necessary in inherited classes.
virtual bool FindInLocators(double *x)
virtual bool FindInLocators(double *x, vtkDataSet *&dataset, vtkIdType &cellId)
std::vector< std::pair< int, std::string > > enumValues
Filter to inject and track particles in a flow.
virtual void InitializeModelPathData(vtkFieldData *vtkNotUsed(data))
Empty method to be reimplemented if necessary in inherited classes.
virtual void InterpolateNextParticleVariables(vtkLagrangianParticle *particle, double interpolationFactor, bool forceInside=false)
compute all particle variables using interpolation factor
vtkNew< vtkIntArray > SeedArrayComps
Abstract interface for sets of functions.
virtual vtkAbstractArray * GetSeedArray(int idx, vtkLagrangianParticle *particle)
Get a seed array, as set in setInputArrayToProcess from the provided particle seed data Access then t...
vtkFunctionSet abstract implementation to be used in the vtkLagrangianParticleTracker integrator.
int FunctionValues(double *x, double *f) override
Evaluate integration model velocity f at position x.
virtual vtkStringArray * GetSeedArrayNames()
Get the seed arrays expected name Used Only be the vtkLagrangianSeedHelper in ParaView plugins.
virtual void SetLocator(vtkAbstractCellLocator *locator)
Set/Get the locator used to locate cells in the datasets.
vtkLocatorsType * Locators
vtkNew< vtkIntArray > SurfaceArrayComps
represent and manipulate point attribute data
virtual vtkIntArray * GetSeedArrayTypes()
Get the seed arrays expected type Used Only be the vtkLagrangianSeedHelper in ParaView plugins.
virtual vtkDoubleArray * GetSurfaceArrayDefaultValues()
Get the surface arrays default values for each leaf Used Only be the vtkLagrangianSurfaceHelper in Pa...
vtkDataSetsType * DataSets
virtual bool CheckFreeFlightTermination(vtkLagrangianParticle *vtkNotUsed(particle))
Method to be reimplemented if needed in inherited classes.
vtkNew< vtkStringArray > SurfaceArrayNames
virtual bool ManualIntegration(double *xcur, double *xnext, double t, double &delT, double &delTActual, double minStep, double maxStep, double maxError, double &error, int &integrationResult)
Let the model define it's own way to integrate Signature is very close to the integrator method signa...
std::map< std::string, SurfaceArrayDescription > SurfaceArrayDescriptions
virtual void SetInputArrayToProcess(int idx, int port, int connection, int fieldAssociation, const char *name)
Set a input array to process at a specific index, identified by a port, connection,...
virtual vtkIntArray * GetSurfaceArrayTypes()
Get the surface arrays expected type Used Only be the vtkLagrangianSurfaceHelper in ParaView plugins.
vtkNew< vtkStringArray > SeedArrayNames
vtkLagrangianParticle * TmpParticle
~vtkLagrangianBasicIntegrationModel() override
virtual vtkIntArray * GetSurfaceArrayComps()
Get the seed array expected number of components Used Only be the vtkLagrangianSurfaceHelper in ParaV...
abstract superclass for arrays of numeric data
virtual bool BreakParticle(vtkLagrangianParticle *particle, vtkDataSet *surface, vtkIdType cellId, std::queue< vtkLagrangianParticle * > &particles)
Breakup a particle at intersection point, by terminating it and creating two new particle using the i...
vtkSurfaceType * Surfaces
virtual void PreIntegrate(std::queue< vtkLagrangianParticle * > &vtkNotUsed(particles))
Enable model to modify particle before integration.
virtual vtkLagrangianParticle * ComputeSurfaceInteraction(vtkLagrangianParticle *particle, std::queue< vtkLagrangianParticle * > &particles, unsigned int &interactedSurfaceFlatIndex, PassThroughParticlesType &passThroughParticles)
Interact the current particle with a surfaces Return a particle to record as interaction point if not...
virtual bool GetFlowOrSurfaceData(int idx, vtkDataSet *flowDataSet, vtkIdType tupleId, double *weights, double *&data, int &nComponents)
Directly get a double value from flow or surface data as defined in SetInputArrayToProcess data point...
represent and manipulate fields of data
virtual bool IntersectWithLine(vtkCell *cell, double p1[3], double p2[3], double tol, double &t, double x[3])
Call vtkCell::IntersectWithLine This method is to be reimplemented in inherited classes willing to im...
virtual vtkStringArray * GetSurfaceArrayNames()
Get the surface arrays expected name Used Only be the vtkLagrangianSurfaceHelper in ParaView plugins.
virtual bool FindInLocators(double *x, vtkDataSet *&dataset, vtkIdType &cellId, vtkAbstractCellLocator *&loc, double *&weights)
Look for a dataset in this integration model containing the point x.
bool UseInitialIntegrationTime
virtual int GetFlowOrSurfaceDataFieldAssociation(int idx)
Recover a field association for a specified array index if it has been set using SetInputArrayToProce...
std::pair< ArrayVal, std::string > ArrayMapVal
virtual void InitializeParticle(vtkLagrangianParticle *vtkNotUsed(particle))
Initialize a particle by setting user variables and perform any user model specific operation.
std::pair< unsigned int, vtkLagrangianParticle * > PassThroughParticlesItem
virtual void SetTracker(vtkLagrangianParticleTracker *Tracker)
Set the parent tracker.
abstract class to specify cell behavior
virtual void InsertModelPathData(vtkLagrangianParticle *vtkNotUsed(particle), vtkFieldData *vtkNotUsed(data))
Empty method to be reimplemented if necessary in inherited classes.
std::map< int, ArrayMapVal > InputArrays
represent and manipulate cell attribute data
a simple class to control print indentation
dynamic, self-adjusting array of int
vtkLagrangianBasicIntegrationModel()
vtkNew< vtkStringArray > SurfaceArrayEnumValues
vtkAbstractCellLocator * LastLocator
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
virtual vtkStringArray * GetSurfaceArrayEnumValues()
Get the surface arrays expected values and associated enums Used Only be the vtkLagrangianSurfaceHelp...
virtual int FunctionValues(vtkDataSet *detaSet, vtkIdType cellId, double *weights, double *x, double *f)=0
Actually compute the integration model velocity field pure abstract, to be implemented in inherited c...
an abstract base class for locators which find cells
Basis class for Lagrangian particles.
vtkNew< vtkDoubleArray > SurfaceArrayDefaultValues
vtkAbstractCellLocator * Locator
abstract class to specify dataset behavior
Abstract superclass for all arrays.
virtual bool CheckAdaptiveStepReintegration(vtkLagrangianParticle *vtkNotUsed(particle))
Method to be reimplemented if needed in inherited classes.
vtkLagrangianParticle * CurrentParticle
virtual vtkIntArray * GetSeedArrayComps()
Get the seed arrays expected number of components Used Only be the vtkLagrangianSeedHelper in ParaVie...
virtual bool FinalizeOutputs(vtkPolyData *vtkNotUsed(particlePathsOutput), vtkDataObject *vtkNotUsed(interractionOutput))
Enable model post process on output Return true if successful, false otherwise Empty and Always retur...
virtual void ComputeSurfaceDefaultValues(const char *arrayName, vtkDataSet *dataset, int nComponent, double *defaultValues)
Methods used by ParaView surface helper to get default values for each leaf of each dataset of surfac...
concrete dataset represents vertices, lines, polygons, and triangle strips
provides thread-safe access to cells
vtkNew< vtkIntArray > SeedArrayTypes
a vtkAbstractArray subclass for strings
virtual bool TerminateParticle(vtkLagrangianParticle *particle)
Terminate a particle, by positioning flags.
virtual void ClearDataSets(bool surface=false)
dynamic, self-adjusting array of double
bool NonPlanarQuadSupport
vtkNew< vtkIntArray > SurfaceArrayTypes
vtkWeakPointer< vtkLagrangianParticleTracker > Tracker
virtual void InsertVariablesParticleData(vtkLagrangianParticle *vtkNotUsed(particle), vtkPointData *vtkNotUsed(particleData), int vtkNotUsed(stepEnum))
Empty method to be reimplemented if necessary in inherited classes.
std::queue< PassThroughParticlesItem > PassThroughParticlesType
general representation of visualization data
virtual void AddDataSet(vtkDataSet *dataset, bool surface=false, unsigned int surfaceFlatIndex=0)
Add a dataset to locate cells in This create a specific locator for the provided dataset using the Lo...
virtual bool InteractWithSurface(int surfaceType, vtkLagrangianParticle *particle, vtkDataSet *surface, vtkIdType cellId, std::queue< vtkLagrangianParticle * > &particles)
Call vtkLagrangianBasicIntegrationModel::Terminate This method is to be reimplemented in inherited cl...
virtual bool CheckSurfacePerforation(vtkLagrangianParticle *particle, vtkDataSet *surface, vtkIdType cellId)
Given a particle, check if it perforate a surface cell ie : interact with next step after interacting...
virtual vtkAbstractArray * GetSeedArray(int idx, vtkPointData *pointData)
Get a seed array, as set in setInputArrayToProcess from the provided seed point data.
virtual void ParallelManualShift(vtkLagrangianParticle *vtkNotUsed(particle))
Method called by parallel algorithm after receiving a particle from stream if PManualShift flag has b...