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

UDF for variable mass flow inlet boundary condition

Register Blogs Community New Posts Updated Threads Search

Like Tree1Likes
  • 1 Post By cfd_steve

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   April 14, 2017, 02:08
Question UDF for variable mass flow inlet boundary condition
  #1
New Member
 
steve
Join Date: Apr 2017
Posts: 3
Rep Power: 9
cfd_steve is on a distinguished road
Hi all,
I need to specify a variable mass flow inlet as a sinusoidal function of time. I am new to FLUENT and managed to write the following code. It shows an error when interpreted in FLUENT.The following message displays "line 5: invalid lvalue in assignment". Total simulation time = 0.003125 s. Time step size = 1.13e-5. Could anyone tell where i'm going wrong?
#include "udf.h"
DEFINE_PROFILE(inlet_mf,th,i)
{
face_t f;
for(CURRENT_TIME=0; CURRENT_TIME<=0.003125; CURRENT_TIME = CURRENT_TIME+1.13e-5)
F_PROFILE(f,th,i) = 0.3866*sin(2010.88*CURRENT_TIME)
printf("Mass flow rate for new time step updated to %d\n",F_PROFILE);
}
Hosseini likes this.

Last edited by cfd_steve; April 19, 2017 at 08:44. Reason: code not specified
cfd_steve is offline   Reply With Quote

Reply

Tags
udf code, variable bc


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
Wind turbine simulation Saturn CFX 60 July 17, 2024 06:45
Issues on the simulation of high-speed compressible flow within turbomachinery dowlee OpenFOAM Running, Solving & CFD 11 August 6, 2021 07:40
Error - Solar absorber - Solar Thermal Radiation MichaelK CFX 12 September 1, 2016 06:15
Wrong flow in ratating domain problem Sanyo CFX 17 August 15, 2015 07:20
Error finding variable "THERMX" sunilpatil CFX 8 April 26, 2013 08:00


All times are GMT -4. The time now is 11:51.