Itasca C++ Interface
Loading...
Searching...
No Matches
contactmodelfluid.h
1#pragma once
2// contactmodelfluid.h
3
4#include "contactmodel/interface/icontactmodelfluid.h"
5#include "contactmodel.h"
6
7#ifndef __GNUC__
8#pragma warning(push)
9#pragma warning(disable : 4251)
10#endif
11namespace itascaxd {
12 class IContactFluid;
13 class IContactMechanical;
14}
15
16namespace cmodelsxd {
17 using namespace itasca;
18 using namespace itascaxd;
19
21 public:
23 ~ContactModelFluidState() override {};
24
25 virtual const IContactFluid* getFluidContact() const = 0;
26 virtual const IContactMechanical* getMechanicalContact() const = 0;
27 const IProgram* getProgram() const override = 0;
28 };
29
30 class CONTACTMODEL_EXPORT ContactModelFluid : public IContactModelFluid,
31 public ContactModel {
32 public:
34 ~ContactModelFluid() override;
35
36 static const char* getPluginPrefix() { return "contactmodelfluid"; }
37 static const char* getPluginDirectory() { return "contactmodels/fluid"; }
38 IContactModel* getContactModel() override { return this; }
39 const IContactModel* getContactModel() const override { return this; }
40
41 double getActivityDistance() const override { return 0.0; }
42
43 virtual double getMassDensity() const {
44 throw Exception( "Fluid model %1 does not have property fluid mass density.", getName() );
45 }
46 virtual double getMobilityCoef() const {
47 throw Exception( "Fluid model %1 does not have property mobility coefficient.", getName() );
48 }
49 virtual double getSpecificStorage() const {
50 throw Exception( "Fluid model %1 does not have property specific storage.", getName() );
51 }
52
53 // For contact specific plotting
54 void getSphereList(const IContact*, std::vector<DVect>*, std::vector<double>*,
55 std::vector<double>*) override {}
56#ifdef THREED
57 void getDiskList(const IContact*, std::vector<DVect>*, std::vector<DVect>*,
58 std::vector<double>*, std::vector<double>*) override {}
59#endif
60 void getCylinderList(const IContact*, std::vector<DVect>*, std::vector<DVect>*,
61 std::vector<double>*, std::vector<double>*, std::vector<double>*) override {}
62 };
63}
64#ifndef __GNUC__
65#pragma warning(pop)
66#endif
Base exception class for all Itasca code.
Definition baseexception.h:10
Definition contactmodelfluid.h:31
void getSphereList(const IContact *, std::vector< DVect > *, std::vector< double > *, std::vector< double > *) override
For contact specific plotting.
Definition contactmodelfluid.h:54
void getCylinderList(const IContact *, std::vector< DVect > *, std::vector< DVect > *, std::vector< double > *, std::vector< double > *, std::vector< double > *) override
For contact specific plotting.
Definition contactmodelfluid.h:60
Definition contactmodelfluid.h:20
const IProgram * getProgram() const override=0
Return a const pointer to the IPrgram interface.
Contact model implementation.
Definition contactmodel.h:77
The ContactModelState class holds necessary information to communicate back and forth between the cod...
Definition contactmodel.h:45
The main program access point.
Definition iprogram.h:37
Definition icontactfluid.h:18
Contact class.
Definition icontact.h:33
ContactMechanical class.
Definition icontactmechanical.h:37
Contact model class.
EXPORT_TAG const char * getName()
Definition fishexample.cpp:43
namespace Itasca
Definition basememory.cpp:14
Itasca Library standard namespace, specific to 2D or 3D.
Definition icontactmodule.h:4