I have some OpenFOAM simulation results (you may use the official can.ex2
model which can be downloaded from here). What I want to do is:
- open a file, load the original data as decomposed case (which can't be applied to the case above)
- apply a Calculator filter one a specific variable (e.g.
DISP*3.14*coordsX
, I used 3.14 because for the love of god I can't find Pi!) - apply filter plot over line
[x1,y1,z1]
to[x2,y2,z2]
- integrate the output of 2 over the line defined in 3 in each time step
- plot the result of 4 over time
I would appreciate if you could help me know how I can write a Python script to do this.