The network xml file
MENY
The network xml file
The network xml file
Structure of the xml file
The xml file contains data of an arterial network. The file is headed by a tag enclosing the file name with .xml:<singleBifurcation.xml id="1.0" version="4.0">the xml file is organised into six categories which are explained in the following:
- SimulationContext
- SolverCalibration
- InitialisationControl
- GlobalFluid
- BoundaryConditions
- Vessels
SimulationContext
<simulationContext> <totalTime unit="s"> 1.0 </totalTime> <CFL> 0.98 </CFL> <gravitationalField> False </gravitationalField> <gravityConstant unit="m s-2"> -9.81 </gravityConstant> <centralVenousPressure unit="Pa"> 0.0 </centralVenousPressure> <minimumVenousPressure unit="Pa"> 0.0 </minimumVenousPressure> </simulationContext>The context of the simulation is define by the following variables:
- totalTime This defines the total simulation time. Variable type and SI unit [float,s]
- CLF The CFL number is a necessary condition for stability and additional criteria on how well the wave propagation can be covered by a numerical solver. The defined CFL number is used to estimate the timestep of the simulation and if enabled for automaticGridAdaptation (see solverCalibration). variable type and unit [float; unitless]
- gravitationalFieldgravitationalField Specify if gravity model is used in the caculations. Variable type [ bool = True/False]
- gravityConstant Set the gravitational field force constant. Variable type and SI unit [ float, m s−² ]
- centralVeneousePressure Specify the initial pressure in the venous system. Variable types and SI unit [float; mmHg]
- minimumVenousPressure Specify the minimum pressure for the venous system. Variable type and SI unit [float; mmHg]
SolverCalibration
<initialisationControls> <rigidAreas> False </rigidAreas> <simplifyEigenvalues> False </simplifyEigenvalues> <riemannInvariantUnitBase> Pressure </riemannInvariantUnitBase> <automaticGridAdaptation> True </automaticGridAdaptation> </initialisationControls>The current methods and procedures to configure the solver are:
- rigidAreas Set constant area through the numerical simulation. Variable type [bool = True/Flase].
- simplyfiedEigenvalues Uses a simplified characteristic wave speed to evaluate the Riemann invariant. Variable type [bool = True/False].
- riemannInvariantUnitBase Uses Riemann invariant based on pressure or flow. Variable type [ string = Pressure/Flow].
- automaticGridAdaptation This method adapts automatically the defined number of grid nodes for each vessel, such that the local CFL number is as close as possible to the defined CFL number in simulationContext. Variable type [bool = True/False].
InitialisationControl
<initialisationControls> <initialsationMethod> ConstantPressure</initialsationMethod> <initMeanFlow unit="ml s-1"> 125 </initMeanFlow> <initMeanPressure unit="mmHg"> 100 </initMeanPressure> <estimateWindkesselCompliance>Tree</estimateWindkesselCompliance> <compPercentageWK3> 0.8 </compPercentageWK3> <compPercentageTree> 0.2 </compPercentageTree> <compTotalSys unit="m3 Pa-1"> 4.895587352e-08 </compTotalSys> </initialisationControls>Defines initial parameters such as flow, pressure and compliance for the numerical simulation.
-
-
- InitialisationMethod defines the method used to calculate the intial flow and pressure values of all arteries, based on the expected mean pressure and flow values and the resistance of the network. Variable type and unit [string=Auto/MeanFlow/MeanPressure/ConstantPressure; unit less] Available methods for network initialisation are:
- Auto The mean flow at the proximal root-vessel node is calculated from defined inflow boundary condition by evaluating the integral over one period.
- MeanFlow The mean flow at the proximal root-vessel node is set to value given by initMeanFlow.
- MeanPressure The mean pressure at the proximal root-vessel node is set to value given by initMeanPressure for initialisation
- ConstantPressure All initial pressure value of all vessel are set to value given by initMeanPressure
- InitialisationMethod defines the method used to calculate the intial flow and pressure values of all arteries, based on the expected mean pressure and flow values and the resistance of the network. Variable type and unit [string=Auto/MeanFlow/MeanPressure/ConstantPressure; unit less] Available methods for network initialisation are:
-
- InitMeanFlow initial mean flow. Variable type and SI unit [ flaot; ml s−¹ ].
- initMeanPressure Initial mean pressure. Variable type and SI unit [float; mmHg].
- estimateWindkesselCompliance Only if Winkessel are defined as boundary conditions. Variable type and unit [string = Tree/Wk3/System/No] If this method is enabled (not No) the Windkessel compliances are estimated based on:
- System: the given total system compliance in variable compTotalSys
- Tree: the percentage of total compliance that is covered by the defined arteries in variable compPercentageTree
- WK3: the percentage of total compliance that is covered by the defined windkessel compliances in variable compPercentageWK3
- compPercentageWK3 the percentage of total compliance that is covered by the defined windkessel compliances Variable type ans SI Unit [float; unit less].
- compPercentageTree the percentage of total compliance that is covered by the defined arteries Variable type and SI unit [float; unit less].
- compTotalSys total compliance of the system. Variable type and SI unit [float; m³ Pa−¹ ].
GlobalFluid
<globalFluid> <my unit="Pa s"> 0.00004 </my> <rho unit="kg m-3"> 1050.0 </rho> <gamma> 2.0 </gamma> </globalFluid>The fluid parameters are set globally, but can be set for each vessel individually (see Vessels).
- my (= μ) viscosity of the blood. Variable type and unit [float; Pa s]
- rho (=ρ) density of the blood. Variable type and SI unit [float; kg m−³ ]
- gamma (= γ) Blundness of the velocity profile. Gamma = 2 for poiseulle flow. variable type and SI unit [ float; unit less].
BoundaryConditions
For all "open" ends a boundary condition need to be defined for the artery. All boundary conditions are defined under the boundaryConditions-tag. A boundary condition for a vessel is defined by the boundaryCondition-tag with the associated vesselId as attribute. If there is only one vessel, the boundary condition at the distal end is specified with an attached "_" in front of the boundary condition name. Otherwise (there is only one open end at each boundary vessel), the boundary condition is placed automatically at the correct position.<boundaryConditions> # boundaryConditions-tag. <boundaryCondition vesselId="0"> # boundaryCondition-tag <Flow-Sinus2> # proximal boundary condition ... </Flow-Sinus2> <_Windkessel-3Elements> # distal boundary condition with "_" .... </_Windkessel-3Elements> </boundaryCondition> </boundaryConditions>There are currently 18 different forms of boundary condition implemented. These 18 can be grouped into two types: type1 and type2.
Type 1 boundary condition:
The type 1 boundray condition models define functions for the pressure P(t) or flow Q(t) set as influx or total values at the boundary. It is also possible to add a new type 1 boundary condition with your personal function due to the object oriented way in a very convenient manner (if you need help on this, just contact us) Available boundary condition models are:Flow-Fourier Flow-FromFile Flow-PhysiologicalData Flow-PhysiologicalFunction Flow-RampMean Flow-Sinus Flow-Sinus2 Velocity-Gaussian Pressure-RampMean Pressure-Sinus Pressure-SinusIn the xml file the type one boundary condition is defined in the following manner:
<modelName> # e.g. <Flow-Sinus2> <amp unit="m3 s-1"> 0.0002 </amp> <ampConst unit="m3 s-1"> 0.0 </ampConst> <Npulse> 25.0 </Npulse> <Tpulse unit="s"> 0.0 </Tpulse> <freq unit="s-1"> 2.0 </freq> <Tspace unit="s"> 0.25 </Tspace> <runtimeEvaluation> False </runtimeEvaluation> <prescribe> influx </prescribe> </modelName>All type1 models have these common variables :
- amp Amplitude of inflow pulse Variable type and unit [ float; m³ s−¹ ]
- freq Frequency of the pulse. Variable type and unit [float; s−¹]
- Tpulse Time delay until first pulse. (Only if initialisationMethod == ConstantPressure). Variable type and unit [float; s]
- Tspace Time between pulses. Variable type and unit [float; s]
- Npulse Number of pulses. Variable type and unit [float; unit less]
- ampConst Constant amplitude value for the pulse. Variable type and unit [float; m³ s−¹].
- RuntimeEvaluation Variable type [bool = True/false].
- prescribed Value prescribed at the inlet. Variable type [string= influx/total].
- Velocity-Gaussian gaussC Gaussian function coefficient variable type and unit [float; unit less]
- Flow-FromFilefilePathName Path to the CSV file in witch the inflow values are defined. Variable type and unit [string]
Type 2 boundary condition
Type 2 are all other boundary conditions with their variables are:ReflectionCoefficient [Rt] ReflectionCoefficientTimeVarying [RtOpen,Topen1,Topen2,RtClosed,Tclosed1,Tclosed2] Resistance [Rc] Windkessel-2Elements [Rc,C] Windkessel-3Elements [Rc,Rtotal,C,Z] L-network [Z,C] VaryingElastanceHeart [T,Emax,Emin,Tpeak,V0,K]The various variables are:
- Rt defines the terminal reflection coefficient value Variable types and unit [float ; unit less ]
- Rc the value of the resistance, in case of a windkessel its in parallel with the compliance. Variable types and unit [float, string = VesselImpedance ; Pa s m−³ ]
- Rtotal total resistance of a windkessel element: Rtotal = RC + Z. Variable type and unit [float; Pa s m−³]
- C compliance of a windkessel element Variable type and unit [float; m³ Pa−¹ ]
- Z resistance element which is connected to vessel boundary. If set to VesselImpedance, the value of the vessel impedance at the boundary grid node is taken. Variable type and unit [float, string = VesselImpedance; Pa s m−³]
- T period of one heart beat. variable type and unit [float; s]
- Emax maximum elastance of the heart. Variable type and unit [float; Pa m-3]
- Emin minimum elastance of the heart. Variable type and unit [float; Pa m-3]
- Tpeak time to maximum elastance of the heart. Variable type and unit [float; s]
- VO initial heart volume. Variable type and unit [float; m3].
- K variable type and unit [float; s m-3]
Vessels
Each vessel in the network is characterised by its topology, geometry compliance and fluid properties. Each vessel is referenced by their individual id, which can be any natural number.<vessels> <vessel Id="0" name="myfristvessel"> <topology> ... </topology> <geometry> ... </geometry> <compliance> ... </compliance> <fluid> ... </fluid> </vessel> <vessel Id="1" name="mysecondvessel"> ... </vessel> ... </vessels>Topology
<topology> <leftDaughter> 1 </leftDaughter> <rightDaughter> 2 </rightDaughter> <angleYMother unit="rad">0.0</angleYMother> </topology>The network of vessels is organised as an extended binary tree, starting with a root vessel at the top. We describe the binary tree of the network is given in terms of a mother-daughter description. When three vessels form a bifurcation the proximal vessel is called mother and the two branches are the daughter vessels. Mother and daughter are referenced by their vessel Ids. An anastomosis is defined when 2 vessels have the same daughter vessel. To define the topology in the network xml file, only the daughters have to be set in the mother vessel topology properties.
- leftDaughter Id of the left daughter vessel. If the vessel has only one daughter it is assumed to be "left" Variable type an unit [int; uni less]
- rightDaughter Id of the right daughter vessel. Variable type and unit [int; unit less].
- angleYMother angle between the axis of the daughter vessel and the mother vessel, this value is only used for the 3d visualisation. Variable type and unit [float; rad/degree]
<geometry> <geometryType> cone </geometryType> <length unit="m"> 0.5 </length> <radiusProximal unit="m"> 0.0075 </radiusProximal> <radiusDistal unit="m"> 0.005 </radiusDistal> <N> 25.0 </N> </geometry>It describes the geometrical properties of the vessels in terms of their type, length, radii and number of grid nodes. The vessels are approximated with a circular cross sectional area.
- geometryType It defined the geometry type of the vessel, which can be a uniform or cone.
- uniform the given proximalRadius is applied at all grid points
- cone the given proximalRadius and distalRadius are applied on the respective end of the vessel, all radii in between are interpolated linearly.
- length The length of the vessel. Variable type and unit [float; m]
- radiusProximal Radius at the proximal grid node of the vessel. Variable type and unit [float; m]
- radiusDistal Radius at the distal grid node of the vessel. Variable type and unit [float; m]
- N Number of grid node along the vessel. Variable type and unit [float; unit less]
<compliance> <complianceType> Laplace </complianceType> <constantCompliance> False </constantCompliance> <externalPressure unit="Pa"> 0.0 </externalPressure> <Ps unit="Pa"> 0.0 </Ps> <As unit="m2"> None </As> <betaLaplace unit="Pa"> 796020.0 </betaLaplace> </compliance>The vessel compliance of a vessel describes the change of the vessel area dependent on a change in pressure. Currently five different compliance models are available:
- Laplace (found in Sherwin et al. 2003) In this model the compliance is a linear function of pressure
- Laplace2 (found in Sherwin et al. 2003) The compliance is the same as in the Laplace model but young modulus is used to calculate the stiffness of the vessel.
- Exponential (found in Hellevik et al. 1998) The compliance is defined as an exponential function of the area.
- Hayashi (found in Hayashi et al. 1993) The compliance is defined as the an exponential function of the diameter.
- Reymond (found in Reymond et al. 2009) The compliance is defined as a atan function of the pressure
- complianceType one of the five compliance model. Variable type and unit [string = Laplace/Laplace2/Exponential/Hayashi/Reymond; unit less].
- constantCompliance set compliance to initial compliance through the simulation. Variable type and unit [bool = True/False].
- ExternalPressure specify the value of the external pressure. Variable type and unit [float; Pa].
- Ps reference pressure for the compliance model. Variable type and unit [float; Pa]
- As reference area for compliance model. Variable type and unit [float;m²]
- Laplace betaLaplace Stiffness parameter of Laplace compliance model. Variable type and unit [float; pa].
- Laplace2wallThickness The thickness of the arterial wall used in Laplace2 compliance model Variable type and unit [float; m] youngModulus Value of the young Modulus used in Laplace2 compliance model Variable type and unit [float; m²]
- Exponential betaExponential Stiffness parameter of the Exponential compliance model. Variable type and unit [foat; unit less].
- Hayashi betaHayashi Stiffness parameter of the Hayashi compliance model. Variable type and unit [float;Pa].
- Reymond distensibility It is the compliance per unit area used in Reymond compliance model Variable type and unit [float; Pa−¹ ].
<fluid> <applyGlobalFluid>True</applyGlobalFluid> <my unit="Pa s">1e-06</my> <rho unit="kg m-3">1050.0</rho> <gamma>2</gamma> </fluid>The fluid properties are exactly the same as the global fluid properties. There is only one addition variable which can be used to turn on the local/vessel fluid properties:
- applyGlobalFluid if this is True, the global fluid properties are used, if this is False the values defined here are applied, Variable type and unit [bool;True/False].