Jump to content


- - - - -

Field Function


  • Please log in to reply
1 reply to this topic

#1 Mr. Tran Quang

Mr. Tran Quang

    Newbie

  • Members
  • Pip
  • 1 posts

Posted 23 August 2019 - 08:57 AM

Hi everybody, I'm from Vietnam. I'm an CFD engineer.Previous I used ANSYS Fluent to simulate but now, I'm using Star CCM+ software to simulate for HVAC project. because of I just used this software in few weeks. So I have a problem. I hope that everybody help me.

I want to hook C language code (similar ANSYS Fluent) into STAR CCM+ to wind speed calculate. I don't know how to do. This is my code. Please help me

#include "udf.h"

DEFINE_PROFILE(log_velocity,thread,index)
{
real y[ND_ND];
real z;
face_t f;

begin_f_loop(f,thread)
{
F_CENTROID(y,f,thread);
    z = y[1];
    F_PROFILE(f,thread,index) = 3.7*log(z/0.6)/log(10.0/0.6);
}
end_f_loop(f,thread)
}

 


  • 0

#2 Ceyhan Erdem

Ceyhan Erdem

    Advanced Member

  • Moderators
  • 86 posts

Posted 28 August 2019 - 09:29 AM

Hi Tran,

 

I guess within STAR-CCM+ there must be a way to hook or compile so called "User Defined Functions (UDF)" as it is the case in ANSYS Fluent. But I believe CAESES forum is not likely the best place to address this question unless you would like to parameterize the velocity definition.

 

Maybe you would be more interested to dig into STAR-CCM+ Forums?

 

Cheers

Ceyhan


  • 0