<
The Pulse Team is excited to announce the Pulse Physiology Engine 4.1.0 release. Upgrade now to get the best in dynamic simulation.
×
SEGasSubstanceQuantity.h
1 /* Distributed under the Apache License, Version 2.0.
2  See accompanying NOTICE file for details.*/
3 
4 #pragma once
5 #include "cdm/compartment/substances/SESubstanceQuantity.h"
6 #include "cdm/substance/SESubstanceTransport.h"
7 class SEGasCompartment;
8 
10 {
11  friend class PBSubstanceQuantity;//friend the serialization class
12  friend class SEGasCompartment;
13 protected:
15 public:
16  virtual ~SEGasSubstanceQuantity();
17 
18  virtual void Clear();
19 
20  virtual std::string GetCompartmentName() override;
21 
22  virtual void SetToZero();
23  virtual const SEScalar* GetScalar(const std::string& name);
24 
25  virtual bool HasPartialPressure() const;
26  virtual SEScalarPressure& GetPartialPressure();
27  virtual double GetPartialPressure(const PressureUnit& unit) const;
28 
29  virtual bool HasVolume() const;
30  virtual SEScalarVolume& GetVolume();
31  virtual double GetVolume(const VolumeUnit& unit) const;
32 
33  virtual bool HasVolumeFraction() const;
34  virtual SEScalar0To1& GetVolumeFraction();
35  virtual double GetVolumeFraction() const;
36 
37 protected:
38  virtual void AddChild(SEGasSubstanceQuantity& subQ);
39 
40  virtual bool HasExtensive() const { return HasVolume(); }
41  virtual SEScalarVolume& GetExtensive() { return GetVolume(); }
42 
43  virtual bool HasIntensive() const { return HasVolumeFraction(); }
44  virtual SEScalar0To1& GetIntensive() { return GetVolumeFraction(); }
45 
49 
51  std::vector<SEGasSubstanceQuantity*> m_Children;
52 };
Definition: SESubstanceTransport.h:13
virtual void Clear()=0
virtual SEScalar0To1 & GetIntensive()
Definition: SEGasSubstanceQuantity.h:44
Definition: SEScalar.h:18
Definition: SEScalarVolume.h:7
Definition: SEGasCompartment.h:13
Definition: SEScalarVolume.h:27
Definition: SEScalarPressure.h:28
virtual bool HasExtensive() const
Definition: SEGasSubstanceQuantity.h:40
Definition: SEScalarPressure.h:7
virtual SEScalarVolume & GetExtensive()
Definition: SEGasSubstanceQuantity.h:41
virtual std::string GetCompartmentName()=0
virtual void SetToZero()=0
SEGasCompartment & m_Compartment
Definition: SEGasSubstanceQuantity.h:50
std::vector< SEGasSubstanceQuantity * > m_Children
Definition: SEGasSubstanceQuantity.h:51
SEScalarVolume * m_Volume
Definition: SEGasSubstanceQuantity.h:47
Definition: PBSubstanceQuantity.h:10
virtual bool HasIntensive() const
Definition: SEGasSubstanceQuantity.h:43
virtual void AddChild(SEGasCompartment &child)
Definition: SEGasCompartment.cpp:104
virtual const SEScalar * GetScalar(const std::string &name)
Definition: SEFluidCompartment.cpp:40
Definition: SEGasSubstanceQuantity.h:9
Definition: SESubstance.h:14
Definition: SEScalar0To1.h:7
SEScalar0To1 * m_VolumeFraction
Definition: SEGasSubstanceQuantity.h:48
Definition: SESubstanceQuantity.h:7
SEScalarPressure * m_PartialPressure
Definition: SEGasSubstanceQuantity.h:46

Distributed under the Apache License, Version 2.0.

See accompanying NOTICE file for details.