1 /*=========================================================================
2 
3   Program:   Visualization Toolkit
4   Module:    vtkLagrangianMatidaIntegrationModel.h
5 
6   Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7   All rights reserved.
8   See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9 
10     This software is distributed WITHOUT ANY WARRANTY; without even
11     the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12     PURPOSE.  See the above copyright notice for more information.
13 
14 =========================================================================*/
15 /**
16  * @class   vtkLagrangianMatidaIntegrationModel
17  * vtkLagrangianBasicIntegrationModel implementation
18  *
19  *
20  * vtkLagrangianBasicIntegrationModel implementation using
21  * article :
22  * "Matida, E. A., et al. "Improved numerical simulation of aerosol deposition in
23  * an idealized mouth-throat." Journal of Aerosol Science 35.1 (2004): 1-19."
24  * Input Array to process are expected as follow :
25  * Index 1 is the "FlowVelocity" from flow input in the tracker
26  * Index 2 is the "FlowDensity" from flow input in the tracker
27  * Index 3 is the "FlowDynamicViscosity" from flow input in the tracker
28  * Index 4 is the "ParticleDiameter" from seed (source) input in the tracker
29  * Index 5 is the "ParticleDensity" from seed (source) input in the tracker
30  *
31  * @sa
32  * vtkLagrangianParticleTracker vtkLagrangianParticle
33  * vtkLagrangianBasicIntegrationModel
34  */
35 
36 #ifndef vtkLagrangianMatidaIntegrationModel_h
37 #define vtkLagrangianMatidaIntegrationModel_h
38 
39 #include "vtkFiltersFlowPathsModule.h" // For export macro
40 #include "vtkLagrangianBasicIntegrationModel.h"
41 
42 class VTKFILTERSFLOWPATHS_EXPORT vtkLagrangianMatidaIntegrationModel
43   : public vtkLagrangianBasicIntegrationModel
44 {
45 public:
46   vtkTypeMacro(vtkLagrangianMatidaIntegrationModel, vtkLagrangianBasicIntegrationModel);
47   void PrintSelf(ostream& os, vtkIndent indent) override;
48   static vtkLagrangianMatidaIntegrationModel* New();
49 
50   // Needed for multiple signatures polymorphism
51   using Superclass::FunctionValues;
52 
53   /**
54    * Evaluate the integration model velocity field
55    * f at position x, using data from cell in dataSet with index cellId
56    */
57   int FunctionValues(vtkLagrangianParticle* particle, vtkDataSet* dataSet, vtkIdType cellId,
58     double* weights, double* x, double* f) override;
59 
60 protected:
61   vtkLagrangianMatidaIntegrationModel();
62   ~vtkLagrangianMatidaIntegrationModel() override;
63 
64   static double GetRelaxationTime(double dynVisc, double diameter, double density);
65 
66   static double GetDragCoefficient(const double* flowVelocity, const double* particleVelocity,
67     double dynVisc, double particleDiameter, double flowDensity);
68 
69 private:
70   vtkLagrangianMatidaIntegrationModel(const vtkLagrangianMatidaIntegrationModel&) = delete;
71   void operator=(const vtkLagrangianMatidaIntegrationModel&) = delete;
72 };
73 
74 #endif
75