答案1
您可以使用 Bodegraph 包,我假设您想绘制此示例 http://fr.mathworks.com/help/control/ref/bode.html
需要设置传递函数的形式
和
\documentclass{article}
\usepackage{tikz}
\usepackage{bodegraph}
\begin{document}
\begin{tikzpicture}[xscale=15/4]
\begin{scope}[yscale=3/60]
\UnitedB
\semilog{-1}{2}{-60}{60}
\BodeGraph[thick,samples=500]{-1:2}
{-\SOAmp{7.5}{0.0182}{2.73}+
\SOAmp{9}{0.02}{3}+
2*\IntAmp{1}
}
\end{scope}
\begin{scope}[yshift=-4cm,yscale=3/90]
\UniteDegre
\OrdBode{15}
\semilog{-1}{2}{-180}{0}
\BodeGraph[thick,samples=500]{-1:2}
{-\SOArg{7.5}{0.0182}{2.73}+
\SOArg{9}{0.02}{3}+
2*\IntArg{1}
}
\end{scope}
\end{tikzpicture}
\end{document}
带有变焦
\documentclass{article}
\usepackage{tikz}
\usepackage{bodegraph}
\begin{document}
\begin{tikzpicture}[xscale=15/1]
\begin{scope}[yscale=3/60]
\UnitedB
\semilog{-0}{1}{-60}{60}
\BodeGraph[thick,samples=500]{0:1}
{-\SOAmp{7.5}{0.0182}{2.73}+
\SOAmp{9}{0.02}{3}+
2*\IntAmp{1}
}
\end{scope}
\begin{scope}[yshift=-4cm,yscale=3/90]
\UniteDegre
\OrdBode{15}
\semilog{-0}{1}{-180}{0}
\BodeGraph[thick,samples=500]{0:1}
{-\SOArg{7.5}{0.0182}{2.73}+
\SOArg{9}{0.02}{3}+
2*\IntArg{1}
}
\end{scope}
\end{tikzpicture}
\end{document}
更多信息 :在 latex 中绘制传递函数