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

Is CCL different with UDF?

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   April 29, 2019, 10:23
Smile Is CCL different with UDF?
  #1
Member
 
Roy
Join Date: Sep 2017
Posts: 80
Rep Power: 8
ROY4 is on a distinguished road
Hello everybody

I'm somehow new to coding in CFX and I want to learn about CCL and CEL. I have read about them in CFX tutorials but it is somehow vivid for me. I would like to know:

- What is the difference between CEL and CCL?
- Is CCL similar to UDF in Fluent or does it differ?
- In order to write a CCL and use it in CFX, do I need to install visual basics on my system just like the UDF?

I know that these questions might seem really basic. However, I would appreciate if someone can be patient and explain it to me.

Thank you in advance
ROY4 is offline   Reply With Quote

Old   April 29, 2019, 11:57
Default
  #2
Senior Member
 
Join Date: Jun 2009
Posts: 1,804
Rep Power: 32
Opaque will become famous soon enough
CCL is not a programming language, but a state language.

CEL (notice the difference) is an expression language that

- allows the writing of mathematical expressions (with only 1 logic statement, If) without the need for a compiler.
- it has predefined mathematical functions: sin/cos, sinh/cosh, sqrt, log, etc.. (see documentation for details)
- it has access to a set of exposed solution variables that you can use directly in the expressions
- there is no array syntax since it is hidden by the local context the expression is evaluated at, what is that
- If you are evaluating say temperature^2 on a boundary, it will evaluate the expression on the faces of the boundary (all of them, or in groups of them)
- If the same expression shows up on the domain level, say initialization, it would be evaluated on all the nodes/vertices of the mesh associated to that domain w/o saying temperature(1:n)^2 or looping structure like for, or DO.

If you exercise the tutorials, you can get a feeling for it.
Opaque is offline   Reply With Quote

Old   April 29, 2019, 12:01
Default
  #3
Member
 
Roy
Join Date: Sep 2017
Posts: 80
Rep Power: 8
ROY4 is on a distinguished road
Quote:
Originally Posted by Opaque View Post
CCL is not a programming language, but a state language.

CEL (notice the difference) is an expression language that

- allows the writing of mathematical expressions (with only 1 logic statement, If) without the need for a compiler.
- it has predefined mathematical functions: sin/cos, sinh/cosh, sqrt, log, etc.. (see documentation for details)
- it has access to a set of exposed solution variables that you can use directly in the expressions
- there is no array syntax since it is hidden by the local context the expression is evaluated at, what is that
- If you are evaluating say temperature^2 on a boundary, it will evaluate the expression on the faces of the boundary (all of them, or in groups of them)
- If the same expression shows up on the domain level, say initialization, it would be evaluated on all the nodes/vertices of the mesh associated to that domain w/o saying temperature(1:n)^2 or looping structure like for, or DO.

If you exercise the tutorials, you can get a feeling for it.
Dear Obaque
Thanks for your helpful answer. If I want to use a new drag model in the simulation of multiphase flow (a model other than Ishi-Zuber, Schiller-Naumann, Grace), How should I enter that model in CFX?
This model uses Re number which needs to be calculated
ROY4 is offline   Reply With Quote

Old   April 29, 2019, 18:00
Default
  #4
Super Moderator
 
Glenn Horrocks
Join Date: Mar 2009
Location: Sydney, Australia
Posts: 17,703
Rep Power: 143
ghorrocks is just really niceghorrocks is just really niceghorrocks is just really niceghorrocks is just really nice
Most new models can be implemented as CEL. If it is too complex for CEL you can use user fortran routines.
__________________
Note: I do not answer CFD questions by PM. CFD questions should be posted on the forum.
ghorrocks is offline   Reply With Quote

Old   April 30, 2019, 01:59
Default
  #5
Member
 
