CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > ANSYS > CFX

Opening velocity varies over time?

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   January 2, 2010, 05:24
Default Opening velocity varies over time?
  #1
Senior Member
 
Join Date: Jul 2009
Posts: 260
Rep Power: 18
kingjewel1 is on a distinguished road
Hi there,

How could I make an opening velocity vary over time. Eg someone breathing? We assume
the frequency of respiration under light physical work is
17 times per minute with a time-mean rate about
8.4 l/min How to implement in CEL?

Thank you
kingjewel1 is offline   Reply With Quote

Old   January 2, 2010, 06:24
Default
  #2
Member
 
Join Date: Nov 2009
Posts: 49
Rep Power: 17
Abou ali is on a distinguished road
Hi,
First try to find a mathematical formulation of the velocity or the mass flowrat versus time.
I mean velocity=f(t) were f is a periodic function with a period T=60/17
And f(0s)=0m/s f(T)=0m/s
Finally: area/T*Integral[(velocity) between T and 0] =8.4/17 must be verified.
Abou ali is offline   Reply With Quote

Old   January 2, 2010, 07:29
Default
  #3
Senior Member
 
Join Date: Jul 2009
Posts: 260
Rep Power: 18
kingjewel1 is on a distinguished road
Quote:
Originally Posted by Abou ali View Post
Hi,
First try to find a mathematical formulation of the velocity or the mass flowrat versus time.
I mean velocity=f(t) were f is a periodic function with a period T=60/17
And f(0s)=0m/s f(T)=0m/s
Finally: area/T*Integral[(velocity) between T and 0] =8.4/17 must be verified.
Thank you for your quick reply.

(1) so if f(t+p)=f(t), f(0)=f(T)=0 such a function could be sin(60/17+t).

(2) 1/T*Area*[F(T)-F(0)]=8.4/17, where F(t)=integral of f(t)

=> -cos(60/17+T)+cos(60/17)=8.4T/(17*Area)

My question is how to adjust the units so that CFX understands the CEL to be in m/s say instead of radians (from sin)?

Thank you and Happy New year
kingjewel1 is offline   Reply With Quote

Old   January 2, 2010, 10:37
Default
  #4
Member
 
Join Date: Nov 2009
Posts: 49
Rep Power: 17
Abou ali is on a distinguished road
Hi,
In the first equation you must add Vmax, it be come Vmax*sin()
were sin is a dimensionless quantity and Vmax can be calculated from the second equation.
Abou ali is offline   Reply With Quote

Old   January 2, 2010, 18:52
Default
  #5
Senior Member
 
Join Date: Jul 2009
Posts: 260
Rep Power: 18
kingjewel1 is on a distinguished road
Quote:
Originally Posted by Abou ali View Post
Hi,
In the first equation you must add Vmax, it be come Vmax*sin()
were sin is a dimensionless quantity and Vmax can be calculated from the second equation.
Hi there and thank you for replying,

How can you make sin nondimensional as CFX tells me it is be radians?
kingjewel1 is offline   Reply With Quote

Old   January 3, 2010, 12:13
Default
  #6
Member
 
Join Date: Nov 2009
Posts: 49
Rep Power: 17
Abou ali is on a distinguished road
Hi,
Can you display the error message sent by CFX here ?
Abou ali is offline   Reply With Quote

Old   January 4, 2010, 05:37
Default
  #7
Senior Member
 
Join Date: Jul 2009
Posts: 260
Rep Power: 18
kingjewel1 is on a distinguished road
I divided t/[s], now the error message disappears. So I have 1.7[ms^-1]*sin(60/17+t/[s]) and have made this a monitor point as well. However when I run a transient solution I'm given the error

ERROR #004100025 has occurred in subroutine SCL_RESCH. |
| Message: |
| A floating point overflow has occurred. Check solver |
| parameters, boundary conditions and mesh quality. The |
| calculation will be terminated. |
| Note: if this error occurs at the first iteration, that may |
| be caused by the initial guess, e.g., a zero initial |
| velocity and zero dynamic viscosity. |
|--------------------------------------------------------------------|
kingjewel1 is offline   Reply With Quote

