1 / 33

ME280 “Fractional Order Mechanics” Fractional Order Modeling: Part-2

ME280 “Fractional Order Mechanics” Fractional Order Modeling: Part-2. YangQuan Chen, Ph.D., Director, MESA (Mechatronics, Embedded Systems and Automation) Lab MEAM/EECS, School of Engineering, University of California, Merced E : yqchen@ieee.org ; or , yangquan.chen@ucmerced.edu

kesler
Download Presentation

ME280 “Fractional Order Mechanics” Fractional Order Modeling: Part-2

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. ME280 “Fractional Order Mechanics”Fractional Order Modeling: Part-2 YangQuan Chen, Ph.D., Director, MESA (Mechatronics, Embedded Systems and Automation)Lab MEAM/EECS, School of Engineering, University of California, Merced E: yqchen@ieee.org; or, yangquan.chen@ucmerced.edu T: (209)228-4672; O: SE1-254; Lab: Castle #22 (T: 228-4398) 10/24/2013. Thursday 09:00-10:15, KL217

  2. Fractional-Order Modeling • How to approximate 1/sα? • Model fitting in time domain • Modeling fitting in frequency domain • Parametric methods (LS etc.) ME280 "Fractional Order Mechanics" @ UC Merced

  3. Fractional operator • First order differentiator: s • First order integrator: 1/s What is sawhen a is a non-integer? sys1=tf([1],[1,0]);figure;bode(sys1);grid on; sys1=tf([1],[1,0]);figure;bode(1/sys1);grid on; ME280 "Fractional Order Mechanics" @ UC Merced

  4. Fractional Order Integrator (half order) a=-0.5;w=logspace(-2,2,1000);fi=(j.*w).^a; figure;subplot(2,1,1);semilogx(w,20*log10(abs(fi))); xlabel('frequency (rad./sec.)');ylabel('dB');grid on subplot(2,1,2);semilogx(w,180*angle(fi)/pi); xlabel('frequency (rad./sec.)');ylabel('degree');grid on ME280 "Fractional Order Mechanics" @ UC Merced

  5. Possible? Possible! I. Petras, I. Podlubny, P. O’Leary, L. Dorcak, and Vinagre B. “Analogue Realization of Fractional Order Controllers”. FBERG, Technical University of Kosice, Kosice, Slovak, ISBN 8070996277 edition, 2002. ME280 "Fractional Order Mechanics" @ UC Merced

  6. Photo credit: Igor Podlubny ME280 "Fractional Order Mechanics" @ UC Merced

  7. Oustaloup Recursive Approximation for fractional order differentiators/integrator w_L=0.1;w_H=1000; r=-0.5; figure; N=3; sys1=tf(1,[1,0]); sys_N_tf=ora_foc(r,N,w_L,w_H);bode(sys_N_tf,'k:',sys1,'r-');grid on; title(['Oustaloup-Recursive-Approximation for {\it s}^{\^}',num2str(r)]); http://www.mathworks.com/matlabcentral/fileexchange/3802-oustaloup-recursive-approximation-for-fractional-order-differentiators ME280 "Fractional Order Mechanics" @ UC Merced

  8. Basic idea: • zig-zag line of 20 dB • segments • (integer order • differentiator is • 20 dB slope, • 90 deg phase advance) ME280 "Fractional Order Mechanics" @ UC Merced

  9. Impulse response invariant discretization for fractional order differentiators/integrator irid_fod(0.5,.001,7) http://www.mathworks.com/matlabcentral/fileexchange/21342-impulse-response-invariant-discretization-of-fractional-order-integratorsdifferentiators ME280 "Fractional Order Mechanics" @ UC Merced

  10. Basic idea: Simple. Generate impulse response sequence from the analytical impulse response funciton (known!) (or use NILT !!) Then, use PRONY command in MATLAB ME280 "Fractional Order Mechanics" @ UC Merced

  11. Fractional-Order Modeling • How to approximate 1/sα? • Model fitting in time domain • Modeling fitting in frequency domain • Parametric methods (LS etc.) ME280 "Fractional Order Mechanics" @ UC Merced

  12. Boundary condition: initial condition Physical limit ME280 "Fractional Order Mechanics" @ UC Merced

  13. Irrational Transfer Function. Taylor series expansion: polynomial of half order integrators!! ME280 "Fractional Order Mechanics" @ UC Merced

  14. Irrational Transfer Function -- There are many such cases. • See more example from this review paper: • Ruth Curtain, Kirsten Morris. Transfer functions of distributed parameter systems: A tutorial, Automatica, Volume 45, Issue 5, May 2009, Pages 1101-1116 • In this paper, fractional order control was specifically mentioned. ME280 "Fractional Order Mechanics" @ UC Merced

  15. Ideal physical plant model: First Order Plus Time Delay (FOPTD) Model: Time Delay with Single Fractional Pole Model: All models are wrong but some are useful. George E. P. Box ME280 "Fractional Order Mechanics" @ UC Merced

  16. Step response of the “Ideal Plant” So, “Reaction-Curve” or Step response of the “Ideal Plant” ME280 "Fractional Order Mechanics" @ UC Merced

  17. Magic code to do % step response of normalized 1D heat equation when x=1 clear all;close all; alpha=.5; Ts=0.1; F= @(s) exp(-s.^alpha)./s; %----------------------------------------------------------------- alfa=0; M=1024; P=20; Er=1e-10; tm=M*Ts; wmax0=2*pi/Ts/2; L = M; Taxis=[0:L-1]*Ts; n=1:L-1; n=n*Ts ; N=2*M; qd=2*P+1; t=linspace(0,tm,M); NT=2*tm*N/(N-2); omega=2*pi/NT; c=alfa-log(Er)/NT; s=c-i*omega*(0:N+qd-1); Fsc=feval(F,s); ft=fft(Fsc(1:N)); ft=ft(1:M); q=Fsc(N+2:N+qd)./Fsc(N+1:N+qd-1); d=zeros(1,qd); e=d; d(1)=Fsc(N+1); d(2)=-q(1); z=exp(-i*omega*t); for r=2:2:qd-1; w=qd-r; e(1:w)=q(2:w+1)-q(1:w)+e(2:w+1); d(r+1)=e(1); if r>2; q(1:w-1)=q(2:w).*e(2:w)./e(1:w-1); d(r)=-q(1); end end A2=zeros(1,M); B2=ones(1,M); A1=d(1)*B2; B1=B2; for n=2:qd A=A1+d(n)*z.*A2; B=B1+d(n)*z.*B2;A2=A1; B2=B1; A1=A; B1=B; end ht=exp(c*t)/NT.*(2*real(ft+A./B)-Fsc(1)); %------------------------------------------------------------------ figure;tt=0:(length(ht)-1);tt=tt*Ts;plot(tt,ht); xlabel('time (sec.)');ylabel('temperature (C)');grid on Application of numerical inverse Laplace transform algorithms in fractional calculusJournal of the Franklin Institute, Volume 348, Issue 2, March 2011, Pages 315-330Hu Sheng, Yan Li, YangQuan Chen http://dx.doi.org/10.1016/j.jfranklin.2010.11.009 (Check ref [8]) ME280 "Fractional Order Mechanics" @ UC Merced

  18. So, let us do fitting! Ideal physical plant model: First Order Plus Time Delay (FOPTD) Model: Time Delay with Single Fractional Pole Model: All models are wrong but some are useful. George E. P. Box ME280 "Fractional Order Mechanics" @ UC Merced

  19. J=0.020817 J=0.13541 K1 T1 L1 1.0197 1.2312 0.0001 K1 T1 L1 0.9120 2.2393 0 ME280 "Fractional Order Mechanics" @ UC Merced

  20. Fitting code for % Ts: sampling period; ht: step response (from NILT numerical inverse % Laplace transform) % previously we got Ts and ht array (reaction curve) options=optimset('TolX',1e-10,'TolFun',1e-10); Tic;[x,FVAL,EXITFLAG] =fminsearch(@(x) fopdtfit(x,ht,Ts),[1,1,0],options);toc % May need to wait half minute K1=x(1);T1=x(2);L1=x(3);T=(0:length(ht)-1)*Ts;if L1<0; L1=0; end sysfoptd=tf([K1],[T1,1],'iodelay',L1); y=step(sysfoptd,T);plot(T,ht,'r',t,y,'k:');grid on; title(['FOPDT optimal fitting result J=',num2str(FVAL)]); xlabel('time (sec.)');ylabel('step response'); legend('ideal', 'FOPDT') % fitting using FOPTD model - integral of error square (ISE) function [J]=foptdfit(x,y0,Ts); K1=x(1);T1=x(2);L1=x(3);T=(0:length(y0)-1)*Ts;if L1<0; L1=0; end sysfoptd=tf([K1],[T1,1],'iodelay',L1); y=step(sysfoptd,T); J=(y'-y0)*(y-y0')*Ts; ME280 "Fractional Order Mechanics" @ UC Merced

  21. Fitting code for options=optimset('TolX',1e-10,'TolFun',1e-10); Tic;[x,FVAL,EXITFLAG] =fminsearch(@(x) tdwfpfit(x,ht,Ts),[1,2,0],options);toc % May need to wait 1000+ seconds! K1=x(1);T1=x(2);L1=x(3);Np=length(ht);T=(0:Np-1)*Ts;if L1<0; L1=0; end y=mlf(0.5,1.5,-T.^0.5/T1);y=(K1/T1)*(T.^0.5) .* y; Nstep=floor(L1/Ts); y1=zeros(size(y));y1(Nstep+1:Np)=y(1:Np-Nstep); y=y1;plot(T,ht,'r',t,y,'k:');gridon; title(['TDWFP optimal fitting result J=',num2str(FVAL)]); xlabel('time (sec.)');ylabel('step response'); legend('ideal', 'TDWFP model') % fitting using TDWFP model - integral of error square (ISE) function [J]=tdwfpfit(x,y0,Ts); K1=x(1);T1=x(2);L1=x(3);Np=length(y0);T=(0:Np-1)*Ts;if L1<0; L1=0; end y=mlf(0.5,1.5,-T.^0.5/T1);y=(K1/T1)*(T.^0.5) .* y; Nstep=floor(L1/Ts);y1=zeros(size(y));y1(Nstep+1:Np)=y(1:Np-Nstep); J=(y1-y0)*(y1-y0)'*Ts; % get MLF.m from % www.mathworks.com/matlabcentral/fileexchange/8738-mittag-leffler-function ME280 "Fractional Order Mechanics" @ UC Merced

  22. Benefits of FOM • Captures (more) physics • Reaction curve fitting: Better than the best FOPDT model • Could be a nice starting point for better controller design? ME280 "Fractional Order Mechanics" @ UC Merced

  23. Fractional-Order Modeling • How to approximate 1/sα? • Model fitting in time domain • Modeling fitting in frequency domain • Parametric methods (LS etc.) ME280 "Fractional Order Mechanics" @ UC Merced

  24. Using invfreqs or invfreqz • Given a fractional order model (or irrational transfer function), how to find an approximate integer-order model? • Given a complex data array of frequency response testing data, how to find an approximate integer-order model? ME280 "Fractional Order Mechanics" @ UC Merced

  25. Ninteger Toolbox http://web.ist.utl.pt/duarte.valerio/ninteger/ninteger.htm ME280 "Fractional Order Mechanics" @ UC Merced

  26. Ninteger Toolbox http://web.ist.utl.pt/duarte.valerio/ninteger/ninteger.htm ME280 "Fractional Order Mechanics" @ UC Merced

  27. Ninteger Toolbox http://web.ist.utl.pt/duarte.valerio/ninteger/ninteger.htm ME280 "Fractional Order Mechanics" @ UC Merced

  28. Key references in Ninteger FOS ID • HARTLEY, Tom; LORENZO, Carl — Fractional-order system identification based on continuous order-distributions. Signal processing. 83 (2003) 2287-2300. • LEVY, E. — Complex curve fitting. IRE trans. on autom. control. 4 (1959) 37-43. • VALÉRIO, Duarte; SÁ DA COSTA, José — Levy’s identification method extended to fractional order transfer functions. In Fifth EUROMECH Nonlinear Dynamics conference. Eindhoven: EUROMECH, 2005b. • VINAGRE JARA, Blas Manuel — Modelado y control de sistemas dinámicos caracterizados por ecuaciones íntegro-diferenciales de orden fraccional. Madrid: Universidad Nacional de Educación a Distancia, 2001. Doctoratethesis. • VALÉRIO, Duarte Pedro Mata de Oliveira — Fractional robust system control. Lisboa: Instituto Superior Técnico da Universidade Técnica de Lisboa, 2005c. Doctorate thesis. • SANATHANAN, C. K.; KOERNER, J. — Transfer function synthesis as a ratio of two complex polynomials. IEEE transactions on automatic control. 8 (1963) 56.58 • LAWRENCE, P. J.; ROGERS, G. J. — Sequential transfer-function synthesis from measured data. Proceedings of the IEE. 126:1 (1979) 104-106. ME280 "Fractional Order Mechanics" @ UC Merced

  29. Fractional-Order Modeling • How to approximate 1/sα? • Model fitting in time domain • Modeling fitting in frequency domain • Parametric methods (LS etc.) ME280 "Fractional Order Mechanics" @ UC Merced

  30. Parameter and differentiation order estimation in fractional modelsAutomatica, Volume 49, Issue 4, April 2013, Pages 926-935Stéphane Victor, RachidMalti, HuguesGarnier, Alain Oustaloup ME280 "Fractional Order Mechanics" @ UC Merced

  31. System Identification Toolbox • Data Preparation • Plot, analyze, detrend, and filter time- and frequency-domain data, generate and import data • Linear Model Identification • Identify impulse-response, frequency-response and parametric models, such as state-space and transfer function models • Nonlinear Model Identification • Identify nonlinear ARX and Hammerstein-Wiener models • Grey-Box Model Estimation • Estimate coefficients of linear and nonlinear differential, difference and state-space equations • Time-Series Model Identification • Identify linear and nonlinear models of time-series data, including AR, ARMA, and state-space models; forecast values • Model Validation • Compare model to measured output, residual analysis, response plots with confidence bounds • Model Analysis • Model discretization, conversions to other types, linearization of nonlinear models, output simulation and prediction ME280 "Fractional Order Mechanics" @ UC Merced

  32. The Basic Steps of System Identification The System Identification problem is to estimate a model of a system based on observed input-output data. The procedure to determine a model of a dynamical system from observed input-output data involves three basic ingredients: • The input-output data • A set of candidate models (the model structure) • A criterion to select a particular model in the set, based on the information in the data (the identification method) The identification process amounts to repeatedly selecting a model structure, computing the best model in the structure, and evaluating this model's properties to see if they are satisfactory. The cycle can be itemized as follows: ME280 "Fractional Order Mechanics" @ UC Merced

  33. Design an experiment and collect input-output data from the process to be identified. • Examine the data. Polish it so as to remove trends and outliers, and select useful portions of the original data. Possibly apply filtering to enhance important frequency ranges. • Select and define a model structure (a set of candidate system descriptions) within which a model is to be found. • Compute the best model in the model structure according to the input-output data and a given criterion of fit. • Examine the obtained model's properties • If the model is good enough, then stop; otherwise go back to Step 3 to try another model set. Possibly also try other estimation methods (Step 4) or work further on the input-output data (Steps 1 and 2). For Step 2 there are routines to plot data, filter data, and remove trends in data, as well as to resample and reconstruct missing data. For Step 3 the System Identification Toolbox offers a variety of nonparametric models, as well as all the most common black-box input-output and state-space structures, and also general tailor-made linear state-space models in discrete and continuous time. For Step 4 general prediction error (maximum likelihood) methods, as well as instrumental variable methods and sub-space methods are offered for parametric models, while basic correlation and spectral analysis methods are used for nonparametric model structures. To examine models in Step 5, many functions allow the computation and presentation of frequency functions and poles and zeros, as well as simulation and prediction using the model. ME280 "Fractional Order Mechanics" @ UC Merced

More Related