GithubHelp home page GithubHelp logo

engjango / secondorder-octave Goto Github PK

View Code? Open in Web Editor NEW
0.0 1.0 0.0 305 KB

This GNU/Octave sscript randomly chooses two Script_2Ord * .m files and calculates, for each one, the parameters of second order systems.

License: GNU General Public License v3.0

MATLAB 100.00%

secondorder-octave's Introduction

Second Order System Parameters

This script randomly chooses two Script_2Ord * .m files present in the same directory and calculates, for each one, the following second order system parameters:

  • Natural frequency (wn);
  • Damping factor (zeta);
  • Transfer Function [G (s)];
  • Peak instant (Tp);
  • Percentage surpassing (UP);
  • Accommodation time (Ts);
  • Rising time (Tr);

Screenshot main


Parâmetros de Sistemas de Segunda Ordem (Sistemas de Controle)

Este script escolhe aleatoriamente dois arquivos Script_2Ord*.m presentes no mesmo diretório e realiza o cálculo, para cada um, dos seguintes parâmetros dos sistemas de segunda ordem, respectivamente:

  • Frequência natural (wn);
  • Fator de amortecimento (zeta);
  • Função de Transferência [G(s)];
  • Instante de pico (Tp);
  • Ultrapassagem de percentual (UP);
  • Tempo de Acomodação (Ts);
  • Tempo de subida (Tr);

Output

Some results obtained for files "Sist_2Ord3.mat" and "Sist_2Ord5.mat".

>> script_sun
-----------------------------------------------------------
Arquivo 1: Sist_2Ord3.mat

Função de Transferência:
G(s)_1 = 0.53/(s^2 + 0.84s + 1.00).

Parâmetros:
Tp = 3.46 s
Ts = 8.38 s
Tr = 1.98s - 0.48s = 1.50 s
Wn =  1.00 rad/s
Zeta =  0.42
UP% = 23.38%

Parâmetros Re-Calculados:
Tp = 3.46 s
Ts = 9.52 s
Tr = 1.46 s
Wn =  1.00 rad/s
Zeta =  0.42
UP% = 23.38%
-----------------------------------------------------------

-----------------------------------------------------------
Arquivo 2: Sist_2Ord5.mat

Função de Transferência:
G(s)_2 = 1.31/(s^2 + 0.97s + 1.21).

Parâmetros:
Tp = 3.18 s
Ts = 7.59 s
Tr = 1.83s - 0.44s = 1.39 s
Wn =  1.10 rad/s
Zeta =  0.44
UP% = 21.46%

Parâmetros Re-Calculados:
Tp = 3.18 s
Ts = 8.27 s
Tr = 1.33 s
Wn =  1.10 rad/s
Zeta =  0.44
UP% = 21.46%
-----------------------------------------------------------

Install Dependencies

control package

If you haven't yet installed the control package, then type the following command in the GNU/Octave terminal window and press Enter.

>> pkg install -forge control

Compile and Run

Once you have the dependencie (see above), open the file script_sun.m on GNU/Octave and go to Execute > Save and Execute (or just press F5).

Dependencies

  • control package.

secondorder-octave's People

Contributors

engjango avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.