Old   January 4, 2010, 17:08
Default
  #8
Member
 
Join Date: Nov 2009
Posts: 49
Rep Power: 17
Abou ali is on a distinguished road
Hi,
It's earlier to speak about the solver error message. The formulation which you found doesn't describe exactly what you want. Try to plot the function in the Plot panel of the Expression window (use t=0s to 60s) and see what it gives.
I think that a right function can be: Vmax*sin(2pi*t/T).
The integration of this function in a period is 0, this signify that the mass flowrat at inspiration = the mass flowrat at expiration = 8.4/17 l/min then Vmax can be calculated from the following eq: area/T*Integral[(velocity) between T/2 and 0] =8.4/17.
Try to verify the new expression again.
Abou ali is offline   Reply With Quote

Old   January 4, 2010, 18:24
Default
  #9
Senior Member
 
Join Date: Jul 2009
Posts: 260
Rep Power: 18
kingjewel1 is on a distinguished road
Quote:
Originally Posted by Abou ali View Post
Hi,
It's earlier to speak about the solver error message. The formulation which you found doesn't describe exactly what you want. Try to plot the function in the Plot panel of the Expression window (use t=0s to 60s) and see what it gives.
I think that a right function can be: Vmax*sin(2pi*t/T).
The integration of this function in a period is 0, this signify that the mass flowrat at inspiration = the mass flowrat at expiration = 8.4/17 l/min then Vmax can be calculated from the following eq: area/T*Integral[(velocity) between T/2 and 0] =8.4/17.
Try to verify the new expression again.
Thank you. I'm wondering though, Sin(2pi*t/T) has a periodicity of 2pi but I'm looking for 60/17 hence the
sin(2pi*t+60/17). What am I missing?

2)area/T*int(Vmax*Sin(2pi*t/T))dt=8.4/17 between 0 and T/2
=> Vmax=8.4e-3/(Pi*17*Area)~0.621[m/s] which seems very reasonable.
presuming 8.4 litres is 8.4e-3 meters cubed
kingjewel1 is offline   Reply With Quote

Old   January 12, 2010, 19:37
Default
  #10
Senior Member
 
Join Date: Jul 2009
Posts: 260
Rep Power: 18
kingjewel1 is on a distinguished road
Quote:
Originally Posted by Abou ali View Post
Hi,
It's earlier to speak about the solver error message. The formulation which you found doesn't describe exactly what you want. Try to plot the function in the Plot panel of the Expression window (use t=0s to 60s) and see what it gives.
I think that a right function can be: Vmax*sin(2pi*t/T).
The integration of this function in a period is 0, this signify that the mass flowrat at inspiration = the mass flowrat at expiration = 8.4/17 l/min then Vmax can be calculated from the following eq: area/T*Integral[(velocity) between T/2 and 0] =8.4/17.
Try to verify the new expression again.
I'm just wondering how I can explain why CFX produces a much smaller flow rate on the exhalation than on inhalation (see Fig for 1 cycle). What do you think could be the reason for this?
Attached Images
File Type: jpg nose3_Q.jpg (54.0 KB, 15 views)
kingjewel1 is offline   Reply With Quote

Old   January 14, 2010, 07:19
Default
  #11
Member
 
Join Date: Nov 2009
Posts: 49
Rep Power: 17
Abou ali is on a distinguished road
Hi,
I think that you have used an inlet and outlet boundaries conditions. This is not consistent with this problem because this type of boundaries prevents the flow to change direction. The solution is to use an opening boundary condition in both side of the domain.
Abou ali is offline   Reply With Quote

Old   January 14, 2010, 07:39
Default
  #12
Senior Member
 
