Scilab Website | Contribute with GitLab | Mailing list archives | ATOMS toolboxes
Scilab Online Help
5.3.2 - English

Change language to:
Français - 日本語 - Português

Please note that the recommended version of Scilab is 2024.0.0. This page might be outdated.
See the recommended documentation of this function

Scilab help >> Xcos > Batch functions > lincos

lincos

Constructs by linearization a linear state-space model from a general dynamical system described by a xcos diagram

Calling Sequence

sys= lincos(scs_m [,x0,u0 [,param] ])

Module

Description

Construct a linear state-space system by linearizing a model given as an xcos diagram. The idea is to transform a sub-diagram to a linear state-space model. The sub-diagram should have inputs and outputs.

The output is a Scilab data structure of type continuous-time state-space linear system.

// loading data
exec("SCI/modules/xcos/tests/unit_tests/PENDULUM_ANIM.sci");
exec("SCI/modules/xcos/tests/unit_tests/anim_pen.sci");
importXcosDiagram("SCI/modules/xcos/tests/unit_tests/pendulum_anim45.xcos");

// specific context data
M  = 10;
m  = 3;
l  = 3;
ph = 0.1;

// looking for the Superblock to linearize
for i=1:length(scs_m.objs)
    if typeof(scs_m.objs(i))=="Block" & scs_m.objs(i).gui=="SUPER_f" then
        scs_m = scs_m.objs(i).model.rpar;
        break;
    end
end

sys = lincos(scs_m);

bode(sys);

Arguments

  • scs_m : a xcos data structure

  • x0 : column vector. Continuous state around which linearization to be done (default 0)

  • u0 : column vector. Input around which linearization to be done (default 0)

  • param : param: list with two elements (default list(1.d-6,0)) param(1): scalar. Perturbation level for linearization; the following variation is used del([x;u])_i = param(1)+param(1)*1d-4*abs([x;u])_i. param(2): scalar. Time t.

  • sys : state-space system

Authors

Ramine Nikoukhah - INRIA

Clément DAVID - DIGITEO

<< Batch functions Batch functions scicos >>

Copyright (c) 2022-2023 (Dassault Systèmes)
Copyright (c) 2017-2022 (ESI Group)
Copyright (c) 2011-2017 (Scilab Enterprises)
Copyright (c) 1989-2012 (INRIA)
Copyright (c) 1989-2007 (ENPC)
with contributors
Last updated:
Thu May 12 11:44:27 CEST 2011