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

CCL Expression - is this possible?

Register Blogs Community New Posts Updated Threads Search

Like Tree2Likes
  • 2 Post By stumpy

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   November 13, 2009, 07:18
Default CCL Expression - is this possible?
  #1
New Member
 
fabio
Join Date: Aug 2009
Posts: 17
Rep Power: 16
fabioacfoz is on a distinguished road
I need to create a damping in my thermostat, so what i though is with this set os parameters:

if T>25.2 AC is ON
if T<24.8 AC is OFF
if (T<25.2 AND T>24.8)AND(T(current timestep)<T(last timestep)) AC is ON
if (T<25.2 AND T>24.8)AND(T(current timestep)>T(last timestep)) AC is OFF

But i dont know how to do the Bolded part of the equation.

Does anyone knows how to set up the temperature at a specified timestep, like what i want to do in the example?

Thanks in advance
fabioacfoz is offline   Reply With Quote

Old   November 14, 2009, 05:50
Default
  #2
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
There is no way of accessing historical data in CEL. Put in a feature request for it, it would have to be the most requested thing for CEL. To implement what you describe you really need fortran.
ghorrocks is offline   Reply With Quote

Old   November 14, 2009, 08:38
Default
  #3
New Member
 
fabio
Join Date: Aug 2009
Posts: 17
Rep Power: 16
fabioacfoz is on a distinguished road
Damn , thanks ghorrocks.
fabioacfoz is offline   Reply With Quote

Old   November 16, 2009, 21:16
Default
  #4
Senior Member
 
Join Date: Apr 2009
Posts: 531
Rep Power: 21
stumpy is on a distinguished road
You can do this without fortran, it just needs a bit of CCL adding. First create an Additional Variable equal to T. In your expression instead of asking for T(last timestep) you now need to ask for AV(last timestep). The usual problem with this approach is that the AV value is only lagged to the last coefficient loop (at most), so you're not getting the previous timestep value. You can force the AV to only get updated once per timestep, hence when you ask for it in timestep n it will actually hold the value from timestep n-1. The magic bit of CCL you need is, errr.., something like:
Update Loop = TRANS_LOOP
This is a parameter that you add to the CCL definition of the AV. PLEASE CHECK THE RULES FILE TO MAKE SURE I GOT THE PARAMETER NAME CORRECT (and to see exactly where it goes in the AV definition) - I don't have access to that right now.
PranjalNewton and Saeef like this.
stumpy 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
CCL / Monitor Object Problem James Date CFX 4 September 29, 2010 02:23
Writing an expression for fully developed flow! Usman CFX 12 December 20, 2007 11:26
Relief Plots in CFX Michael CFX 15 June 30, 2006 08:01
Lift, Drag Vs time chart,calculations Jamesd69climber CFX 8 February 17, 2005 17:23
Creating, loop or iteration using expression edito Jan CFX 3 July 28, 2003 11:01


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