Join Date: Jul 2009
Posts: 260
Rep Power: 18
kingjewel1 is on a distinguished road
Quote:
Originally Posted by Abou ali View Post
Hi,
I think that you have used an inlet and outlet boundaries conditions. This is not consistent with this problem because this type of boundaries prevents the flow to change direction. The solution is to use an opening boundary condition in both side of the domain.
No no, I used an opening boundary condition applied to a single face (0.05cm*0.05cm). You say 'both side of the domain', what do you mean by this?

Subsequently I tried using an outlet and obtained similar flow rates but biased towards the inhalation (logically). Picture is of the domain for reference purposes. small cube in the middle is cut out. One face is the opening.
Set up:
Domain temp: 21C
Nose opening temp: 34C
Fluid:Air Ideal gas
Buoyancy: ON
Buoyancy Ref density: 1.204kg/m^3
Opening Uvelocity: Vmax*sin(2*pi*t/T/1[s])


By the way thank you for your help. What do you think?
Attached Images
File Type: jpg nose3_Q_1.jpg (34.1 KB, 13 views)
kingjewel1 is offline   Reply With Quote

Old   January 14, 2010, 18:05
Default
  #13
Member
 
Join Date: Nov 2009
Posts: 49
Rep Power: 17
Abou ali is on a distinguished road
Hi,
I think that there is a problem in the simulation definitions!!!! If you attach the output file here, maybe I can help.
Abou ali is offline   Reply With Quote

Old   January 14, 2010, 18:21
Default
  #14
Senior Member
 
Join Date: Jul 2009
Posts: 260
Rep Power: 18
kingjewel1 is on a distinguished road
Quote:
Originally Posted by Abou ali View Post
Hi,
I think that there is a problem in the simulation definitions!!!! If you attach the output file here, maybe I can help.
I tried to attach it in a number of formats without much success, so i've pasted the top bit here:

Quote:
+--------------------------------------------------------------------+
| |
| CFX Command Language for Run |
| |
+--------------------------------------------------------------------+

