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

UDF error: Double udf function expected

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   February 14, 2021, 13:42
Default UDF error: Double udf function expected
  #1
New Member
 
Andrew Bickerdike
Join Date: Feb 2021
Posts: 6
Rep Power: 5
andrewbickerdike is on a distinguished road
Hi,
I'm doing a project where I am simulating blood flow in the aorta and I've got a UDF for the pulsatile flow:

/* PULSATILE FLOW DEFINITION UDF */
#include "udf.h"
#define PI 3.141592654

DEFINE_PROFILE(inlet_x_velocity,th, i)
{
face_t f;
real t = CURRENT_TIME;
begin_f_loop(f,th)
{
F_PROFILE(f,th,i) = (4700.000000/(0.064731*60.0*437.435361))*pow(sin(3.141593*t),13 .0)*(cos((3.141593*t)-(PI/10.0)));
}
end_f_loop(f,th)
}


the problem being that I always get the error:
"chip-exec: inlet_x_velocity: wrong return type: double udf function expected"

Any suggestions about this?

Thanks.
andrewbickerdike is offline   Reply With Quote

Old   February 15, 2021, 00:31
Default
  #2
Senior Member
 
Join Date: Nov 2013
Posts: 1,965
Rep Power: 26
pakk will become famous soon enough
Quote:
Originally Posted by andrewbickerdike View Post
Hi,
I'm doing a project where I am simulating blood flow in the aorta and I've got a UDF for the pulsatile flow:

/* PULSATILE FLOW DEFINITION UDF */
#include "udf.h"
#define PI 3.141592654

DEFINE_PROFILE(inlet_x_velocity,th, i)
{
face_t f;
real t = CURRENT_TIME;
begin_f_loop(f,th)
{
F_PROFILE(f,th,i) = (4700.000000/(0.064731*60.0*437.435361))*pow(sin(3.141593*t),13 .0)*(cos((3.141593*t)-(PI/10.0)));
}
end_f_loop(f,th)
}


the problem being that I always get the error:
"chip-exec: inlet_x_velocity: wrong return type: double udf function expected"

Any suggestions about this?

Thanks.
This is not a problematic error. It's the compiler being pedantic. It will never give you any problem in your simulation.
But it looks distracting. One way to remove it:

F_PROFILE(f,th,i) = (real) (4700.000000/(0.064731*60.0*437.435361))*pow(sin(3.141593*t),13 .0)*(cos((3.141593*t)-(PI/10.0)));
pakk is offline   Reply With Quote

Reply

Tags
ansys, fluent, fluent - udf, udf


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
Problem About Running Fluent In Linux mitra FLUENT 18 June 20, 2019 02:11
long error when using make-install SU2_AD. tomp1993 SU2 Installation 3 March 17, 2018 06:25
[blockMesh] Errors during blockMesh meshing Madeleine P. Vincent OpenFOAM Meshing & Mesh Conversion 51 May 30, 2016 10:51
[blockMesh] Axisymmetrical mesh Rasmus Gjesing (Gjesing) OpenFOAM Meshing & Mesh Conversion 10 April 2, 2007 14:00
Droplet Evaporation Christian Main CFD Forum 2 February 27, 2007 06:27


All times are GMT -4. The time now is 23:09.