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

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

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   October 20, 2009, 01: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: 17
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


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
Single or double precision Jonas Larsson Main CFD Forum 16 June 20, 2017 07:53
Single v.s. double precision Confused CFX 15 November 10, 2016 05:42
compressible two phase flow in CFX4.4 youngan CFX 0 July 2, 2003 00:32
Double Precision? Novak Elliott CFX 1 June 6, 2003 02:45
CFX 5.5 Roued CFX 1 October 2, 2001 17:49


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