GMX-TRAJECTORY(1)

✨ NAME ✨

gmx-trajectory β€” bestie, this one prints out coordinates, velocities, and/or forces for whatever selections you're obsessed with πŸ’…

This is part of the GROMACS manual crew, and it's giving "I just want to see where my atoms are going" energy.


🌸 SYNOPSIS 🌸

gmx trajectory [-f [<.xtc/.trr/...>]] [-s [<.tpr/.gro/...>]]
             [-n [<.ndx>]] [-ox [<.xvg>]] [-ov [<.xvg>]]
             [-of [<.xvg>]] [-b <time>] [-e <time>] [-dt <time>]
             [-tu <enum>] [-fgroup <selection>] [-xvg <enum>]
             [-[no]rmpbc] [-[no]pbc] [-sf <file>] [-selrpos <enum>]
             [-seltype <enum>] [-select <selection>] [-[no]x]
             [-[no]y] [-[no]z] [-[no]len]

πŸ¦‹ DESCRIPTION πŸ¦‹

Okay so gmx trajectory plots coords, velocities, and/or forces for the selections you hand it. By default it's plotting the X, Y, and Z components of all those requested vectors β€” that's the vibe. But the second you specify one or more of -len, -x, -y, and -z, it overrides that default, no cap.

And for dynamic selections? Currently the values get written out for all positions that the selection could select. Like, every possibility. Not just the ones it actually picked. That's just how it is, bestie. 🫢


πŸ’– OPTIONS πŸ’–

πŸŽ€ Options to specify input files

  • -f [<.xtc/.trr/...>] (traj.xtc) (Optional) β€” your input trajectory or single configuration, and the formats it fucks with are: xtc trr cpt gro g96 pdb tng h5md
  • -s [<.tpr/.gro/...>] (topol.tpr) (Optional) β€” input structure: tpr gro g96 pdb brk ent
  • -n [<.ndx>] (index.ndx) (Optional) β€” extra index groups, if you've got them

πŸ“ Options to specify output files

  • -ox [<.xvg>] (coord.xvg) (Optional) β€” coordinates for each position as a function of time πŸ“ˆ
  • -ov [<.xvg>] (veloc.xvg) (Optional) β€” velocities for each position as a function of time πŸƒ
  • -of [<.xvg>] (force.xvg) (Optional) β€” forces for each position as a function of time πŸ’₯

🧚 Other options

  • -b <time> (0) β€” first frame (in ps) to read from the trajectory
  • -e <time> (0) β€” last frame (in ps) to read from the trajectory
  • -dt <time> (0) β€” only use a frame if t MOD dt == first time (ps)
  • -tu <enum> (ps) β€” the unit for time values, pick one: fs, ps, ns, us, ms, s
  • -fgroup <selection> β€” atoms stored in the trajectory file (and if you don't set it, it assumes the first N atoms)
  • -xvg <enum> (xmgrace) β€” plot formatting, options are: xmgrace, xmgr, none
  • -[no]rmpbc (yes) β€” make molecules whole for each frame
  • -[no]pbc (yes) β€” use periodic boundary conditions for distance calculation
  • -sf <file> β€” provide selections from files
  • -selrpos <enum> (atom) β€” selection reference positions, and the full menu is: atom, res_com, res_cog, mol_com, mol_cog, whole_res_com, whole_res_cog, whole_mol_com, whole_mol_cog, part_res_com, part_res_cog, part_mol_com, part_mol_cog, dyn_res_com, dyn_res_cog, dyn_mol_com, dyn_mol_cog
  • -seltype <enum> (atom) β€” default selection output positions, same whole menu: atom, res_com, res_cog, mol_com, mol_cog, whole_res_com, whole_res_cog, whole_mol_com, whole_mol_cog, part_res_com, part_res_cog, part_mol_com, part_mol_cog, dyn_res_com, dyn_res_cog, dyn_mol_com, dyn_mol_cog
  • -select <selection> β€” the selections to analyze πŸ‘‘
  • -[no]x (yes) β€” plot the X component
  • -[no]y (yes) β€” plot the Y component
  • -[no]z (yes) β€” plot the Z component
  • -[no]len (no) β€” plot the vector length

🌈 SEE ALSO 🌈

More GROMACS lore is available at <http://www.gromacs.org/>. Go read it, fr fr.


2026, GROMACS development team


And that's the whole page, bestie β€” GROMACS 2026.4, dated Oct 02, 2026. Slay, go plot something iconic. πŸ’–βœ¨

πŸ“¦ where this page comes from