<DIV>&nbsp;</DIV><DIV>&nbsp;</DIV><SPAN>On 11/04/12, <B class=name>Paolo Franz </B>&lt;paolo.franz@gmail.com&gt; wrote:</SPAN>
<BLOCKQUOTE style="BORDER-LEFT: #00f 1px solid; PADDING-LEFT: 13px; MARGIN-LEFT: 0px" class=iwcQuote cite=mid:CACeB6wy8=rXhyY_v52fLeeJ4jBwFefpY0ShPuSnXEM4gKSB--A@mail.gmail.com type="cite">Thanks for the answer. Am I correct in saying that if I want to activate two options (say&nbsp;ANA_USE_TOPX&nbsp; and&nbsp;ANA_NOUSER_PBC, which might not make any sense!)&nbsp;for a trajectory, I need to call gmx_ana_traj_create with flags=ANA_USE_TOPX&nbsp;|&nbsp;ANA_NOUSER_PBC?&nbsp; 
<DIV><br /></DIV><DIV>Sorry if my questions are silly, I am more familiar with c++ than c and I have used rarely bitwise operations.</DIV></BLOCKQUOTE>
<DIV>&nbsp;</DIV><DIV>Yes, that's the kind of usage expected.&nbsp;For the record, c++ does do this kind of thing too (e.g. stl::bit_vector, which will be replaced with a template specialization eventually) but in a&nbsp;non-HPC C++ context&nbsp;one is less concerned about things like cache footprint.</DIV><DIV>&nbsp;</DIV><BLOCKQUOTE style="BORDER-LEFT: #00f 1px solid; PADDING-LEFT: 13px; MARGIN-LEFT: 0px" class=iwcQuote cite=mid:CACeB6wy8=rXhyY_v52fLeeJ4jBwFefpY0ShPuSnXEM4gKSB--A@mail.gmail.com type="cite">
<DIV>&nbsp;</DIV><DIV>Cheers</DIV><DIV>Paolo<br /><br />
<DIV class=gmail_quote>On 11 April 2012 11:26, Tsjerk Wassenaar <SPAN dir=ltr>&lt;<a href="mailto:tsjerkw@gmail.com" >tsjerkw@gmail.com</A>&gt;</SPAN> wrote:<br />
<BLOCKQUOTE style="BORDER-LEFT: #ccc 1px solid; MARGIN: 0px 0px 0px 0.8ex; PADDING-LEFT: 1ex" class=gmail_quote>Hi Paolo,<br /><br />If you use masking and other bitwise operations, it is handy to know<br />which bit is set; the second for ANA_USE_TOPX and the fifth for<br />ANA_NOUSER_PBC. Of course it's equal to 2 and 16, but that notation<br />makes it a bit less obvious what to do with bitwise operations.</BLOCKQUOTE></DIV></DIV></BLOCKQUOTE>
<DIV>&nbsp;</DIV><DIV>And by the time you get to the 13th option people might not know the value of 2^13&nbsp;- much better to write&nbsp;an equivalent version that suggests how&nbsp;the value is intended to be used.&nbsp;</DIV><DIV>&nbsp;</DIV><DIV>Mark&nbsp;</DIV><DIV>&nbsp;</DIV><BLOCKQUOTE style="BORDER-LEFT: #00f 1px solid; PADDING-LEFT: 13px; MARGIN-LEFT: 0px" class=iwcQuote cite=mid:CACeB6wy8=rXhyY_v52fLeeJ4jBwFefpY0ShPuSnXEM4gKSB--A@mail.gmail.com type="cite">
<DIV class="mimepart text html">
<DIV>
<DIV class=gmail_quote>
<BLOCKQUOTE style="BORDER-LEFT: #ccc 1px solid; MARGIN: 0px 0px 0px 0.8ex; PADDING-LEFT: 1ex" class=gmail_quote><br /><br />Cheers,<br /><br />Tsjerk<br />
<DIV>
<DIV class=h5><br />On Wed, Apr 11, 2012 at 11:18 AM, Paolo Franz &lt;<a href="mailto:paolo.franz@gmail.com" >paolo.franz@gmail.com</A>&gt; wrote:<br />&gt; Hello everybody,<br />&gt; For sometimes, I have been developing analysis tools for gromacs<br />&gt; trajectories using the gromacs library. I am puzzled about some definitions<br />&gt; in the file trajana.h, which I do not seem to understand completely. Why are<br />&gt; definitions such as<br />&gt;<br />&gt; #define&nbsp;ANA_USE_TOPX&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;&nbsp;(1&lt;&lt;1)<br />&gt;<br />&gt; #define&nbsp;ANA_NOUSER_PBC&nbsp;&nbsp; &nbsp; &nbsp;&nbsp;(1&lt;&lt;4)<br />&gt;<br />&gt; used in the code? What is the purpose of this bitwise shift - why not set<br />&gt; ANA_USE_TOPX and&nbsp;ANA_NOUSER_PBC&nbsp;to 2 and 16 for instance??<br />&gt;<br />&gt; Thanks in advance<br />&gt;<br />&gt; Paolo<br />&gt;<br />&gt;<br />&gt;<br /></DIV></DIV>&gt; --<br />&gt; gmx-developers mailing list<br />&gt; <a href="mailto:gmx-developers@gromacs.org" >gmx-developers@gromacs.org</A><br />&gt; <a href="http://lists.gromacs.org/mailman/listinfo/gmx-developers" target=1 >http://lists.gromacs.org/mailman/listinfo/gmx-developers</A><br />&gt; Please don't post (un)subscribe requests to the list. Use the<br />&gt; www interface or send it to <a href="mailto:gmx-developers-request@gromacs.org" >gmx-developers-request@gromacs.org</A>.<br /><SPAN class=HOEnZb><FONT color=#888888><br /><br /><br />--<br />Tsjerk A. Wassenaar, Ph.D.<br /><br />post-doctoral researcher<br />Molecular Dynamics Group<br />* Groningen Institute for Biomolecular Research and Biotechnology<br />* Zernike Institute for Advanced Materials<br />University of Groningen<br />The Netherlands<br />--<br />gmx-developers mailing list<br /><a href="mailto:gmx-developers@gromacs.org" >gmx-developers@gromacs.org</A><br /><a href="http://lists.gromacs.org/mailman/listinfo/gmx-developers" target=1 >http://lists.gromacs.org/mailman/listinfo/gmx-developers</A><br />Please don't post (un)subscribe requests to the list. Use the<br />www interface or send it to <a href="mailto:gmx-developers-request@gromacs.org" >gmx-developers-request@gromacs.org</A>.<br /></FONT></SPAN></BLOCKQUOTE></DIV><br /></DIV></DIV></BLOCKQUOTE>
<DIV>&nbsp;</DIV>