CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   CFX (https://www.cfd-online.com/Forums/cfx/)
-   -   Plotting monitor data after the interrupted run is finished (https://www.cfd-online.com/Forums/cfx/122636-plotting-monitor-data-after-interrupted-run-finished.html)

majinsaha August 23, 2013 14:13

Plotting monitor data after the interrupted run is finished
 
Hello!
I have a transient cfd simulation, and I want to plot a pressure value at only one point in space. I started a monitor at that point. I know that I should load a res file in the CFX solver manager after the computation is finished and I will see the plot immediately. However, my simulation had several terminations due to overflows or whatever, and I had to rerun my simulation starting from the last successful transient file using the key -continue-from-file in the command line. So when I load my res file, it plots the pressure value for the time steps corresponding to the very last simulation ( maybe adding a few earlier ones somehow ).
How can I force the Solver manager to plot the data starting from t = 0?
I hope it does not lose the monitor data in the earlier runs. Otherwise this is going to be a very, very bad news, since my deadline is in two days, and I need a plot for the global simulation, starting from 0.

I think it is possible to plot what I need using a series of trn files in CFX-post ( although I don't know how ), but those file were saved every 150 steps, and I need my data at every step.

Please help!
Thanks.

brunoc August 23, 2013 14:29

Some good and some bad news for you.

The bad news: Solver Manager does automatically continue monitor points from previous cases when they are available. The fact that they're not showing in your case means the solver couldn't find then on you the file you used for the restart. This can happen if you're restarting from a crashed simulation or if you use a .trn file for restarts.

The good news: If you didn't erase the folders with you interrupted simulations, the monitor points are still there. Open Solver Manager and go to 'File > Monitor Run in Progress' then select the folder from the interrupted run. Your monitor points will be there. Just right-click and export them.

majinsaha August 23, 2013 16:34

Thanks for you constructive answer!
By folders for the interrupted run do you mean those ending with ".dir"? As far as I know, they are automatically deleted after the run stops ( regardless of success or not ).
I have a folder where all the trn files stored, and also a file named mon. I choose that folder, but Solver manager doesn't do anything afterward. It's not like it's loading anything.
I also checked that mon file. I believe it has some monitored data there, according to its name. But I believe all the data stored corresponds to the later time steps, since I saw it starting monitor process from step 34050, which is not 1.

Do you think the problem here is hidden in the fact that I managed to finish the run and this created a res file, which automatically erased earlier data in the mon file?

brunoc August 23, 2013 17:15

Yes, I meant the ones with the '.dir'. CFX only deletes them on clean exits. Since you have .res file you probably have clean exits, which I imagined you didn't.

Restarting runs with res files should bring the monitor points data along, unless you chose to ignore history data (which you said you didn't).

Still, res files usually have mon data within them. Try opening the res file using the 'Monitor finished run' option in the solver. Also the mon file is exactly what you said: temporary monitor data that is written to the res file after the solver finishes its job.

So, try opening your last res files in the solver to see what you get back.

majinsaha August 23, 2013 17:22

I actually mentioned in the first post, literally: "so when I load my res file, it plots the pressure value for the time steps corresponding to the very last simulation". I manage to create the res file after several terminations, by changing some conditions in the ccl file after each termination.

So I guess my older data is lost then...

I will use your advice in the future! Thanks!

brunoc August 23, 2013 17:24

No, what I meant is to open the older .res files in the solver, the ones you used to restart the previous cases.

If you don't have them anymore (nor .bak files) them you're out of luck...

majinsaha August 24, 2013 02:13

Unfortunately, I was restarting from trn file using switch -continue-from-file. The only res file I have is the one corresponding to the last simulation. Guess I need to make it a habit to always create intermidiate res files, to cover all the time intervals.

majinsaha August 24, 2013 02:37

Ok, so now I checked my other run that just finished. It was interrupted due to "Fatal overflow in linear solver". I checked the list of my directories first thing. There is no .dir directory there. So as I said previously, it is probably being erased each time the solver stops by itself. There is no res file obviously either. I have a directory with fresh trn files and mon. The solver manager refuses to open this run, neither from "monitor finished run", nor from "monitor run in progress". Does it mean my cfx is not configured the way it should?
The only thing I can do is to open mon file with some text editor and work with it on my own.

majinsaha August 24, 2013 04:46

Some amazing miracle happened. When I started a new run with the same -continue-from-file switch, I just looked in .dir, while it was still there. There was a mon file that's being filled during the simulation. But I also found mon.old, which appeared out of nowhere. It has all the old data for the previous time steps stored!

When I started the CFX Solver manager and chose "monitor run in progress", I could see the whole curve starting from t = 0.
I quickly saved that mon.old file in another folder before the execution finished.
I'm still not completely not sure how CFX behaves and where it stores all of its data, but at least I'm glad this issue resolved with success.
Thanks, brunoc, for participation.


All times are GMT -4. The time now is 10:41.