CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   CFX (http://www.cfd-online.com/Forums/cfx/)
-   -   cfx5mondata - error (http://www.cfd-online.com/Forums/cfx/110580-cfx5mondata-error.html)

Roland R December 14, 2012 12:33

cfx5mondata - error
 
Hello,

I would like to export data of monitor point 1 during the run. I have written in the command line:

e:\...my working directory...>mon.bat -res 0mm_007.res varlist "USER POINT,Monitor Point 1" > output.txt

Content of "mon.bat": "C:\...v121\bin\cfx5mondata"

And the result:

"You must supply a single results file, run directory or monitor data text file."

What is the problem? I have supplied one results file.

Thanks
Roland

Lance December 17, 2012 03:40

Quote:

Originally Posted by Roland R (Post 397589)
e:\...my working directory...>mon.bat -res 0mm_007.res varlist "USER POINT,Monitor Point 1" > output.txt

Could it be because you are missing a - before varlist?

Roland R December 17, 2012 04:30

I tried to use the command with "-" but it doesn't operate...

Lance December 17, 2012 04:39

Odd. This command works for me:

cfx5mondata -res myres.res -out output.csv -nocoeffloops -varlist "TIME" -varrule "CATEGORY = USER POINT"

Roland R December 17, 2012 06:47

Quote:

Originally Posted by Lance (Post 397859)
Odd. This command works for me:

cfx5mondata -res myres.res -out output.csv -nocoeffloops -varlist "TIME" -varrule "CATEGORY = USER POINT"

And which monitor point will be exported by this command? I should exported one determined monitor point.

Thanks
Roland

Roland R December 17, 2012 06:52

By the way, I tried to apply your commant but the result is same:mad:

"You must supply a single results file, run directory or monitor data text file."


I dont understand...

Lance December 17, 2012 07:51

It will export all monitors to a single file. Have you tried to supply the entire path to your results file?

Roland R December 17, 2012 08:22

Quote:

Originally Posted by Lance (Post 397899)
It will export all monitors to a single file. Have you tried to supply the entire path to your results file?

Yes. I open the window of command line in my working directory which contain my result, so i think, this can not cause problem.

Roland R December 17, 2012 08:40

Ohh....yeah....I found the error.

My first command (mon.bat) has to contain your command too. If it contains just the entire path of mondata then it will not operate.

Thanks
Roland

Roland R December 17, 2012 08:59

I would like to exported a txt (or csv) file from the monitor points while the running. So the exported txt file should be updated continously.

How can I carry out this?

Thanks
Roland

Lance December 17, 2012 09:06

Quote:

Originally Posted by Roland R (Post 397905)
I would like to exported a txt (or csv) file from the monitor points while the running. So the exported txt file should be updated continously.

How can I carry out this?

Thanks
Roland

change -res "myresults".res to -dir "mydirectory".dir
(this is described in the documentation and "cfx5mondata -help"

You'll have to run the command manually (or make a script do it for you at a prescribed interval) to update the .csv file during the run. Dont know if it is possible to automatically export monitor data to a .csv file after each time step. I guess it can be made with Fortran, but I dont really see the use?

Roland R December 17, 2012 09:52

OK, I understand. I would like to carry out a remeshing method. The new mesh feils will be created previously but I have to know the size of mesh deformation based on the text file monitor point.

brunoc December 17, 2012 11:43

A much easier way to do this is to open your res file in the CFX Solver Manager (File > Monitor Finished Run), go to the tab with the data you want, right-click it and select 'Export Plot Data'.

Cheers

Lance December 17, 2012 12:32

Why not make the simulation automatically stop when the deformation reaches a predefined limit? This should be possible using CEL expressions.

brunoc December 17, 2012 13:14

Quote:

Originally Posted by Lance (Post 397948)
Why not make the simulation automatically stop when the deformation reaches a predefined limit? This should be possible using CEL expressions.

That is a good idea. Another option if you don't want to parse the mon data file is to run a simple script that opens CFD Post and retrieves that displacement value you're looking for. It is something fairly simple to do.

Roland R December 18, 2012 09:55

Thanks for you helpfulness!

Yes, as you said; I have to define a condition in the interrupt control menu for the mesh deformation. I will generate the mesh files previously for case of every mesh deforamtion but I have a problem. For example my deformation is 5mm. I have two pregenerated mesh files for 4mm and 6mm, but the solver doesn't know which files will be selected for the next running period. Therefore I have to generate a txt (or dat) file (with cfx5mondata) which contains the deformaiton (or mesh velocity) and the solver will select the next mesh file based on this txt file (with an if function).

I think, I have to write for example a matlab code and it will select the mesh files.

regards
Roland

brunoc December 18, 2012 11:49

If you have pre-generated meshes at specific displacements, then just go with the option to stop the solver at these positions. That would be the easiest solution.

In your case, if the solver is stopping due to bad quality at 5mm, have it stop earlier at 4mm and swap the mesh.

Roland R December 20, 2012 10:10

OK, I understand you. I will think of this solution but just in next year;)

Thanks for your suggestions!

Happy New Year!

Roland

kar.coep May 21, 2015 09:54

Hi Lance,

Quote:

change -res "myresults".res to -dir "mydirectory".dir
(this is described in the documentation and "cfx5mondata -help"

You'll have to run the command manually (or make a script do it for you at a prescribed interval) to update the .csv file during the run. Dont know if it is possible to automatically export monitor data to a .csv file after each time step. I guess it can be made with Fortran, but I dont really see the use?
with reference to this, can you please elaborate how to run the cfx5mondata to get csv file during run? and if any basics on how to start on fortran to have export after every iteration?

Thanks,
Kartiki


All times are GMT -4. The time now is 19:49.