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

how to print parameters on console

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   June 3, 2022, 12:31
Default how to print parameters on console
  #1
New Member
 
sheida
Join Date: Mar 2021
Posts: 11
Rep Power: 5
shedo is on a distinguished road
Hello experts
I want to print some parameters I've defined their formula on the console, therefore I used bellow code:

printf("i=%d omega[i-1] HH[i-1] random=%d frandom=%f phi=%f\n",i,omega[i-1], HH[i-1] random,frandom,random_PHI[i-1]);

but when I initialize nothing printed on console, even when I run my code which gives me the correct results at the end, non of mentioned parameters are printed.
some friends said if I am going to compile my code I should write *message* instead of *printf* but no change was observed.
Do you now what should I do?
shedo is offline   Reply With Quote

Old   June 7, 2022, 04:43
Default
  #2
Senior Member
 
Alexander
Join Date: Apr 2013
Posts: 2,363
Rep Power: 34
AlexanderZ will become famous soon enoughAlexanderZ will become famous soon enough
compile with *message* instead of *printf*
that should print what you want into console if not, probably there is a problem with logic in your code

show your code here
__________________
best regards


******************************
press LIKE if this message was helpful
AlexanderZ is offline   Reply With Quote

Reply

Tags
printing, 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
how to get Sutherland and JANAF coefficients of air? immortality OpenFOAM Running, Solving & CFD 64 October 18, 2022 11:17
Print to console simulated plots ma_martinez FLUENT 5 March 25, 2020 15:54
Pro/E to ANSYS Parameterization Guide Trues ANSYS 4 April 18, 2018 06:52
Hybrid discretisation - blend factor gcoopermax CFX 5 September 23, 2016 09:05
[blockMesh] Another cylinder question bendel_boy OpenFOAM Meshing & Mesh Conversion 5 January 6, 2015 06:09


All times are GMT -4. The time now is 16:48.