[Nek5000-users] Averaging *.f files

nek5000-users at lists.mcs.anl.gov nek5000-users at lists.mcs.anl.gov
Fri Jul 9 18:12:34 CDT 2010


The best is to use the avg_all routine and dump the results at
every (say) 5000 steps by setting p68=5000.   That way, you get
the integrated quantities over the time interval spanned by
steps 1-5000, 5001-10000, etc., and you can then average as
many of those files together as you wish (e.g., often one wants
to skip the first set of steps because of initial transients).

The current version places etime in the header of the .f file,
which is the elapsed time for the avgblah0.fnnnn file, rather
than the physical simulation time that is stored in the std
blah0.fnnnn files.   The advantage of this is that you then
know how much time is associated w/ each avg file - so that
later you can take a weighted average of the files (in case your
dt or p68 changed between runs).   The correct avg would be

    avg_tot = sum_i  (et_i * avgblah0.f000i) / (sum_j et_j)

Note that this change to the time in the avg header was only
recently made.

Paul



On Fri, 9 Jul 2010, nek5000-users at lists.mcs.anl.gov wrote:

> Hello,
>
> I would like to look at the average values of a bunch of blah.f ( not the
> fld format) files. I noticed that under tools directory, there is a .c code
> to do a similar operation.
> Could anyone brief the procedure for using it ?
>
> Is it better to use this routine or directly compute
> statistical quantities at run time using avg_all routine ?
>
> Regards
> Shriram
>



More information about the Nek5000-users mailing list