bugGNU Octave - Bugs: bug #43947, [octave forge] (control) tf num...

 
 

bug #43947: [octave forge] (control) tf num and den vectors should have same length

Submitted by:  None
Submitted on:  Tue 06 Jan 2015 10:54:11 PM UTC  
 
Category: Octave Forge PackageSeverity: 1 - Wish
Priority: 5 - NormalItem Group: Matlab Compatibility
Status: ConfirmedAssigned to: None
Originator Name: Scott JoblingOriginator Email: -unavailable-
Open/Closed: OpenRelease: other
Operating System: Any

Add a New Comment(Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

Tue 17 May 2016 05:40:14 PM UTC, comment #3:

The output of

s = tf('s')
x = (2s^2 + 1s^1 + 0) / (3s^3 + 2s^2 + 1*s^1 + 0)
x.num
x.den
x.num{1}
x.den{1}

is

s =

s

Continuous-time transfer function.

x =

2 s^2 + s
-----------------
3 s^3 + 2 s^2 + s

Continuous-time transfer function.

ans =

[1x4 double]

ans =

[1x4 double]

ans =

0 2 1 0

ans =

3 2 1 0

Alexander Wilms <alexanderw>
Tue 17 May 2016 05:13:22 PM UTC, comment #2:

Moving information from bug #46621 here. The num and den vectors should have the same length, also the returned vectors when calling the tfdata function.

Mike Miller <mtmiller>
Project Administrator
Thu 15 Jan 2015 02:52:09 AM UTC, comment #1:

Thanks for your bug report. This should be easy for someone with access to Matlab's control toolbox to test and report back the results of the following:

Cc'ing the control package maintainer.

Mike Miller <mtmiller>
Project Administrator
Tue 06 Jan 2015 10:54:11 PM UTC, original submission:

I was running a script originally built for Matlab and ran into several out-of-bounds errors when making assumptions about how many modeling coefficients should be returned by the numerator/denominator calls. I believe this is an issue with the x.Num/Den properties only returning the minimum necessary coefficients from the control model parameters. The person that wrote this for Matlab did so in the last two years, so I'm assuming the issues is on the Octave end. So, via Octave's TF function:

Padding the smaller of the x.Num / x.Den returned arrays with zeros for the missing coefficients fixed the problem for me.

Anonymous

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach File(s):
   
   
Comment:
   

No files currently attached

 

Digest:
   bug dependencies.

Digest:
   bug dependencies.

 

Carbon-Copy List
  • -unavailable- added by jwe (Updated the item)
  • -unavailable- added by alexanderw (Posted a comment)
  • -unavailable- added by mtmiller (Posted a comment)
  • -unavailable- added by mtmiller
  • -unavailable- added by None (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only project members can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 12 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Sun 13 Aug 2017 01:24:05 PM UTCjweSummarycontrol package: tf num and den vectors should have same length=>[octave forge] (control) tf num and den vectors should have same length
    Tue 17 May 2016 05:13:22 PM UTCmtmillerSeverity3 - Normal=>1 - Wish
      StatusNeed Info=>Confirmed
      Release3.8.2=>other
      Summarycontrol package: tf returns different sized x.num and x.den if higher order coefficients missing=>control package: tf num and den vectors should have same length
    Tue 17 May 2016 05:10:02 PM UTCmtmillerDependencies-=>bugs #46621 is dependent
    Tue 17 May 2016 05:09:38 PM UTCmtmillerDependencies-=>Depends on bugs #46621
    Thu 15 Jan 2015 02:52:09 AM UTCmtmillerItem GroupNone=>Matlab Compatibility
      StatusNone=>Need Info
      Operating SystemMicrosoft Windows=>Any
      SummaryTF function in Control returns different sized x.Num and x.Den if higher order coefficients missing=>control package: tf returns different sized x.num and x.den if higher order coefficients missing
      Carbon-Copy-=>Added paramaniac

    Back to the top


    Powered by Savane 3.1-cleanup1