CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > ANSYS > FLUENT

animation form dat files

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   October 24, 2003, 07:31
Default animation form dat files
  #1
user
Guest
 
Posts: n/a
Hi!

I made my unsteady simulation and saves the case file and all the dat files (for each time step).

Can someone please tell me how can I now make an animation. I want fluent to read the dat file make an image and save it (for each time step).

Can this be done automaticly or do I have to open each file manually????

Help please

Thanks
  Reply With Quote

Old   October 24, 2003, 08:06
Default Re: animation form dat files
  #2
ap
Guest
 
Posts: n/a
FLUENT animations don't work that way.

You have to define an animation (Define -> Animation) before you start the calculation, choosing the view, the colours scale and how often you want to save a frame (see the manual for more details).

When you completed the definition of the animation, just run the calculation. At the end you can create an mpeg file.

Hi

ap
  Reply With Quote

Old   October 24, 2003, 08:11
Default Re: animation form dat files
  #3
user
Guest
 
Posts: n/a
Thanks!

But what if i don't know what do i want to animate prior to simulation. Or if i want it in a different colour later???
  Reply With Quote

Old   October 24, 2003, 08:34
Default Re: animation form dat files
  #4
david
Guest
 
Posts: n/a
hi,

you need to define first what you want to animate otherwise you would save all the data?

well, you can at least define what you want to animate, few parameters, by going to solve->animate-> define.

On animation sequences you define the number of sequences you want to save for animation prior to the simulation. On the right you have the case bottom called define where you can define all the parameters you might be interested in.

Hope this helps

david
  Reply With Quote

Old   October 24, 2003, 13:51
Default Re: animation form dat files
  #5
Tim
Guest
 
Posts: n/a
Good day,

I've had the same frustrating realisation (having to think of what I want to aminmate before iterating). The only way I can foresee around this is to use the autosave function (File -> Write -> Autosave) then enter how often you want a dat file saved (once every X timesteps). I don't think that you'd be able to go back into FLUENT and animate this way, but probably need to use an external visualisation program like FieldView or Tecplot. I suspect that this way will still be painfully time consuming.

Cheers, Tim.
  Reply With Quote

Old   October 24, 2003, 18:54
Default Re: animation form dat files
  #6
anton
Guest
 
Posts: n/a
Yes, you can read in all the dat files and make an image and save it for each dat file you read in. You need to create a journal file. In the journal file you write commands to read in each dat file, plot a contour, hardcopy a tiff, and then repeat for all the dat files you have. It is very easy, and the preferred way to make an animation. It will take a bit of time to write the journal file, but once it's done, you just read the journal file in fluent, and fluent will automatically create your tif files.
  Reply With Quote

Old   October 26, 2003, 19:22
Default Re: animation form dat files
  #7
Alamgir
Guest
 
Posts: n/a
Hi Anton,

I'm in same position like user, so if don't mind give us an example of journal writing (I know very little writing journal)

Alamgir
  Reply With Quote

Old   October 27, 2003, 02:34
Default Re: animation form dat files
  #8
user
Guest
 
Posts: n/a
Hi!

Yes please give us an example of journal....

Thanks
  Reply With Quote

Old   November 1, 2003, 19:02
Default Re: animation form dat files
  #9
Anton
Guest
 
Posts: n/a
Suppose you have a case file with 4 dat files:

myexample.cas.gz myexample001.dat.gz myexample002.dat.gz myexample003.dat.gz myexample004.dat.gz

Suppose you want to generate 4 tiff files of velocity magnitude (with scale 0 to 10 m/s) on a plane (say plane-x) from each dat file. Here's how to do it automatically using a journal file. Using a text editor (any text editor will do, even notepad!) write the following commands:

rd myexample001.dat.gz display contour velocity 0 10 display hardcopy myexample001.tif

rd myexample002.dat.gz display contour velocity 0 10 display hardcopy myexample002.tif

rd myexample003.dat.gz display contour velocity 0 10 display hardcopy myexample003.tif

rd myexample004.dat.gz display contour velocity 0 10 display hardcopy myexample004.tif

Save the above file, call it myexample.jou

In Fluent, setup your hardcopy options, ie., set the file format to tiff, change to colour, set the resolution, click apply. Set the display the way you want, ie., the orientation of the geometry,etc.

Then, just read in the journal file created above:

file->read->journal->myexample.jou

And Fluent will automatically read in the dat file, generate the contour plot, hardcopy the tiff, and repeat according to the commands in the journal file.

Now, if you've got a 1000 dat files, then it would a tedious task to copy and paste each statement above 1000 times, to say the least!. So, in that case, just write a C program for example to generate the journal file by looping through incrementing for each dat file.
  Reply With Quote

Old   November 1, 2003, 19:10
Default Re: animation form dat files- CORRECTION
  #10
Anton
Guest
 
Posts: n/a
In the above journal file, the statement:

display contour velocity 0 10

should be:

display contour plane-x velocity-magnitude 0 10

and should be on a new line. In fact, each statement starting with "display" should be on a new line.

All teh commands are just taken from the text user interface. Just go through the text user interface to see the sequence of commands necessary. ALMOST everything can be done through the text user interface.
  Reply With Quote

Old   November 7, 2003, 04:09
Default Re: animation form dat files- CORRECTION
  #11
user
Guest
 
Posts: n/a
Hi Anton!

Thanks for your help but i still have problems. After runing the journal file I get this message from Fluent:
:rd test.dat Reading "test01.dat"... Done.

> display contour velocity invalid command [velocity]

>display hardcopy test01.jpg

It makes 4 jpgs but only from a window that is open - where i set the image (not from the desired dat file)

The same thing is if i write velocity-magnitude, or velocity magnitude contour...

Can you tell me what am i doing wrong...

Thanks in advance

user

  Reply With Quote

Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
UDF issue MASOUD Fluent UDF and Scheme Programming 14 December 6, 2012 13:39
critical error during installation of openfoam Fabio88 OpenFOAM Installation 21 June 2, 2010 03:01
OF 1.6 | Ubuntu 9.10 (64bit) | GLIBCXX_3.4.11 not found piprus OpenFOAM Installation 22 February 25, 2010 13:43
Problems in compiling paraview in Suse 10.3 platform chiven OpenFOAM Installation 3 December 1, 2009 07:21
Results saving in CFD hawk Main CFD Forum 16 July 21, 2005 20:51


All times are GMT -4. The time now is 23:25.