LIBRARY:
CEL:
EXPRESSIONS:
Te = 60/17
Veln = 3[m/s]*sin(2*pi*t/Te/1[s])
END
END
ADDITIONAL VARIABLE: Contaminant
Option = Definition
Tensor Type = SCALAR
Units = [m/m ]
Variable Type = Specific
END
MATERIAL: Air Ideal Gas
Material Description = Air Ideal Gas (constant Cp)
Material Group = Air Data, Calorically Perfect Ideal Gases
Option = Pure Substance
Thermodynamic State = Gas
PROPERTIES:
Option = General Material
ABSORPTION COEFFICIENT:
Absorption Coefficient = 0.01 [m^-1]
Option = Value
END
DYNAMIC VISCOSITY:
Dynamic Viscosity = 1.831E-05 [kg m^-1 s^-1]
Option = Value
END
EQUATION OF STATE:
Molar Mass = 28.96 [kg kmol^-1]
Option = Ideal Gas
END
REFERENCE STATE:
Option = Specified Point
Reference Pressure = 1 [atm]
Reference Specific Enthalpy = 0. [J/kg]
Reference Specific Entropy = 0. [J/kg/K]
Reference Temperature = 25 [C]
END
REFRACTIVE INDEX:
Option = Value
Refractive Index = 1.0 [m m^-1]
END
SCATTERING COEFFICIENT:
Option = Value
Scattering Coefficient = 0.0 [m^-1]
END
SPECIFIC HEAT CAPACITY:
Option = Value
Specific Heat Capacity = 1.0044E+03 [J kg^-1 K^-1]
Specific Heat Type = Constant Pressure
END
THERMAL CONDUCTIVITY:
Option = Value
Thermal Conductivity = 2.61E-2 [W m^-1 K^-1]
END
END
END
END
FLOW:
SOLUTION UNITS:
Angle Units = [rad]
Length Units = [m]
Mass Units = [kg]
Solid Angle Units = [sr]
Temperature Units = [K]
Time Units = [s]
END
SIMULATION TYPE:
Option = Transient
EXTERNAL SOLVER COUPLING:
Option = None
END
INITIAL TIME:
Option = Automatic with Value
Time = 0 [s]
END
TIME DURATION:
Option = Total Time
Total Time = Te[s]
END
TIME STEPS:
Option = Timesteps
Timesteps = 0.05 [s]
END
END
DOMAIN: Default Domain
Coord Frame = Coord 0
Domain Type = Fluid
Fluids List = Air Ideal Gas
Location = B32
BOUNDARY: Default Domain Default
Boundary Type = WALL
Location = F28.32,F30.32,F31.32,F35.32,F36.32,F37.32,F38.32
BOUNDARY CONDITIONS:
ADDITIONAL VARIABLE: Contaminant
Option = Zero Flux
END
HEAT TRANSFER:
Option = Adiabatic
END
WALL INFLUENCE ON FLOW:
Option = No Slip
END
WALL ROUGHNESS:
Option = Smooth Wall
END
END
END
BOUNDARY: Nose
Boundary Type = OPENING
Location = F29.32
BOUNDARY CONDITIONS:
ADDITIONAL VARIABLE: Contaminant
Additional Variable Value = 0 [m m^-1]
Option = Value
END
FLOW REGIME:
Option = Subsonic
END
HEAT TRANSFER:
Option = Static Temperature
Static Temperature = 34 [C]
END
MASS AND MOMENTUM:
Option = Cartesian Velocity Components
U = Veln
V = 0 [m s^-1]
W = 0 [m s^-1]
END
TURBULENCE:
Option = Medium Intensity and Eddy Viscosity Ratio
END
END
BOUNDARY SOURCE:
SOURCES:
EQUATION SOURCE: Contaminant
Option = Total Source
Total Source = 1e-15 [kg s^-1]
END
END
END
END
BOUNDARY: Symm
Boundary Type = SYMMETRY
Location = F33.32,F34.32
END
DOMAIN MODELS:
BUOYANCY MODEL:
Buoyancy Reference Density = 1.2 [kg m^-3]
Gravity X Component = 0 [m s^-2]
Gravity Y Component = -9.81 [m s^-2]
Gravity Z Component = 0 [m s^-2]
Option = Buoyant
BUOYANCY REFERENCE LOCATION:
Option = Automatic
END
END
DOMAIN MOTION:
Option = Stationary
END
MESH DEFORMATION:
Option = None
END
REFERENCE PRESSURE:
Reference Pressure = 1 [atm]
END
END
FLUID MODELS:
ADDITIONAL VARIABLE: Contaminant
Kinematic Diffusivity = 1e-5 [m^2 s^-1]
Option = Transport Equation
END
COMBUSTION MODEL:
Option = None
END
HEAT TRANSFER MODEL:
Option = Thermal Energy
END
THERMAL RADIATION MODEL:
Option = None
END
TURBULENCE MODEL:
Option = k epsilon
BUOYANCY TURBULENCE:
Option = None
END
END
TURBULENT WALL FUNCTIONS:
Option = Scalable
END
END
END
INITIALISATION:
Option = Automatic
INITIAL CONDITIONS:
Velocity Type = Cartesian
ADDITIONAL VARIABLE: Contaminant
Additional Variable Value = 0 [m m^-1]
Option = Automatic with Value
END
CARTESIAN VELOCITY COMPONENTS:
Option = Automatic with Value
U = 0 [m s^-1]
V = 0 [m s^-1]
W = 0 [m s^-1]
END
EPSILON:
Option = Automatic
END
K:
Fractional Intensity = 0.05
Option = Automatic with Value
END
STATIC PRESSURE:
Option = Automatic with Value
Relative Pressure = 0 [Pa]
END
TEMPERATURE:
Option = Automatic with Value
Temperature = 21 [C]
END
END
END
OUTPUT CONTROL:
MONITOR OBJECTS:
MONITOR BALANCES:
Option = Full
END
MONITOR FORCES:
Option = Full
END
MONITOR PARTICLES:
Option = Full
END
MONITOR POINT: Ve
Expression Value = Veln
Option = Expression
END
MONITOR RESIDUALS:
Option = Full
END
MONITOR TOTALS:
Option = Full
END
END
RESULTS:
File Compression Level = Default
Option = Standard
END
TRANSIENT RESULTS: Transient Results 1
File Compression Level = Default
Option = Standard
OUTPUT FREQUENCY:
Option = Every Timestep
END
END
END
SOLVER CONTROL:
ADVECTION SCHEME:
Option = High Resolution
END
CONVERGENCE CONTROL:
Maximum Number of Coefficient Loops = 3
Timescale Control = Coefficient Loops
END
CONVERGENCE CRITERIA:
Residual Target = 0.000001
Residual Type = RMS
END
TRANSIENT SCHEME:
Option = Second Order Backward Euler
TIMESTEP INITIALISATION:
Option = Automatic
END
END
END
END
COMMAND FILE:
Version = 11.0
Results Version = 11.0
END
EXECUTION CONTROL:
INTERPOLATOR STEP CONTROL:
Runtime Priority = Standard
EXECUTABLE SELECTION:
Double Precision = Off
END
MEMORY CONTROL:
Memory Allocation Factor = 1.0
END
END
PARALLEL HOST LIBRARY:
HOST DEFINITION: phipc
Remote Host Name = PHI-PC
Host Architecture String = winnt
Installation Root = C:\Program Files\ANSYS Inc\v%v\CFX
END
END
PARTITIONER STEP CONTROL:
Multidomain Option = Independent Partitioning
Runtime Priority = Standard
EXECUTABLE SELECTION:
Use Large Problem Partitioner = Off
END
MEMORY CONTROL:
Memory Allocation Factor = 1.0
END
PARTITIONING TYPE:
MeTiS Type = k-way
Option = MeTiS
Partition Size Rule = Automatic
Partition Weight Factors = 0.250, 0.250, 0.250, 0.250
END
END
RUN DEFINITION:
Definition File = C:/Users/Phi/Documents/New \
folder/cylinder/nose3_Q_fast.def
Interpolate Initial Values = Off
Run Mode = Full
END
SOLVER STEP CONTROL:
Runtime Priority = Standard
EXECUTABLE SELECTION:
Double Precision = Off
END
MEMORY CONTROL:
Memory Allocation Factor = 1.0
END
PARALLEL ENVIRONMENT:
Number of Processes = 4
Start Method = PVM Local Parallel
Parallel Host List = phipc*4
END
END
END
kingjewel1 is offline   Reply With Quote

