This repo contains the code presented in the JuliaHub workshop "Julia for Engineers" given on September 26, 2024. The code solves the Actuator Safety Design problem. The diagram below represents the problem to be solved, which is to solve for an appropriate orifice area (
Solving will produce the final plot for actuator velocity comparing compressible and incopressible solutions:
The orifice pressure drop is defined by the manufacturer as
Where
-
$\Delta p$ is the pressure drop [$Pa$] -
$\rho$ is the fluid density [$kg/m^3$] -
$u$ is the nominal fluid velocity thru the orifice [$m/s$] -
$C_d$ is the resistance coefficient = 2.7
The fluid velocity thru the orifice is found from
Where
-
$Q$ is the flow rate [$m^3/s$] -
$A_o$ is the orifice area [$m^2$]
The flow rate is known from the actuator
Where
-
$A$ is the area of the actuator face [$m^2$] -
$\dot{x}$ is the velocity of the actuator [$m/s$]
The actuator can be derived from Newton's 2nd law
Where
-
$m$ is the mass of the actuator [$kg$] -
$x$ is the actuator position [$m$] -
$\dot{x}$ is the actuator velocity [$m/s$] -
$\ddot{x}$ is the actuator acceleration [$m/s^2$] -
$F_1$ is the pressure pushing down on the actuator ($p_1 A$ ) [$N$] -
$F_2$ is the pressure pushing up on the actuator ($p_2 A$ ) [$N$] -
$F_d$ is the damping resistance ($c \dot{x}$ ) [$N$] -
$p$ is pressure [$Pa$] -
$A$ is the area of the actuator face [$A$] -
$c$ is the damping coefficient [$N/(m/s)$]
The system of equaitons for the incompressible system then is
Given the actuator max velocity should be
Note: for steady state
Given the orifice area
The volume component will be defined as a cylinder with a moving wall. Starting with the conservation of mass in and out of the cylinder
Where
-
$\dot{m}$ is mass flow [$kg/s$] -
$\rho$ is density [$kg/m^3$] -
$V$ is volume$=x A$ [$m^2$]
In other words, the mass flow in and out of the cylinder is a function of the change in time of density and volume. Expanding the derivative gives
The force output is simply pressure applied on the moving area