- Index
- » Users
- » rakrao2007
- » Profile
Posts
Posts
I am trying to simulate a pipe flow model and I am using a grid with 100 points for a pipe of length 1m. I tried using the following friction model:
for i in 1:100 loop
if abs(u[i]) * Diameter * rho[i] / (1.85 * 10 ^ (-5)) > 2000 then
fw[i] = 1.325 / log(e / (3.75 * Diameter) + 5.74 / (abs(u[i]) * Diameter * rho[i] / (1.85 * 10 ^ (-5))) ^ 0.9) ^ 2;
else
if abs(u[i]) * Diameter * rho[i] / (1.85 * 10 ^ (-5)) < 100 then
fw[i] = 0.64;
else
fw[i] = 64/abs(u[i]) * Diameter * rho[i] / (1.85 * 10 ^ (-5));
end if;
end if;
end for;
With this code, the pipe model gets compiled in OMEdit, but the simulation does not progress from 0%, even after 3 days.
But if I change the friction model to the following:
for i in 1:100 loop
if abs(u[i]) * Diameter * rho[i] / (1.85 * 10 ^ (-5)) > 2000 then
fw[i] = 1.325 / log(e / (3.75 * Diameter) + 5.74 / (abs(u[i]) * Diameter * rho[i] / (1.85 * 10 ^ (-5))) ^ 0.9) ^ 2;
else
fw[i] = 0.35;
end if;
end for;
then the pipe model simulates without any trouble.
Please help me in understanding why this happens. I am using OpenModelica 1.9.0 (r17628).
- Index
- » Users
- » rakrao2007
- » Profile