使用 PGFplot 重新创建图形(无数据的绘图)

使用 PGFplot 重新创建图形(无数据的绘图)

有没有办法在没有数据的情况下将源中的绘图重新创建为我自己的 LaTeX 格式?我想重新创建这两个图像(只显示线条,不显示箭头或文本): 在此处输入图片描述

我希望它看起来像这样: 在此处输入图片描述

我的图形代码:

\begin{figure}[b]
\centering
\begin{tikzpicture}
    \begin{axis}[name = ax1, width = 0.7\textwidth, height = 0.4\textwidth,  every axis plot/.append style={ultra thick},
    axis lines = left, no markers, legend cell align={left},  grid,
    xmin = 0, xmax = 30, ymin = 0, ymax = 7, 
    xlabel = Voltage (V), ylabel = Current (A),]
    \addplot [color=red!70!black] table [x=V2, y=A2, mark = none, col sep = semicolon] {tempeffect.csv};\addlegendentry{Warm}   
    \addplot [color=blue!70!black] table [x=V1, y=A1, mark = none, col sep = semicolon] {tempeffect.csv};\addlegendentry{Cold}  
    \end{axis}
\end{tikzpicture}
\caption{Illustration of the effect of temperature on the IV curve of a cSi module}
\label{fig:ivcurvetemp}
\end{figure}

答案1

这是基于 Torbjørn T. 建议的多种应用方案。(@Torbjørn T. 如果您想发表答案,我很乐意删除它。)

\documentclass{article}
\usepackage{pgfplots}
\pgfplotsset{compat=1.16}
\begin{document}
\begin{tikzpicture}
    \begin{axis}[name = ax1, width = 0.7\textwidth, height = 0.4\textwidth,  every axis plot/.append style={ultra thick},
    axis lines = left, no markers, legend cell align={left},  grid,
    xmin = 0, xmax = 60, ymin = 0, ymax = 7, 
    xlabel = Module Output Voltage, ylabel = Current Output]
    \addplot[domain=0:60,samples=60,smooth,blue] {6 - exp((x-45)/3)};
    \addplot[domain=0:60,samples=60,smooth,blue!60] {5.5 - exp((x-45)/3)};
    \addplot[domain=0:60,samples=60,smooth,blue!20] {5 - exp((x-45)/3)};
    \end{axis}
\end{tikzpicture}

\begin{tikzpicture}
    \begin{axis}[name = ax1, width = 0.7\textwidth, height = 0.4\textwidth,  every axis plot/.append style={ultra thick},
    axis lines = left, no markers, legend cell align={left},  grid,
    xmin = 0, xmax = 600, ymin = 0, ymax = 20,restrict y to domain=-2:20, 
    xlabel = Module Output Voltage, ylabel = Current Output]
    \addplot[domain=0:590,samples=60,smooth,gray!50] {18 -
    min(exp((x-420)/30),18)};
    \addplot[domain=0:590,samples=120,smooth,blue!50] {
    6 - min(exp((x-120)/20),6) +
    6 - min(exp((x-300)/20),6) +
    6 - min(exp((x-470)/20),6)
    };
    \node[align=center,blue!50,font=\small] at (axis cs:240,8) {SHADED\\ OUTPUT};
    \node[align=center,gray!50,font=\small] at (axis cs:540,16) {NORMAL\\ OUTPUT};
    \end{axis}
\end{tikzpicture}
\end{document}

在此处输入图片描述

相关内容