A de Laval nozzle is a tube that is pinched in the middle as in the above figure. It is often used to accelerate low speed high pressure gases to supersonic speed and is applied to variety of aerospace devices. Using Flowsquare, the flow through the nozzle can be simulated straightforwardly. The shape of the nozzle is just taken from wikipedia using Microsoft Paint. Easy Peasy!
During the simulation, the Mach number field transients as in the below figures.
At the location where nozzle area is the smallest, the Mach number reaches to 1 and the fluid moves at a sonic speed. After that, the velocity continues to increase due to gas expansion to reach supersonic speed near the exit. The exit fluid speed can be obtained theoretically using the following equation.
Here, ve is exit velocity (m/s), T is inlet temperature, R is Universal gas constant (8314 J/kmol K), M is the gas molar weight (g/mol), gamma is isentropic expansion factor (=1.4 in flowsquare), pe is absolute exhaust pressure (Pa), and p is the absolute inlet pressure. As in the figures in below, if we neglect the inlet boundary effect, we obtain T=410 (K), R=8314.5 (J/kmol K), M=29 (air, g/mol), gamma=1.4, pe=13,800 (Pa), and p=231,000 (Pa), yielding ve=681.1 (m/s) from the above equation. If you compare the exit velocity obtained from Flowsquare simulation, the difference is only 1.7% of the theoretical value!