My question is about drawing a "commutative-type diagram" in mathematics. I would like to integrate an arrow of the type \rightsquigarrow
, which is described how to be obtained here : Squiggly arrows in tikz.
The problem is that I uses \path
to connect the entries of my matrix in tikz
(because this part comes integrated in a bigger diagram), and i get an error
"Package PGF Error: I cannot decorate an empty path.".
The code is
\documentclass{article}
\usepackage{tikz}
\usetikzlibrary{decorations.pathmorphing}
\usepackage{amssymb}
\begin{document}
\begin{tikzpicture}
\matrix (m) [matrix of math nodes, row sep=3em, column sep=4em, text height=2ex, text depth=0.25ex]
{ U & U \\};
\path [->, font=\scriptsize, line join=round, decoration={
zigzag,
segment length=4,
amplitude=.9,post=lineto,
post length=2pt}, decorate] (m-1-1) edge node[auto] {F} (m-1-2);
\end{tikzpicture}
\end{document}
where the decorate part does not work.
Best Answer
You could specify the decoration to the path, and give the
edge
thedecorate
option: