20 一条曲线上排列着圆点组与箭头组,目前有错位,每个箭头起点位置如何对准圆?

发布于 2023-07-01 19:58:55

一条曲线上排列着圆点组与箭头组,目前有错位,从左往右偏移量越来越大。每个箭头起点位置如何对准圆?
Q0701.jpg

\documentclass{standalone}
\usepackage{tikz}
\usetikzlibrary {arrows.meta}
\usetikzlibrary{decorations,decorations.pathreplacing}
\usetikzlibrary {decorations.shapes,shapes.geometric}
\usepackage{xfp}
\tikzset{paint/.style={ draw=#1!50!black, fill=#1!80 }, decorate with/.style= {decorate,decoration={shape backgrounds,shape=#1,shape sep=4pt,shape size=1.0mm}}}
\begin{document}    
% 定义decoration
\pgfdeclaredecoration{lipidleaflet}{initial}
{\state{initial}[width=\pgfdecoratedpathlength/floor(\pgfdecoratedpathlength/4pt)]
{
\pgfsetarrowsstart{Stealth[gray,inset=0pt, length=4pt, angle'=20]}
\pgfpathmoveto{\pgfpoint{0pt}{10pt}}
\pgfpathlineto{\pgfpoint{0pt}{0pt}}
\pgfusepath{stroke}  
}
\state{final}
{\pgfpathmoveto{\pgfpointdecoratedpathlast}
}
}
\begin{tikzpicture}
\draw [decorate, decoration={lipidleaflet}]plot [domain=0:4.25, samples=60] (\x,\fpeval{1/(1+0.0075*10^{\x})});
\draw [blue,line width=1pt]
plot [domain=-0.5:4.5, samples=60] (\x,\fpeval{1/(1+0.0075*10^{\x})});
\draw [decorate, decorate with=circle,paint=yellow]
plot [domain=0:4.25, samples=60] (\x,\fpeval{1/(1+0.0075*10^{\x})});    
\end{tikzpicture}
\end{document} 

查看更多

关注者
0
被浏览
701
雾月
雾月 2023-07-02
这家伙很懒,什么也没写!

箭头和圆一起画。

\documentclass[tikz,border=2pt]{standalone}
\usetikzlibrary {arrows.meta}
\usetikzlibrary{decorations.markings}
\usepackage{xfp}
\tikzset{paint/.style={ draw=#1!50!black, fill=#1!80 },
  gray arrow/.style={>={Stealth[gray,inset=0pt, length=4pt, angle'=20]}},
}

\begin{document}
\begin{tikzpicture}
\draw [blue,line width=1pt]
  plot [domain=-0.5:4.5, samples=60] (\x,\fpeval{1/(1+0.0075*10^{\x})});
\path [decorate, decoration={markings,
  mark=between positions 0 and 1 step 1/30 with{
    \draw[->, gray arrow] (0,0)--(0,10pt);
    \draw[paint=yellow, line width=.5pt](0,0) circle (.5mm);
  }
}] {plot [domain=0:4.25, samples=60] (\x,\fpeval{1/(1+0.0075*10^{\x})})};  
\end{tikzpicture}

\end{document} 

image.png

1 个回答

撰写答案

请登录后再发布答案,点击登录

发布
问题

分享
好友

手机
浏览

扫码手机浏览