|
[Sponsors] |
July 19, 2022, 08:47 |
CFD-Post import data as variable
|
#1 |
New Member
Benjamin
Join Date: Jul 2015
Posts: 21
Rep Power: 11 |
Hi everyone,
I notice it is possible to export data from a variable as csv from CFD-Post, but I was wondering if it would be possible to do the same for importing data? My goal would be to export a few variables, perform some calculations on them to create a new variable (using better tools than the expressions or macro available in CFD-Post), and then re-importing that variable into CFD-Post. The reason for this is because I would like to perform some matrix calculations or use complex numbers, which are not possible in CFD-Post from what I found. Thank you! |
|
July 19, 2022, 20:21 |
|
#2 |
Super Moderator
Glenn Horrocks
Join Date: Mar 2009
Location: Sydney, Australia
Posts: 17,864
Rep Power: 144 |
I do not know of a good way to do this. Your best bet would be to do it during the solver (maybe as a user fortran routine, it could even just read a text file) and write the result of that to a additional variable in the solver. Then it will be available in the post processor.
If you are doing advanced post processing like this you might want to consider more sophisticated post processors like tecplot, ensight or fieldview.
__________________
Note: I do not answer CFD questions by PM. CFD questions should be posted on the forum. |
|
July 20, 2022, 11:14 |
|
#3 | |
Senior Member
Join Date: Jun 2009
Posts: 1,877
Rep Power: 33 |
Quote:
__________________
Note: I do not answer CFD questions by PM. CFD questions should be posted on the forum. |
||
August 2, 2022, 07:36 |
|
#4 |
New Member
Benjamin
Join Date: Jul 2015
Posts: 21
Rep Power: 11 |
Thank you for your answers. I was away last week so I didn't get to reply earlier.
In the end I used the import command to load my csv: >import type=Generic, filename=C:/file.csv The thing is that I needed to check the Line and Face Connectivity when exporting the data otherwise I wouldn't be able to reload it properly after my calculation. By the way by complex I meant the use of complex numbers, with real and imaginary parts, which I don't think CFD-post can handle. |
|
August 2, 2022, 08:26 |
|
#5 |
Super Moderator
Glenn Horrocks
Join Date: Mar 2009
Location: Sydney, Australia
Posts: 17,864
Rep Power: 144 |
While CFD-Post does not natively support complex number functions, you can write a complex number as two scalar variables and then define complex number functions from those two variables. Obviously this is not as nice as native functions but it could be worth considering to to avoid the hassle of exporting data and doing the function somewhere else.
__________________
Note: I do not answer CFD questions by PM. CFD questions should be posted on the forum. |
|
Tags |
cfd-post, import, variable |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
CFD by anderson, chp 10.... supersonic flow over flat plate | varunjain89 | Main CFD Forum | 18 | May 11, 2018 08:31 |
Query-HOW TO EXTRACT MONITOR PLOT DATA AND IMPORT ON CFD POST | Mfaizan | CFX | 6 | June 9, 2016 22:18 |
[OpenFOAM] Import CFD data for visualizing in paraview | rpk | ParaView | 0 | March 29, 2012 05:46 |
emag beta feature: charge density | charlotte | CFX | 4 | March 22, 2011 10:14 |
How to update polyPatchbs localPoints | liu | OpenFOAM Running, Solving & CFD | 6 | December 30, 2005 18:27 |