<html><head></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; color: rgb(0, 0, 0); font-size: 14px; font-family: Arial, sans-serif;"><div>Here you go:</div><div><br></div><div>h … handle to use generated by findpts_setup</div><div>stride … used to increment the pointer to the next grid point (e.g. proc_stride = 1, x_stride = mdim)</div><div>r_base … stores the coordinates in rst-space (needed for interpolation)</div><div><br></div><div>There are no global variables. All MPI_ranks have to call findpts().However in your case only one MPI_rank (it is your choice and can be completely arbitrary) will do the call with npt = 1, all others will use npt = 0. It does not matter if this point is located on that MPI_rank or not!</div><div><br></div><div>Cheers,</div><div>Stefan</div><div><br></div><span id="OLK_SRC_BODY_SECTION"><div style="font-family:Calibri; font-size:11pt; text-align:left; color:black; BORDER-BOTTOM: medium none; BORDER-LEFT: medium none; PADDING-BOTTOM: 0in; PADDING-LEFT: 0in; PADDING-RIGHT: 0in; BORDER-TOP: #b5c4df 1pt solid; BORDER-RIGHT: medium none; PADDING-TOP: 3pt"><span style="font-weight:bold">Von: </span> <<a href="mailto:nek5000-users@lists.mcs.anl.gov">nek5000-users@lists.mcs.anl.gov</a>><br><span style="font-weight:bold">Antworten an: </span> <<a href="mailto:nek5000-users@lists.mcs.anl.gov">nek5000-users@lists.mcs.anl.gov</a>><br><span style="font-weight:bold">Datum: </span> Wednesday, December 2, 2015 at 1:14 AM<br><span style="font-weight:bold">An: </span> <<a href="mailto:nek5000-users@lists.mcs.anl.gov">nek5000-users@lists.mcs.anl.gov</a>><br><span style="font-weight:bold">Betreff: </span> Re: [Nek5000-users] find a point<br></div><div><br></div><div dir="ltr">Thanks for your answers! <div>I think I found the routine that is right for me:<br></div><div><br></div><div><div>call findpts(h, code_base,  code_stride,</div><div>                  proc_base,  proc_stride,</div><div>                    el_base,    el_stride,</div><div>                     r_base,     r_stride,</div><div>                 dist2_base, dist2_stride,</div><div>                     x_base,     x_stride,</div><div>                     y_base,     y_stride,</div><div>                     z_base,     z_stride, npt)</div></div><div><br></div><div>nevertheless I didn't understand the meaning of some variables. I think that I can set the *_stride parameters equal to 1 for my case because i should follow just one point. "code_base" return 0 if is in the element, 1 if it is on the border and 2 if it is out. "proc_base" the processor that have the element ("el_base") in which the point is located. "x_base", "y_base" and "z_base" are the coordinates of the input point. But is not clear for me the means of "r_base", "dist2_base" and "h". Moreover I should give in input the "h" value and I saw that "h" is the output of findpts_setup function or intpts_setup if I use the routine defined in postpro.f that wrap the findpts_setup routine. However in both cases it is not clear for me what "h" represents.<br></div><div><br></div><div>Other question, are *_base values global variables or local? namely, does each processor know that the investigated point is contained in the el_base element?  </div><div><br></div><div>Alessandro</div><div><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">2015-12-01 18:39 GMT+01:00  <span dir="ltr"><<a href="mailto:nek5000-users@lists.mcs.anl.gov" target="_blank">nek5000-users@lists.mcs.anl.gov</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">in postpro.f there is a Fortran routine hpts which acts as a driver to the various hpts... routines. I guess from reading that subroutine you can figure out how to call the various operations. You can also use these routines to find out on what processor and in what element a certain point is located.<br><br>
philipp<span class=""><br><br>
On 2015-12-01 17:35, <a href="mailto:nek5000-users@lists.mcs.anl.gov" target="_blank">nek5000-users@lists.mcs.anl.gov</a> wrote:<br></span><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">
Yes, the routines in findpts.c are your friends. Have a look at hpts()<br>
to see how it works.<br><br>
Cheers,<br>
Stefan<br>
Von: <<a href="mailto:nek5000-users@lists.mcs.anl.gov" target="_blank">nek5000-users@lists.mcs.anl.gov</a><br></span>
<mailto:<a href="mailto:nek5000-users@lists.mcs.anl.gov" target="_blank">nek5000-users@lists.mcs.anl.gov</a>>><br>
Antworten an: <<a href="mailto:nek5000-users@lists.mcs.anl.gov" target="_blank">nek5000-users@lists.mcs.anl.gov</a><br>
<mailto:<a href="mailto:nek5000-users@lists.mcs.anl.gov" target="_blank">nek5000-users@lists.mcs.anl.gov</a>>><span class=""><br>
Datum: Tuesday, December 1, 2015 at 7:02 PM<br>
An: <<a href="mailto:nek5000-users@lists.mcs.anl.gov" target="_blank">nek5000-users@lists.mcs.anl.gov</a><br></span>
<mailto:<a href="mailto:nek5000-users@lists.mcs.anl.gov" target="_blank">nek5000-users@lists.mcs.anl.gov</a>>><span class=""><br>
Betreff: [Nek5000-users] find a point<br><br>
Hi Neks,<br><br>
Given a point P(x,y,z) (even not grid point), is there in Nek a fast way<br>
to found in which element it is located and also the corresponding<br>
processor?<br><br>
sincerely<br>
Alessandro<br>
_______________________________________________ Nek5000-users mailing<br>
list <a href="mailto:Nek5000-users@lists.mcs.anl.gov" target="_blank">Nek5000-users@lists.mcs.anl.gov</a><br></span>
<mailto:<a href="mailto:Nek5000-users@lists.mcs.anl.gov" target="_blank">Nek5000-users@lists.mcs.anl.gov</a>><br><a href="https://lists.mcs.anl.gov/mailman/listinfo/nek5000-users" rel="noreferrer" target="_blank">https://lists.mcs.anl.gov/mailman/listinfo/nek5000-users</a><span class=""><br><br><br>
_______________________________________________<br>
Nek5000-users mailing list<br><a href="mailto:Nek5000-users@lists.mcs.anl.gov" target="_blank">Nek5000-users@lists.mcs.anl.gov</a><br><a href="https://lists.mcs.anl.gov/mailman/listinfo/nek5000-users" rel="noreferrer" target="_blank">https://lists.mcs.anl.gov/mailman/listinfo/nek5000-users</a><br><br></span></blockquote><div class="HOEnZb"><div class="h5">
_______________________________________________<br>
Nek5000-users mailing list<br><a href="mailto:Nek5000-users@lists.mcs.anl.gov" target="_blank">Nek5000-users@lists.mcs.anl.gov</a><br><a href="https://lists.mcs.anl.gov/mailman/listinfo/nek5000-users" rel="noreferrer" target="_blank">https://lists.mcs.anl.gov/mailman/listinfo/nek5000-users</a><br></div></div></blockquote></div><br></div>
_______________________________________________
Nek5000-users mailing list
<a href="mailto:Nek5000-users@lists.mcs.anl.gov">Nek5000-users@lists.mcs.anl.gov</a>
<a href="https://lists.mcs.anl.gov/mailman/listinfo/nek5000-users">https://lists.mcs.anl.gov/mailman/listinfo/nek5000-users</a>
</span></body></html>