Gain margin and associated crossover frequency (original) (raw)
Scilab 5.3.3
- Scilab help
- CACSD
- abcd
- abinv
- arhnk
- arl2
- arma
- arma2p
- armac
- armax
- armax1
- arsimul
- augment
- balreal
- bilin
- black
- bode
- bstap
- cainv
- calfrq
- canon
- ccontrg
- chart
- cls2dls
- colinout
- colregul
- cont_frm
- cont_mat
- contr
- contrss
- copfac
- csim
- ctr_gram
- dbphi
- dcf
- ddp
- des2ss
- des2tf
- dhinf
- dhnorm
- dscr
- dsimul
- dt_ility
- dtsi
- equil
- equil1
- evans
- feedback
- findABCD
- findAC
- findBD
- findBDK
- findR
- findx0BD
- flts
- fourplan
- frep2tf
- freq
- freson
- fspecg
- fstabst
- g_margin
- gainplot
- gamitg
- gcare
- gfare
- gfrancis
- gtild
- h2norm
- h_cl
- h_inf
- h_inf_st
- h_norm
- hallchart
- hankelsv
- hinf
- imrep2ss
- inistate
- invsyslin
- kpure
- krac2
- lcf
- leqr
- lft
- lin
- linf
- linfn
- linmeq
- lqe
- lqg
- lqg2stan
- lqg_ltr
- lqr
- ltitr
- m_circle
- macglov
- markp2ss
- minreal
- minss
- mucomp
- narsimul
- nehari
- nicholschart
- noisegen
- nyquist
- nyquistfrequencybounds
- obs_gram
- obscont
- observer
- obsv_mat
- obsvss
- p_margin
- parrot
- pfss
- phasemag
- ppol
- prbs_a
- projsl
- reglin
- repfreq
- ric_desc
- ricc
- riccati
- routh_t
- rowinout
- rowregul
- rtitr
- sensi
- sgrid
- show_margins
- sident
- sm2des
- sm2ss
- sorder
- specfact
- ss2des
- ss2ss
- ss2tf
- st_ility
- stabil
- svplot
- sysfact
- syssize
- tf2des
- tf2ss
- time_id
- trzeros
- ui_observer
- unobs
- zeropen
- zgrid
Please note that the recommended version of Scilab is 2026.0.1. This page might be outdated.
See the recommended documentation of this function
Scilab help >> CACSD > g_margin
g_margin
gain margin and associated crossover frequency
Calling Sequence
gm=g_margin(h) [gm,fr]=g_margin(h)
Arguments
h
a SISO linear system (see :syslin).
gm
a number, the gain margin (in dB) if any ofInf
fr
a number, the associated frequency in hertz, or an empty matrix if the gain margin does not exist.
Description
Given a SISO linear system in continuous or discrete time,g_margin returns gm, the gain margin in dB of h andfr, the achieved corresponding frequency in hz.
The gain margin, if it exists, is the minimal value of the system gain at points where the nyquist plot crosses the negative real axis. In other words the gain margin is20*log10(1/g) where g is the open loop gain of h when the frequency response phase of h equals -180°
The algorithm uses polynomial root finder to solve the equations:
h(s)=h(-s)
for the continuous time case.
h(z)=h(1/z)
for the discrete time case.
Examples
h=syslin('c',-1+%s,3+2*%s+%s^2) [g,fr]=g_margin(h) [g,fr]=g_margin(h-10) nyquist(h-10)
h = syslin(0.1,0.04798*%z+0.0464,%z^2-1.81*%z+0.9048); [g ,fr]=g_margin(h); show_margins(h)
See Also
- p_margin — phase margin and associated crossover frequency
- show_margins — display gain and phase margin and associated crossover frequencies
- repfreq — frequency response
- black — Black-Nichols diagram of a linear dynamical system
- bode — Bode plot
- chart — Nichols chart
- nyquist — nyquist plot
Authors
Serge Steer, INRIA