Path: news.mathworks.com!not-for-mail
From: "Hosein " <Kalaeimh@yahoo.com>
Newsgroups: comp.soft-sys.matlab
Subject: Re: Jumping to the next interval
Date: Thu, 15 May 2008 17:45:03 +0000 (UTC)
Organization: The MathWorks, Inc.
Lines: 17
Message-ID: <g0hsqv$ahq$1@fred.mathworks.com>
References: <g0hs2i$ntm$1@fred.mathworks.com>
Reply-To: "Hosein " <Kalaeimh@yahoo.com>
NNTP-Posting-Host: webapp-02-blr.mathworks.com
Content-Type: text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding: 8bit
X-Trace: fred.mathworks.com 1210873503 10810 172.30.248.37 (15 May 2008 17:45:03 GMT)
X-Complaints-To: news@mathworks.com
NNTP-Posting-Date: Thu, 15 May 2008 17:45:03 +0000 (UTC)
X-Newsreader: MATLAB Central Newsreader 498815
Xref: news.mathworks.com comp.soft-sys.matlab:468654


"Archana Ananthanarayan" <archana1985_ms@hotmail.com> wrote
in message <g0hs2i$ntm$1@fred.mathworks.com>...
> My problem goes like this :
> 
> I've a number line extending say from 0 to 600. I've divided
> the line into equal intervals of 200 each. now i'm at 151 of
> the 1st section. i need to jump to the next section say
> number 201(of course - due to a condition), how do i
> calculate the 1st number of the next interval? (that is 201)!
> 
> Thanks in Advance!

A=[.....] (1,600);
numcell(A); % (for example) =600
b=numcell(A)/number of lines
(line number)*b+1
I hope I understood your question rightly