nk 1.0.0
C++ Numerical Computing Runtime
Loading...
Searching...
No Matches
analyze.hpp
Go to the documentation of this file.
1
3// toolboxes/control/include/nk/control/analyze/analyze.hpp
4//
5// Steady-state and time-domain quality metrics on top of the
6// existing tf/zpk/ss + step/bode primitives.
7
8#pragma once
9
10#include <memory_resource>
11#include <nk/value/value.hpp>
12
13namespace nk::control {
14
17
18
35Value dcgain(const Value &sys, std::pmr::memory_resource *mr = nullptr);
36
48
69 std::pmr::memory_resource *mr = nullptr);
70
93Value stepinfo(const Value &sys, std::pmr::memory_resource *mr = nullptr);
94
109Value allmargin(const Value &sys, std::pmr::memory_resource *mr = nullptr);
110
125Value hinfnorm(const Value &sys, std::pmr::memory_resource *mr = nullptr);
126
127
129} // namespace nk::control
Core MATLAB-compatible multidimensional array and scalar value type.
Definition value.hpp:61
Value hinfnorm(const Value &sys, std::pmr::memory_resource *mr=nullptr)
H-infinity norm of a continuous-time LTI system (g = hinfnorm(sys)).
Value dcgain(const Value &sys, std::pmr::memory_resource *mr=nullptr)
DC (steady-state) gain of an LTI system.
Value stepinfo(const Value &sys, std::pmr::memory_resource *mr=nullptr)
Step-response quality metrics (S = stepinfo(sys)).
Value allmargin(const Value &sys, std::pmr::memory_resource *mr=nullptr)
All stability margins as a struct (S = allmargin(sys)).
MarginResult margin(const Value &sys, std::pmr::memory_resource *mr=nullptr)
Gain and phase margins ([Gm, Pm, Wcg, Wcp] = margin(sys)).
Result of margin(sys) — gain / phase margin pair plus the frequencies at which they occur.
Definition analyze.hpp:42
Value Wcp
Gain-crossover frequency (where |H| = 1), rad/s.
Definition analyze.hpp:46
Value Gm
Gain margin (linear, not dB).
Definition analyze.hpp:43
Value Pm
Phase margin in degrees.
Definition analyze.hpp:44
Value Wcg
Phase-crossover frequency (where phase = −180°), rad/s.
Definition analyze.hpp:45