---
name: "g_sans"
section: "1"
platform: "linux"
package: "gromacs-data"
version: "5.0.2-1"
release: "Debian 8 (Jessie)"
platforms: ["linux"]
url: "https://new.carta.tech/gmx-sans"
---

# g\_sans(1)

Compute small angle neutron scattering spectra

Part of [gmx-sans(1)](/gmx-sans/1.md).

## NAME

gmx-sans - Compute small angle neutron scattering spectra

## SYNOPSIS

gmx sans \[-s \[\<.tpr/.tpb/...\>\]\] \[-f \[\<.xtc/.trr/...\>\]\] \[-n \[\<.ndx\>\]\]\
          \[-d \[\<.dat\>\]\] \[-pr \[\<.xvg\>\]\] \[-sq \[\<.xvg\>\]\]\
          \[-prframe \[\<.xvg\>\]\] \[-sqframe \[\<.xvg\>\]\] \[-nice \<int\>\]\
          \[-b \<time\>\] \[-e \<time\>\] \[-dt \<time\>\] \[-tu \<enum\>\]\
          \[-xvg \<enum\>\] \[-mode \<enum\>\] \[-mcover \<real\>\] \[-\[no\]pbc\]\
          \[-startq \<real\>\] \[-endq \<real\>\] \[-qstep \<real\>\]\
          \[-seed \<int\>\]

## DESCRIPTION

**gmx sans** computes SANS spectra using Debye formula. It currently uses topology file (since it need to assigne element for each atom).

Parameters:

**-pr** Computes normalized g(r) function averaged over trajectory

**-prframe** Computes normalized g(r) function for each frame

**-sq** Computes SANS intensity curve averaged over trajectory

**-sqframe** Computes SANS intensity curve for each frame

**-startq** Starting q value in nm

**-endq** Ending q value in nm

**-qstep** Stepping in q space

Note: When using Debye direct method computational cost increases as 1/2 \* N \* (N - 1) where N is atom number in group of interest.

WARNING: If sq or pr specified this tool can produce large number of files! Up to two times larger than number of frames!

## OPTIONS

Options to specify input and output files:

**-s** *\[\<.tpr/.tpb/...\>\] (topol.tpr) (Input)*\
     Run input file: tpr tpb tpa

**-f** *\[\<.xtc/.trr/...\>\] (traj.xtc) (Input)*\
     Trajectory: xtc trr cpt trj gro g96 pdb tng

**-n** *\[\<.ndx\>\] (index.ndx) (Input, Optional)*\
     Index file

**-d** *\[\<.dat\>\] (nsfactor.dat) (Input, Optional)*\
     Generic data file

**-pr** *\[\<.xvg\>\] (pr.xvg) (Output)*\
     xvgr/xmgr file

**-sq** *\[\<.xvg\>\] (sq.xvg) (Output)*\
     xvgr/xmgr file

**-prframe** *\[\<.xvg\>\] (prframe.xvg) (Output, Optional)*\
     xvgr/xmgr file

**-sqframe** *\[\<.xvg\>\] (sqframe.xvg) (Output, Optional)*\
     xvgr/xmgr file

Other options:

**-nice** *\<int\> (19)*\
     Set the nicelevel

**-b** *\<time\> (0)*\
     First frame (ps) to read from trajectory

**-e** *\<time\> (0)*\
     Last frame (ps) to read from trajectory

**-dt** *\<time\> (0)*\
     Only use frame when t MOD dt = first time (ps)

**-tu** *\<enum\> (ps)*\
     Time unit: fs, ps, ns, us, ms, s

**-xvg** *\<enum\> (xmgrace)*\
     xvg plot formatting: xmgrace, xmgr, none

**-mode** *\<enum\> (direct)*\
     Mode for sans spectra calculation: direct, mc

**-mcover** *\<real\> (-1)*\
     Monte-Carlo coverage should be -1(default) or (0,1\]

**-\[no\]pbc**  *(yes)*\
     Use periodic boundary conditions for computing distances

**-startq** *\<real\> (0)*\
     Starting q (1/nm)

**-endq** *\<real\> (2)*\
     Ending q (1/nm)

**-qstep** *\<real\> (0.01)*\
     Stepping in q (1/nm)

**-seed** *\<int\> (0)*\
     Random seed for Monte-Carlo

## SEE ALSO

**[gromacs(7)](/gromacs/7.md)**

More information about **GROMACS** is available at \<*http://www.gromacs.org/*\>.
