我有一个复平面图,但我想要一个幅度上的误差幅度

我有一个复平面图,但我想要一个幅度上的误差幅度

我有一个特殊的系统,它提供一个信号,该信号必须解码为一个在 0 到 1799 范围内的完整圆的整数。

复平面角映射到模 1800 的整数 我也有误差范围。我该如何修改这张图片,使其显示 1.5 \pm 0.25 星等圆,其中的值是可以接受的,但同时指出该圆之外的区域不可接受。

这是我目前正在使用的 tikz 代码,其中灰色区域的边缘代表理想值。

\begin{figure}[ht]
\begin{tikzpicture}
    \begin{scope}[thick,font=\scriptsize]
    % Axes:
    % Are simply drawn using line with the `->` option to make them arrows:
    % The main labels of the axes can be places using `node`s:
    \draw [->] (-2,0) -- (2,0) node [above left]  {$\Re\{z\}$};
    \draw [->] (0,-2) -- (0,2) node [below right] {$\Im\{z\}$};

    % Axes labels:
    % Are drawn using small lines and labeled with `node`s. The placement can be set using options
    \iffalse% Single
    % If you only want a single label per axis side:
    \draw (1,-3pt) -- (1,3pt)   node [above] {$1$};
    \draw (-1,-3pt) -- (-1,3pt) node [above] {$-1$};
    \draw (-3pt,1) -- (3pt,1)   node [right] {$i$};
    \draw (-3pt,-1) -- (3pt,-1) node [right] {$-i$};
    \else% Multiple
    % If you want labels at every unit step:
    \foreach \n in {-1.5,...,-1.0,1.0,1.0,...,-1.5}{%
        \draw (\n,-3pt) -- (\n,3pt)   node [above] {$\n$};
        \draw (-3pt,\n) -- (3pt,\n)   node [right] {$\n i$};
    }
    \fi
    \end{scope}
    % The circle is drawn with `(x,y) circle (radius)`
    % You can draw the outer border and fill the inner area differently.
    % Here I use gray, semitransparent filling to not cover the axes below the circle
    \path [draw=none,fill=gray,semitransparent] (+0,0) circle (1.5);
    % Place the equation into the circle:
    \node [above right,red] at (+2,0) {$\alpha = 0 \; or \; \alpha = 1800$};
    \node [above right,blue] at (+2,-0.3) {$0 \; or \; 2 \pi \; radians $};

\node [above right,red] at (0,2) {$\alpha = 450$};
\node [below right,blue] at (0,2.9) {$\frac{\pi}{2} \; radians$};


\node [below right,red] at (-4.4,0.4) {$\alpha = 900$};
\node [below right,blue] at (-4.4,0.1) {$ {\pi} \; or -{\pi} \; radians$};


\node [below right,red] at (0,-2) {$\alpha = 1350$};
\node [below right,blue] at (0,-2.3) {$-\frac{\pi}{2} \; radians$};
\end{tikzpicture}
%\label{fig:zplane} always put the label at the end!
\caption{
%
Amplified voltages interpreted as complex numbers; the angle in radians
is converted to a modulo 1800 integer used to represent a rotation. 
%
Note the integer
increments in same direction to the angles in radians if the servo angle
is viewed from the front (i.e. facing the shaft). 
%
The magnitude, typically $1V5 ... 1V58$, is shown as the edge of the grey area.}
\label{fig:zplane}
\end{figure}

答案1

我很乐意删除它,但这里有一种绘制环的方法,即“允许”区域,加上一些额外的小改动(文本模式下的文本等)。

\documentclass{article}
\usepackage{amsmath}
\DeclareMathOperator{\re}{Re}
\DeclareMathOperator{\im}{Im}
\usepackage{tikz}
\begin{document}
\begin{figure}[ht]
\centering
\begin{tikzpicture}
    \begin{scope}[thick,font=\scriptsize]
    % Axes:
    % Are simply drawn using line with the `->` option to make them arrows:
    % The main labels of the axes can be places using `node`s:
    \draw [->] (-2,0) -- (2,0) node [above left]  {$\re z$};
    \draw [->] (0,-2) -- (0,2) node [below right] {$\im z$};

    % Axes labels:
    % Are drawn using small lines and labeled with `node`s. The placement can be set using options
    \iffalse% Single
    % If you only want a single label per axis side:
    \draw (1,-3pt) -- (1,3pt)   node [above] {$1$};
    \draw (-1,-3pt) -- (-1,3pt) node [above] {$-1$};
    \draw (-3pt,1) -- (3pt,1)   node [right] {$\mathrm{i}$};
    \draw (-3pt,-1) -- (3pt,-1) node [right] {$-\mathrm{i}$};
    \else% Multiple
    % If you want labels at every unit step:
    \foreach \n in {-1.5,...,-1.0,1.0,1.0,...,-1.5}{%
        \draw (\n,-3pt) -- (\n,3pt)   node [above] {$\n$};
        \draw (-3pt,\n) -- (3pt,\n)   node [right] {$\n \mathrm{i}$};
    }
    \fi
    \end{scope}
    % The circle is drawn with `(x,y) circle (radius)`
    % You can draw the outer border and fill the inner area differently.
    % Here I use gray, semitransparent filling to not cover the axes below the circle
    \path [draw=none,fill=gray,semitransparent,even odd rule] (+0,0) circle (1.5) circle (1);
    % Place the equation into the circle:
    \node [above right,red] at (+2,0) {$\alpha = 0$ or $\alpha = 1800$};
    \node [above right,blue] at (+2,-0.3) {$0$ or $2 \pi$ radians};

    \node [above right,red] at (0,2) {$\alpha = 450$};
    \node [below right,blue] at (0,2.9) {$\frac{\pi}{2}$ radians};


    \node [below right,red] at (-4.4,0.4) {$\alpha = 900$};
    \node [below right,blue] at (-4.4,0.1) {$ {\pi}$ or ${\pi}$ radians};


    \node [below right,red] at (0,-2) {$\alpha = 1350$};
    \node [below right,blue] at (0,-2.3) {$-\frac{\pi}{2}$ radians};
\end{tikzpicture}
%\label{fig:zplane} always put the label at the end!
\caption{
%
Amplified voltages interpreted as complex numbers; the angle in radians
is converted to a modulo 1800 integer used to represent a rotation. 
%
Note the integer
increments in same direction to the angles in radians if the servo angle
is viewed from the front (i.e.\ facing the shaft). 
%
The magnitude, typically $1V5 \ldots 1V58$, is shown as the edge of the grey area.}
\label{fig:zplane}
\end{figure}
\end{document}

在此处输入图片描述

相关内容