# End-to-end distance of the protein

**URL:** <https://gromacs.bioexcel.eu/t/end-to-end-distance-of-the-protein/8101>\
**Category:** User discussions\
**Created:** [January 22, 2024, 5:20am UTC](https://gromacs.bioexcel.eu/t/end-to-end-distance-of-the-protein/8101 "2024-01-22T05:20:15Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![ManojRana](https://avatars.discourse-cdn.com/v4/letter/m/ebca7d/32.png) [@ManojRana](https://gromacs.bioexcel.eu/u/ManojRana)\
**Post date:** [January 22, 2024, 5:20am UTC](https://gromacs.bioexcel.eu/t/end-to-end-distance-of-the-protein/8101/1 "2024-01-22T05:20:15Z")

</div>

GROMACS version:  
GROMACS modification: Yes/No  
1.I want to calculate end to end distance of a proteins 1 atom and last atom how should i do that?  
2.I’m only getting 8 frame for distance measure.what could be the potential cause?

---

<div class="post-metadata">

**Author:** ![MagnusL](https://dub1.discourse-cdn.com/flex017/user_avatar/gromacs.bioexcel.eu/magnusl/32/2380_2.png) [@MagnusL](https://gromacs.bioexcel.eu/u/MagnusL)\
**Post date:** [January 25, 2024, 8:21am UTC](https://gromacs.bioexcel.eu/t/end-to-end-distance-of-the-protein/8101/2 "2024-01-25T08:21:08Z")

</div>

You can either use `gmx distance` or `gmx pairdist` to calculate the distances. One calculates the pairwise distances within a selection group, the other calculates pairwise distances from one reference selection group to one, or more, other groups. If you make an index.ndx file with the first and the last atom of the protein in one selection group you can use `gmx distance` to calculate the distance.

If you only get 8 frames in the distance measurement output, you probably only have 8 frames in your trajectory.
