Error using DynamicSystem/pidtune

I am using the following matlab function to update the PID parameter ******************************************* function [Kp,Ki,Kd] = PIDEst() X = xlsread("D:\data\X.xls"); Y = xlsread("D:\data\Y.xls"); trData= iddata (Y,X,1); sys = tfest(trData,2) ; C = pidtune(sys,"pid") ; Kp= C.Kp ; Ki=C.Ki; Kd=C.Kd; ************************************* I am getting this error each time I try to run this function "Error using DynamicSystem/pidtune (line 102) The first input argument of the "pidtune" command must be a single-input, single-output linear plant model" Please help

댓글 수: 1

Walter Roberson
Walter Roberson 2018년 4월 22일
Do either of your xls files have multiple columns? That could trigger a problem like that.

댓글을 달려면 로그인하십시오.

답변 (0개)

카테고리

제품

태그

질문:

2018년 4월 22일

댓글:

2018년 4월 22일

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by