<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0">
  <channel>
    <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/169333</link>
    <title>MATLAB Central Newsreader - Jumping to the next interval</title>
    <description>Feed for thread: Jumping to the next interval</description>
    <language>en-us</language>
    <copyright>&amp;copy;1994-2008 by The MathWorks, Inc.</copyright>
    <webmaster>webmaster@mathworks.com</webmaster>
    <generator>MATLAB Central Newsreader</generator>
    <docs>http://blogs.law.harvard.edu/tech/rss</docs>
    <ttl>60</ttl>
    <image>
      <title>The MathWorks</title>
      <url>http://www.mathworks.com/images/membrane_icon.gif</url>
    </image>
    <item>
      <pubDate>Thu, 15 May 2008 17:32:02 -0400</pubDate>
      <title>Jumping to the next interval</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/169333#432300</link>
      <author>Archana Ananthanarayan</author>
      <description>My problem goes like this :&lt;br&gt;
&lt;br&gt;
I've a number line extending say from 0 to 600. I've divided&lt;br&gt;
the line into equal intervals of 200 each. now i'm at 151 of&lt;br&gt;
the 1st section. i need to jump to the next section say&lt;br&gt;
number 201(of course - due to a condition), how do i&lt;br&gt;
calculate the 1st number of the next interval? (that is 201)!&lt;br&gt;
&lt;br&gt;
Thanks in Advance!&lt;br&gt;
</description>
    </item>
    <item>
      <pubDate>Thu, 15 May 2008 17:42:03 -0400</pubDate>
      <title>Re: Jumping to the next interval</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/169333#432307</link>
      <author>helper </author>
      <description>"Archana Ananthanarayan" &amp;lt;archana1985_ms@hotmail.com&amp;gt; wrote &lt;br&gt;
in message &amp;lt;g0hs2i$ntm$1@fred.mathworks.com&amp;gt;...&lt;br&gt;
&amp;gt; My problem goes like this :&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; I've a number line extending say from 0 to 600. I've &lt;br&gt;
divided&lt;br&gt;
&amp;gt; the line into equal intervals of 200 each. now i'm at 151 &lt;br&gt;
of&lt;br&gt;
&amp;gt; the 1st section. i need to jump to the next section say&lt;br&gt;
&amp;gt; number 201(of course - due to a condition), how do i&lt;br&gt;
&amp;gt; calculate the 1st number of the next interval? (that is &lt;br&gt;
201)!&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; Thanks in Advance!&lt;br&gt;
&lt;br&gt;
First, if your line is from 0 to 600, you have 601 points, &lt;br&gt;
not 600.  So let's assume your line is from 1 to 600.&lt;br&gt;
&lt;br&gt;
If you know your current point is cPt = 151, then you can &lt;br&gt;
get the first point of the next section using:&lt;br&gt;
&lt;br&gt;
firstNext = ceil((cPt-1)/200)*200 + 1&lt;br&gt;
&lt;br&gt;
Note that I had to use (cPt-1) to handle the case where &lt;br&gt;
cPt=200.&lt;br&gt;
&lt;br&gt;
&lt;br&gt;
</description>
    </item>
    <item>
      <pubDate>Thu, 15 May 2008 17:45:03 -0400</pubDate>
      <title>Re: Jumping to the next interval</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/169333#432308</link>
      <author>Hosein </author>
      <description>"Archana Ananthanarayan" &amp;lt;archana1985_ms@hotmail.com&amp;gt; wrote&lt;br&gt;
in message &amp;lt;g0hs2i$ntm$1@fred.mathworks.com&amp;gt;...&lt;br&gt;
&amp;gt; My problem goes like this :&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; I've a number line extending say from 0 to 600. I've divided&lt;br&gt;
&amp;gt; the line into equal intervals of 200 each. now i'm at 151 of&lt;br&gt;
&amp;gt; the 1st section. i need to jump to the next section say&lt;br&gt;
&amp;gt; number 201(of course - due to a condition), how do i&lt;br&gt;
&amp;gt; calculate the 1st number of the next interval? (that is 201)!&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; Thanks in Advance!&lt;br&gt;
&lt;br&gt;
A=[.....] (1,600);&lt;br&gt;
numcell(A); % (for example) =600&lt;br&gt;
b=numcell(A)/number of lines&lt;br&gt;
(line number)*b+1&lt;br&gt;
I hope I understood your question rightly&lt;br&gt;
</description>
    </item>
    <item>
      <pubDate>Thu, 15 May 2008 17:54:02 -0400</pubDate>
      <title>Re: Jumping to the next interval</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/169333#432313</link>
      <author>helper </author>
      <description>&amp;gt; firstNext = ceil((cPt-1)/200)*200 + 1&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; Note that I had to use (cPt-1) to handle the case where &lt;br&gt;
&amp;gt; cPt=200.&lt;br&gt;
&lt;br&gt;
&lt;br&gt;
Ooops.  Looking at this again, I was wrong.  No need to use &lt;br&gt;
cPt-1&lt;br&gt;
&lt;br&gt;
firstNext = ceil(cPt/200)*200 + 1&lt;br&gt;
&lt;br&gt;
is sufficient.&lt;br&gt;
</description>
    </item>
    <item>
      <pubDate>Thu, 15 May 2008 18:00:22 -0400</pubDate>
      <title>Re: Jumping to the next interval</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/169333#432321</link>
      <author>Archana Ananthanarayan</author>
      <description>"helper " &amp;lt;spamless@nospam.com&amp;gt; wrote in message&lt;br&gt;
