
[Sponsors] 
October 5, 2012, 11:59 
lumped parameter udfinclude pressure profile

#1 
Senior Member
Join Date: Feb 2011
Posts: 138
Rep Power: 7 
Dear all,
I want to use a lumped paramter outflow boundary condition for my coronary artery geometry and need to additionaly implement the pressure of the left ventricle there. I am working at writing a udf for this problem and thought of including a profile of this form (one of the normal profiles you can read with "File>Read>profiles"): ((pressure transient 10 1) (time ....) (pressure ....)) Is it possible to include it in a normal udf and how can I do this? Thanks a million for any help and idea! Lilly 

October 8, 2012, 06:59 
lumped parameter udfudf function in certain range

#2 
Senior Member
Join Date: Feb 2011
Posts: 138
Rep Power: 7 
I just wanted to add something:
Maybe I could also implement another udf inside the lumped parameter udf describing the pressure profile instead of using a "point profile". But my problem is: my profile should be periodic, that means it should start at 0s and it's duration should 1s and afterwards it should just start again from the beginning (This should go like this for about 50 times). Since it is a fit function, only the values of the function in a certain range (01s) are interesting for me. Is there a way to define this? Thanks a million for any help and ideas! Lilly 

May 19, 2015, 05:21 

#3  
New Member
Krishnaprasad
Join Date: Mar 2015
Posts: 2
Rep Power: 0 
Quote:
#include "udf.h"//file that contains definitions for define functions and fluent operations #define PI 3.141592654 DEFINE_PROFILE(inlet_velocity,th,i) { face_t f; begin_f_loop(f,th) double t = (CURRENT_TIME*2floor(CURRENT_TIME*2))/2; //t is the local time within each period { if(t <= 0.015) F_PROFILE(f,th,i) = (.0003.03t)/.02; else if((t >.015)&&(t<=.02)) F_PROFILE(f,th,i) = (t19.999)/333.33; else if((t >.02)&&(t<=.285)) F_PROFILE(f,th,i) = .085*sin((10.375*t).2075); else if((t >.285)&&(t<=.325)) F_PROFILE(f,th,i) = (28.33*t*t)+(20.3563*t)3.4679; else if((t >.325)&&(t<=.47)) F_PROFILE(f,th,i) = (2.7037*t*t)+(2.1696*t).2646; else if((t >.47)&&(t<=1)) F_PROFILE(f,th,i) = (.0206*t*t)(.2995*t)+.2939; } end_f_loop(f,th); } 

May 19, 2015, 11:22 

#4 
Senior Member
Join Date: Nov 2013
Posts: 887
Rep Power: 12 
It would help if you are more exact on the error that you get.
Probably you don't just get "parse error", but something like "parse error on line 12", which tells you to look carefully at line 12. Anyway, you have a problem in your line 12: Code:
F_PROFILE(f,th,i) = (.0003.03t)/.02; 

May 22, 2015, 22:15 

#5  
New Member
Krishnaprasad
Join Date: Mar 2015
Posts: 2
Rep Power: 0 
Quote:


Thread Tools  
Display Modes  


Similar Threads  
Thread  Thread Starter  Forum  Replies  Last Post 
Average static Pressure  san.pirate  CFX  34  December 6, 2011 15:26 
Problems in compiling paraview in Suse 10.3 platform  chiven  OpenFOAM Installation  3  December 1, 2009 08:21 
UDF to control Static Pressure (in cylinder)  James  FLUENT  0  July 20, 2004 07:54 
Hydrostatic pressure in 2phase flow modeling (CFX4.2)  HB &DS  CFX  0  January 9, 2000 14:19 
Hydrostatic pressure in 2phase flow modeling (long)  DS & HB  Main CFD Forum  0  January 8, 2000 16:00 