|
[Sponsors] |
![]() |
![]() |
#1 |
New Member
Bill Huang
Join Date: Oct 2017
Posts: 1
Rep Power: 0 ![]() |
Hi all,
I'm currently working on a heat exchanger simulation, and I'm trying to calculate the energy discharge rate of my system. In order to do that, I let CFView calculate the volume average temperature, and I can view that result in the message window inside CFView. I'm wondering if there's a way to export that value from the message window of CFView? Thanks in advance! |
|
![]() |
![]() |
![]() |
![]() |
#2 |
Senior Member
Holger Dietrich
Join Date: Apr 2011
Location: Germany
Posts: 174
Rep Power: 14 ![]() |
Dear Bill Huang,
yes this is possible with a few lines of python script. At first, please do your operations as desired (select the quantity you need and compute the volume average, for example). When you see the desired value in the message box in CFView please save the script via File -> Macro -> Save All. This is the easiest way to extract the python commands you need. The important part will look like this: CFViewBackward(1210) QntFieldScalar('Static Temperature') VolumeAverage() What you can do now is assigning a variable to Volume Average: CFViewBackward(1210) QntFieldScalar('Static Temperature') f = VolumeAverage() print f To test it you can print the value in the shell with an additional line "print f", please keep in mind that you need to start CFView with the argument -print for extended shell output. Or you can write this value to a file. I think there are enough tutorials how to write a variable to a file with python out there, as this is not specific to CFView. For a detailed explaination of the python commands available in CFView you may visit the online documentation of our customer portal: CFView™ > User Guide > Macro Language > CFView™ Command Description > Commands for Computing Volume Integrals I hope this helps you to proceed. If you have further questions please don't hesitate to ask. Kind regards, Holger |
|
![]() |
![]() |
![]() |
Tags |
cfview, numeca, postprocessing |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Volume average of a scalar? | mecarlg | ANSYS | 4 | September 3, 2018 13:50 |
multiphaseEulerFoam high Courant number | Frenk_T | OpenFOAM | 5 | November 24, 2016 04:23 |
Hypermesh to STARCCM+ export 3D volume mesh | totocros | STAR-CCM+ | 2 | July 5, 2015 23:59 |
Difference between Volume average and Mass flow average? | nygrenm | STAR-CCM+ | 1 | March 2, 2015 14:11 |
[blockMesh] error message with modeling a cube with a hold at the center | hsingtzu | OpenFOAM Meshing & Mesh Conversion | 2 | March 14, 2012 10:56 |