Old   January 15, 2010, 04:05
Default
  #15
Member
 
Join Date: Nov 2009
Posts: 49
Rep Power: 17
Abou ali is on a distinguished road
Hi,
I have seen your output file and maybe the problem is in the symmetry condition.
I have run a test simulation of a nose (0.05*0.05*0.05 cm3) in a domain of 2*2*2 m3.
I use an opening boundary condition in one side of the nose with the same condition as yours, for the boundaries of the domain I set them as opening with 0 Pa.
You can see here the rusults.
Attached Images
File Type: png nose in room.PNG (17.5 KB, 8 views)
File Type: jpg mass flow.jpg (36.3 KB, 11 views)
Attached Files
File Type: txt output.txt (7.8 KB, 4 views)
Abou ali is offline   Reply With Quote

Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Floating point exception error Alan OpenFOAM Running, Solving & CFD 11 July 1, 2021 22:51
How to write k and epsilon before the abnormal end xiuying OpenFOAM Running, Solving & CFD 8 August 27, 2013 16:33
Time Variable Velocity programming? Michelle FLUENT 2 February 18, 2008 13:38
Variables Definition in CFX Solver 5.6 R P CFX 2 October 26, 2004 03:13
Graph ploting of velocity vs time Lam FLUENT 1 October 31, 2003 07:50


All times are GMT -4. The time now is 17:18.