UNS files and making movies with uns_2dplot

UNS (Unified N-Body Snapshot) files can be in any of the understood file formats (see unsio manual page).

An animation

the following pipe will follow the evolution of 20,000 particles in an exponential disk for about 1.5 dynamical times, and is grossly unstable due to the lack of an embedded halo:
 
%  mkexpdisk - 20000 | gyrfalcON - - kmax=6 logfile=/dev/null step=0 tstop=1.5 | uns_2dplot - all range=1.5 dev=frame 
this simulation is piped into uns_2plot to create a series of gif files, one for each of the 96 timesteps, which can then be combined into a movie using for example ffmpeg:
%  ffmpeg -f image2 -i frame.%5d.gif -r 25 -threads 2 -vcodec libx264 -vpre default -b 4000k -y plot.avi  
after this you can for example use mplayer in a loop to replay it:
%  mplayer -loop 0 plot.avi 
The last frame (#96) looks as follows:

This page was last modified on by PJT.