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

return a normal number to solver in double precision mode in udfs

Register Blogs Members List Search Today's Posts Mark Forums Read

Reply
 
LinkBack Thread Tools Display Modes
Old   October 20, 2009, 00:11
Default return a normal number to solver in double precision mode in udfs
  #1
New Member
 
Payan
Join Date: Oct 2009
Posts: 21
Rep Power: 7
payam_IUST is on a distinguished road
Hi
when we run fluent in double precision mode,how we can return a normal number to solver in double precision mode in udfs?when I return a normal number in udf in double precision mode fllowing error in reported :

original udf :

#include "udf.h"
#include "dpm.h"

DEFINE_DPM_TIMESTEP(payam,p,dt)
{
return 0.01;
}

Error:
"function returning double returns float"
payam_IUST is offline   Reply With Quote

Old   February 13, 2012, 08:06
Default
  #2
New Member
 
Join Date: Feb 2012
Posts: 1
Rep Power: 0
SanderD is on a distinguished road
Maybe this works:

#include "udf.h"
#include "dpm.h"

DEFINE_DPM_TIMESTEP(payam,p,dt)
{
real X = 0.01;
return X;
}
SanderD is offline   Reply With Quote

Reply

Thread Tools
Display Modes

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 On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Single or double precision Jonas Larsson Main CFD Forum 15 March 26, 2007 23:15
Single v.s. double precision Confused CFX 9 April 19, 2004 18:33
compressible two phase flow in CFX4.4 youngan CFX 0 July 1, 2003 23:32
Double Precision? Novak Elliott CFX 1 June 6, 2003 01:45
CFX 5.5 Roued CFX 1 October 2, 2001 16:49


All times are GMT -4. The time now is 10:04.