Roy
Join Date: Sep 2017
Posts: 80
Rep Power: 8
ROY4 is on a distinguished road
Quote:
Originally Posted by ghorrocks View Post
Most new models can be implemented as CEL. If it is too complex for CEL you can use user fortran routines.
Dear ghorrocks
I have used simple CEL in CFD Post before, but not in CFX-Pre. If I want to enter a model which contains bubble diameter based Reynolds number, then am I able to use CEL?

In order to use CEL, should I write a special form of code or I just need to write the formula?

Do you have any reference or can you please tell me how I can enter my user Fortran code into the simulation?
ROY4 is offline   Reply With Quote

Old   April 30, 2019, 02:03
Default
  #6
Super Moderator
 
Glenn Horrocks
Join Date: Mar 2009
Location: Sydney, Australia
Posts: 17,703
Rep Power: 143
ghorrocks is just really niceghorrocks is just really niceghorrocks is just really niceghorrocks is just really nice
Only consider user fortran if what you want to do cannot be done in CEL. Always try CEL first.

CEL is described in the CFX documentation, in the reference manual. There is a variables and function guide in there.
__________________
Note: I do not answer CFD questions by PM. CFD questions should be posted on the forum.
ghorrocks is offline   Reply With Quote

Old   April 30, 2019, 02:05
Default
  #7
Member
 
Roy
Join Date: Sep 2017
Posts: 80
Rep Power: 8
ROY4 is on a distinguished road
Quote:
Originally Posted by ghorrocks View Post
Only consider user fortran if what you want to do cannot be done in CEL. Always try CEL first.

CEL is described in the CFX documentation, in the reference manual. There is a variables and function guide in there.
Is there also a manual for user Fortran?
ROY4 is offline   Reply With Quote

Old   April 30, 2019, 02:10
Default
  #8
Super Moderator
 
Glenn Horrocks
Join Date: Mar 2009
Location: Sydney, Australia
Posts: 17,703
Rep Power: 143
ghorrocks is just really niceghorrocks is just really niceghorrocks is just really niceghorrocks is just really nice
Yes, in the solver modelling guide.

How about for the next one you try looking in the CFX documentation to find these things yourself? The search function finds stuff pretty quickly in my experience.
__________________
Note: I do not answer CFD questions by PM. CFD questions should be posted on the forum.
ghorrocks is offline   Reply With Quote

Old   April 30, 2019, 02:13
Default
  #9
Member
 
Roy
Join Date: Sep 2017
Posts: 80
Rep Power: 8
ROY4 is on a distinguished road
Quote:
Originally Posted by ghorrocks View Post
Yes, in the solver modelling guide.

How about for the next one you try looking in the CFX documentation to find these things yourself? The search function finds stuff pretty quickly in my experience.
Dear ghorrocks,

I don't have access to all CFX manual guide, I just have the Tutorials and its just vivid for me. I'm so sorry for asking you obvious questions and Thank you for answering them.
ROY4 is offline   Reply With Quote

Old   April 30, 2019, 02:46
Default
  #10
Super Moderator
 
Glenn Horrocks
Join Date: Mar 2009
Location: Sydney, Australia
Posts: 17,703
Rep Power: 143
ghorrocks is just really niceghorrocks is just really niceghorrocks is just really niceghorrocks is just really nice
http://lmgtfy.com/?q=cfx+documentation

__________________
Note: I do not answer CFD questions by PM. CFD questions should be posted on the forum.
ghorrocks 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
udf for one dimensional linear motion based on force maccheese Fluent UDF and Scheme Programming 2 September 1, 2019 02:18
Save output of udf in another udf! JuanJoMex FLUENT 0 February 8, 2018 12:43
UDF Compilation Error - Loading Library - COMMON Problem! Help! robtheslob Fluent UDF and Scheme Programming 8 July 24, 2015 00:53
UDF parallel error: chip-exec: function not found????? shankara.2 Fluent UDF and Scheme Programming 1 January 16, 2012 22:14
UDF, UDF, UDF, UDF Luc SEMINEL Main CFD Forum 0 November 25, 2002 04:01


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