<div dir="ltr">Hi Roland,<div><br></div><div>thanks for the reply, it was actually a false alarm: I performed some thorough checks and everything behaves as it should. The odd behavour in my code was the result of a &quot;static&quot; keyword that I overlooked.</div><div><br></div><div>Thanks again,</div><div>Federico</div></div><div class="gmail_extra"><br><div class="gmail_quote">2015-10-26 17:18 GMT+01:00 Roland Haas <span dir="ltr">&lt;<a href="mailto:rhaas@aei.mpg.de" target="_blank">rhaas@aei.mpg.de</a>&gt;</span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hello Frederico,<br>
<br>
&gt; CCTK_VarIndex (example_gf[0]) --&gt; 180<br>
&gt; CCTK_VarIndex (example_gf[1]) --&gt; 181<br>
&gt;<br>
&gt; However when the index is fed to CCTK_VarDataPtrI to get a pointer to the<br>
&gt; grid function, it always points to the 0th component. To get the pointer to<br>
&gt; the component I wanted, I had to increment the pointer by the correct<br>
&gt; amount.<br>
&gt;<br>
&gt; This not a major inconvenience, but it is quite counterintuitive. Is there<br>
&gt; a reason for such behaviour?<br>
Sounds like a bug to me, namely I wonder what would happen if you were<br>
to pass &quot;example_gf[1]&quot; to say CarpetIOHDF5::out_vars.<br>
<br>
Can you check what the results of CCTK_VarDataPtrI(cctkGH, 0,<br>
CCTK_VarIndex(&quot;example_gf[1]&quot;)) and CCTK_VarDataPtr(cctkGH, 0,<br>
&quot;example_gf[1]&quot;) is and if they agree? At the very least I would have<br>
expected that they agree.<br>
<br>
Yours,<br>
Roland<br>
<br>
<br>_______________________________________________<br>
Users mailing list<br>
<a href="mailto:Users@einsteintoolkit.org">Users@einsteintoolkit.org</a><br>
<a href="http://lists.einsteintoolkit.org/mailman/listinfo/users" rel="noreferrer" target="_blank">http://lists.einsteintoolkit.org/mailman/listinfo/users</a><br>
<br></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature"><div dir="ltr"><div>Federico Guercilena</div><div>Institut für Theoretische Physik</div><div>Johann Wolfgang Goethe-Universität</div><div>Max-von-Laue-Str. 1</div><div>60438 Frankfurt am Main, Germany</div><div>Telephone: +49 69 798 47887</div><div>Email: guercilena[at]<a href="http://th.physik.uni-frankfurt.de" target="_blank">th.physik.uni-frankfurt.de</a></div></div></div>
</div>