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

udf

Register Blogs Community New Posts Updated Threads Search

Like Tree3Likes
  • 1 Post By Sixkillers
  • 1 Post By shk12345
  • 1 Post By Sixkillers

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   January 13, 2012, 23:23
Unhappy udf
  #1
New Member
 
studen
Join Date: Jan 2012
Posts: 12
Rep Power: 14
studen is on a distinguished road
i have a udf for variable viscosity function in .cpp format can anyone tell me how make fluent read .cpp files i read in the udf manual it only read .c extension.



the program in c++ is running fine, do i have to change it to work in fluent, or just load it as udf.
studen is offline   Reply With Quote

Old   January 14, 2012, 03:28
Default
  #2
Member
 
Join Date: Nov 2011
Location: Czech Republic
Posts: 97
Rep Power: 14
Sixkillers is on a distinguished road
You will have to rewrite it into C. From C++ it should be so hard.
studen likes this.
Sixkillers is offline   Reply With Quote

Old   January 14, 2012, 04:43
Default
  #3
Senior Member
 
shoeb khan
Join Date: Nov 2011
Posts: 179
Rep Power: 14
shk12345 is on a distinguished road
hi
I think you know copy paste .

copy the content of the file
opne a new notepad and paste it there with name.c

hoke it in fluent and run

you are done

shk
studen likes this.
shk12345 is offline   Reply With Quote

Old   January 14, 2012, 05:30
Default
  #4
Member
 
Join Date: Nov 2011
Location: Czech Republic
Posts: 97
Rep Power: 14
Sixkillers is on a distinguished road
Well I think it depends on how the UDF is written. If it is using C++ features, C compiler won't be able to compile it So if you can share your UDF with us.
studen likes this.
Sixkillers is offline   Reply With Quote

Old   January 15, 2012, 00:30
Red face thanks for the help
  #5
New Member
 
studen
Join Date: Jan 2012
Posts: 12
Rep Power: 14
studen is on a distinguished road
Thank you guys for the replies, shk12345 i had tried that, but c++ syntax is different from c suchas println can't be used in c, we have to opt for pintf and many other commands,


sixkillers thank you, i wrote it in c with some help and the function works i hooked it fluent and its working fine there too.


now am facing a new probs, in fluent i have assigned the wall temperature as 25 and the fluid temperature as 45, am doing working on natural convection cooling, so after a certain amount of time the temperature inside the cavity will become constant at 25. but when i check for temp contour and velocity countours at particular intervals of time, i dont get temp range from 25 to 45, fluent contour plots only show temp range from 25 to 31 , can anyone explain why this is happening, and how can i get the o/p for my desired, range (the one i want), i tried changing the setting in contours by removing auto range and manually set min to 25 and max to 45, but the plots are not matching with the previous work.

help and suggestion pls,

thnx in advance
studen 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
Dynamic Mesh UDF Qureshi FLUENT 7 March 23, 2017 07:37
UDF parallel error: chip-exec: function not found????? shankara.2 Fluent UDF and Scheme Programming 1 January 16, 2012 22:14
How to add a UDF to a compiled UDF library kim FLUENT 3 October 26, 2011 21:38
UDF...UDF...UDF...UDF Luc SEMINEL FLUENT 0 November 25, 2002 04:03
UDF, UDF, UDF, UDF Luc SEMINEL Main CFD Forum 0 November 25, 2002 04:01


All times are GMT -4. The time now is 14:47.