曲线,面积,pgfplot

曲线,面积,pgfplot

x^2+y^2=16

我想使用 tikz 绘制这样的图像。我该怎么做?

答案1

在此处输入图片描述

\documentclass{article}
\usepackage{tikz}

\begin{document}
\begin{tikzpicture}[scale=3]
\draw[step=,gray,thick] (-1,-1) grid (4.5,4.5);
\filldraw[
            fill=red!40,
            draw=red!80!black,ultra thick,
            opacity=.5
            ] 
            (0,0) -- (4cm,0mm)
arc [start angle=0, end angle=90, radius=4cm] -- cycle;
\draw[->] (-1,0) -- (4,0);
\draw[->] (0,-1) -- (0,4);
\node at(0,0) (node name)[below,xshift=-4pt] {0};
\node at(0,2) (node name)[left,fill=white,xshift=-2pt] {2};
\node at(0,4) (node name)[left,fill=white,xshift=-2pt] {4};
\node at(2,0) (node name)[below,fill=white, yshift=-2pt] {2};
\node at(4,0) (node name)[below,fill=white, yshift=-2pt] {4};
\end{tikzpicture}
\end{document}

相关内容