Path: news.mathworks.com!not-for-mail
From: "Nitin Chhabra" <nitin.chhabra@st.com>
Newsgroups: comp.soft-sys.matlab
Subject: Re: Jumping to the next interval
Date: Fri, 16 May 2008 11:15:04 +0000 (UTC)
Organization: STMicroelectronics
Lines: 45
Message-ID: <g0jqbo$7g1$1@fred.mathworks.com>
References: <g0hs2i$ntm$1@fred.mathworks.com> <g0hslb$4o$1@fred.mathworks.com> <g0htbq$bhf$1@fred.mathworks.com> <g0htnm$4s9$1@fred.mathworks.com> <g0jpn2$p6n$1@fred.mathworks.com>
Reply-To: "Nitin Chhabra" <nitin.chhabra@st.com>
NNTP-Posting-Host: webapp-03-blr.mathworks.com
Content-Type: text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding: 8bit
X-Trace: fred.mathworks.com 1210936504 7681 172.30.248.38 (16 May 2008 11:15:04 GMT)
X-Complaints-To: news@mathworks.com
NNTP-Posting-Date: Fri, 16 May 2008 11:15:04 +0000 (UTC)
X-Newsreader: MATLAB Central Newsreader 1388017
Xref: news.mathworks.com comp.soft-sys.matlab:468814


"Archana Ananthanarayan" <archana1985_ms@hotmail.com> 
wrote in message <g0jpn2$p6n$1@fred.mathworks.com>...
> "Archana Ananthanarayan" <archana1985_ms@hotmail.com> 
wrote
> in message <g0htnm$4s9$1@fred.mathworks.com>...
> > "helper " <spamless@nospam.com> wrote in message
> > <g0htbq$bhf$1@fred.mathworks.com>...
> > > > firstNext = ceil((cPt-1)/200)*200 + 1
> > > > 
> > > > Note that I had to use (cPt-1) to handle the case 
where 
> > > > cPt=200.
> > > 
> > > 
> > > Ooops.  Looking at this again, I was wrong.  No need 
to use 
> > > cPt-1
> > > 
> > > firstNext = ceil(cPt/200)*200 + 1
> > > 
> > > is
> sufficie-------------------------------------------------
-----------
> > 
> > thanks for all the replies! Its working!! Thanks a ton!
> > 
> 
> ---------------------------------------------------------
--
> 
> The equation is not working when cPt assumes the values
> 150,250 etc.,
> 
> How to solve this?
> 
Hi,

what exactly is the problem ??
i checked for 150/250 etc and above gives correct 
result....
Please tell the error message and result u get .

with reagrds,
Nitin