[gmx-developers] iparams size question

Mark Abraham mark.j.abraham at gmail.com
Sat Apr 6 20:19:33 CEST 2013


On Sat, Apr 6, 2013 at 7:52 PM, francesco oteri
<francesco.oteri at gmail.com>wrote:

> Dear gromacs developers,
> on the webpage describing the data sructures (
> http://www.gromacs.org/Developer_Zone/Programming_Guide/Data_Structures)
> it is written that "t_iparams *iparams; *//matrix of size atnr² with
> interaction params"*
>
> but looking at the different part of the code (ex pr_iparams in txtdump.c)
> it is clear that in iparams there are all the parameters for the possible
> nteractions, so for sure is more than atnr**2 and it seems to me that the
> size should be ntypes.
>
> Am I wrong?
>

Probably not. The code is definitive. The size of a matrix is whatever it
was given when it was allocated. A comment is a doubtful secondary source
of information. A webpage is even less likely to be definitive :-)

That programming guide was contributed by a user some years ago, and AFAIK
could have any sort of inaccuracies. One of the lessons of history is that
documentation that is not in the code does not get maintained when the code
changes. For 5.0, there are plans to a) document better, and b) make that
available via Doxygen.

Mark


> Francesco
>
> --
> gmx-developers mailing list
> gmx-developers at gromacs.org
> http://lists.gromacs.org/mailman/listinfo/gmx-developers
> Please don't post (un)subscribe requests to the list. Use the
> www interface or send it to gmx-developers-request at gromacs.org.
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://maillist.sys.kth.se/pipermail/gromacs.org_gmx-developers/attachments/20130406/248c4935/attachment.html>


More information about the gromacs.org_gmx-developers mailing list