&amp;lt;g0htbq$bhf$1@fred.mathworks.com&amp;gt;...&lt;br&gt;
&amp;gt; &amp;gt; firstNext = ceil((cPt-1)/200)*200 + 1&lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; Note that I had to use (cPt-1) to handle the case where &lt;br&gt;
&amp;gt; &amp;gt; cPt=200.&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; Ooops.  Looking at this again, I was wrong.  No need to use &lt;br&gt;
&amp;gt; cPt-1&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; firstNext = ceil(cPt/200)*200 + 1&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; is sufficient.&lt;br&gt;
&lt;br&gt;
&lt;br&gt;
------------------------------------------------------------&lt;br&gt;
&lt;br&gt;
thanks for all the replies! Its working!! Thanks a ton!&lt;br&gt;
&lt;br&gt;
</description>
    </item>
    <item>
      <pubDate>Fri, 16 May 2008 11:04:02 -0400</pubDate>
      <title>Re: Jumping to the next interval</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/169333#432466</link>
      <author>Archana Ananthanarayan</author>
      <description>"Archana Ananthanarayan" &amp;lt;archana1985_ms@hotmail.com&amp;gt; wrote&lt;br&gt;
in message &amp;lt;g0htnm$4s9$1@fred.mathworks.com&amp;gt;...&lt;br&gt;
&amp;gt; "helper " &amp;lt;spamless@nospam.com&amp;gt; wrote in message&lt;br&gt;
&amp;gt; &amp;lt;g0htbq$bhf$1@fred.mathworks.com&amp;gt;...&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; firstNext = ceil((cPt-1)/200)*200 + 1&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; Note that I had to use (cPt-1) to handle the case where &lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; cPt=200.&lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; Ooops.  Looking at this again, I was wrong.  No need to use &lt;br&gt;
&amp;gt; &amp;gt; cPt-1&lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; firstNext = ceil(cPt/200)*200 + 1&lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; is&lt;br&gt;
sufficie------------------------------------------------------------&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; thanks for all the replies! Its working!! Thanks a ton!&lt;br&gt;
&amp;gt; &lt;br&gt;
&lt;br&gt;
-----------------------------------------------------------&lt;br&gt;
&lt;br&gt;
The equation is not working when cPt assumes the values&lt;br&gt;
150,250 etc.,&lt;br&gt;
&lt;br&gt;
How to solve this?&lt;br&gt;
&lt;br&gt;
</description>
    </item>
    <item>
      <pubDate>Fri, 16 May 2008 11:15:04 -0400</pubDate>
      <title>Re: Jumping to the next interval</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/169333#432468</link>
      <author>Nitin Chhabra</author>
      <description>"Archana Ananthanarayan" &amp;lt;archana1985_ms@hotmail.com&amp;gt; &lt;br&gt;
wrote in message &amp;lt;g0jpn2$p6n$1@fred.mathworks.com&amp;gt;...&lt;br&gt;
&amp;gt; "Archana Ananthanarayan" &amp;lt;archana1985_ms@hotmail.com&amp;gt; &lt;br&gt;
wrote&lt;br&gt;
&amp;gt; in message &amp;lt;g0htnm$4s9$1@fred.mathworks.com&amp;gt;...&lt;br&gt;
&amp;gt; &amp;gt; "helper " &amp;lt;spamless@nospam.com&amp;gt; wrote in message&lt;br&gt;
&amp;gt; &amp;gt; &amp;lt;g0htbq$bhf$1@fred.mathworks.com&amp;gt;...&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt; firstNext = ceil((cPt-1)/200)*200 + 1&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt; Note that I had to use (cPt-1) to handle the case &lt;br&gt;
where &lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt; cPt=200.&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; Ooops.  Looking at this again, I was wrong.  No need &lt;br&gt;
to use &lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; cPt-1&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; firstNext = ceil(cPt/200)*200 + 1&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; is&lt;br&gt;
&amp;gt; sufficie-------------------------------------------------&lt;br&gt;
-----------&lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; thanks for all the replies! Its working!! Thanks a ton!&lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; ---------------------------------------------------------&lt;br&gt;
--&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; The equation is not working when cPt assumes the values&lt;br&gt;
&amp;gt; 150,250 etc.,&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; How to solve this?&lt;br&gt;
&amp;gt; &lt;br&gt;
Hi,&lt;br&gt;
&lt;br&gt;
what exactly is the problem ??&lt;br&gt;
i checked for 150/250 etc and above gives correct &lt;br&gt;
result....&lt;br&gt;
Please tell the error message and result u get .&lt;br&gt;
&lt;br&gt;
with reagrds,&lt;br&gt;
Nitin&lt;br&gt;
&lt;br&gt;
</description>
    </item>
    <item>
      <pubDate>Fri, 16 May 2008 11:29:02 -0400</pubDate>
      <title>Re: Jumping to the next interval</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/169333#432471</link>
      <author>Archana Ananthanarayan</author>
      <description>&lt;br&gt;
&amp;gt; Hi,&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; what exactly is the problem ??&lt;br&gt;
&amp;gt; i checked for 150/250 etc and above gives correct &lt;br&gt;
&amp;gt; result....&lt;br&gt;
&amp;gt; Please tell the error message and result u get .&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; with reagrds,&lt;br&gt;
&amp;gt; Nitin&lt;br&gt;
&amp;gt; &lt;br&gt;
--------------------------------------------------------&lt;br&gt;
&lt;br&gt;
Its working now!! i will get back when i encounter any&lt;br&gt;
error. thanks!&lt;br&gt;
</description>
    </item>
  </channel>
</rss>
