CFD Online Logo CFD Online URL
Home > Forums > Software User Forums > ANSYS > CFX

CCL and Perl syntax

Register Blogs Members List Search Today's Posts Mark Forums Read

LinkBack Thread Tools Search this Thread Display Modes
Old   March 10, 2015, 10:26
Default CCL and Perl syntax
New Member
Join Date: Apr 2013
Posts: 9
Rep Power: 12
Leackim is on a distinguished road

I am currently using CCL and Perl to make a post treatment file.

I would like to know if someone already managed to used CCL syntax inside a perl .pm file (library file).

To explain a little more, when i am writting my .pm file i can't use !,
So how i show CFX that some commands are CCL.
Here is an example :
package Cfx;

use strict;
use Exporter qw(import);

our $VERSION = 1.00;
our @ISA = qw(Exporter);
our @EXPORT = ();
our @EXPORT_OK = qw(PointXYZ);
our %EXPORT_TAGS = ( DEFAULT => [qw(&PointXYZ)],
All => [qw(&PointXYZ)]);

CFX Post Version = 14.5

sub PointXYZ{
my ($s_dom,$s_x,$s_y,$s_z,$s_unit,$s_name)=@_; # Subroutine Input

my ($r_name);

# ------------Variable Initialization-----------------------------------------------------------------------------------------------------#
# -----------------------------------------------------------------------------------------------------------------------------------------#
POINT:Point $s_name
Apply Instancing Transform = On
Colour = 1, 1, 0
Domain List = $s_dom
Line Width = 2
Option = XYZ
Point = $s_x $s_unit, $s_y $s_unit, $s_z $s_unit;
Point Symbol = Crosshair
Range = Global
Specular Lighting = On
Surface Drawing = Smooth Shading;
Symbol Size = 0.07
Transparency = 0.0
$r_name="/POINT:Point $s_name"; #/
As soon as i add CFX command (CCL) like POINT... my code stop working, however if i removed any CFX line and make just "print" things, my library works.

So,if someone find a solution to mix perl and CFX language let me know.

Thank you
Leackim is offline   Reply With Quote

Old   March 10, 2015, 10:37
Senior Member
Join Date: Jun 2009
Posts: 1,803
Rep Power: 32
Opaque will become famous soon enough
Have you looked in the installation directory for CFD-Post session file examples ? They are suffixed .cse (Cfx SEssion)

They are worth a fortune if you are interested in Perl+CCL

Last edited by Opaque; March 10, 2015 at 17:43.
Opaque is offline   Reply With Quote

Old   March 11, 2015, 13:51
Senior Member
Edmund Singer P.E.
Join Date: Aug 2010
Location: Minneapolis, MN
Posts: 511
Rep Power: 20
singer1812 is on a distinguished road
Why do you have ; on END and Point = $s_x $s_unit, $s_y $s_unit, $s_z $s_unit

Those are CFX commands, not Perl
singer1812 is offline   Reply With Quote


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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
CCL CFD post: use of common perl function Leackim CFX 1 January 23, 2017 08:37
Access to arrays of variables with CCL or perl in command editor omidiut CFX 2 October 18, 2011 05:13
Perl script for intialisation pratik mehta CFX 2 September 10, 2008 03:09
CFX5Post error in batch mode with Perl windhair CFX 2 March 20, 2007 05:41
Time-steps via Perl in CCL Rui CFX 5 March 29, 2004 00:47

All times are GMT -4. The time now is 09:33.