[gmx-users] single X double precision

Szilárd Páll szilard.pall at cbr.su.se
Tue Apr 17 21:11:46 CEST 2012


Manual Appendix A.2; note that the last one among the reasons listed
for needing double will soon not be the case anymore (see verlet
scheme in 4.6 http://www.gromacs.org/Documentation/Cut-off_schemes).

--
Szilárd



2012/4/17 Pedro Alexandre de Araújo Gomes Lapido Loureiro <palaplou at gmail.com>:
> Thank you, Szilárd.
>
> Do you know where (say, in a piece of code or some documentation) I can be
> sure about that?
> Cheers,
>
> Pedro.
> Em 17 de abril de 2012 15:43, Szilárd Páll <szilard.pall at cbr.su.se>
> escreveu:
>
>> 2012/4/17 Pedro Alexandre de Araújo Gomes Lapido Loureiro
>> <palaplou at gmail.com>:
>> > Hi,
>> >
>> > I've come across a discussion about the "single X double precision"
>> > issue in
>> > a NAMD users list e-mail
>> > (http://www.ks.uiuc.edu/Research/namd/mailing_list/namd-l/9166.html).
>> > I would like to know what do you think about these 3 specific points:
>> >
>> > 1) "there are some places where single precision (FFT, force/energy
>> > computation), where single precision can be applied, but in other
>> > places (summations) where even double precision may result in
>> > artefacts, due to limited numerical accuracy for large enough
>> > systems. there are some applications that show little sensitivity
>> > to single/double precision issues (homogeneous bulk lennard-jones
>> > systems), but others are notoriously difficult (systems with
>> > significant potential drops in one or two dimensions, e.g. metal
>> > surface slabs or lipid bilayers) since you don't have that much
>> > error cancellation anymore."
>> >
>> > 2) "if you store coordinates in single precision, you have to take
>> > extra precautions for handling very large systems, since you
>> > would store coordinates with different relative precision,
>> > depending on how close you are to the origin. e.g., with domain
>> > decomposition, you can define per domain offsets, but that
>> > would work only well in case of a large enough number of domains. "
>> >
>> > 3) "the best way to study the impact of single vs. double would be
>> > by running tests with the gromacs code. gromacs _can_ be compiled
>> > in single or double precision. for a proper comparison, you'll have
>> > to turn off the assembly innerloops though, since they may use single
>> > precision even in double precision mode."
>> >
>> > Specifically this last point startled me. In fact, is this true?
>>
>> AFAIK no, the assembly (SSE intrinsic in 4.6) kernels have both single
>> and double versions. If double precision is requested that's always
>> respected in the code.
>>
>> Additionally, single precision in GROMACS is in fact not *pure* single
>> precision, in some parts of the code where needed double precision is
>> used (e.g. constraints). Therefore, technically what we call single
>> corresponds to what some MD packages call mixed precision.
>>
>> --
>> Szilárd
>>
>>
>> > Cheers,
>> >
>> > Pedro.
>> >
>> >
>> > --
>> > gmx-users mailing list    gmx-users at gromacs.org
>> > http://lists.gromacs.org/mailman/listinfo/gmx-users
>> > Please search the archive at
>> > http://www.gromacs.org/Support/Mailing_Lists/Search before posting!
>> > Please don't post (un)subscribe requests to the list. Use the
>> > www interface or send it to gmx-users-request at gromacs.org.
>> > Can't post? Read http://www.gromacs.org/Support/Mailing_Lists
>> --
>> gmx-users mailing list    gmx-users at gromacs.org
>> http://lists.gromacs.org/mailman/listinfo/gmx-users
>> Please search the archive at
>> http://www.gromacs.org/Support/Mailing_Lists/Search before posting!
>> Please don't post (un)subscribe requests to the list. Use the
>> www interface or send it to gmx-users-request at gromacs.org.
>> Can't post? Read http://www.gromacs.org/Support/Mailing_Lists
>
>
>
> --
> gmx-users mailing list    gmx-users at gromacs.org
> http://lists.gromacs.org/mailman/listinfo/gmx-users
> Please search the archive at
> http://www.gromacs.org/Support/Mailing_Lists/Search before posting!
> Please don't post (un)subscribe requests to the list. Use the
> www interface or send it to gmx-users-request at gromacs.org.
> Can't post? Read http://www.gromacs.org/Support/Mailing_Lists



More information about the gromacs.org_gmx-users mailing list