TransWikia.com

standalone tikzcd: missing { inserted

TeX - LaTeX Asked by Lukas Juhrich on January 27, 2021

My org-mode latex preview seems to have a problem with the following tikzcd diagram. The generated source reads as follows:

documentclass[preview]{standalone}
usepackage[usenames]{color}
% Package babel omitted
usepackage{tikz}
usepackage{amssymb}
usepackage{tikz-cd}
usetikzlibrary{babel}
tikzset{every path/.style={line width=1 cm}}
usepackage[utf8]{inputenc}
usepackage[T1]{fontenc}
% Package fixltx2e omitted
usepackage{graphicx}
usepackage{grffile}
% Package longtable omitted
% Package wrapfig omitted
% Package rotating omitted
usepackage[normalem]{ulem}
usepackage{amsmath}
usepackage{textcomp}
usepackage{amssymb}
% Package capt-of omitted
% Package hyperref omitted
% Package commath omitted

begin{document}
definecolor{fg}{rgb}{0.396078,0.482353,0.513725}
definecolor{bg}{rgb}{0.992157,0.964706,0.890196}

pagecolor{bg}

{color{fg}
begin{tikzcd}
                                                                         &                                                    & Utimes F arrow[ld, "phi^{-1}", bend left] 
(f^ast E_)V arrow[r, "tilde f"] arrow[d, "tilde pivert_cdots"] & E_U arrow[ru, "phi"] arrow[d, "pivert_{E_U}"] &                                              
V arrow[r, "f"]                                                         & U                                                  &
end{tikzcd}

}

end{document}

latexmk -pdf tells me:

! Missing { inserted.
<to be read again> 
                   def 
l.37 end{tikzcd}
                 
?

However, it renders just fine on the online tikzcd editor. What did I do wrong?

One Answer

vert_cdots is wrong, correct is vert_{cdots}:

documentclass{standalone}
usepackage[usenames]{color}
usepackage{tikz-cd}

definecolor{fg}{rgb}{0.396078,0.482353,0.513725}
definecolor{bg}{rgb}{0.992157,0.964706,0.890196}

pagecolor{bg}

begin{document}
{color{fg}
begin{tikzcd}
    &   & Utimes F ar[ld, "phi^{-1}", bend left] 
(f^ast E)V ar[r, "tilde f"] % (f^ast E_) is probably wrong
             ar[d, "tilde pi vert_{cdots}"] % <---
    & E_U ar[ru, "phi"]
          ar[d, "pi vert_{E_U}"] %
        &                                            
V ar[r, "f"]                                                         
    & U &
end{tikzcd}
}
end{document}

enter image description here

Answered by Zarko on January 27, 2021

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP