Ori Cav No States $—$ Orifice model for laminar/turbulent flow possibly with cavitation

The Ori Cav No States component describes the laminar/turbulent flow through an orifice possibly with cavitation. It is valid if

$1<\frac{\ell }{d}$

This condition is checked by an assert statement. The mass and flow forces are not included.

Related Components

 Name Description Resistance with laminar flow. Resistance with laminar flow and externally commanded conductance. The component, based on the loss coefficient K, describes both flow regimes: laminar for very small Reynolds numbers and turbulent for higher Reynolds numbers (default model). The component describes both flow regimes, using an interpolation polynomial. Simple textbook component, using a constant discharge coefficient. It is valid for turbulent flow only; severe numerical problems for laminar flow. Metering Orifice (that is, model Orifice No States with variable diameter). Two orifices in series, one with variable the other with fixed flow area. Same as Orifice No States, but with the equations rearranged to compute dp for given q. Differences between basic models are shown by a figure.

 Equations $\left\{\begin{array}{cc}\left\{\mathrm{dpeff}=\mathrm{dpacting},\mathrm{dpeffu}=0,\mathrm{pmax}=0,\mathrm{pmin}=0,\mathrm{pminab}=0,\mathrm{alpha_dmax}=0,\mathrm{delta_pk}=0\right\}& \mathrm{checkvalve}\\ \left\{\begin{array}{cc}\left\{\mathrm{dpeff}=\mathrm{noEvent}\left(\left\{\begin{array}{cc}\mathrm{dpeffu}& 0<\mathrm{Δp}\\ -\mathrm{dpeffu}& \mathrm{otherwise}\end{array}\right\\right),\mathrm{dpeffu}=\mathrm{noEvent}\left(\left|\mathrm{pmax}-\mathrm{pmin}\right|\right),\mathrm{pmax}=\mathrm{max}\left({p}_{A\left(\mathrm{limited}\right)},{p}_{B\left(\mathrm{limited}\right)}\right),\mathrm{pmin}=\left\{\begin{array}{cc}\mathrm{pmax}-\mathrm{delta_pk}& \mathrm{pminab}<\mathrm{pmax}-\mathrm{delta_pk}\\ \mathrm{pminab}& \mathrm{otherwise}\end{array}\right\,\mathrm{pminab}=\mathrm{min}\left({p}_{A\left(\mathrm{limited}\right)},{p}_{B\left(\mathrm{limited}\right)}\right),\mathrm{alpha_dmax}=\frac{827}{1000}-\frac{17\ell }{2000\mathrm{D}},\mathrm{delta_pk}={\mathrm{α\left[k\right]}}^{2}{\left(\frac{\sqrt{\mathrm{max}\left(0,\mathrm{pmax}\right)}}{\mathrm{alpha_dmax}}+\frac{10\mathrm{\nu }\left(1+\frac{9\ell }{4\mathrm{D}}\right)\sqrt{2}}{\mathrm{α\left[k\right]}\sqrt{\frac{1}{\mathrm{\rho }}}\mathrm{D}}\right)}^{2}\right\}& \mathrm{cavitation}\\ \left\{\mathrm{dpeff}=\mathrm{Δp},\mathrm{dpeffu}=0,\mathrm{pmax}=0,\mathrm{pmin}=0,\mathrm{pminab}=0,\mathrm{alpha_dmax}=0,\mathrm{delta_pk}=0\right\}& \mathrm{otherwise}\end{array}\right\& \mathrm{otherwise}\end{array}\right\$ $\left\{\begin{array}{cc}\left\{\mathrm{Aeq}=\frac{\mathrm{\pi }{\mathrm{Deq}}^{2}}{4},\mathrm{Deq}=\left\{\begin{array}{cc}\mathrm{command}& 0<\mathrm{command}\\ 0& \mathrm{otherwise}\end{array}\right\\right\}& \mathrm{orif}=\mathrm{Hydraulics.Restrictions.Basic.PressureDrop.orifinput.D}\\ \left\{\mathrm{Aeq}=\mathrm{smooth}\left(0,\left\{\begin{array}{cc}\mathrm{command}& 0<\mathrm{command}\\ 0& \mathrm{otherwise}\end{array}\right\\right),\mathrm{Deq}=2\sqrt{\frac{\mathrm{Aeq}}{\mathrm{\pi }}}\right\}& \mathrm{orif}=\mathrm{Hydraulics.Restrictions.Basic.PressureDrop.orifinput.A}\\ \left\{\mathrm{Aeq}=\frac{\mathrm{\pi }{\mathrm{Deq}}^{2}}{4},\mathrm{Deq}=\mathrm{smooth}\left(0,\left\{\begin{array}{cc}\mathrm{command}\mathrm{Dmax}& 0<\mathrm{command}\\ 0& \mathrm{otherwise}\end{array}\right\\right)\right\}& \mathrm{orif}=\mathrm{Hydraulics.Restrictions.Basic.PressureDrop.orifinput.Dr}\\ \left\{\mathrm{Aeq}=\mathrm{smooth}\left(0,\left\{\begin{array}{cc}\mathrm{command}\mathrm{Amax}& 0<\mathrm{command}\\ 0& \mathrm{otherwise}\end{array}\right\\right),\mathrm{Deq}=2\sqrt{\frac{\mathrm{Aeq}}{\mathrm{\pi }}}\right\}& \mathrm{otherwise}\end{array}\right\$ $\left\{\begin{array}{cc}\left\{\left\{\begin{array}{cc}\left\{\mathrm{\lambda }=0,\mathrm{qunsigned}=\mathrm{Hydraulics.Restrictions.Basic.PressureDrop.lossCoeff}\left(\mathrm{Δp}=\mathrm{dpeff}-{p}_{\mathrm{open}},{k}_{1}={k}_{1},{k}_{2}={k}_{2},\mathrm{\nu }=\mathrm{\nu },\mathrm{\rho }=\mathrm{\rho },A=A,\mathrm{D}=\mathrm{D},\mathrm{orif}=\mathrm{orif}\right)\right\}& \mathrm{Transition}=1\\ \left[\mathrm{qunsigned},\mathrm{\lambda }\right]=\mathrm{Hydraulics.Restrictions.Basic.PressureDrop.dischargeCoeff}\left(\mathrm{Δp}=\mathrm{dpeff}-{p}_{\mathrm{open}},{C}_{d}={C}_{d},{\mathrm{\lambda }}_{c}={\mathrm{\lambda }}_{c},\mathrm{\nu }=\mathrm{\nu },\mathrm{\rho }=\mathrm{\rho },A=A,\mathrm{D}=\mathrm{D},\mathrm{orif}=\mathrm{orif}\right)& \mathrm{otherwise}\end{array}\right\,\left\{\begin{array}{cc}{q}_{\mathrm{noleak}}=\mathrm{noEvent}\left(\left\{\begin{array}{cc}\mathrm{qunsigned}& 0\le \mathrm{dpeff}-{p}_{\mathrm{open}}\\ 0& \mathrm{otherwise}\end{array}\right\\right)& \mathrm{checkvalve}\\ {q}_{\mathrm{noleak}}=\mathrm{noEvent}\left(\left\{\begin{array}{cc}\mathrm{qunsigned}& 0\le \mathrm{dpeff}-{p}_{\mathrm{open}}\\ -\mathrm{qunsigned}& \mathrm{otherwise}\end{array}\right\\right)& \mathrm{otherwise}\end{array}\right\,\mathrm{q_reg}={q}_{\mathrm{noleak}},{p}_{\mathrm{open}}={p}_{\mathrm{trans}},{q}_{\mathrm{open}}=0\right\}& \mathrm{flowcond}=1\\ \left\{\mathrm{\lambda }=0,\mathrm{q_reg}={q}_{\mathrm{noleak}},\mathrm{qunsigned}=\mathrm{Hydraulics.Restrictions.Basic.PressureDrop.laminar}\left(\mathrm{Δp}=\mathrm{dpeff},G=G\right),{p}_{\mathrm{open}}=0,{q}_{\mathrm{noleak}}=\mathrm{qunsigned},{q}_{\mathrm{open}}=0\right\}& \mathrm{flowcond}=2\\ \left\{\mathrm{\lambda }=0,\mathrm{q_reg}={q}_{\mathrm{noleak}},\mathrm{qunsigned}=\mathrm{Hydraulics.Restrictions.Basic.PressureDrop.dischargeCoeff}\left(\mathrm{Δp}=\mathrm{dpeff},{C}_{d}={C}_{d},\mathrm{flownumber}=\mathrm{false},\mathrm{\rho }=\mathrm{\rho },A=A,\mathrm{D}=\mathrm{D},\mathrm{orif}=\mathrm{orif}\right),{p}_{\mathrm{open}}=0,{q}_{\mathrm{noleak}}=\mathrm{noEvent}\left(\left\{\begin{array}{cc}\mathrm{qunsigned}& 0\le \mathrm{dpeff}\\ -\mathrm{qunsigned}& \mathrm{otherwise}\end{array}\right\\right),{q}_{\mathrm{open}}=0\right\}& \mathrm{flowcond}=3\\ \left\{\left\{\begin{array}{cc}{q}_{\mathrm{noleak}}=\mathrm{noEvent}\left(\left\{\begin{array}{cc}\mathrm{smooth}\left(0,\left\{\begin{array}{cc}\mathrm{qunsigned}& {p}_{\mathrm{open}}<\mathrm{dpeff}\\ \mathrm{q_reg}& \mathrm{otherwise}\end{array}\right\\right)& 0\le \mathrm{dpeff}-{p}_{\mathrm{closed}}\\ 0& \mathrm{otherwise}\end{array}\right\\right)& \mathrm{checkvalve}\\ {q}_{\mathrm{noleak}}=\mathrm{noEvent}\left(\left\{\begin{array}{cc}\mathrm{smooth}\left(0,\left\{\begin{array}{cc}\mathrm{qunsigned}& {p}_{\mathrm{open}}<\mathrm{dpeff}\\ \mathrm{q_reg}& \mathrm{otherwise}\end{array}\right\\right)& 0\le \mathrm{dpeff}-{p}_{\mathrm{closed}}\\ \mathrm{smooth}\left(0,\left\{\begin{array}{cc}-\mathrm{qunsigned}& \mathrm{dpeff}<-{p}_{\mathrm{open}}\\ -\mathrm{q_reg}& \mathrm{otherwise}\end{array}\right\\right)& \mathrm{otherwise}\end{array}\right\\right)& \mathrm{otherwise}\end{array}\right\,\left\{\begin{array}{cc}\left\{\left\{\begin{array}{cc}{q}_{\mathrm{open}}=\frac{\left(\frac{1}{G}+\sqrt{\frac{1}{{G}^{2}}+\frac{2{p}_{\mathrm{closed}}\mathrm{\rho }}{{C}_{d}^{2}{A}^{2}}}\right){C}_{d}^{2}{A}^{2}}{\mathrm{\rho }}& \mathrm{Transition}=2\\ {q}_{\mathrm{open}}=\frac{\left(\frac{1}{G}-\frac{\mathrm{\rho }{k}_{1}\mathrm{\nu }}{2\mathrm{D}A}+\sqrt{{\left(-\frac{1}{G}+\frac{\mathrm{\rho }{k}_{1}\mathrm{\nu }}{2\mathrm{D}A}\right)}^{2}+\frac{2{p}_{\mathrm{closed}}\mathrm{\rho }{k}_{2}}{{A}^{2}}}\right){A}^{2}}{\mathrm{\rho }{k}_{2}}& \mathrm{otherwise}\end{array}\right\,\mathrm{\lambda }=0,{p}_{\mathrm{open}}={p}_{\mathrm{closed}}+\frac{{q}_{\mathrm{open}}}{G}\right\}& \mathrm{regparam}=1\\ \left\{\left\{\begin{array}{cc}{p}_{\mathrm{open}}=\mathrm{Hydraulics.Restrictions.Basic.PressureDrop.inv_lossCoeff}\left(q={q}_{\mathrm{open}},{k}_{1}={k}_{1},{k}_{2}={k}_{2},\mathrm{\rho }=\mathrm{\rho },\mathrm{\nu }=\mathrm{\nu },\mathrm{D}=\mathrm{D}\right)& \mathrm{Transition}=1\\ {p}_{\mathrm{open}}=\mathrm{Hydraulics.Restrictions.Basic.PressureDrop.inv_dischargeCoeff}\left(q={q}_{\mathrm{open}},{C}_{d}={C}_{d},\mathrm{\rho }=\mathrm{\rho },\mathrm{D}=\mathrm{D}\right)& \mathrm{otherwise}\end{array}\right\,\mathrm{\lambda }=0,{q}_{\mathrm{open}}=\frac{{\mathrm{Re}}_{\mathrm{trans}}\mathrm{\nu }A}{\mathrm{D}}\right\}& \mathrm{regparam}=2\\ \left\{\left\{\begin{array}{cc}\left\{\mathrm{\lambda }=0,{q}_{\mathrm{open}}=\mathrm{Hydraulics.Restrictions.Basic.PressureDrop.lossCoeff}\left(\mathrm{Δp}={p}_{\mathrm{open}},\mathrm{\rho }=\mathrm{\rho },A=A,\mathrm{D}=\mathrm{D},{k}_{1}={k}_{1},{k}_{2}={k}_{2},\mathrm{\nu }=\mathrm{\nu },\mathrm{orif}=\mathrm{orif}\right)\right\}& \mathrm{Transition}=1\\ \left[{q}_{\mathrm{open}},\mathrm{\lambda }\right]=\mathrm{Hydraulics.Restrictions.Basic.PressureDrop.dischargeCoeff}\left(\mathrm{Δp}={p}_{\mathrm{open}},\mathrm{\rho }=\mathrm{\rho },A=A,\mathrm{D}=\mathrm{D},{C}_{d}={C}_{d},\mathrm{flownumber}=\mathrm{false},\mathrm{orif}=\mathrm{orif}\right)& \mathrm{otherwise}\end{array}\right\,{p}_{\mathrm{open}}={p}_{\mathrm{trans}}\right\}& \mathrm{otherwise}\end{array}\right\,\left[\mathrm{qunsigned},\mathrm{q_reg}\right]=\mathrm{Hydraulics.Restrictions.Basic.PressureDrop.conditionalFlow}\left(\mathrm{Δp}=\mathrm{dpeff},\mathrm{\rho }=\mathrm{\rho },A=A,\mathrm{D}=\mathrm{D},\mathrm{Transition}=\mathrm{Transition},\mathrm{regtype}=\mathrm{regtype},\mathrm{\nu }=\mathrm{\nu },{p}_{\mathrm{closed}}={p}_{\mathrm{closed}},{p}_{\mathrm{open}}={p}_{\mathrm{open}},{q}_{\mathrm{open}}={q}_{\mathrm{open}},{k}_{1}={k}_{1},{k}_{2}={k}_{2},{C}_{d}={C}_{d}\right)\right\}& \mathrm{otherwise}\end{array}\right\$ $\mathrm{\nu }=\mathrm{Modelica.Media.Air.MoistAir.Utilities.spliceFunction}\left(x=\mathrm{Δp},\mathrm{pos}={\mathrm{\nu }}_{\mathrm{oil}}\left(p={p}_{A\left(\mathrm{abs}\right)},T=T,{v}_{\mathrm{air}}={v}_{\mathrm{gas}\left(\mathrm{oil}\right)},{p}_{\mathrm{sat}}={p}_{\mathrm{sat}}\right),\mathrm{neg}={\mathrm{\nu }}_{\mathrm{oil}}\left(p={p}_{B\left(\mathrm{abs}\right)},T=T,{v}_{\mathrm{air}}={v}_{\mathrm{gas}\left(\mathrm{oil}\right)},{p}_{\mathrm{sat}}={p}_{\mathrm{sat}}\right),\mathrm{Δx}=100\right)$ $\mathrm{\rho }=\mathrm{Modelica.Media.Air.MoistAir.Utilities.spliceFunction}\left(x=\mathrm{Δp},\mathrm{pos}={\mathrm{\rho }}_{\mathrm{oil}}\left(p={p}_{A\left(\mathrm{abs}\right)},T=T,{v}_{\mathrm{air}}={v}_{\mathrm{gas}\left(\mathrm{oil}\right)},{p}_{\mathrm{sat}}={p}_{\mathrm{sat}}\right),\mathrm{neg}={\mathrm{\rho }}_{\mathrm{oil}}\left(p={p}_{B\left(\mathrm{abs}\right)},T=T,{v}_{\mathrm{air}}={v}_{\mathrm{gas}\left(\mathrm{oil}\right)},{p}_{\mathrm{sat}}={p}_{\mathrm{sat}}\right),\mathrm{Δx}=100\right)$ $T={T}_{0\left(\mathrm{oil}\right)}+{\mathrm{ΔT}}_{\mathrm{system}}$ $q=\frac{{m}_{\mathrm{flow}\left(A\right)}}{\mathrm{\rho }}$ $q={q}_{\mathrm{noleak}}+{q}_{\mathrm{leak}}$ $\mathrm{Δp}={p}_{A\left(\mathrm{limited}\right)}-{p}_{B\left(\mathrm{limited}\right)}$ ${p}_{A\left(\mathrm{abs}\right)}={p}_{A}+{p}_{\mathrm{atm}\left(\mathrm{oil}\right)}$ ${p}_{A\left(\mathrm{limited}\right)}=\mathrm{max}\left({p}_{A},{p}_{\mathrm{vapour}\left(\mathrm{oil}\right)}-{p}_{\mathrm{atm}\left(\mathrm{oil}\right)}\right)$ ${p}_{B\left(\mathrm{abs}\right)}={p}_{B}+{p}_{\mathrm{atm}\left(\mathrm{oil}\right)}$ ${p}_{B\left(\mathrm{limited}\right)}=\mathrm{max}\left({p}_{B},{p}_{\mathrm{vapour}\left(\mathrm{oil}\right)}-{p}_{\mathrm{atm}\left(\mathrm{oil}\right)}\right)$ ${m}_{\mathrm{flow}\left(A\right)}+{m}_{\mathrm{flow}\left(B\right)}=0$

Variables

 Name Value Units Description Modelica ID $\mathrm{Δp}$ $\mathrm{Pa}$ Pressure drop dp $q$ $\frac{{m}^{3}}{s}$ Flow rate flowing into port_A q ${p}_{A\left(\mathrm{limited}\right)}$ $\mathrm{Pa}$ Limited gauge pressure pA_limited ${p}_{B\left(\mathrm{limited}\right)}$ $\mathrm{Pa}$ Limited gauge pressure pB_limited $\mathrm{\rho }$ $\frac{\mathrm{kg}}{{m}^{3}}$ Upstream density rho $\mathrm{\nu }$ $\frac{{m}^{2}}{s}$ Upstream kinematic viscosity nu ${p}_{A\left(\mathrm{abs}\right)}$ $\mathrm{Pa}$ Absolute pressure pA pA_abs ${p}_{B\left(\mathrm{abs}\right)}$ $\mathrm{Pa}$ Absolute pressure pB pB_abs $T$ $K$ Local temperature T ${p}_{A\left(\mathrm{summary}\right)}$ ${p}_{A}$ $\mathrm{Pa}$ Pressure at port A summary_pA ${p}_{B\left(\mathrm{summary}\right)}$ ${p}_{B}$ $\mathrm{Pa}$ Pressure at port B summary_pB ${\mathrm{Δp}}_{\mathrm{summary}}$ $\mathrm{Δp}$ $\mathrm{Pa}$ Pressure drop summary_dp ${q}_{\mathrm{summary}}$ $q$ $\frac{{m}^{3}}{s}$ Flow rate flowing into port_A summary_q ${P}_{\mathrm{hyd}\left(\mathrm{summary}\right)}$ $-\mathrm{Δp}q$ $W$ Hydraulic Power summary_HP ${p}_{\mathrm{sat}}$ [1] $\mathrm{Pa}$ Gas saturation pressure p_sat ${q}_{\mathrm{leak}}$ ${G}_{\mathrm{leak}}\mathrm{Δp}$ $\frac{{m}^{3}}{s}$ Leakage flow q_leak ${q}_{\mathrm{noleak}}$ $\frac{{m}^{3}}{s}$ Flow rate through component q_noleak $\mathrm{dpeff}$ $\mathrm{Pa}$ Effective pressure drop dpeff $A$ $\mathrm{Aeq}$ ${m}^{2}$ Orifice area A $\mathrm{D}$ $\mathrm{Deq}$ $m$ Orifice diameter D ${q}_{\mathrm{open}}$ $\frac{{m}^{3}}{s}$ Flow when fully open orifice q_open ${p}_{\mathrm{open}}$ $\mathrm{Pa}$ Pressure when fully open orifice p_open $\mathrm{dpacting}$ $0$ $\mathrm{Pa}$ Acting, i.e. delayed pressure differential dpacting $G$ $0$ $\frac{{m}^{3}}{s\mathrm{Pa}}$ Hydraulic conductance $G=\frac{\mathrm{∂q}}{\mathrm{∂p}}$ G $\mathrm{\lambda }$ Flow coefficient lambda $\mathrm{command}$ if orif = Hydraulics.Restrictions.Basic.PressureDrop.orifinput.D then diameter / dummyD else if orif = Hydraulics.Restrictions.Basic.PressureDrop.orifinput.A then area / dummyD ^ 2 else 1 command $\mathrm{Deq}$ Equivalent diameter Deq $\mathrm{Aeq}$ Equivalent area Aeq

[1] $\mathrm{oil.gasSaturationPressure}\left(T=T,{v}_{\mathrm{gas}}={\mathrm{oil.v}}_{\mathrm{gas}}\right)$

Connections

 Name Description Modelica ID ${\mathrm{port}}_{A}$ Layout of port where oil flows into an element ($0<{m}_{\mathrm{flow}}$, ${p}_{B}<{p}_{A}$ means $0<\mathrm{Δp}$) port_A ${\mathrm{port}}_{B}$ Hydraulic port where oil leaves the component (${m}_{\mathrm{flow}}<0$, ${p}_{B}<{p}_{A}$ means $0<\mathrm{Δp}$) port_B $\mathrm{oil}$ oil

Parameters

General Parameters

 Name Default Units Description Modelica ID ${\mathrm{ΔT}}_{\mathrm{system}}$ $0$ $K$ Temperature offset from system temperature dT_system $\mathrm{orif}$ [1] Orifice dimension orif $\mathrm{Transition}$ $1$ Transition model Transition ${k}_{1}$ $10$ Laminar part k1 ${k}_{2}$ $2$ ${k}_{2}=\frac{1}{{C}_{d}^{2}}$ k2 ${C}_{d}$ $\frac{1}{\sqrt{{k}_{2}}}$ Max discharge coefficient C_d ${\mathrm{\lambda }}_{c}$ $\frac{2{k}_{1}}{\sqrt{{k}_{2}}}$ Critical flow number lambdac $\ell$ $0.003$ $m$ Orifice length; $1<\frac{\ell }{d}$ length ${p}_{\mathrm{nom}}$ ${10}^{6}$ $\mathrm{Pa}$ Nominal pressure drop pnom ${q}_{\mathrm{nom}}$ $1.89·{10}^{-5}$ $\frac{{m}^{3}}{s}$ Nominal volume flow rate qnom ${\mathrm{\rho }}_{\mathrm{nom}}$ $865$ $\frac{\mathrm{kg}}{{m}^{3}}$ Nominal density rhonom $d$ $0.001$ $m$ Orifice diameter diameter $\mathrm{area}$ $0.001$ ${m}^{2}$ Orifice area area

[1] $\mathrm{Hydraulics.Restrictions.Basic.PressureDrop.orifinput.D}$

Constant Parameters

 Name Default Units Description Modelica ID $\mathrm{flowcond}$ $1$ Flow condition flowcond reg type $0$ Regularization type regtype reg param $0$ Regularization parameter regparam $\mathrm{cavitation}$ $\mathrm{true}$ Cavitation cavitation $\mathrm{checkvalve}$ $\mathrm{false}$ checkvalve ${\Re }_{\mathrm{trans}}$ $0$ Transition Reynolds number Re_trans ${p}_{\mathrm{trans}}$ $0$ $\mathrm{Pa}$ Transition pressure p_trans ${p}_{\mathrm{closed}}$ $0$ $\mathrm{Pa}$ Cracking pressure p_closed ${G}_{\mathrm{leak}}$ $0$ $\frac{{m}^{3}}{s\mathrm{Pa}}$ Leakage conductance G_Leak ${C}_{d}$ $\mathrm{Cd_eq}$ Cd

Constants

 Name Value Units Description Modelica ID $\mathrm{α\left[k\right]}$ $0.649$ alpha_k