title: NetLogo: Topology: An error occurs when the turtle reaches the end (max-pxcor) of a boxed or cylindrical world with ends
body: <p>I tried the following syntax but got the following error.</p>
  
  <p>Error messages: TURTLES-ON expected input to be an agent or agentset but got NOBODY instead.</p>
  
  <p>In the 2D screen when an error message was issued, an error occurred when the turtle reached the rightmost cell. If the sintax "forward 1", this case works well withour any error. But I need to use the "forward 1 * 0.1" syntax with "tick-advance 0.1".</p>
  
  <p>I already saw the following description, but I do not solve it still now.Does anyone know a good way? Thank you in advance.</p>
  
  <p><a href="https://ccl.northwestern.edu/netlogo/docs/programming.html#topology" rel="nofollow noreferrer">https://ccl.northwestern.edu/netlogo/docs/programming.html#topology</a></p>
  
  <p>The following is an example syntax:</p>
  
  <pre><code>ask turtles with [xcor &lt; max-pxcor][ 
  if not any? turtles-on patch-ahead 1
  [forward 1 * 0.1]] 
  </code></pre>