The Math Forum

Search All of the Math Forum:

Views expressed in these public forums are not endorsed by NCTM or The Math Forum.

Math Forum » Discussions » Software » comp.soft-sys.matlab

Notice: We are no longer accepting new posts, but the forums will continue to be readable.

Topic: iddata irregular sampling time
Replies: 3   Last Post: Mar 16, 2015 9:58 PM

Advanced Search

Back to Topic List Back to Topic List Jump to Tree View Jump to Tree View   Messages: [ Previous | Next ]

Posts: 6
Registered: 2/26/09
Re: iddata irregular sampling time
Posted: Sep 13, 2010 1:07 PM
  Click to see the message monospaced in plain text Plain Text   Click to reply to this topic Reply

Hi Greg,

Thanks for posting the solution. I've also read it from the Matlab documentation however, I still face a problem. Matlab keeps complaining that Ts needs to be specified even when I used the example given directly, i.e.

data = iddata(y,u,Ts,[],'SamplingInstants',TimeVector)

I'm sure I have all the variables correct except Ts because I cannot specify any scalar value for it since the interval is irregular. Furthermore, Matlab says Ts will be interpreted automatically as []. Why then does it still complain?

Appreciate any advice.

Best regards,

Greg Heath <> wrote in message <>...
> On Feb 26, 9:24 am, Keith <> wrote:
> > Hi all,
> > I am trying to create a iddata variable in Matlab with inputs/outputs that I already have. The sampling interval, however, is irregular. When I put
> >
> > load('y_u')
> > load('time')
> > z=iddata(y_u,u,[])
> >
> > (the [] is to denote an irregular ts), the following message appears:
> >
> > "If the value of the "Ts" property is empty, a non-empty value for the "SamplingInstants" property must
> > be specified."
> >
> > Therefore, I put the following:
> >
> > load('y_u')
> > load('time')
> > z=iddata(y_u,u,[], 'SamplingInstances',time)

> The documentation states:
> For nonuniformly sampled data, specify Ts as [], and set the value of
> the SamplingInstants property as a column vector containing individual
> time values.
> For example:
> data = iddata(y,u,Ts,[],'SamplingInstants',TimeVector)
> Where TimeVector represents a vector of time values.
> Although the example doesn't seem to follow the directions,
> considering this may help you figure it out.
> Hope this helps.
> Greg

Point your RSS reader here for a feed of the latest messages in this topic.

[Privacy Policy] [Terms of Use]

© The Math Forum at NCTM 1994-2018. All Rights Reserved.