\documentclass[finalversion]{FPSAC2024}
\articlenumber{100}

\newtheorem{thm}{Theorem}
\newtheorem{lem}{Lemma}
\newtheorem{ex}{Example}
\newtheorem{rmk}{Remark}

\usepackage{lipsum}
\usepackage{tikz}
\usepackage{cleveref}
\usepackage{subcaption}

\title[Schur--Demazure vertex models]{Vertex models for the product of a Schur and Demazure polynomial}
\author{Timothy C. Miller\thanks{\href{mailto:tcmiller@uwaterloo.ca}{tcmiller@uwaterloo.ca}}\addressmark{1}}
\address{\addressmark{1}Department of Combinatorics and Optimization, University of Waterloo, Waterloo, ON N2L 3G1, Canada}

\received{November 15, 2023}
\revised{March 31, 2024}

\abstract{
    The product of a Schur polynomial and Demazure atom or character expands positively in Demazure atoms or characters, respectively. The structure coefficients in these expansions have known combinatorial rules in terms of skyline tableaux. We develop alternative rules using the theory of integrable vertex models, inspired by a technique introduced by Zinn-Justin. We apply this method to coloured vertex models for atoms and characters obtained from Borodin and Wheeler's models for non-symmetric Macdonald polynomials. The structure coefficients are then obtained as partition functions of vertex models that are compatible with both Schur (uncoloured) and Demazure (coloured) vertex models.
}

\keywords{Demazure atoms, Demazure characters, Schur polynomials, vertex models, structure coefficients, key polynomials}

\usepackage[backend=bibtex]{biblatex}
\addbibresource{bibfile}

%%%%%%%%%%%%%%%%% Symbols %%%%%%%%%%%%%%%%%
\newcommand{\al}{\alpha}
\newcommand{\be}{\beta}
\newcommand{\de}{\delta}
\newcommand{\ga}{\gamma}
\newcommand{\ka}{\kappa}
\newcommand{\la}{\lambda}
\newcommand{\si}{\sigma}
\newcommand{\N}{\mathbb{N}}
\newcommand{\Z}{\mathbb{Z}}
\newcommand{\R}{\mathbb{R}}
\newcommand{\C}{\mathbb{C}}
\newcommand{\A}{\mathcal{A}}
\newcommand{\K}{\mathcal{K}}
\newcommand{\dg}{{\operatorname{dg}}}
\newcommand{\SSAF}{{\operatorname{SSAF}}}
\newcommand{\sort}{{\operatorname{sort}}}
\newcommand{\id}{{\operatorname{id}}}
\newcommand{\rev}{{\operatorname{rev}}}

%%%%%%%%%%%%%%%%% Constants, definitions, setup %%%%%%%%%%%%%%%%%
\def\thickwidth{1mm}
\def\colourwidth{0.6mm}
\def\circwidth{0.3mm}
\def\circsize{1.1mm}
\definecolor{blue1}{rgb}{0,1.0,1.0}
\definecolor{blue2}{rgb}{0,0.8,0.9}
\definecolor{blue3}{rgb}{0,0.6,0.8}
\definecolor{blue4}{rgb}{0,0.4,0.7}
\definecolor{blue5}{rgb}{0,0.2,0.6}
\definecolor{blue6}{rgb}{0,0.0,0.5}
\definecolor{red}{rgb}{1,0,0}
\definecolor{gray}{rgb}{0.4,0.4,0.4}
\definecolor{light gray}{rgb}{0.9,0.9,0.9}
\tikzset{thick/.style={line width=\thickwidth}}
\tikzset{thick dashed/.style={line width=\thickwidth,dashed}}
\tikzset{blue1 line/.style={line width=\colourwidth,blue1}}
\tikzset{blue2 line/.style={line width=\colourwidth,blue2}}
\tikzset{blue3 line/.style={line width=\colourwidth,blue3}}
\tikzset{blue4 line/.style={line width=\colourwidth,blue4}}
\tikzset{blue5 line/.style={line width=\colourwidth,blue5}}
\tikzset{blue6 line/.style={line width=\colourwidth,blue6}}
\tikzset{red line/.style={line width=\colourwidth,red}}
\tikzset{dotted red line/.style={line width=\colourwidth,red,dotted}}
\tikzset{blue weight/.style={blue1, opacity=0.15}}
\tikzset{red weight/.style={red, opacity=0.15}}
\tikzset{gray fill/.style={fill=light gray, draw=gray}}
\def\ascale{4mm}
\def\bscale{3mm}
\def\cscale{2.5mm}
\def\dscale{2mm}
\def\v{{sqrt(3)}}
\def\vx{sqrt(3)}
\def\smfont{\footnotesize}
\newcommand{\BB}[1]{${\color{blue6}\mathbf{#1}}$}

%%%%%%%%%%%%%%%%% TikZ helper functions %%%%%%%%%%%%%%%%%
% base tiles
\newcommand{\xtile}{
    \draw[gray](0,0)--++(2,0)--++(1,\v)--++(-2,0)--cycle;
}
\newcommand{\ytile}{
    \draw[gray](0,0)--++(1,-\v)--++(2,0)--++(-1,\v)--cycle;
}
\newcommand{\ztile}{
    \draw[gray](0,0)--++(1,\v)--++(1,-\v)--++(-1,-\v)--cycle;
}

% coloured line helpers
\newcommand{\vver}{--++(1,+\v)}
\newcommand{\ver}{--++(1/2,+\v/2)}
\newcommand{\hor}{--++(-1,0)}
\newcommand{\hhor}{--++(-2,0)}
\newcommand{\rhor}{--++(1,0)}
\newcommand{\rhhor}{--++(2,0)}
\newcommand{\dia}{--++(-1/2,+\v/2)}
\newcommand{\ddia}{--++(-1,+\v)}
\newcommand{\lel}{--++(1/2,+\v/2)--++(-1/2,+\v/2)}
\newcommand{\rel}{--++(-1/2,+\v/2)--++(1/2,+\v/2)}
\newcommand{\bel}{--++(1/2,+\v/2)--++(1,0)}
\newcommand{\tel}{--++(1,0)--++(1/2,+\v/2)}
\newcommand{\blueweight}[2]{
    \filldraw[blue weight]({2*(#1-1)+#2-1},{+\v*(#2-1)})--++(2,0)--++(1,\v)--++(-2,0)--cycle;
}

% double lines
\newcommand{\double}[4]{
    \begin{scope}%[line width = 2*\colourwidth]
        \draw[#3 line]({#1},{#2-1/15})--++(#4,0);
        \clip({#1},{#2})--++(#4,0)--++(0,1)--++(-#4,0)--++(0,-1);
        \draw[red line]({#1},{#2+1/15})--++(#4,0);
    \end{scope}
}

% circles
\newcommand{\redcirc}[2]{
    \filldraw[color=red, fill=red, line width=\circwidth]({#1},{#2}) circle (\circsize);
}
\newcommand{\whitecirc}[2]{
    \filldraw[color=black, fill=white, line width=\circwidth]({#1},{#2}) circle (\circsize);
}
\newcommand{\colourcirc}[3]{
    \filldraw[color=white, fill=#3, line width=\circwidth]({#1},{#2}) circle (\circsize);
}
\newcommand{\halfcirc}[3]{
    \begin{scope}[shift={({#1},{#2})}]
        \fill[#3] (0,0) circle (\circsize);
        \fill[red] (0,0) -- (0:\circsize) arc (0:180:\circsize);
        \draw[white] (0,0) circle (\circsize);
    \end{scope}
}
\newcommand{\rcirc}{{\tikz{\filldraw[color=red, fill=red, line width=\circwidth](0,0) circle (\circsize)}}}
\newcommand{\wcirc}{{\tikz{\filldraw[color=black, fill=white, line width=\circwidth](0,0) circle (\circsize)}}}
\newcommand{\bacirc}{{\tikz{\filldraw[color=blue1, fill=blue1, line width=\circwidth](0,0) circle (\circsize)}}}
\newcommand{\bbcirc}{{\tikz{\filldraw[color=blue2, fill=blue2, line width=\circwidth](0,0) circle (\circsize)}}}
\newcommand{\bccirc}{{\tikz{\filldraw[color=blue3, fill=blue3, line width=\circwidth](0,0) circle (\circsize)}}}
\newcommand{\bdcirc}{{\tikz{\filldraw[color=blue4, fill=blue4, line width=\circwidth](0,0) circle (\circsize)}}}
\newcommand{\becirc}{{\tikz{\filldraw[color=blue5, fill=blue5, line width=\circwidth](0,0) circle (\circsize)}}}

% arrows on edges
\newcommand{\perparrow}[7]{
    \def\rd{(#5)/sqrt((#3-(#1))^2+(#4-(#2))^2)}
    \def\xd{(#4-(#2))*\rd}
    \def\yd{(#1-(#3))*\rd}
    \draw[->] ({#1+\xd},{#2+\yd})--node[#6]{#7}({#3+\xd},{#4+\yd});
}

%%%%%%%%%%%%%%%%% TikZ pictures %%%%%%%%%%%%%%%%%
\newcommand{\atomexample}[1]{
    \begin{tikzpicture}[x=#1,y=#1]
        \draw[blue1 line](1,0)\vver\dia;
        \draw[blue2 line](3,0)\vver\vver\vver\vver\ddia\dia;
        \draw[blue3 line](5,0)\vver\vver\dia\hhor\dia\vver\dia;
        \draw[blue4 line](7,0)\dia\hhor\hhor\hhor;
        \blueweight{2}{2}
        \blueweight{3}{2}
        \blueweight{2}{4}
        \blueweight{1}{4}
        
        \draw[gray](0,0)--++(8,0)--++(6,+\v*6)--++(-8,0)--cycle;
        \foreach \i in {1,...,3} \draw[gray](\i*2,0)--++(6,+\v*6);
        \foreach \i in {1,...,5} \draw[gray](\i,+\v*\i)--++(8,0);
        \foreach \i in {1,...,4} \draw({2*\i-1},0)node[below]{\smfont$\i$};
        \draw(1/2,+\v*1/2)node[left]{\smfont$4$};
        \draw(3/2,+\v*3/2)node[left]{\smfont$1$};
        \draw(9/2,+\v*9/2)node[left]{\smfont$3$};
        \draw(11/2,+\v*11/2)node[left]{\smfont$2$};
        \colourcirc{1/2}{+\v*1/2}{blue4}
        \colourcirc{3/2}{+\v*3/2}{blue1}
        \colourcirc{9/2}{+\v*9/2}{blue3}
        \colourcirc{11/2}{+\v*11/2}{blue2}
        \colourcirc{1}{0}{blue1}
        \colourcirc{3}{0}{blue2}
        \colourcirc{5}{0}{blue3}
        \colourcirc{7}{0}{blue4}
        \begin{scope}[shift={(14,0)}]
            \draw[blue1 line](1,0)\vver\dia;
            \draw[blue2 line](3,0)\vver\vver\ddia\vver\vver\dia;
            \draw[blue3 line](5,0)\vver\vver\vver\ddia\dia\hhor;
            \draw[blue4 line](7,0)\dia\hhor\hhor\hhor;
            \blueweight{2}{2}
            \blueweight{3}{2}
            \blueweight{3}{3}
            \blueweight{1}{4}
            
            \draw[gray](0,0)--++(8,0)--++(6,+\v*6)--++(-8,0)--cycle;
            \foreach \i in {1,...,3} \draw[gray](\i*2,0)--++(6,+\v*6);
            \foreach \i in {1,...,5} \draw[gray](\i,+\v*\i)--++(8,0);
            \foreach \i in {1,...,4} \draw({2*\i-1},0)node[below]{\smfont$\i$};
            \draw(1/2,+\v*1/2)node[left]{\smfont$4$};
            \draw(3/2,+\v*3/2)node[left]{\smfont$1$};
            \draw(9/2,+\v*9/2)node[left]{\smfont$3$};
            \draw(11/2,+\v*11/2)node[left]{\smfont$2$};
            \colourcirc{1/2}{+\v*1/2}{blue4}
            \colourcirc{3/2}{+\v*3/2}{blue1}
            \colourcirc{9/2}{+\v*9/2}{blue3}
            \colourcirc{11/2}{+\v*11/2}{blue2}
            \colourcirc{1}{0}{blue1}
            \colourcirc{3}{0}{blue2}
            \colourcirc{5}{0}{blue3}
            \colourcirc{7}{0}{blue4}
        \end{scope}
        \begin{scope}[shift={(28,0)}]
            \draw[blue1 line](1,0)\vver\dia;
            \draw[blue2 line](3,0)\vver\vver\vver\vver\ddia\dia;
            \draw[blue3 line](5,0)\vver\vver\vver\dia\hhor\ddia;
            \draw[blue4 line](7,0)\dia\hhor\hhor\hhor;
            \blueweight{2}{2}
            \blueweight{3}{2}
            \blueweight{3}{3}
            \blueweight{2}{3}
            
            \draw[gray](0,0)--++(8,0)--++(6,+\v*6)--++(-8,0)--cycle;
            \foreach \i in {1,...,3} \draw[gray](\i*2,0)--++(6,+\v*6);
            \foreach \i in {1,...,5} \draw[gray](\i,+\v*\i)--++(8,0);
            \foreach \i in {1,...,4} \draw({2*\i-1},0)node[below]{\smfont$\i$};
            \draw(1/2,+\v*1/2)node[left]{\smfont$4$};
            \draw(3/2,+\v*3/2)node[left]{\smfont$1$};
            \draw(9/2,+\v*9/2)node[left]{\smfont$3$};
            \draw(11/2,+\v*11/2)node[left]{\smfont$2$};
            \colourcirc{1/2}{+\v*1/2}{blue4}
            \colourcirc{3/2}{+\v*3/2}{blue1}
            \colourcirc{9/2}{+\v*9/2}{blue3}
            \colourcirc{11/2}{+\v*11/2}{blue2}
            \colourcirc{1}{0}{blue1}
            \colourcirc{3}{0}{blue2}
            \colourcirc{5}{0}{blue3}
            \colourcirc{7}{0}{blue4}
        \end{scope}
        \draw(4,-3)node{$x_1x_2^2x_3$};
        \draw(18,-3)node{$x_1x_2x_3^2$};
        \draw(32,-3)node{$x_2^2x_3^2$};
        \draw(14,+\v*3)node{$+$};
        \draw(28,+\v*3)node{$+$};
    \end{tikzpicture}
}

\newcommand{\schurexample}[1]{
    \begin{tikzpicture}[x=#1,y=#1]
        \draw[blue1 line](1,0)\vver\dia;
        \draw[blue1 line](3,0)\vver\ddia\vver\dia;
        \draw[blue1 line](5,0)\vver\ddia\vver\ddia\dia;
        \blueweight{1}{1}
        \blueweight{2}{1}
        \blueweight{3}{1}
        \blueweight{1}{3}
        \blueweight{2}{3}
        
        \draw[gray](0,0)--++(6,0)--++(5,+\v*5)--++(-6,0)--cycle;
        \foreach \i in {1,...,2} \draw[gray](\i*2,0)--++(5,+\v*5);
        \foreach \i in {1,...,4} \draw[gray](\i,+\v*\i)--++(6,0);
        \draw(3/2,+\v*3/2)node[left]{\smfont$1$};
        \draw(7/2,+\v*7/2)node[left]{\smfont$1$};
        \draw(9/2,+\v*9/2)node[left]{\smfont$1$};
        \draw(1,0)node[below]{\smfont$1$};
        \draw(3,0)node[below]{\smfont$1$};
        \draw(5,0)node[below]{\smfont$1$};
        \colourcirc{3/2}{+\v*3/2}{blue1}
        \colourcirc{7/2}{+\v*7/2}{blue1}
        \colourcirc{9/2}{+\v*9/2}{blue1}
        \colourcirc{1}{0}{blue1}
        \colourcirc{3}{0}{blue1}
        \colourcirc{5}{0}{blue1}
        \begin{scope}[shift={(12,0)}]
            \draw[blue1 line](1,0)\vver\dia;
            \draw[blue1 line](3,0)\vver\ddia\vver\dia;
            \draw[blue1 line](5,0)\vver\vver\ddia\ddia\dia;
            \blueweight{1}{1}
            \blueweight{2}{1}
            \blueweight{3}{1}
            \blueweight{1}{3}
            \blueweight{3}{2}
            
            \draw[gray](0,0)--++(6,0)--++(5,+\v*5)--++(-6,0)--cycle;
            \foreach \i in {1,...,2} \draw[gray](\i*2,0)--++(5,+\v*5);
            \foreach \i in {1,...,4} \draw[gray](\i,+\v*\i)--++(6,0);
            \draw(3/2,+\v*3/2)node[left]{\smfont$1$};
            \draw(7/2,+\v*7/2)node[left]{\smfont$1$};
            \draw(9/2,+\v*9/2)node[left]{\smfont$1$};
            \draw(1,0)node[below]{\smfont$1$};
            \draw(3,0)node[below]{\smfont$1$};
            \draw(5,0)node[below]{\smfont$1$};
            \colourcirc{3/2}{+\v*3/2}{blue1}
            \colourcirc{7/2}{+\v*7/2}{blue1}
            \colourcirc{9/2}{+\v*9/2}{blue1}
            \colourcirc{1}{0}{blue1}
            \colourcirc{3}{0}{blue1}
            \colourcirc{5}{0}{blue1}
        \end{scope}
        \begin{scope}[shift={(24,0)}]
            \draw[blue1 line](1,0)\vver\dia;
            \draw[blue1 line](3,0)\vver\vver\ddia\dia;
            \draw[blue1 line](5,0)\vver\vver\ddia\ddia\dia;
            \blueweight{1}{1}
            \blueweight{2}{1}
            \blueweight{3}{1}
            \blueweight{2}{2}
            \blueweight{3}{2}
            
            \draw[gray](0,0)--++(6,0)--++(5,+\v*5)--++(-6,0)--cycle;
            \foreach \i in {1,...,2} \draw[gray](\i*2,0)--++(5,+\v*5);
            \foreach \i in {1,...,4} \draw[gray](\i,+\v*\i)--++(6,0);
            \draw(3/2,+\v*3/2)node[left]{\smfont$1$};
            \draw(7/2,+\v*7/2)node[left]{\smfont$1$};
            \draw(9/2,+\v*9/2)node[left]{\smfont$1$};
            \draw(1,0)node[below]{\smfont$1$};
            \draw(3,0)node[below]{\smfont$1$};
            \draw(5,0)node[below]{\smfont$1$};
            \colourcirc{3/2}{+\v*3/2}{blue1}
            \colourcirc{7/2}{+\v*7/2}{blue1}
            \colourcirc{9/2}{+\v*9/2}{blue1}
            \colourcirc{1}{0}{blue1}
            \colourcirc{3}{0}{blue1}
            \colourcirc{5}{0}{blue1}
        \end{scope}
        \draw(3,-3)node{$x_1^2x_2^2x_3$};
        \draw(15,-3)node{$x_1^2x_2x_3^2$};
        \draw(27,-3)node{$x_1x_2^2x_3^2$};
        \draw(11.5,+\v*5/2)node{$+$};
        \draw(23.5,+\v*5/2)node{$+$};
    \end{tikzpicture}
}

\newcommand{\demazuretiles}[1]{
    \begin{tikzpicture}[x=#1,y=#1]
        \draw[draw=gray](0,0)--node[below]{\smfont$0$}++(2,0)--node[right]{\smfont$0$}++(1,\v)--node[above]{\smfont$0$}++(-2,0)--node[left]{\smfont$0$}cycle;
        
        \begin{scope}[shift={(5,0)}]
            \draw[blue1 line](5/2,+\v/2)\dia;
            \draw[draw=gray](0,0)--node[below]{\smfont$0$}++(2,0)--node[right]{\smfont$i$}++(1,\v)--node[above]{\smfont$i$}++(-2,0)--node[left]{\smfont$0$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(10,0)}]
            \draw[blue1 line](1,0)\dia;
            \draw[draw=gray](0,0)--node[below]{\smfont$i$}++(2,0)--node[right]{\smfont$0$}++(1,\v)--node[above]{\smfont$0$}++(-2,0)--node[left]{\smfont$i$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(15,0)}]
            \draw[blue1 line](5/2,+\v/2)\dia;
            \draw[blue1 line](1,0)\dia;
            \draw[draw=gray](0,0)--node[below]{\smfont$i$}++(2,0)--node[right]{\smfont$i$}++(1,\v)--node[above]{\smfont$i$}++(-2,0)--node[left]{\smfont$i$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(20,0)}]
            \draw[blue1 line](5/2,+\v/2)\dia;
            \draw[blue3 line](1,0)\dia;
            \draw[draw=gray](0,0)--node[below]{\smfont$j$}++(2,0)--node[right]{\smfont$i$}++(1,\v)--node[above]{\smfont$i$}++(-2,0)--node[left]{\smfont$j$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(25,0)}]
            \draw[blue1 line](1,0)\vver;
            \draw[blue3 line](5/2,+\v/2)\hhor;
            \draw[draw=gray](0,0)--node[below]{\smfont$i$}++(2,0)--node[right]{\smfont$j$}++(1,\v)--node[above]{\smfont$i$}++(-2,0)--node[left]{\smfont$j$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(30,0)}]
            \filldraw[blue weight](0,0)--++(2,0)--++(1,+\v)--++(-2,0)--cycle;
            \draw[blue1 line](1,0)\vver;
            \draw[draw=gray](0,0)--node[below]{\smfont$i$}++(2,0)--node[right]{\smfont$0$}++(1,\v)--node[above]{\smfont$i$}++(-2,0)--node[left]{\smfont$0$}cycle;
            \draw(1.5,-2)node{weight: $x_c$};
        \end{scope}
    \end{tikzpicture}
}

\newcommand{\composition}[1]{
    \begin{tikzpicture}[x=#1,y=#1]
        \filldraw[draw=gray,fill=light gray](0,0)--++(0,4)--++(2,0)--++(0,2)--++(4,0)--++(0,4)--++(-6,0)--cycle;
        \colourcirc{0}{1}{blue3}
        \colourcirc{0}{3}{blue1}
        \colourcirc{2}{5}{blue4}
        \colourcirc{6}{7}{blue5}
        \colourcirc{6}{9}{blue2}
        \draw(0,1)node[right]{\smfont$3$};
        \draw(0,3)node[right]{\smfont$1$};
        \draw(2,5)node[right]{\smfont$4$};
        \draw(6,7)node[right]{\smfont$5$};
        \draw(6,9)node[right]{\smfont$2$};
        \draw(1,4)node[above]{\smfont$0$};
        \draw(3,6)node[above]{\smfont$0$};
        \draw(5,6)node[above]{\smfont$0$};
        
        \draw(1,9)node{$\al_\A$};
        
        \begin{scope}[shift={(10,0)}]
            \filldraw[draw=gray,fill=light gray](0,0)--++(0,4)--++(2,0)--++(0,2)--++(4,0)--++(0,4)--++(-6,0)--cycle;
            \colourcirc{0}{1}{blue1}
            \colourcirc{0}{3}{blue3}
            \colourcirc{2}{5}{blue4}
            \colourcirc{6}{7}{blue2}
            \colourcirc{6}{9}{blue5}
            \draw(0,1)node[right]{\smfont$1$};
            \draw(0,3)node[right]{\smfont$3$};
            \draw(2,5)node[right]{\smfont$4$};
            \draw(6,7)node[right]{\smfont$2$};
            \draw(6,9)node[right]{\smfont$5$};
            \draw(1,4)node[above]{\smfont$0$};
            \draw(3,6)node[above]{\smfont$0$};
            \draw(5,6)node[above]{\smfont$0$};
            
            \draw(1,9)node{$\al_\K$};
        \end{scope}
        
        \begin{scope}[shift={(20,0)}]
            \filldraw[draw=gray,fill=light gray](0,0)--++(0,4)--++(2,0)--++(0,2)--++(4,0)--++(0,4)--++(-6,0)--cycle;
            \colourcirc{0}{1}{blue1}
            \colourcirc{0}{3}{blue1}
            \colourcirc{2}{5}{blue1}
            \colourcirc{6}{7}{blue1}
            \colourcirc{6}{9}{blue1}
            \draw(0,1)node[right]{\smfont$1$};
            \draw(0,3)node[right]{\smfont$1$};
            \draw(2,5)node[right]{\smfont$1$};
            \draw(6,7)node[right]{\smfont$1$};
            \draw(6,9)node[right]{\smfont$1$};
            \draw(1,4)node[above]{\smfont$0$};
            \draw(3,6)node[above]{\smfont$0$};
            \draw(5,6)node[above]{\smfont$0$};
            
            \draw(1,9)node{$\la^-$};
        \end{scope}
        
        \begin{scope}[shift={(30,0)}]
            \filldraw[draw=gray,fill=light gray](0,0)--++(0,4)--++(2,0)--++(0,2)--++(4,0)--++(0,4)--++(-6,0)--cycle;
            \colourcirc{1}{4}{red}
            \colourcirc{3}{6}{red}
            \colourcirc{5}{6}{red}
            \draw(0,1)node[right]{\smfont$0$};
            \draw(0,3)node[right]{\smfont$0$};
            \draw(2,5)node[right]{\smfont$0$};
            \draw(6,7)node[right]{\smfont$0$};
            \draw(6,9)node[right]{\smfont$0$};
            \draw(1,4)node[above]{\smfont$+$};
            \draw(3,6)node[above]{\smfont$+$};
            \draw(5,6)node[above]{\smfont$+$};
            
            \draw(1,9)node{$\la^+$};
        \end{scope}
    \end{tikzpicture}
}

\newcommand{\atommodel}[1]{
    \begin{tikzpicture}[x=#1,y=#1]
        \filldraw[gray fill](0,0)--++(6,0)--++(4,+\v*4)--++(-6,0)--cycle;
        \perparrow{0}{0}{4}{\vx*4}{-1}{left}{$\al_\A$}
        \perparrow{0}{0}{6}{0}{1}{below}{\smfont$1$ $2$ $3$ $\cdots$ $n$}
        \draw(-1,+\v*2)node[left]{$\A_\al(x)=$};
    \end{tikzpicture}
}

\newcommand{\schurmodel}[1]{
    \begin{tikzpicture}[x=#1,y=#1]
        \filldraw[gray fill](0,0)--++(6,0)--++(4,+\v*4)--++(-6,0)--cycle;
        \perparrow{0}{0}{4}{\vx*4}{-1}{left}{$\la^-$}
        \perparrow{0}{0}{6}{0}{1}{below}{$\bacirc^n$}
        \draw(-1,+\v*2)node[left]{$s_\la(x)=$};
    \end{tikzpicture}
}

\newcommand{\charmodel}[1]{
    \begin{tikzpicture}[x=#1,y=#1]
        \filldraw[gray fill](0,0)--++(6,0)--++(4,+\v*4)--++(-6,0)--cycle;
        \perparrow{0}{0}{4}{\vx*4}{-1}{left}{$\al_\K$}
        \perparrow{0}{0}{6}{0}{1}{below}{\smfont$1$ $2$ $3$ $\cdots$ $n$}
        \draw(-1,+\v*2)node[left]{$\K_\al(x)=$};
    \end{tikzpicture}
}

\def\diamondspace{4.5}
\newcommand{\diamonds}[1]{
    \begin{tikzpicture}[x=#1,y=#1]
        \draw[blue1 line](3/2,-\v/2)\ddia;
        \draw[draw=gray](0,0)--node[left]{\smfont$0$}++(1,-\v)--node[right]{\smfont$i$}++(1,\v)--node[right]{\smfont$0$}++(-1,\v)--node[left]{\smfont$i$}cycle;
        
        \begin{scope}[shift={(\diamondspace,0)}]
            \draw[blue1 line](3/2,-\v/2)\ddia;
            \draw[red line](3/2,-\v/2)\hor;
            \draw[draw=gray](0,0)--node[left]{\smfont$+$}++(1,-\v)--node[right]{\smfont$i^+$}++(1,\v)--node[right]{\smfont$0$}++(-1,\v)--node[left]{\smfont$i$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(2*\diamondspace,0)}]
            \draw[blue1 line](3/2,-\v/2)\ddia;
            \draw[red line](3/2,+\v/2)\hor;
            \draw[draw=gray](0,0)--node[left]{\smfont$0$}++(1,-\v)--node[right]{\smfont$i$}++(1,\v)--node[right]{\smfont$+$}++(-1,\v)--node[left]{\smfont$i^+$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(3*\diamondspace,0)}]
            \draw[blue1 line](3/2,-\v/2)\ddia;
            \draw[red line](3/2,-\v/2)\hor;
            \draw[red line](3/2,+\v/2)\hor;
            \draw[draw=gray](0,0)--node[left]{\smfont$+$}++(1,-\v)--node[right]{\smfont$i^+$}++(1,\v)--node[right]{\smfont$+$}++(-1,\v)--node[left]{\smfont$i^+$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(4*\diamondspace,0)}]
            \draw[blue1 line](1/2,-\v/2)\vver;
            \draw[blue3 line](3/2,+\v/2)\hor;
            \draw[blue3 line](3/2,-\v/2)\hor;
            \draw[draw=gray](0,0)--node[left]{\smfont$ij$}++(1,-\v)--node[right]{\smfont$j$}++(1,\v)--node[right]{\smfont$ij$}++(-1,\v)--node[left]{\smfont$j$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(5*\diamondspace,0)}]
            \draw[blue1 line](1/2,-\v/2)\vver;
            \draw[blue3 line](3/2,+\v/2)\hor;
            \draw[blue5 line](3/2,-\v/2)\hor;
            \draw[draw=gray](0,0)--node[left]{\smfont$ik$}++(1,-\v)--node[right]{\smfont$k$}++(1,\v)--node[right]{\smfont$ij$}++(-1,\v)--node[left]{\smfont$j$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(6*\diamondspace,0)}]
            \draw[blue1 line](1/2,-\v/2)\vver;
            \draw[blue5 line](3/2,+\v/2)\hor;
            \draw[blue3 line](3/2,-\v/2)\hor;
            \draw[draw=gray](0,0)--node[left]{\smfont$ij$}++(1,-\v)--node[right]{\smfont$j$}++(1,\v)--node[right]{\smfont$ik$}++(-1,\v)--node[left]{\smfont$k$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(7*\diamondspace,0)}]
            \draw[blue1 line](3/2,-\v/2)\rel;
            \draw[blue3 line](3/2,+\v/2)\hor;
            \draw[draw=gray](0,0)--node[left]{\smfont$0$}++(1,-\v)--node[right]{\smfont$i$}++(1,\v)--node[right]{\smfont$ij$}++(-1,\v)--node[left]{\smfont$j$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(8*\diamondspace,0)}]
            \draw[blue1 line](1/2,-\v/2)\lel;
            \draw[blue3 line](3/2,-\v/2)\hor;
            \draw[draw=gray](0,0)--node[left]{\smfont$ij$}++(1,-\v)--node[right]{\smfont$j$}++(1,\v)--node[right]{\smfont$0$}++(-1,\v)--node[left]{\smfont$i$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(0,-4)}]
            \draw[draw=gray](0,0)--node[left]{\smfont$0$}++(1,-\v)--node[right]{\smfont$0$}++(1,\v)--node[right]{\smfont$0$}++(-1,\v)--node[left]{\smfont$0$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(\diamondspace,-4)}]
            \draw[red line](1/2,-\v/2)\vver;
            \draw[draw=gray](0,0)--node[left]{\smfont$+$}++(1,-\v)--node[right]{\smfont$0$}++(1,\v)--node[right]{\smfont$+$}++(-1,\v)--node[left]{\smfont$0$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(2*\diamondspace,-4)}]
            \draw[blue1 line](3/2,-\v/2)\hor;
            \draw[red line](1/2,-\v/2)\vver;
            \draw[draw=gray](0,0)--node[left]{\smfont$i^+$}++(1,-\v)--node[right]{\smfont$i$}++(1,\v)--node[right]{\smfont$+$}++(-1,\v)--node[left]{\smfont$0$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(3*\diamondspace,-4)}]
            \draw[blue1 line](3/2,+\v/2)\hor;
            \draw[red line](1/2,-\v/2)\vver;
            \draw[draw=gray](0,0)--node[left]{\smfont$+$}++(1,-\v)--node[right]{\smfont$0$}++(1,\v)--node[right]{\smfont$i^+$}++(-1,\v)--node[left]{\smfont$i$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(4*\diamondspace,-4)}]
            \draw[blue1 line](3/2,+\v/2)\hor;
            \draw[blue1 line](3/2,-\v/2)\hor;
            \draw[red line](1/2,-\v/2)\vver;
            \draw[draw=gray](0,0)--node[left]{\smfont$i^+$}++(1,-\v)--node[right]{\smfont$i$}++(1,\v)--node[right]{\smfont$i^+$}++(-1,\v)--node[left]{\smfont$i$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(5*\diamondspace,-4)}]
            \draw[blue1 line](3/2,+\v/2)\hor;
            \draw[blue3 line](3/2,-\v/2)\hor;
            \draw[red line](1/2,-\v/2)\vver;
            \draw[draw=gray](0,0)--node[left]{\smfont$j^+$}++(1,-\v)--node[right]{\smfont$j$}++(1,\v)--node[right]{\smfont$i^+$}++(-1,\v)--node[left]{\smfont$i$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(6*\diamondspace,-4)}]
            \draw[blue3 line](3/2,+\v/2)\hor;
            \draw[blue1 line](3/2,-\v/2)\hor;
            \draw[red line](1/2,-\v/2)\vver;
            \draw[draw=gray](0,0)--node[left]{\smfont$i^+$}++(1,-\v)--node[right]{\smfont$i$}++(1,\v)--node[right]{\smfont$j^+$}++(-1,\v)--node[left]{\smfont$j$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(7*\diamondspace,-4)}]
            \draw[blue1 line](3/2,-\v/2)\rel;
            \draw[blue3 line](3/2,+\v/2)\hor;
            \draw[red line](3/2,-\v/2)\hor;
            \draw[draw=gray](0,0)--node[left]{\smfont$+$}++(1,-\v)--node[right]{\smfont$i^+$}++(1,\v)--node[right]{\smfont$ij$}++(-1,\v)--node[left]{\smfont$j$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(8*\diamondspace,-4)}]
            \draw[blue1 line](1/2,-\v/2)\lel;
            \draw[blue3 line](3/2,-\v/2)\hor;
            \draw[red line](3/2,+\v/2)\hor;
            \draw[draw=gray](0,0)--node[left]{\smfont$ij$}++(1,-\v)--node[right]{\smfont$j$}++(1,\v)--node[right]{\smfont$+$}++(-1,\v)--node[left]{\smfont$i^+$}cycle;
        \end{scope}
    \end{tikzpicture}
}

\newcommand{\banneda}[1]{
    \begin{tikzpicture}[x=#1,y=#1]
        \filldraw[light gray](1,\v)--++(2,0)--++(-1,\v)--cycle;
        \filldraw[light gray](0,0)--++(2,0)--++(-1,-\v)--cycle;
        \draw[blue1 line](1,0)\dia;
        \draw[blue3 line](2.5,+\v/2)\dia;
        \draw[gray](0,0)--++(2,+\v*2)--++(1,-\v)--++(-2,-\v*2)--cycle;
        \draw[gray](2,0)--++(-1,\v);
        \draw[gray, dotted](0,0)--++(2,0);
        \draw[gray, dotted](1,\v)--++(2,0);
        \draw(1/2,+\v/2)node[left]{\smfont$i$};
        \draw(5/2,+\v/2)node[right]{\smfont$j$};
        
        \begin{scope}[shift={(6,0)}]
            \filldraw[light gray](1,\v)--++(2,0)--++(-1,\v)--cycle;
            \filldraw[light gray](0,0)--++(2,0)--++(-1,-\v)--cycle;
            \draw[blue1 line](1,0)\dia;
            \draw[blue3 line](2.5,+\v/2)\dia;
            \draw[red line](5/2,+\v/2)\hhor;
            \draw[gray](0,0)--++(2,+\v*2)--++(1,-\v)--++(-2,-\v*2)--cycle;
            \draw[gray](2,0)--++(-1,\v);
            \draw[gray, dotted](0,0)--++(2,0);
            \draw[gray, dotted](1,\v)--++(2,0);
            \draw(1/2,+\v/2)node[left]{\smfont$i^+$};
            \draw(5/2,+\v/2)node[right]{\smfont$j^+$};
        \end{scope}
    \end{tikzpicture}
}

\newcommand{\bannedb}[1]{
    \begin{tikzpicture}[x=#1,y=#1]
        \filldraw[light gray](1,\v)--++(2,0)--++(-1,\v)--cycle;
        \filldraw[light gray](0,0)--++(2,0)--++(-1,-\v)--cycle;
        \draw[blue3 line](1,0)\dia;
        \draw[blue1 line](2.5,+\v/2)\dia;
        \draw[gray](0,0)--++(2,+\v*2)--++(1,-\v)--++(-2,-\v*2)--cycle;
        \draw[gray](2,0)--++(-1,\v);
        \draw[gray, dotted](0,0)--++(2,0);
        \draw[gray, dotted](1,\v)--++(2,0);
        \draw(1/2,+\v/2)node[left]{\smfont$j$};
        \draw(5/2,+\v/2)node[right]{\smfont$i$};
        
        \begin{scope}[shift={(6,0)}]
            \filldraw[light gray](1,\v)--++(2,0)--++(-1,\v)--cycle;
            \filldraw[light gray](0,0)--++(2,0)--++(-1,-\v)--cycle;
            \draw[blue3 line](1,0)\dia;
            \draw[blue1 line](2.5,+\v/2)\dia;
            \draw[red line](5/2,+\v/2)\hhor;
            \draw[gray](0,0)--++(2,+\v*2)--++(1,-\v)--++(-2,-\v*2)--cycle;
            \draw[gray](2,0)--++(-1,\v);
            \draw[gray, dotted](0,0)--++(2,0);
            \draw[gray, dotted](1,\v)--++(2,0);
            \draw(1/2,+\v/2)node[left]{\smfont$j^+$};
            \draw(5/2,+\v/2)node[right]{\smfont$i^+$};
        \end{scope}
    \end{tikzpicture}
}

\newcommand{\producttheorem}[1]{
    \begin{tikzpicture}[x=#1,y=#1]
        \filldraw[gray fill](0,0)--++(4,-\v*4)--++(4,+\v*4)--++(-4,+\v*4)--cycle;
        \draw(4,0)node{$c_{\la,\al}^\be$};
        \perparrow{0}{0}{4}{\vx*4}{-1}{left}{$\al_\A$}
        \perparrow{4}{-\vx*4}{8}{0}{1}{right}{$\be_\A$}
        \perparrow{4}{-\vx*4}{0}{0}{-1}{left}{$\la^+$}
        \perparrow{8}{0}{4}{\vx*4}{1}{right}{$\rcirc^k\wcirc^n$}
        
        \begin{scope}[shift={(16,0)}]
            \filldraw[gray fill](0,0)--++(4,-\v*4)--++(4,+\v*4)--++(-4,+\v*4)--cycle;
            \draw(4,0)node{$d_{\la,\al}^\be$};
            \perparrow{0}{0}{4}{\vx*4}{-1}{left}{$\al_\K$}
            \perparrow{4}{-\vx*4}{8}{0}{1}{right}{$\be_\K$}
            \perparrow{4}{-\vx*4}{0}{0}{-1}{left}{$\la^+$}
            \perparrow{8}{0}{4}{\vx*4}{1}{right}{$\rcirc^k\wcirc^n$}
        \end{scope}
    \end{tikzpicture}
}

\newcommand{\atomdiamondex}[1]{
    \begin{tikzpicture}[x=#1,y=#1]
        \draw[blue1 line](21/2,-\v*11/2)\ddia\ddia\ddia\rel\lel\ddia\ddia\ddia\ddia;
        \draw[blue2 line](31/2,-\v*1/2)\hhor\ddia\ddia\ddia\ddia\ddia\ddia\ddia;
        \draw[blue3 line](27/2,-\v*5/2)\hhor\ddia\hhor\hhor\ddia\ddia\ddia\ddia;
        \draw[blue4 line](19/2,-\v*13/2)\ddia\ddia\ddia\ddia\ddia\hhor\ddia\ddia;
        \draw[red line](1/2,-\v*1/2)\rhhor\vver\rhhor\rhhor\vver\vver\rhhor\vver;
        \draw[red line](5/2,-\v*5/2)\vver\vver\rhhor\rhhor\vver\vver\rhhor\vver;
        \draw[red line](7/2,-\v*7/2)\vver\rhhor\rhhor\vver\vver\vver\rhhor\vver;
        \draw[red line](11/2,-\v*11/2)\vver\rhhor\rhhor\vver\vver\vver\vver\vver;
        \draw[gray](0,0)--++(8,-\v*8)--++(8,+\v*8)--++(-8,+\v*8)--cycle;
        \foreach \i in {1,...,7}{
            \draw[gray](\i,-\v*\i)--++(8,+\v*8);
            \draw[gray](\i,+\v*\i)--++(8,-\v*8);
        }
        \colourcirc{7/2}{+\v*7/2}{blue1}
        \colourcirc{13/2}{+\v*13/2}{blue2}
        \colourcirc{5/2}{+\v*5/2}{blue3}
        \colourcirc{1/2}{+\v*1/2}{blue4}
        \colourcirc{21/2}{-\v*11/2}{blue1}
        \colourcirc{31/2}{-\v*1/2}{blue2}
        \colourcirc{27/2}{-\v*5/2}{blue3}
        \colourcirc{19/2}{-\v*13/2}{blue4}
        \colourcirc{1/2}{-\v*1/2}{red}
        \colourcirc{5/2}{-\v*5/2}{red}
        \colourcirc{7/2}{-\v*7/2}{red}
        \colourcirc{11/2}{-\v*11/2}{red}
        \colourcirc{31/2}{+\v*1/2}{red}
        \colourcirc{29/2}{+\v*3/2}{red}
        \colourcirc{27/2}{+\v*5/2}{red}
        \colourcirc{25/2}{+\v*7/2}{red}
        \draw(7/2,+\v*7/2)node[left]{\smfont$1$};
        \draw(13/2,+\v*13/2)node[left]{\smfont$2$};
        \draw(5/2,+\v*5/2)node[left]{\smfont$3$};
        \draw(1/2,+\v*1/2)node[left]{\smfont$4$};
        \draw(21/2,-\v*11/2)node[right]{\smfont$1$};
        \draw(31/2,-\v*1/2)node[right]{\smfont$2$};
        \draw(27/2,-\v*5/2)node[right]{\smfont$3$};
        \draw(19/2,-\v*13/2)node[right]{\smfont$4$};
        \draw(1/2,-\v*1/2)node[left]{\smfont$+$};
        \draw(5/2,-\v*5/2)node[left]{\smfont$+$};
        \draw(7/2,-\v*7/2)node[left]{\smfont$+$};
        \draw(11/2,-\v*11/2)node[left]{\smfont$+$};
        \draw(31/2,+\v*1/2)node[right]{\smfont$+$};
        \draw(29/2,+\v*3/2)node[right]{\smfont$+$};
        \draw(27/2,+\v*5/2)node[right]{\smfont$+$};
        \draw(25/2,+\v*7/2)node[right]{\smfont$+$};
        
        \begin{scope}[shift={(25,0)}]
            \draw[blue1 line](21/2,-\v*11/2)\ddia\ddia\ddia\ddia\rel\lel\ddia\ddia\ddia;
            \draw[blue2 line](31/2,-\v*1/2)\hhor\ddia\ddia\ddia\ddia\ddia\ddia\ddia;
            \draw[blue3 line](27/2,-\v*5/2)\ddia\ddia\hhor\hhor\hhor\ddia\ddia\ddia;
            \draw[blue4 line](19/2,-\v*13/2)\ddia\ddia\hhor\ddia\ddia\ddia\ddia\ddia;
            \draw[red line](1/2,-\v*1/2)\rhhor\vver\rhhor\rhhor\vver\vver\rhhor\vver;
            \draw[red line](5/2,-\v*5/2)\rhhor\vver\rhhor\vver\vver\vver\rhhor\vver;
            \draw[red line](7/2,-\v*7/2)\rhhor\vver\rhhor\vver\vver\vver\rhhor\vver;
            \draw[red line](11/2,-\v*11/2)\vver\vver\rhhor\vver\vver\rhhor\vver\vver;
            \draw[gray](0,0)--++(8,-\v*8)--++(8,+\v*8)--++(-8,+\v*8)--cycle;
            \foreach \i in {1,...,7}{
                \draw[gray](\i,-\v*\i)--++(8,+\v*8);
                \draw[gray](\i,+\v*\i)--++(8,-\v*8);
            }
            \colourcirc{7/2}{+\v*7/2}{blue1}
            \colourcirc{13/2}{+\v*13/2}{blue2}
            \colourcirc{5/2}{+\v*5/2}{blue3}
            \colourcirc{1/2}{+\v*1/2}{blue4}
            \colourcirc{21/2}{-\v*11/2}{blue1}
            \colourcirc{31/2}{-\v*1/2}{blue2}
            \colourcirc{27/2}{-\v*5/2}{blue3}
            \colourcirc{19/2}{-\v*13/2}{blue4}
            \colourcirc{1/2}{-\v*1/2}{red}
            \colourcirc{5/2}{-\v*5/2}{red}
            \colourcirc{7/2}{-\v*7/2}{red}
            \colourcirc{11/2}{-\v*11/2}{red}
            \colourcirc{31/2}{+\v*1/2}{red}
            \colourcirc{29/2}{+\v*3/2}{red}
            \colourcirc{27/2}{+\v*5/2}{red}
            \colourcirc{25/2}{+\v*7/2}{red}
            \draw(7/2,+\v*7/2)node[left]{\smfont$1$};
            \draw(13/2,+\v*13/2)node[left]{\smfont$2$};
            \draw(5/2,+\v*5/2)node[left]{\smfont$3$};
            \draw(1/2,+\v*1/2)node[left]{\smfont$4$};
            \draw(21/2,-\v*11/2)node[right]{\smfont$1$};
            \draw(31/2,-\v*1/2)node[right]{\smfont$2$};
            \draw(27/2,-\v*5/2)node[right]{\smfont$3$};
            \draw(19/2,-\v*13/2)node[right]{\smfont$4$};
            \draw(1/2,-\v*1/2)node[left]{\smfont$+$};
            \draw(5/2,-\v*5/2)node[left]{\smfont$+$};
            \draw(7/2,-\v*7/2)node[left]{\smfont$+$};
            \draw(11/2,-\v*11/2)node[left]{\smfont$+$};
            \draw(31/2,+\v*1/2)node[right]{\smfont$+$};
            \draw(29/2,+\v*3/2)node[right]{\smfont$+$};
            \draw(27/2,+\v*5/2)node[right]{\smfont$+$};
            \draw(25/2,+\v*7/2)node[right]{\smfont$+$};
        \end{scope}
    \end{tikzpicture}
}

\newcommand{\columnlemma}[1]{
    \begin{tikzpicture}[x=#1,y=#1]
        \filldraw[light gray](0,0)--++(1,-\v)--++(2,0)--++(4,+\v*4)--++(-1,\v)--++(-2,0)--cycle;
        \draw[gray](0,0)--++(1,-\v)--++(2,0)--++(2,+\v*2)--++(-1,\v)--++(-2,0)--cycle;
        \draw[gray](3,+\v*3)--++(2,0)--++(1,-\v)--++(1,+\v)--++(-1,\v)--++(-2,0)--cycle;
        \draw[gray](2,0)--++(2,+\v*2);
        \draw[gray](5,+\v*3)--++(1,+\v);
        \draw[gray](0,0)--++(2,0)--++(1,-\v);
        \draw[gray](1,+\v)--++(2,0)--++(1,-\v);
        \draw[gray](2,+\v*2)--++(2,0)--++(1,-\v);
        \draw[gray, dashed](2,+\v*2)--++(1,\v);
        \draw[gray, dashed](4,+\v*2)--++(1,\v);
        \draw[gray, dashed](5,\v)--++(1,\v);
        
        \draw(1/2,+\v*1/2)node[left]{\smfont$q_1$};
        \draw(3/2,+\v*3/2)node[left]{\smfont$q_2$};
        \draw(7/2,+\v*7/2)node[left]{\smfont$q_m$};
        \draw(7/2,-\v*1/2)node[right]{\smfont$t_1$};
        \draw(9/2,+\v*1/2)node[right]{\smfont$t_2$};
        \draw(13/2,+\v*5/2)node[right]{\smfont$t_m$};
        \draw(5,+\v*4)node[above]{\smfont$v$};
        \draw(2,-\v)node[below]{\smfont$s$};
        \draw(1/2,-\v/2)node[left]{\smfont$r$};
        \draw(13/2,+\v*7/2)node[right]{\smfont$u$};
        \begin{scope}[shift={(11,0)}]
            \filldraw[light gray](0,0)--++(1,-\v)--++(2,0)--++(4,+\v*4)--++(-1,\v)--++(-2,0)--cycle;
            \draw[gray](0,0)--++(1,-\v)--++(2,0)--++(2,+\v*2)--++(-2,0)--++(-1,\v)--cycle;
            \draw[gray](3,+\v*3)--++(1,-\v)--++(2,0)--++(1,+\v)--++(-1,\v)--++(-2,0)--cycle;
            \draw[gray](1,-\v)--++(2,+\v*2);
            \draw[gray](4,+\v*2)--++(1,+\v);
            \draw[gray](1,+\v)--++(1,-\v)--++(2,0);
            \draw[gray](4,+\v*4)--++(1,-\v)--++(2,0);
            \draw[gray, dashed](2,+\v*2)--++(1,\v);
            \draw[gray, dashed](3,+\v)--++(1,\v);
            \draw[gray, dashed](5,\v)--++(1,\v);
            
            \draw(1/2,+\v*1/2)node[left]{\smfont$q_1$};
            \draw(3/2,+\v*3/2)node[left]{\smfont$q_2$};
            \draw(7/2,+\v*7/2)node[left]{\smfont$q_m$};
            \draw(7/2,-\v*1/2)node[right]{\smfont$t_1$};
            \draw(9/2,+\v*1/2)node[right]{\smfont$t_2$};
            \draw(13/2,+\v*5/2)node[right]{\smfont$t_m$};
            \draw(5,+\v*4)node[above]{\smfont$v$};
            \draw(2,-\v)node[below]{\smfont$s$};
            \draw(1/2,-\v/2)node[left]{\smfont$r$};
            \draw(13/2,+\v*7/2)node[right]{\smfont$u$};
        \end{scope}
        
        \draw(9,+\v*3/2)node{$=$};
    \end{tikzpicture}
}

\newcommand{\prisms}[1]{
    \begin{tikzpicture}[x=#1,y=#1]
        \filldraw[gray fill](0,0)--++(3,-\v*3)--++(4,0)--++(6,+\v*6)--++(-3,+\v*3)--++(-4,0)--cycle;
        \draw[gray](0,0)--++(4,0)--++(3,-\v*3);
        \draw[gray](3,+\v*3)--++(4,0)--++(3,-\v*3);
        \draw[gray](4,0)--++(6,+\v*6);
        \perparrow{0}{0}{3}{\vx*3}{-1}{left}{$\al_\A$}
        \perparrow{3}{-\vx*3}{0}{0}{-1}{left}{$\la^+$}
        \perparrow{3}{-\vx*3}{7}{-\vx*3}{1}{below}{\smfont$1$ $2$ $3$ $\cdots$ $n$}
        \perparrow{6}{\vx*6}{10}{\vx*6}{-1}{above}{$\bacirc^n$}
        \perparrow{13}{\vx*3}{10}{\vx*6}{1}{right}{$\rcirc^k\wcirc^n$}
        \perparrow{10}{0}{13}{\vx*3}{1}{right}{$\wcirc^k\bacirc^n$}
        
        \begin{scope}[shift={(21,0)}]
            \filldraw[gray fill](0,0)--++(3,-\v*3)--++(4,0)--++(6,+\v*6)--++(-3,+\v*3)--++(-4,0)--cycle;
            \draw[gray](3,+\v*3)--++(3,-\v*3)--++(4,0);
            \draw[gray](6,+\v*6)--++(3,-\v*3)--++(4,0);
            \draw[gray](3,-\v*3)--++(6,+\v*6);
            \perparrow{0}{0}{3}{\vx*3}{-1}{left}{$\al_\A$}
            \perparrow{3}{-\vx*3}{0}{0}{-1}{left}{$\la^+$}
            \perparrow{3}{-\vx*3}{7}{-\vx*3}{1}{below}{\smfont$1$ $2$ $3$ $\cdots$ $n$}
            \perparrow{6}{\vx*6}{10}{\vx*6}{-1}{above}{$\bacirc^n$}
            \perparrow{13}{\vx*3}{10}{\vx*6}{1}{right}{$\rcirc^k\wcirc^n$}
            \perparrow{10}{0}{13}{\vx*3}{1}{right}{$\wcirc^k\bacirc^n$}
        \end{scope}
        
        \draw(17,+\v*3/2)node{$=$};
    \end{tikzpicture}
}

\newcommand{\oldxtiles}[1]{
    \begin{tikzpicture}[x=#1,y=#1]
        \draw[dotted red line](1,0)\vver;
        \draw[draw=gray](0,0)--node[below]{\smfont$*$}++(2,0)--node[right]{\smfont$0$}++(1,\v)--node[above]{\smfont$*$}++(-2,0)--node[left]{\smfont$0$}cycle;
        
        \begin{scope}[shift={(5,0)}]
            \draw[blue1 line](5/2,+\v/2)\dia;
            \draw[dotted red line](1,0)\bel;
            \draw[draw=gray](0,0)--node[below]{\smfont$*$}++(2,0)--node[right]{\smfont$i^*$}++(1,\v)--node[above]{\smfont$i$}++(-2,0)--node[left]{\smfont$0$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(10,0)}]
            \draw[blue1 line](1,0)\dia;
            \draw[dotted red line](1/2,+\v/2)\tel;
            \draw[draw=gray](0,0)--node[below]{\smfont$i$}++(2,0)--node[right]{\smfont$0$}++(1,\v)--node[above]{\smfont$*$}++(-2,0)--node[left]{\smfont$i^*$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(15,0)}]
            \draw[blue1 line](5/2,+\v/2)\dia;
            \draw[blue1 line](1,0)\dia;
            \draw[dotted red line](1/2,+\v/2)\rhhor;
            \draw[draw=gray](0,0)--node[below]{\smfont$i$}++(2,0)--node[right]{\smfont$i^*$}++(1,\v)--node[above]{\smfont$i$}++(-2,0)--node[left]{\smfont$i^*$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(20,0)}]
            \draw[blue1 line](5/2,+\v/2)\dia;
            \draw[blue3 line](1,0)\dia;
            \draw[dotted red line](1/2,+\v/2)\rhhor;
            \draw[draw=gray](0,0)--node[below]{\smfont$j$}++(2,0)--node[right]{\smfont$i^*$}++(1,\v)--node[above]{\smfont$i$}++(-2,0)--node[left]{\smfont$j^*$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(25,0)}]
            \draw[blue1 line](1,0)\vver;
            \draw[blue3 line](5/2,+\v/2)\hhor;
            \draw[dotted red line](1/2,+\v/2)\rhhor;
            \draw[draw=gray](0,0)--node[below]{\smfont$i$}++(2,0)--node[right]{\smfont$j^*$}++(1,\v)--node[above]{\smfont$i$}++(-2,0)--node[left]{\smfont$j^*$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(30,0)}]
            \draw[blue1 line](1/2,+\v/2)\rhhor;
            \draw[red line](1,0)\vver;
            \draw[draw=gray](0,0)--node[below]{\smfont$+$}++(2,0)--node[right]{\smfont$i$}++(1,\v)--node[above]{\smfont$+$}++(-2,0)--node[left]{\smfont$i$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(35,0)}]
            \filldraw[blue weight](0,0)--++(2,0)--++(1,+\v)--++(-2,0)--cycle;
            \draw[blue1 line](1,0)\vver;
            \draw[draw=gray](0,0)--node[below]{\smfont$i$}++(2,0)--node[right]{\smfont$0$}++(1,\v)--node[above]{\smfont$i$}++(-2,0)--node[left]{\smfont$0$}cycle;
            \draw(1.5,-2)node{weight: $x_c$};
        \end{scope}
    \end{tikzpicture}
}

\newcommand{\oldytiles}[1]{
    \begin{tikzpicture}[x=#1,y=#1]
        \draw[dotted red line](1/2,+\v/2)\ver;
        \draw[dotted red line](2,0)\ver;
        \draw[draw=gray](0,\v)--node[above]{\smfont$*$}++(2,0)--node[right]{\smfont$\#$}++(1,-\v)--node[below]{\smfont$\#$}++(-2,0)--node[left]{\smfont$*$}cycle;
        
        \begin{scope}[shift={(5,0)}]
            \filldraw[white](0,\v)--++(1,-\v)--++(2,0)--++(-1,\v)--++(2,0)--cycle;
            \draw[blue1 line](2,0)\ddia;
            \draw[dotted red line](1/2,+\v/2)\rhhor;
            \draw[draw=gray](0,\v)--node[above]{\smfont$i$}++(2,0)--node[right]{\smfont$*$}++(1,-\v)--node[below]{\smfont$i$}++(-2,0)--node[left]{\smfont$*$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(10,0)}]
            \filldraw[white](0,\v)--++(1,-\v)--++(2,0)--++(-1,\v)--++(2,0)--cycle;
            \draw[blue1 line](5/2,+\v/2)\hor\dia;
            \draw[red line](2,0)\ver;
            \draw[draw=gray](0,\v)--node[above]{\smfont$i$}++(2,0)--node[right]{\smfont$i^+$}++(1,-\v)--node[below]{\smfont$+$}++(-2,0)--node[left]{\smfont$0$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(15,0)}]
            \filldraw[white](0,\v)--++(1,-\v)--++(2,0)--++(-1,\v)--++(2,0)--cycle;
            \draw[blue1 line](2,0)\dia\hor;
            \draw[red line](1/2,+\v/2)\ver;
            \draw[draw=gray](0,\v)--node[above]{\smfont$+$}++(2,0)--node[right]{\smfont$0$}++(1,-\v)--node[below]{\smfont$i$}++(-2,0)--node[left]{\smfont$i^+$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(20,0)}]
            \filldraw[white](0,\v)--++(1,-\v)--++(2,0)--++(-1,\v)--++(2,0)--cycle;
            \draw[blue1 line](1/2,+\v/2)\rhhor;
            \draw[red line](1/2,+\v/2)\ver;
            \draw[red line](2,0)\ver;
            \draw[draw=gray](0,\v)--node[above]{\smfont$+$}++(2,0)--node[right]{\smfont$i^+$}++(1,-\v)--node[below]{\smfont$+$}++(-2,0)--node[left]{\smfont$i^+$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(25,0)}]
            \filldraw[white](0,\v)--++(1,-\v)--++(2,0)--++(-1,\v)--++(2,0)--cycle;
            \filldraw[red weight](0,\v)--++(2,0)--++(1,-\v)--++(-2,0)--cycle;
            \draw[red line](2,0)\ddia;
            \draw[draw=gray](0,\v)--node[above]{\smfont$+$}++(2,0)--node[right]{\smfont$0$}++(1,-\v)--node[below]{\smfont$+$}++(-2,0)--node[left]{\smfont$0$}cycle;
            \draw(1.5,-2)node{weight: $-x_c$};
        \end{scope}
        % node to make spacing
        \draw(0,-\v*2)node{};
    \end{tikzpicture}
}

\newcommand{\oldztiles}[1]{
    \begin{tikzpicture}[x=#1,y=#1]
        \draw[blue1 line](3/2,-\v/2)\ddia;
        \draw[dotted red line](3/2,+\v/2)\hor;
        \draw[dotted red line](3/2,-\v/2)\hor;
        \draw[draw=gray](0,0)--node[left]{\smfont$\#$}++(1,-\v)--node[right]{\smfont$i^\#$}++(1,\v)--node[right]{\smfont$*$}++(-1,\v)--node[left]{\smfont$i^*$}cycle;
        
        \begin{scope}[shift={(\alldiamondspace,0)}]
            \draw[blue1 line](3/2,-\v/2)\rel;
            \draw[blue3 line](3/2,+\v/2)\hor;
            \draw[dotted red line](3/2,+\v/2)\hor;
            \draw[dotted red line](3/2,-\v/2)\hor;
            \draw[draw=gray](0,0)--node[left]{\smfont$\#$}++(1,-\v)--node[right]{\smfont$i^\#$}++(1,\v)--node[right]{\smfont$ij^*$}++(-1,\v)--node[left]{\smfont$j^*$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(2*\alldiamondspace,0)}]
            \draw[blue1 line](1/2,-\v/2)\lel;
            \draw[blue3 line](3/2,-\v/2)\hor;
            \draw[dotted red line](3/2,+\v/2)\hor;
            \draw[dotted red line](3/2,-\v/2)\hor;
            \draw[draw=gray](0,0)--node[left]{\smfont$ij^\#$}++(1,-\v)--node[right]{\smfont$j^\#$}++(1,\v)--node[right]{\smfont$*$}++(-1,\v)--node[left]{\smfont$i^*$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(3*\alldiamondspace,0)}]
            \draw[blue1 line](1/2,-\v/2)\vver;
            \draw[blue3 line](3/2,+\v/2)\hor;
            \draw[blue3 line](3/2,-\v/2)\hor;
            \draw[dotted red line](3/2,+\v/2)\hor;
            \draw[dotted red line](3/2,-\v/2)\hor;
            \draw[draw=gray](0,0)--node[left]{\smfont$ij^\#$}++(1,-\v)--node[right]{\smfont$j^\#$}++(1,\v)--node[right]{\smfont$ij^*$}++(-1,\v)--node[left]{\smfont$j^*$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(4*\alldiamondspace,0)}]
            \draw[blue1 line](1/2,-\v/2)\vver;
            \draw[blue3 line](3/2,+\v/2)\hor;
            \draw[blue5 line](3/2,-\v/2)\hor;
            \draw[dotted red line](3/2,+\v/2)\hor;
            \draw[dotted red line](3/2,-\v/2)\hor;
            \draw[draw=gray](0,0)--node[left]{\smfont$ik^\#$}++(1,-\v)--node[right]{\smfont$k^\#$}++(1,\v)--node[right]{\smfont$ij^*$}++(-1,\v)--node[left]{\smfont$j^*$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(5*\alldiamondspace,0)}]
            \draw[blue1 line](1/2,-\v/2)\vver;
            \draw[blue5 line](3/2,+\v/2)\hor;
            \draw[blue3 line](3/2,-\v/2)\hor;
            \draw[dotted red line](3/2,+\v/2)\hor;
            \draw[dotted red line](3/2,-\v/2)\hor;
            \draw[draw=gray](0,0)--node[left]{\smfont$ij^\#$}++(1,-\v)--node[right]{\smfont$j^\#$}++(1,\v)--node[right]{\smfont$ik^*$}++(-1,\v)--node[left]{\smfont$k^*$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(0,-4)}]
            \draw[dotted red line](1/2,-\v/2)\vver;
            \draw[draw=gray](0,0)--node[left]{\smfont$*$}++(1,-\v)--node[right]{\smfont$0$}++(1,\v)--node[right]{\smfont$*$}++(-1,\v)--node[left]{\smfont$0$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(\alldiamondspace,-4)}]
            \draw[blue1 line](3/2,-\v/2)\hor;
            \draw[red line](1/2,-\v/2)\vver;
            \draw[draw=gray](0,0)--node[left]{\smfont$i^+$}++(1,-\v)--node[right]{\smfont$i$}++(1,\v)--node[right]{\smfont$+$}++(-1,\v)--node[left]{\smfont$0$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(2*\alldiamondspace,-4)}]
            \draw[blue1 line](3/2,+\v/2)\hor;
            \draw[red line](1/2,-\v/2)\vver;
            \draw[draw=gray](0,0)--node[left]{\smfont$+$}++(1,-\v)--node[right]{\smfont$0$}++(1,\v)--node[right]{\smfont$i^+$}++(-1,\v)--node[left]{\smfont$i$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(3*\alldiamondspace,-4)}]
            \draw[blue1 line](3/2,+\v/2)\hor;
            \draw[blue1 line](3/2,-\v/2)\hor;
            \draw[red line](1/2,-\v/2)\vver;
            \draw[draw=gray](0,0)--node[left]{\smfont$i^+$}++(1,-\v)--node[right]{\smfont$i$}++(1,\v)--node[right]{\smfont$i^+$}++(-1,\v)--node[left]{\smfont$i$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(4*\alldiamondspace,-4)}]
            \draw[blue1 line](3/2,+\v/2)\hor;
            \draw[blue3 line](3/2,-\v/2)\hor;
            \draw[red line](1/2,-\v/2)\vver;
            \draw[draw=gray](0,0)--node[left]{\smfont$j^+$}++(1,-\v)--node[right]{\smfont$j$}++(1,\v)--node[right]{\smfont$i^+$}++(-1,\v)--node[left]{\smfont$i$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(5*\alldiamondspace,-4)}]
            \draw[blue3 line](3/2,+\v/2)\hor;
            \draw[blue1 line](3/2,-\v/2)\hor;
            \draw[red line](1/2,-\v/2)\vver;
            \draw[draw=gray](0,0)--node[left]{\smfont$i^+$}++(1,-\v)--node[right]{\smfont$i$}++(1,\v)--node[right]{\smfont$j^+$}++(-1,\v)--node[left]{\smfont$j$}cycle;
        \end{scope}
    \end{tikzpicture}
}

\def\allshearspace{5}
\newcommand{\xtiles}[1]{
    \begin{tikzpicture}[x=#1,y=#1]
        \draw[draw=gray](0,0)--node[below]{\smfont$0$}++(2,0)--node[right]{\smfont$0$}++(1,\v)--node[above]{\smfont$0$}++(-2,0)--node[left]{\smfont$0$}cycle;
        
        \begin{scope}[shift={(\allshearspace,0)}]
            \draw[blue1 line](5/2,+\v/2)\dia;
            \draw[draw=gray](0,0)--node[below]{\smfont$0$}++(2,0)--node[right]{\smfont$i$}++(1,\v)--node[above]{\smfont$i$}++(-2,0)--node[left]{\smfont$0$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(2*\allshearspace,0)}]
            \draw[blue1 line](1,0)\dia;
            \draw[draw=gray](0,0)--node[below]{\smfont$i$}++(2,0)--node[right]{\smfont$0$}++(1,\v)--node[above]{\smfont$0$}++(-2,0)--node[left]{\smfont$i$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(3*\allshearspace,0)}]
            \draw[blue1 line](5/2,+\v/2)\dia;
            \draw[blue1 line](1,0)\dia;
            \draw[draw=gray](0,0)--node[below]{\smfont$i$}++(2,0)--node[right]{\smfont$i$}++(1,\v)--node[above]{\smfont$i$}++(-2,0)--node[left]{\smfont$i$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(4*\allshearspace,0)}]
            \draw[blue1 line](5/2,+\v/2)\dia;
            \draw[blue3 line](1,0)\dia;
            \draw[draw=gray](0,0)--node[below]{\smfont$j$}++(2,0)--node[right]{\smfont$i$}++(1,\v)--node[above]{\smfont$i$}++(-2,0)--node[left]{\smfont$j$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(5*\allshearspace,0)}]
            \draw[blue1 line](1,0)\vver;
            \draw[blue3 line](5/2,+\v/2)\hhor;
            \draw[draw=gray](0,0)--node[below]{\smfont$i$}++(2,0)--node[right]{\smfont$j$}++(1,\v)--node[above]{\smfont$i$}++(-2,0)--node[left]{\smfont$j$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(6*\allshearspace,0)}]
            \draw[blue1 line](1/2,+\v/2)\rhhor;
            \draw[red line](1,0)\vver;
            \draw[draw=gray](0,0)--node[below]{\smfont$+$}++(2,0)--node[right]{\smfont$i$}++(1,\v)--node[above]{\smfont$+$}++(-2,0)--node[left]{\smfont$i$}cycle;
        \end{scope}
        
        % second row
        \begin{scope}[shift={(0,-4)}]
            \draw[red line](1,0)\vver;
            \draw[draw=gray](0,0)--node[below]{\smfont$+$}++(2,0)--node[right]{\smfont$0$}++(1,\v)--node[above]{\smfont$+$}++(-2,0)--node[left]{\smfont$0$}cycle;
            
            \begin{scope}[shift={(\allshearspace,0)}]
                \draw[blue1 line](5/2,+\v/2)\dia;
                \draw[red line](1,0)\bel;
                \draw[draw=gray](0,0)--node[below]{\smfont$+$}++(2,0)--node[right]{\smfont$i^+$}++(1,\v)--node[above]{\smfont$i$}++(-2,0)--node[left]{\smfont$0$}cycle;
            \end{scope}
            
            \begin{scope}[shift={(2*\allshearspace,0)}]
                \draw[blue1 line](1,0)\dia;
                \draw[red line](1/2,+\v/2)\tel;
                \draw[draw=gray](0,0)--node[below]{\smfont$i$}++(2,0)--node[right]{\smfont$0$}++(1,\v)--node[above]{\smfont$+$}++(-2,0)--node[left]{\smfont$i^+$}cycle;
            \end{scope}
            
            \begin{scope}[shift={(3*\allshearspace,0)}]
                \draw[blue1 line](5/2,+\v/2)\dia;
                \draw[blue1 line](1,0)\dia;
                \draw[red line](1/2,+\v/2)\rhhor;
                \draw[draw=gray](0,0)--node[below]{\smfont$i$}++(2,0)--node[right]{\smfont$i^+$}++(1,\v)--node[above]{\smfont$i$}++(-2,0)--node[left]{\smfont$i^+$}cycle;
            \end{scope}
            
            \begin{scope}[shift={(4*\allshearspace,0)}]
                \draw[blue1 line](5/2,+\v/2)\dia;
                \draw[blue3 line](1,0)\dia;
                \draw[red line](1/2,+\v/2)\rhhor;
                \draw[draw=gray](0,0)--node[below]{\smfont$j$}++(2,0)--node[right]{\smfont$i^+$}++(1,\v)--node[above]{\smfont$i$}++(-2,0)--node[left]{\smfont$j^+$}cycle;
            \end{scope}
            
            \begin{scope}[shift={(5*\allshearspace,0)}]
                \draw[blue1 line](1,0)\vver;
                \double{5/2}{+\v/2}{blue3}{-2}
                \draw[draw=gray](0,0)--node[below]{\smfont$i$}++(2,0)--node[right]{\smfont$j^+$}++(1,\v)--node[above]{\smfont$i$}++(-2,0)--node[left]{\smfont$j^+$}cycle;
            \end{scope}
            
            \begin{scope}[shift={(6*\allshearspace,0)}]
                \filldraw[blue weight](0,0)--++(2,0)--++(1,+\v)--++(-2,0)--cycle;
                \draw[blue1 line](1,0)\vver;
                \draw[draw=gray](0,0)--node[below]{\smfont$i$}++(2,0)--node[right]{\smfont$0$}++(1,\v)--node[above]{\smfont$i$}++(-2,0)--node[left]{\smfont$0$}cycle;
                \draw(1.5,-2)node{weight: $x_c$};
            \end{scope}
        \end{scope}
        
        % node to make spacing
        \draw(0,-\v*7/2)node{};
    \end{tikzpicture}
}

\newcommand{\ytiles}[1]{
    \begin{tikzpicture}[x=#1,y=#1]
        \filldraw[white](0,\v)--++(1,-\v)--++(2,0)--++(-1,\v)--++(2,0)--cycle;
        \draw[blue1 line](2,0)\ddia;
        \draw[draw=gray](0,\v)--node[above]{\smfont$i$}++(2,0)--node[right]{\smfont$0$}++(1,-\v)--node[below]{\smfont$i$}++(-2,0)--node[left]{\smfont$0$}cycle;
        
        \begin{scope}[shift={(\allshearspace,0)}]
            \filldraw[white](0,\v)--++(1,-\v)--++(2,0)--++(-1,\v)--++(2,0)--cycle;
            \draw[blue1 line](5/2,+\v/2)\hor\dia;
            \draw[red line](2,0)\ver;
            \draw[draw=gray](0,\v)--node[above]{\smfont$i$}++(2,0)--node[right]{\smfont$i^+$}++(1,-\v)--node[below]{\smfont$+$}++(-2,0)--node[left]{\smfont$0$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(2*\allshearspace,0)}]
            \filldraw[white](0,\v)--++(1,-\v)--++(2,0)--++(-1,\v)--++(2,0)--cycle;
            \draw[blue1 line](2,0)\dia\hor;
            \draw[red line](1/2,+\v/2)\ver;
            \draw[draw=gray](0,\v)--node[above]{\smfont$+$}++(2,0)--node[right]{\smfont$0$}++(1,-\v)--node[below]{\smfont$i$}++(-2,0)--node[left]{\smfont$i^+$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(3*\allshearspace,0)}]
            \filldraw[white](0,\v)--++(1,-\v)--++(2,0)--++(-1,\v)--++(2,0)--cycle;
            \draw[blue1 line](1/2,+\v/2)\rhhor;
            \draw[red line](1/2,+\v/2)\ver;
            \draw[red line](2,0)\ver;
            \draw[draw=gray](0,\v)--node[above]{\smfont$+$}++(2,0)--node[right]{\smfont$i^+$}++(1,-\v)--node[below]{\smfont$+$}++(-2,0)--node[left]{\smfont$i^+$}cycle;
        \end{scope}
        
        \begin{scope}[shift={(4*\allshearspace,0)}]
            \filldraw[white](0,\v)--++(1,-\v)--++(2,0)--++(-1,\v)--++(2,0)--cycle;
            \draw[blue1 line](2,0)\ddia;
            \draw[red line](1/2,+\v/2)\rhhor;
            \draw[draw=gray](0,\v)--node[above]{\smfont$i$}++(2,0)--node[right]{\smfont$+$}++(1,-\v)--node[below]{\smfont$i$}++(-2,0)--node[left]{\smfont$+$}cycle;
        \end{scope}
        
        % second row
        \begin{scope}[shift={(0,-4)}]
            \draw[draw=gray](0,\v)--node[above]{\smfont$0$}++(2,0)--node[right]{\smfont$0$}++(1,-\v)--node[below]{\smfont$0$}++(-2,0)--node[left]{\smfont$0$}cycle;
            
            \begin{scope}[shift={(\allshearspace,0)}]
                \filldraw[white](0,\v)--++(1,-\v)--++(2,0)--++(-1,\v)--++(2,0)--cycle;
                \draw[red line](2,0)\ver;
                \draw[draw=gray](0,\v)--node[above]{\smfont$0$}++(2,0)--node[right]{\smfont$+$}++(1,-\v)--node[below]{\smfont$+$}++(-2,0)--node[left]{\smfont$0$}cycle;
            \end{scope}
            
            \begin{scope}[shift={(2*\allshearspace,0)}]
                \filldraw[white](0,\v)--++(1,-\v)--++(2,0)--++(-1,\v)--++(2,0)--cycle;
                \draw[red line](1/2,+\v/2)\ver;
                \draw[draw=gray](0,\v)--node[above]{\smfont$+$}++(2,0)--node[right]{\smfont$0$}++(1,-\v)--node[below]{\smfont$0$}++(-2,0)--node[left]{\smfont$+$}cycle;
            \end{scope}
            
            \begin{scope}[shift={(3*\allshearspace,0)}]
                \filldraw[white](0,\v)--++(1,-\v)--++(2,0)--++(-1,\v)--++(2,0)--cycle;
                \draw[red line](1/2,+\v/2)\ver;
                \draw[red line](2,0)\ver;
                \draw[draw=gray](0,\v)--node[above]{\smfont$+$}++(2,0)--node[right]{\smfont$+$}++(1,-\v)--node[below]{\smfont$+$}++(-2,0)--node[left]{\smfont$+$}cycle;
            \end{scope}
            
            \begin{scope}[shift={(4*\allshearspace,0)}]
                \filldraw[white](0,\v)--++(1,-\v)--++(2,0)--++(-1,\v)--++(2,0)--cycle;
                \filldraw[red weight](0,\v)--++(2,0)--++(1,-\v)--++(-2,0)--cycle;
                \draw[red line](2,0)\ddia;
                \draw[draw=gray](0,\v)--node[above]{\smfont$+$}++(2,0)--node[right]{\smfont$0$}++(1,-\v)--node[below]{\smfont$+$}++(-2,0)--node[left]{\smfont$0$}cycle;
                \draw(1.5,-2)node{weight: $-x_c$};
            \end{scope}
        \end{scope}
        % node to make spacing
        \draw(0,-\v*9/2)node{};
    \end{tikzpicture}
}

\def\alldiamondspace{5}
\def\diamondrowspace{9/2}
\newcommand{\ztiles}[1]{
    \begin{tikzpicture}[x=#1,y=#1]
        \begin{scope}[shift={(-\alldiamondspace/2,0)}]
            \draw[draw=gray](0,0)--node[left]{\smfont$0$}++(1,-\v)--node[right]{\smfont$0$}++(1,\v)--node[right]{\smfont$0$}++(-1,\v)--node[left]{\smfont$0$}cycle;
            
            \begin{scope}[shift={(\alldiamondspace,0)}]
                \draw[red line](1/2,-\v/2)\vver;
                \draw[draw=gray](0,0)--node[left]{\smfont$+$}++(1,-\v)--node[right]{\smfont$0$}++(1,\v)--node[right]{\smfont$+$}++(-1,\v)--node[left]{\smfont$0$}cycle;
            \end{scope}
            
            \begin{scope}[shift={(2*\alldiamondspace,0)}]
                \draw[blue1 line](3/2,-\v/2)\hor;
                \draw[red line](1/2,-\v/2)\vver;
                \draw[draw=gray](0,0)--node[left]{\smfont$i^+$}++(1,-\v)--node[right]{\smfont$i$}++(1,\v)--node[right]{\smfont$+$}++(-1,\v)--node[left]{\smfont$0$}cycle;
            \end{scope}
            
            \begin{scope}[shift={(3*\alldiamondspace,0)}]
                \draw[blue1 line](3/2,+\v/2)\hor;
                \draw[red line](1/2,-\v/2)\vver;
                \draw[draw=gray](0,0)--node[left]{\smfont$+$}++(1,-\v)--node[right]{\smfont$0$}++(1,\v)--node[right]{\smfont$i^+$}++(-1,\v)--node[left]{\smfont$i$}cycle;
            \end{scope}
            
            \begin{scope}[shift={(4*\alldiamondspace,0)}]
                \draw[blue1 line](3/2,+\v/2)\hor;
                \draw[blue1 line](3/2,-\v/2)\hor;
                \draw[red line](1/2,-\v/2)\vver;
                \draw[draw=gray](0,0)--node[left]{\smfont$i^+$}++(1,-\v)--node[right]{\smfont$i$}++(1,\v)--node[right]{\smfont$i^+$}++(-1,\v)--node[left]{\smfont$i$}cycle;
            \end{scope}
            
            \begin{scope}[shift={(5*\alldiamondspace,0)}]
                \draw[blue1 line](3/2,+\v/2)\hor;
                \draw[blue3 line](3/2,-\v/2)\hor;
                \draw[red line](1/2,-\v/2)\vver;
                \draw[draw=gray](0,0)--node[left]{\smfont$j^+$}++(1,-\v)--node[right]{\smfont$j$}++(1,\v)--node[right]{\smfont$i^+$}++(-1,\v)--node[left]{\smfont$i$}cycle;
            \end{scope}
            
            \begin{scope}[shift={(6*\alldiamondspace,0)}]
                \draw[blue3 line](3/2,+\v/2)\hor;
                \draw[blue1 line](3/2,-\v/2)\hor;
                \draw[red line](1/2,-\v/2)\vver;
                \draw[draw=gray](0,0)--node[left]{\smfont$i^+$}++(1,-\v)--node[right]{\smfont$i$}++(1,\v)--node[right]{\smfont$j^+$}++(-1,\v)--node[left]{\smfont$j$}cycle;
            \end{scope}
        \end{scope}
        
        % second row
        \begin{scope}[shift={(0,-\diamondrowspace)}]
            \draw[blue1 line](3/2,-\v/2)\ddia;
            \draw[draw=gray](0,0)--node[left]{\smfont$0$}++(1,-\v)--node[right]{\smfont$i$}++(1,\v)--node[right]{\smfont$0$}++(-1,\v)--node[left]{\smfont$i$}cycle;
            
            \begin{scope}[shift={(\alldiamondspace,0)}]
                \draw[blue1 line](3/2,-\v/2)\rel;
                \draw[blue3 line](3/2,+\v/2)\hor;
                \draw[draw=gray](0,0)--node[left]{\smfont$0$}++(1,-\v)--node[right]{\smfont$i$}++(1,\v)--node[right]{\smfont$ij$}++(-1,\v)--node[left]{\smfont$j$}cycle;
            \end{scope}
            
            \begin{scope}[shift={(2*\alldiamondspace,0)}]
                \draw[blue1 line](1/2,-\v/2)\lel;
                \draw[blue3 line](3/2,-\v/2)\hor;
                \draw[draw=gray](0,0)--node[left]{\smfont$ij$}++(1,-\v)--node[right]{\smfont$j$}++(1,\v)--node[right]{\smfont$0$}++(-1,\v)--node[left]{\smfont$i$}cycle;
            \end{scope}
            
            \begin{scope}[shift={(3*\alldiamondspace,0)}]
                \draw[blue1 line](1/2,-\v/2)\vver;
                \draw[blue3 line](3/2,+\v/2)\hor;
                \draw[blue3 line](3/2,-\v/2)\hor;
                \draw[draw=gray](0,0)--node[left]{\smfont$ij$}++(1,-\v)--node[right]{\smfont$j$}++(1,\v)--node[right]{\smfont$ij$}++(-1,\v)--node[left]{\smfont$j$}cycle;
            \end{scope}
            
            \begin{scope}[shift={(4*\alldiamondspace,0)}]
                \draw[blue1 line](1/2,-\v/2)\vver;
                \draw[blue3 line](3/2,+\v/2)\hor;
                \draw[blue5 line](3/2,-\v/2)\hor;
                \draw[draw=gray](0,0)--node[left]{\smfont$ik$}++(1,-\v)--node[right]{\smfont$k$}++(1,\v)--node[right]{\smfont$ij$}++(-1,\v)--node[left]{\smfont$j$}cycle;
            \end{scope}
            
            \begin{scope}[shift={(5*\alldiamondspace,0)}]
                \draw[blue1 line](1/2,-\v/2)\vver;
                \draw[blue5 line](3/2,+\v/2)\hor;
                \draw[blue3 line](3/2,-\v/2)\hor;
                \draw[draw=gray](0,0)--node[left]{\smfont$ij$}++(1,-\v)--node[right]{\smfont$j$}++(1,\v)--node[right]{\smfont$ik$}++(-1,\v)--node[left]{\smfont$k$}cycle;
            \end{scope}
        \end{scope}
        
        % third row
        \begin{scope}[shift={(0,-2*\diamondrowspace)}]
            \draw[blue1 line](3/2,-\v/2)\ddia;
            \draw[red line](3/2,-\v/2)\hor;
            \draw[draw=gray](0,0)--node[left]{\smfont$+$}++(1,-\v)--node[right]{\smfont$i^+$}++(1,\v)--node[right]{\smfont$0$}++(-1,\v)--node[left]{\smfont$i$}cycle;
            
            \begin{scope}[shift={(\alldiamondspace,0)}]
                \draw[blue1 line](3/2,-\v/2)\rel;
                \draw[blue3 line](3/2,+\v/2)\hor;
                \draw[red line](3/2,-\v/2)\hor;
                \draw[draw=gray](0,0)--node[left]{\smfont$+$}++(1,-\v)--node[right]{\smfont$i^+$}++(1,\v)--node[right]{\smfont$ij$}++(-1,\v)--node[left]{\smfont$j$}cycle;
            \end{scope}
            
            \begin{scope}[shift={(2*\alldiamondspace,0)}]
                \draw[blue1 line](1/2,-\v/2)\lel;
                \double{1/2}{-\v/2}{blue3}{1}
                \draw[draw=gray](0,0)--node[left]{\smfont$ij^+$}++(1,-\v)--node[right]{\smfont$j^+$}++(1,\v)--node[right]{\smfont$0$}++(-1,\v)--node[left]{\smfont$i$}cycle;
            \end{scope}
            
            \begin{scope}[shift={(3*\alldiamondspace,0)}]
                \draw[blue1 line](1/2,-\v/2)\vver;
                \draw[blue3 line](3/2,+\v/2)\hor;
                \double{1/2}{-\v/2}{blue3}{1}
                \draw[draw=gray](0,0)--node[left]{\smfont$ij^+$}++(1,-\v)--node[right]{\smfont$j^+$}++(1,\v)--node[right]{\smfont$ij$}++(-1,\v)--node[left]{\smfont$j$}cycle;
            \end{scope}
            
            \begin{scope}[shift={(4*\alldiamondspace,0)}]
                \draw[blue1 line](1/2,-\v/2)\vver;
                \draw[blue3 line](3/2,+\v/2)\hor;
                \double{1/2}{-\v/2}{blue5}{1}
                \draw[draw=gray](0,0)--node[left]{\smfont$ik^+$}++(1,-\v)--node[right]{\smfont$k^+$}++(1,\v)--node[right]{\smfont$ij$}++(-1,\v)--node[left]{\smfont$j$}cycle;
            \end{scope}
            
            \begin{scope}[shift={(5*\alldiamondspace,0)}]
                \draw[blue1 line](1/2,-\v/2)\vver;
                \draw[blue5 line](3/2,+\v/2)\hor;
                \double{1/2}{-\v/2}{blue3}{1}
                \draw[draw=gray](0,0)--node[left]{\smfont$ij^+$}++(1,-\v)--node[right]{\smfont$j^+$}++(1,\v)--node[right]{\smfont$ik$}++(-1,\v)--node[left]{\smfont$k$}cycle;
            \end{scope}
        \end{scope}
        
        % fourth row
        \begin{scope}[shift={(0,-3*\diamondrowspace)}]
            \draw[blue1 line](3/2,-\v/2)\ddia;
            \draw[red line](3/2,+\v/2)\hor;
            \draw[draw=gray](0,0)--node[left]{\smfont$0$}++(1,-\v)--node[right]{\smfont$i$}++(1,\v)--node[right]{\smfont$+$}++(-1,\v)--node[left]{\smfont$i^+$}cycle;
            
            \begin{scope}[shift={(\alldiamondspace,0)}]
                \draw[blue1 line](3/2,-\v/2)\rel;
                \double{1/2}{+\v/2}{blue3}{1}
                \draw[draw=gray](0,0)--node[left]{\smfont$0$}++(1,-\v)--node[right]{\smfont$i$}++(1,\v)--node[right]{\smfont$ij^+$}++(-1,\v)--node[left]{\smfont$j^+$}cycle;
            \end{scope}
            
            \begin{scope}[shift={(2*\alldiamondspace,0)}]
                \draw[blue1 line](1/2,-\v/2)\lel;
                \draw[blue3 line](3/2,-\v/2)\hor;
                \draw[red line](3/2,+\v/2)\hor;
                \draw[draw=gray](0,0)--node[left]{\smfont$ij$}++(1,-\v)--node[right]{\smfont$j$}++(1,\v)--node[right]{\smfont$+$}++(-1,\v)--node[left]{\smfont$i^+$}cycle;
            \end{scope}
            
            \begin{scope}[shift={(3*\alldiamondspace,0)}]
                \draw[blue1 line](1/2,-\v/2)\vver;
                \draw[blue3 line](3/2,-\v/2)\hor;
                \double{1/2}{+\v/2}{blue3}{1}
                \draw[draw=gray](0,0)--node[left]{\smfont$ij$}++(1,-\v)--node[right]{\smfont$j$}++(1,\v)--node[right]{\smfont$ij^+$}++(-1,\v)--node[left]{\smfont$j^+$}cycle;
            \end{scope}
            
            \begin{scope}[shift={(4*\alldiamondspace,0)}]
                \draw[blue1 line](1/2,-\v/2)\vver;
                \draw[blue5 line](3/2,-\v/2)\hor;
                \double{1/2}{+\v/2}{blue3}{1}
                \draw[draw=gray](0,0)--node[left]{\smfont$ik$}++(1,-\v)--node[right]{\smfont$k$}++(1,\v)--node[right]{\smfont$ij^+$}++(-1,\v)--node[left]{\smfont$j^+$}cycle;
            \end{scope}
            
            \begin{scope}[shift={(5*\alldiamondspace,0)}]
                \draw[blue1 line](1/2,-\v/2)\vver;
                \draw[blue3 line](3/2,-\v/2)\hor;
                \double{1/2}{+\v/2}{blue5}{1}
                \draw[draw=gray](0,0)--node[left]{\smfont$ij$}++(1,-\v)--node[right]{\smfont$j$}++(1,\v)--node[right]{\smfont$ik^+$}++(-1,\v)--node[left]{\smfont$k^+$}cycle;
            \end{scope}
        \end{scope}
        
        % fifth row
        \begin{scope}[shift={(0,-4*\diamondrowspace)}]
            \draw[blue1 line](3/2,-\v/2)\ddia;
            \draw[red line](3/2,+\v/2)\hor;
            \draw[red line](3/2,-\v/2)\hor;
            \draw[draw=gray](0,0)--node[left]{\smfont$+$}++(1,-\v)--node[right]{\smfont$i^+$}++(1,\v)--node[right]{\smfont$+$}++(-1,\v)--node[left]{\smfont$i^+$}cycle;
            
            \begin{scope}[shift={(\alldiamondspace,0)}]
                \draw[blue1 line](3/2,-\v/2)\rel;
                \double{1/2}{+\v/2}{blue3}{1}
                \draw[red line](3/2,-\v/2)\hor;
                \draw[draw=gray](0,0)--node[left]{\smfont$+$}++(1,-\v)--node[right]{\smfont$i^+$}++(1,\v)--node[right]{\smfont$ij^+$}++(-1,\v)--node[left]{\smfont$j^+$}cycle;
            \end{scope}
            
            \begin{scope}[shift={(2*\alldiamondspace,0)}]
                \draw[blue1 line](1/2,-\v/2)\lel;
                \draw[red line](3/2,+\v/2)\hor;
                \double{1/2}{-\v/2}{blue3}{1}
                \draw[draw=gray](0,0)--node[left]{\smfont$ij^+$}++(1,-\v)--node[right]{\smfont$j^+$}++(1,\v)--node[right]{\smfont$+$}++(-1,\v)--node[left]{\smfont$i^+$}cycle;
            \end{scope}
            
            \begin{scope}[shift={(3*\alldiamondspace,0)}]
                \draw[blue1 line](1/2,-\v/2)\vver;
                \double{1/2}{+\v/2}{blue3}{1}
                \double{1/2}{-\v/2}{blue3}{1}
                \draw[draw=gray](0,0)--node[left]{\smfont$ij^+$}++(1,-\v)--node[right]{\smfont$j^+$}++(1,\v)--node[right]{\smfont$ij^+$}++(-1,\v)--node[left]{\smfont$j^+$}cycle;
            \end{scope}
            
            \begin{scope}[shift={(4*\alldiamondspace,0)}]
                \draw[blue1 line](1/2,-\v/2)\vver;
                \double{1/2}{+\v/2}{blue3}{1}
                \double{1/2}{-\v/2}{blue5}{1}
                \draw[draw=gray](0,0)--node[left]{\smfont$ik^+$}++(1,-\v)--node[right]{\smfont$k^+$}++(1,\v)--node[right]{\smfont$ij^+$}++(-1,\v)--node[left]{\smfont$j^+$}cycle;
            \end{scope}
            
            \begin{scope}[shift={(5*\alldiamondspace,0)}]
                \draw[blue1 line](1/2,-\v/2)\vver;
                \double{1/2}{+\v/2}{blue5}{1}
                \double{1/2}{-\v/2}{blue3}{1}
                \draw[draw=gray](0,0)--node[left]{\smfont$ij^+$}++(1,-\v)--node[right]{\smfont$j^+$}++(1,\v)--node[right]{\smfont$ik^+$}++(-1,\v)--node[left]{\smfont$k^+$}cycle;
            \end{scope}
        \end{scope}
    \end{tikzpicture}
}

\newcommand{\columnexamples}[1]{
    \begin{tikzpicture}[x=#1,y=#1]
        \filldraw[blue weight](3,+\v*3)--++(2,0)--++(1,\v)--++(-2,0)--cycle;
        
        \draw[blue1 line](15/2,+\v*7/2)\ddia\ddia;
        \draw[blue2 line](2,-\v)\ddia\vver\vver\vver\vver\dia;
        \draw[blue4 line](11/2,+\v*3/2)\hhor\hhor;
        \draw[blue3 line](9/2,+\v/2)\rel\lel\hhor;
        \draw[blue5 line](7/2,-\v/2)\ddia;
        \double{1/2}{+\v/2}{blue5}{2}
        \draw[red line](9/2,+\v/2)\hhor;
        \draw[red line](9/2,+\v*9/2)\rhhor\rhor\vver;
        
        \draw[gray](0,0)--++(1,-\v)--++(2,0)--++(6,+\v*6)--++(-1,\v)--++(-2,0)--cycle;
        \draw[gray](2,0)--++(6,+\v*6);
        \foreach \i in {0,...,5} \draw[gray](\i,+\v*\i)--++(2,0)--++(1,-\v);
        
        \halfcirc{9/2}{+\v*9/2}{blue2}
        \halfcirc{9/2}{+\v/2}{blue3}
        \halfcirc{1/2}{+\v/2}{blue5}
        \colourcirc{11/2}{+\v*11/2}{blue1}
        \colourcirc{15/2}{+\v*7/2}{blue1}
        \colourcirc{2}{-\v}{blue2}
        \colourcirc{3/2}{+\v*3/2}{blue4}
        \colourcirc{11/2}{+\v*3/2}{blue4}
        \colourcirc{5/2}{+\v*5/2}{blue3}
        \colourcirc{7/2}{-\v/2}{blue5}
        \colourcirc{17/2}{+\v*11/2}{red}
        
        \draw(9/2,+\v*9/2)node[left]{\smfont$2^+$};
        \draw(9/2,+\v/2)node[right]{\smfont$3^+$};
        \draw(1/2,+\v/2)node[left]{\smfont$5^+$};
        \draw(11/2,+\v*11/2)node[left]{\smfont$1$};
        \draw(15/2,+\v*7/2)node[right]{\smfont$1$};
        \draw(2,-\v)node[below]{\smfont$2$};
        \draw(3/2,+\v*3/2)node[left]{\smfont$4$};
        \draw(11/2,+\v*3/2)node[right]{\smfont$4$};
        \draw(5/2,+\v*5/2)node[left]{\smfont$3$};
        \draw(7/2,-\v/2)node[right]{\smfont$5$};
        \draw(17/2,+\v*11/2)node[right]{\smfont$+$};
        
        \draw(2,-5)node{$x_c$};
        \draw(10,+\v*5/2)node{$=$};
        \begin{scope}[shift={(11,0)}]
            \filldraw[blue weight](4,+\v*2)--++(2,0)--++(1,\v)--++(-2,0)--cycle;
            
            \draw[blue1 line](15/2,+\v*7/2)\ddia\ddia;
            \draw[blue2 line](2,-\v)\vver\vver\vver\vver\ddia\dia;
            \draw[blue4 line](11/2,+\v*3/2)\hhor\hhor;
            \draw[blue3 line](5/2,+\v/2)\rel\lel;
            \double{9/2}{+\v/2}{blue3}{-2}
            \draw[blue5 line](7/2,-\v/2)\hhor\ddia;
            \draw[red line](1/2,+\v/2)\rhhor;
            \draw[red line](9/2,+\v*9/2)\rhhor\rhor\vver;
            
            \draw[gray](0,0)--++(1,-\v)--++(2,0)--++(6,+\v*6)--++(-1,\v)--++(-2,0)--cycle;
            \draw[gray](1,-\v)--++(6,+\v*6);
            \foreach \i in {1,...,6} \draw[gray](\i,+\v*\i)--++(1,-\v)--++(2,0);
            
            \halfcirc{9/2}{+\v*9/2}{blue2}
            \halfcirc{9/2}{+\v/2}{blue3}
            \halfcirc{1/2}{+\v/2}{blue5}
            \colourcirc{11/2}{+\v*11/2}{blue1}
            \colourcirc{15/2}{+\v*7/2}{blue1}
            \colourcirc{2}{-\v}{blue2}
            \colourcirc{3/2}{+\v*3/2}{blue4}
            \colourcirc{11/2}{+\v*3/2}{blue4}
            \colourcirc{5/2}{+\v*5/2}{blue3}
            \colourcirc{7/2}{-\v/2}{blue5}
            \colourcirc{17/2}{+\v*11/2}{red}
            
            \draw(9/2,+\v*9/2)node[left]{\smfont$2^+$};
            \draw(9/2,+\v/2)node[right]{\smfont$3^+$};
            \draw(1/2,+\v/2)node[left]{\smfont$5^+$};
            \draw(11/2,+\v*11/2)node[left]{\smfont$1$};
            \draw(15/2,+\v*7/2)node[right]{\smfont$1$};
            \draw(2,-\v)node[below]{\smfont$2$};
            \draw(3/2,+\v*3/2)node[left]{\smfont$4$};
            \draw(11/2,+\v*3/2)node[right]{\smfont$4$};
            \draw(5/2,+\v*5/2)node[left]{\smfont$3$};
            \draw(7/2,-\v/2)node[right]{\smfont$5$};
            \draw(17/2,+\v*11/2)node[right]{\smfont$+$};
            
            \draw(2,-5)node{$x_c$};
        \end{scope}
        
        \begin{scope}[shift={(27,0)}]
            \filldraw[blue weight](1,\v)--++(2,0)--++(1,\v)--++(-2,0)--cycle;
            \filldraw[blue weight](4,+\v*4)--++(2,0)--++(1,\v)--++(-2,0)--cycle;
            \filldraw[blue weight](5,+\v*5)--++(2,0)--++(1,\v)--++(-2,0)--cycle;
            
            \draw[blue1 line](9/2,+\v/2)\hhor\dia\vver\vver\vver\vver\vver;
            \draw[blue2 line](7/2,-\v/2)\hhor\ddia;
            \draw[blue3 line](11/2,+\v*3/2)\rel\lel\hhor;
            \draw[blue4 line](13/2,+\v*5/2)\hhor\hhor;
            \draw[red line](2,-\v)\vver\vver\ver\rhor;
            \draw[red line](11/2,+\v*7/2)\rhor\vver\vver;
            \double{7/2}{+\v*7/2}{blue3}{2}
            
            \draw[gray](0,0)--++(1,-\v)--++(2,0)--++(6,+\v*6)--++(-1,\v)--++(-2,0)--cycle;
            \draw[gray](2,0)--++(6,+\v*6);
            \foreach \i in {0,...,5} \draw[gray](\i,+\v*\i)--++(2,0)--++(1,-\v);
            
            \halfcirc{7/2}{+\v*7/2}{blue3}
            \halfcirc{11/2}{+\v*3/2}{blue3}
            \colourcirc{9/2}{+\v/2}{blue1}
            \colourcirc{7}{+\v*6}{blue1}
            \colourcirc{1/2}{+\v/2}{blue2}
            \colourcirc{7/2}{-\v/2}{blue2}
            \colourcirc{5/2}{+\v*5/2}{blue4}
            \colourcirc{13/2}{+\v*5/2}{blue4}
            \colourcirc{2}{-\v}{red}
            \colourcirc{17/2}{+\v*11/2}{red}
            
            \draw(7/2,+\v*7/2)node[left]{\smfont$3^+$};
            \draw(11/2,+\v*3/2)node[right]{\smfont$3^+$};
            \draw(9/2,+\v/2)node[right]{\smfont$1$};
            \draw(7,+\v*6)node[above]{\smfont$1$};
            \draw(1/2,+\v/2)node[left]{\smfont$2$};
            \draw(7/2,-\v/2)node[right]{\smfont$2$};
            \draw(5/2,+\v*5/2)node[left]{\smfont$4$};
            \draw(13/2,+\v*5/2)node[right]{\smfont$4$};
            \draw(2,-\v)node[below]{\smfont$+$};
            \draw(17/2,+\v*11/2)node[right]{\smfont$+$};
            
            \draw(2,-5)node{$x_c^3$};
            \draw(10,+\v*5/2)node{$+$};
        \end{scope}
        
        \begin{scope}[shift={(38,0)}]
            \filldraw[blue weight](4,+\v*4)--++(2,0)--++(1,\v)--++(-2,0)--cycle;
            \filldraw[blue weight](5,+\v*5)--++(2,0)--++(1,\v)--++(-2,0)--cycle;
            \filldraw[red weight](0,0)--++(2,0)--++(1,-\v)--++(-2,0)--cycle;
            
            \draw[blue1 line](9/2,+\v/2)\rel\vver\lel\dia\vver\vver;
            \draw[blue2 line](7/2,-\v/2)\ddia\hhor;
            \draw[blue3 line](11/2,+\v*3/2)\hhor\dia\vver\dia;
            \double{11/2}{+\v*3/2}{blue3}{-2}
            \draw[blue4 line](13/2,+\v*5/2)\hhor\hhor;
            \draw[red line](2,-\v)\ddia\vver\bel;
            \draw[red line](7/2,+\v*7/2)\rhhor\rhor\vver\vver;
            
            \draw[gray](0,0)--++(1,-\v)--++(2,0)--++(6,+\v*6)--++(-1,\v)--++(-2,0)--cycle;
            \draw[gray](2,0)--++(6,+\v*6);
            \foreach \i in {0,...,5} \draw[gray](\i,+\v*\i)--++(2,0)--++(1,-\v);
            
            \halfcirc{7/2}{+\v*7/2}{blue3}
            \halfcirc{11/2}{+\v*3/2}{blue3}
            \colourcirc{9/2}{+\v/2}{blue1}
            \colourcirc{7}{+\v*6}{blue1}
            \colourcirc{1/2}{+\v/2}{blue2}
            \colourcirc{7/2}{-\v/2}{blue2}
            \colourcirc{5/2}{+\v*5/2}{blue4}
            \colourcirc{13/2}{+\v*5/2}{blue4}
            \colourcirc{2}{-\v}{red}
            \colourcirc{17/2}{+\v*11/2}{red}
            
            \draw(7/2,+\v*7/2)node[left]{\smfont$3^+$};
            \draw(11/2,+\v*3/2)node[right]{\smfont$3^+$};
            \draw(9/2,+\v/2)node[right]{\smfont$1$};
            \draw(7,+\v*6)node[above]{\smfont$1$};
            \draw(1/2,+\v/2)node[left]{\smfont$2$};
            \draw(7/2,-\v/2)node[right]{\smfont$2$};
            \draw(5/2,+\v*5/2)node[left]{\smfont$4$};
            \draw(13/2,+\v*5/2)node[right]{\smfont$4$};
            \draw(2,-\v)node[below]{\smfont$+$};
            \draw(17/2,+\v*11/2)node[right]{\smfont$+$};
            
            \draw(2,-5)node{$-x_c^3$};
            \draw(10,+\v*5/2)node{$=$};
            \draw(12,+\v*5/2)node{$0$};
        \end{scope}
    \end{tikzpicture}
}

\newcommand{\prismexample}[1]{
    \begin{tikzpicture}[x=#1,y=#1]
        \blueweight{1}{1}
        \blueweight{1}{3}
        \blueweight{2}{1}
        \blueweight{3}{1}
        \blueweight{3}{2}
        \blueweight{1}{14}
        \blueweight{2}{14}
        \blueweight{3}{11}
        \blueweight{3}{14}
        
        \draw[blue1 line](53/2,+\v*13/2)\hhor--++(-6,+\v*6)\dia\vver;
        \draw[blue1 line](51/2,+\v*11/2)\hhor--++(-6,+\v*6)\ddia\dia\vver;
        \draw[blue1 line](49/2,+\v*9/2)\hhor\ddia\ddia\hhor\ddia\ddia\ddia\dia\vver\ddia\ddia\vver;
        \draw[blue1 line](8,-\v*7)--++(-7,+\v*7)\vver\vver\vver\vver\dia;
        \draw[blue2 line](10,-\v*7)--++(-7,+\v*7)\vver\dia\hhor;
        \draw[blue3 line](12,-\v*7)--++(-7,+\v*7)\vver\vver\dia\ddia\hhor;
        \draw[red line](1/2,-\v/2)--++(6,0)--++(7,+\v*7)\vver\vver\rhhor\vver\rhhor\rhhor\vver;
        \draw[red line](3/2,-\v*3/2)--++(6,0)--++(7,+\v*7)\vver\vver\rhhor\vver\rhhor\rhhor\vver;
        \draw[red line](7/2,-\v*7/2)--++(6,0)--++(7,+\v*7)\vver\vver\vver\vver\rhhor\rhhor\vver;
        \draw[red line](13/2,-\v*13/2)--++(6,0)--++(14,+\v*14);
        
        \draw[gray](0,0)--++(7,-\v*7)--++(6,0)--++(14,+\v*14)--++(-7,+\v*7)--++(-6,0)--cycle;
        \draw[gray](0,0)--++(6,0)--++(7,-\v*7);
        \draw[gray](7,+\v*7)--++(6,0)--++(7,-\v*7);
        \draw[gray](6,0)--++(14,+\v*14);
        
        \colourcirc{15}{+\v*14}{blue1}
        \colourcirc{17}{+\v*14}{blue1}
        \colourcirc{19}{+\v*14}{blue1}
        \colourcirc{53/2}{+\v*13/2}{blue1}
        \colourcirc{51/2}{+\v*11/2}{blue1}
        \colourcirc{49/2}{+\v*9/2}{blue1}
        \colourcirc{9/2}{+\v*9/2}{blue1}
        \colourcirc{3/2}{+\v*3/2}{blue2}
        \colourcirc{7/2}{+\v*7/2}{blue3}
        \colourcirc{8}{-\v*7}{blue1}
        \colourcirc{10}{-\v*7}{blue2}
        \colourcirc{12}{-\v*7}{blue3}
        \colourcirc{1/2}{-\v/2}{red}
        \colourcirc{3/2}{-\v*3/2}{red}
        \colourcirc{7/2}{-\v*7/2}{red}
        \colourcirc{13/2}{-\v*13/2}{red}
        \colourcirc{53/2}{+\v*15/2}{red}
        \colourcirc{51/2}{+\v*17/2}{red}
        \colourcirc{49/2}{+\v*19/2}{red}
        \colourcirc{47/2}{+\v*21/2}{red}
        
        \draw(15,+\v*14)node[above]{\smfont$1$};
        \draw(17,+\v*14)node[above]{\smfont$1$};
        \draw(19,+\v*14)node[above]{\smfont$1$};
        \draw(53/2,+\v*13/2)node[right]{\smfont$1$};
        \draw(51/2,+\v*11/2)node[right]{\smfont$1$};
        \draw(49/2,+\v*9/2)node[right]{\smfont$1$};
        \draw(9/2,+\v*9/2)node[left]{\smfont$1$};
        \draw(3/2,+\v*3/2)node[left]{\smfont$2$};
        \draw(7/2,+\v*7/2)node[left]{\smfont$3$};
        \draw(8,-\v*7)node[below]{\smfont$1$};
        \draw(10,-\v*7)node[below]{\smfont$2$};
        \draw(12,-\v*7)node[below]{\smfont$3$};
        \draw(1/2,-\v/2)node[left]{\smfont$+$};
        \draw(3/2,-\v*3/2)node[left]{\smfont$+$};
        \draw(7/2,-\v*7/2)node[left]{\smfont$+$};
        \draw(13/2,-\v*13/2)node[left]{\smfont$+$};
        \draw(53/2,+\v*15/2)node[right]{\smfont$+$};
        \draw(51/2,+\v*17/2)node[right]{\smfont$+$};
        \draw(49/2,+\v*19/2)node[right]{\smfont$+$};
        \draw(47/2,+\v*21/2)node[right]{\smfont$+$};
        
        \draw[blue6](15/2,-\v*11/2)node{$\mathbf{A}$};
        \draw[blue6](17,\v)node{$\mathbf{B}$};
        \draw[blue6](19,+\v*3)node{$\mathbf{C}$};
        \draw[blue6](9,+\v*6)node{$\mathbf{D}$};
        \draw[blue6](11,+\v*8)node{$\mathbf{E}$};
        
        \begin{scope}[shift={(35,0)}]
            \blueweight{8}{-6}
            \blueweight{8}{-5}
            \blueweight{8}{-3}
            \blueweight{9}{-6}
            \blueweight{9}{-5}
            \blueweight{10}{-6}
            \blueweight{10}{-5}
            \blueweight{10}{-4}
            \blueweight{10}{-3}
            
            \draw[blue1 line](53/2,+\v*13/2)--++(-15/2,+\v*15/2);
            \draw[blue1 line](51/2,+\v*11/2)--++(-17/2,+\v*17/2);
            \draw[blue1 line](49/2,+\v*9/2)--++(-19/2,+\v*19/2);
            \draw[blue1 line](8,-\v*7)\vver\vver\vver\vver\dia\hhor\ddia\rel\lel--++(-4,+\v*4);
            \draw[blue2 line](10,-\v*7)\vver\vver\dia\hhor\hhor--++(-6,+\v*6);
            \draw[blue3 line](12,-\v*7)\vver\vver\vver\vver\dia\ddia\ddia\hhor\hhor\hhor--++(-4,+\v*4);
            \draw[red line](1/2,-\v/2)\vver\rhhor\vver\rhhor\rhhor\vver\vver--++(7,+\v*7)--++(6,0);
            \draw[red line](3/2,-\v*3/2)\vver\rhhor\vver\rhhor\rhhor\vver\vver--++(7,+\v*7)--++(6,0);
            \draw[red line](7/2,-\v*7/2)\vver\rhhor\vver\rhhor\vver\vver\vver--++(7,+\v*7)--++(6,0);
            \draw[red line](13/2,-\v*13/2)--++(14,+\v*14)--++(6,0);
            
            \draw[gray](0,0)--++(7,-\v*7)--++(6,0)--++(14,+\v*14)--++(-7,+\v*7)--++(-6,0)--cycle;
            \draw[gray](7,+\v*7)--++(7,-\v*7)--++(6,0);
            \draw[gray](14,+\v*14)--++(7,-\v*7)--++(6,0);
            \draw[gray](7,-\v*7)--++(14,+\v*14);
            
            \colourcirc{15}{+\v*14}{blue1}
            \colourcirc{17}{+\v*14}{blue1}
            \colourcirc{19}{+\v*14}{blue1}
            \colourcirc{53/2}{+\v*13/2}{blue1}
            \colourcirc{51/2}{+\v*11/2}{blue1}
            \colourcirc{49/2}{+\v*9/2}{blue1}
            \colourcirc{9/2}{+\v*9/2}{blue1}
            \colourcirc{3/2}{+\v*3/2}{blue2}
            \colourcirc{7/2}{+\v*7/2}{blue3}
            \colourcirc{8}{-\v*7}{blue1}
            \colourcirc{10}{-\v*7}{blue2}
            \colourcirc{12}{-\v*7}{blue3}
            \colourcirc{1/2}{-\v/2}{red}
            \colourcirc{3/2}{-\v*3/2}{red}
            \colourcirc{7/2}{-\v*7/2}{red}
            \colourcirc{13/2}{-\v*13/2}{red}
            \colourcirc{53/2}{+\v*15/2}{red}
            \colourcirc{51/2}{+\v*17/2}{red}
            \colourcirc{49/2}{+\v*19/2}{red}
            \colourcirc{47/2}{+\v*21/2}{red}
            
            \draw(15,+\v*14)node[above]{\smfont$1$};
            \draw(17,+\v*14)node[above]{\smfont$1$};
            \draw(19,+\v*14)node[above]{\smfont$1$};
            \draw(53/2,+\v*13/2)node[right]{\smfont$1$};
            \draw(51/2,+\v*11/2)node[right]{\smfont$1$};
            \draw(49/2,+\v*9/2)node[right]{\smfont$1$};
            \draw(9/2,+\v*9/2)node[left]{\smfont$1$};
            \draw(3/2,+\v*3/2)node[left]{\smfont$2$};
            \draw(7/2,+\v*7/2)node[left]{\smfont$3$};
            \draw(8,-\v*7)node[below]{\smfont$1$};
            \draw(10,-\v*7)node[below]{\smfont$2$};
            \draw(12,-\v*7)node[below]{\smfont$3$};
            \draw(1/2,-\v/2)node[left]{\smfont$+$};
            \draw(3/2,-\v*3/2)node[left]{\smfont$+$};
            \draw(7/2,-\v*7/2)node[left]{\smfont$+$};
            \draw(13/2,-\v*13/2)node[left]{\smfont$+$};
            \draw(53/2,+\v*15/2)node[right]{\smfont$+$};
            \draw(51/2,+\v*17/2)node[right]{\smfont$+$};
            \draw(49/2,+\v*19/2)node[right]{\smfont$+$};
            \draw(47/2,+\v*21/2)node[right]{\smfont$+$};
            
            \draw[blue6](15/2,+\v*9/2)node{$\mathbf{K}$};
            \draw[blue6](19/2,+\v*13/2)node{$\mathbf{I}$};
            \draw[blue6](17,-\v)node{$\mathbf{J}$};
            \draw[blue6](19,+\v)node{$\mathbf{G}$};
            \draw[blue6](19,+\v*13)node{$\mathbf{H}$};
        \end{scope}
    \end{tikzpicture}
}

\newcommand{\LHSeq}[1]{
    \begin{tikzpicture}[x=#1,y=#1]
        \filldraw[gray fill](0,0)--++(3,-\v*3)--++(4,0)--++(6,+\v*6)--++(-3,+\v*3)--++(-4,0)--cycle;
        \draw[gray](0,0)--++(4,0)--++(3,-\v*3);
        \draw[gray](3,+\v*3)--++(4,0)--++(3,-\v*3);
        \draw[gray](4,0)--++(6,+\v*6);
        \perparrow{0}{0}{3}{\vx*3}{-1}{left}{$\al_\A$}
        \perparrow{3}{-\vx*3}{0}{0}{-1}{left}{$\la^+$}
        \perparrow{3}{-\vx*3}{7}{-\vx*3}{1}{below}{\smfont$1$ $2$ $3$ $\cdots$ $n$}
        \perparrow{6}{\vx*6}{10}{\vx*6}{-1}{above}{$\bacirc^n$}
        \perparrow{13}{\vx*3}{10}{\vx*6}{1}{right}{$\rcirc^k\wcirc^n$}
        \perparrow{10}{0}{13}{\vx*3}{1}{right}{$\wcirc^k\bacirc^n$}
        
        \draw(7/2,-\v*3/2)node{$1$};
        \draw(7,0)node{$1$};
        \draw(10,+\v*3)node{$1$};
        
        \draw(79/4,+\v*3/2)node{$=$};
        
        \begin{scope}[shift={(25,-\v*3/2)}]
            \filldraw[gray fill](0,0)--++(4,0)--++(6,+\v*6)--++(-4,0)--cycle;
            \draw[gray](3,+\v*3)--++(4,0);
            \perparrow{0}{0}{3}{\vx*3}{-1}{left}{$\al_\A$}
            \perparrow{0}{0}{4}{0}{1}{below}{\smfont$1$ $2$ $3$ $\cdots$ $n$}
            \perparrow{6}{\vx*6}{10}{\vx*6}{-1}{above}{$\bacirc^n$}
            \perparrow{10}{\vx*6}{7}{\vx*3}{-1}{right}{$\la^-$}
            
            \draw(13/2,+\v*9/2)node{$s_\la$};
            \draw(7/2,+\v*3/2)node{$\A_\al$};
        \end{scope}
        
        \draw(38,+\v*3/2)node{$=$};
        \draw(40,+\v*3/2)node[right]{$s_\la(x)\A_\al(x)$};
    \end{tikzpicture}
}

\newcommand{\RHSeq}[1]{
    \begin{tikzpicture}[x=#1,y=#1]
        \filldraw[gray fill](0,0)--++(3,-\v*3)--++(4,0)--++(6,+\v*6)--++(-3,+\v*3)--++(-4,0)--cycle;
        \draw[gray](3,+\v*3)--++(3,-\v*3)--++(4,0);
        \draw[gray](6,+\v*6)--++(3,-\v*3)--++(4,0);
        \draw[gray](3,-\v*3)--++(6,+\v*6);
        \perparrow{0}{0}{3}{\vx*3}{-1}{left}{$\al_\A$}
        \perparrow{3}{-\vx*3}{0}{0}{-1}{left}{$\la^+$}
        \perparrow{3}{-\vx*3}{7}{-\vx*3}{1}{below}{\smfont$1$ $2$ $3$ $\cdots$ $n$}
        \perparrow{6}{\vx*6}{10}{\vx*6}{-1}{above}{$\bacirc^n$}
        \perparrow{13}{\vx*3}{10}{\vx*6}{1}{right}{$\rcirc^k\wcirc^n$}
        \perparrow{10}{0}{13}{\vx*3}{1}{right}{$\wcirc^k\bacirc^n$}
        
        \draw(6,+\v*3)node{$1$};
        \draw(19/2,+\v*9/2)node{$1$};
        \draw(19/2,+\v*3/2)node{$1$};
        
        \draw(79/4,+\v*3/2)node{$=$};
        \begin{scope}[shift={(24,+\v*3/2)}]
            \draw(0,0)node{$\displaystyle\sum_\be$};
            \begin{scope}[shift={(3,0)}]
                \filldraw[gray fill](0,0)--++(3,-\v*3)--++(4,0)--++(3,+\v*3)--++(-4,0)--++(-3,+\v*3)--cycle;
                \draw[gray](3,-\v*3)--++(3,+\v*3);
                \perparrow{0}{0}{3}{\vx*3}{-1}{left}{$\al_\A$}
                \perparrow{3}{-\vx*3}{0}{0}{-1}{left}{$\la^+$}
                \perparrow{3}{-\vx*3}{7}{-\vx*3}{1}{below}{\smfont$1$ $2$ $3$ $\cdots$ $n$}
                \perparrow{6}{0}{3}{\vx*3}{1}{right}{$\rcirc^k\wcirc^n$}
                
                \draw(13/2,-\v*3/2)node{$\A_\be$};
            \end{scope}
        \end{scope}
        
        \begin{scope}[shift={(45,+\v*3/2)}]
            \draw(0,0)node{$\displaystyle\sum_\be$};
            \begin{scope}[shift={(3,0)}]
                \filldraw[gray fill](0,0)--++(3,-\v*3)--++(3,+\v*3)--++(-3,+\v*3)--cycle;
                \perparrow{0}{0}{3}{\vx*3}{-1}{left}{$\al_\A$}
                \perparrow{3}{-\vx*3}{0}{0}{-1}{left}{$\la^+$}
                \perparrow{6}{0}{3}{\vx*3}{1}{right}{$\rcirc^k\wcirc^n$}
                \perparrow{3}{-\vx*3}{6}{0}{1}{right}{$\be_\A$}
                
                \draw(3,0)node{$c_{\la,\al}^\be$};
                \draw(7,0)node[right]{$\A_\be(x)$};
            \end{scope}
        \end{scope}
        
        \draw(41,+\v*3/2)node{$=$};
    \end{tikzpicture}
}

%%%%%%%%%%%%%%%%% Document begins %%%%%%%%%%%%%%%%%
\begin{document}
\maketitle

\section{Introduction}
Demazure atoms, also called standard bases, are a family of non-symmetric polynomials indexed by weak compositions. Demazure characters, also called key polynomials, are a closely related family of polynomials which are also indexed by weak compositions; they may be written as a sum of Demazure atoms. Denote the Demazure atom and character on a weak composition $\al=(\al_1,\ldots,\al_n)$ in the variables $x=(x_1,\ldots,x_n)$ by $\A_\al(x)$ and $\K_\al(x)$, respectively. The set of Demazure atoms or characters over all weak compositions of length $n$ are a basis for $\Z[x_1,\ldots,x_n]$. It is known that the products of a Schur polynomial~$s_\la(x)$ and a Demazure polynomial have positive expansions:
\begin{align*}
    s_\la(x)\A_\al(x) &= \sum_\be c_{\la,\al}^\be\A_\be(x), \\
    s_\la(x)\K_\al(x) &= \sum_\be d_{\la,\al}^\be\K_\be(x),
\end{align*}
where the structure coefficients $c_{\la,\al}^\be$ and $d_{\la,\al}^\be$ are non-negative integers.

In \cite{HLMW11}, Haglund, Luoto, Mason and van Willigenburg give formulas to calculate $c_{\la,\al}^\be$ and $d_{\la,\al}^\be$ in terms of skyline tableaux. Here, we use the theory of integrable vertex models to derive alternative rules where the structure coefficients are calculated as the number of fillings of ``diamond'' vertex models. We emulate the technique developed in \cite{Z09} where Zinn-Justin reproves the puzzle rule of \cite{KT03,KTW03} for the product of two double Schur polynomials. Wheeler and Zinn-Justin later use the same technique to find structure coefficients for double Grothendieck polynomials \cite{WZ19}. Knutson and Zinn-Justin also employ techniques from integrability in a series of papers computing puzzle rules for products of Schubert classes in $d$-step flag varieties (for $d\leq4$) \cite{KZ20,KZ21,KZ23}.

The proofs in \cite{WZ19,Z09} are completely combinatorial, gluing vertex models together in two different ways and showing both are equivalent. One side of the equation is manifestly a product and the other side is manifestly a summation. Applying a Yang--Baxter equation to the model for the product transforms it into the model for the summation. Both of these results concern products of symmetric polynomials, whereas our results involve the non-symmetric Demazure polynomials. Our results follow from a variant of the Yang--Baxter equation stated in \Cref{lma.column}.

In this extended abstract, we define Demazure atoms and characters as the partition function of a vertex model. Our conventions for atoms match those of Mason \cite{M09} who defines $\A_\al(x)$ in terms of semi-skyline augmented fillings; reversing the order of the composition and basement in Mason's diagrams yields $\K_\al(x)$. Our model is derived from setting $q=t=0$ in Borodin and Wheeler's \cite{BW22} vertex model for permuted basement non-symmetric Macdonald polynomials $f^\rho_\al(x;q,t)$, where $\rho$ is a permutation. In our conventions, we have $\A_\al(x) = f^\id_{(\al_n,\ldots,\al_1)}(x_n,\ldots,x_1;0,0)$ and $\K_\al(x)=f^{w_0}_\al(x_n,\ldots,x_1;0,0)$. Significant modifications are made to make the vertices compatible with the Schur polynomial model in \cite{Z09}. Our model for $\A_\al(x)$ bears more resemblance to that of Brubaker, Buciumas, Bump and Gustafsson \cite{BBBG21} with differing weights and boundary.

A benefit of this approach is that vertex models may be developed independently and then fit into this framework, allowing one to test rules assuming an analogue of \Cref{lma.column} holds. Our results are suggestive of further applications such as extensions to the Grothendieck model in \cite{WZ19}.

\section{Vertex models for Schur and Demazure polynomials}
A weak composition $\al=(\al_1,\ldots,\al_n)$ is a sequence of non-negative integers. The integer $\al_i$ is the part of $\al$ at index $i$ and the length of $\al$ is its number of parts; the largest part in $\al$ is denoted $\max(\al)$. A partition $\la=(\la_1,\ldots,\la_n)$ is a weak composition sorted in descending order. Throughout this extended abstract, $\al$ and $\be$ are weak compositions, $\la$ is a partition and all weak compositions have length $n$.

We describe two strings, $\al_\A$ and $\al_\K$, that re-encode a weak composition $\al$. Let $\la=\sort(\al)$ be the partition with the same parts as $\al$ sorted in descending order. Enclose the Young diagram of $\la$ between the top left corner of a rectangle and a North-East lattice path as depicted in \Cref{ex.compositions}. East steps are labelled $0$ and North steps are labelled with the integers $1$ through $n$ so that $i$ occurs after precisely $\al_i$ East steps. If North steps occur in the same vertical, then moving North, we label them in descending order for $\al_\A$ and ascending order for $\al_K$. We then obtain either string by reading labels off the lattice path from South-West to North-East.

We also specify two strings, $\la^-$ and $\la^+$, that re-encode a partition $\la$. For $\la^-$, East steps are labelled $0$ and North steps are labelled $1$. For $\la^+$, East steps are labelled with the symbol $+$ and North steps are labelled $0$. Strings are read off the lattice path as before.

\begin{ex}\label{ex.compositions}
    We depict our labelling procedure below with $\al=(0,3,0,1,3)$ and $\la=\sort(\al)=(3,3,1,0,0)$, assigning each label a colour as a visual aid. Darker shades of blue correspond to larger integers.
    \begin{center}
        \composition{\ascale}
    \end{center}
    Reading the labels from South-West to North-East produces the strings:
    \begin{align*}
        \al_\A &= \bccirc \ \bacirc \ \wcirc \ \bdcirc \ \wcirc \ \wcirc \ \becirc \ \bbcirc = 31040052 \\
        \al_\K &= \bacirc \ \bccirc \ \wcirc \ \bdcirc \ \wcirc \ \wcirc \ \bbcirc \ \becirc = 13040025 \\
        \la^- &= \bacirc \ \bacirc \ \wcirc \ \bacirc \ \wcirc \ \wcirc \ \bacirc \ \bacirc = 11010011 \\
        \la^+ &= \wcirc \ \wcirc \ \rcirc \ \wcirc \ \rcirc \ \rcirc \ \wcirc \ \wcirc = 00\text{+}0\text{++}00
    \end{align*}
\end{ex}

The model for Demazure atoms consists of a lattice filled with the tiles in \Cref{fig.tiles}. This is a coloured vertex model where the tiles are ``vertices'' much like those in \cite{BBBG21}. Labels of tiles must match along adjacent edges and along the boundary of the lattice. We label the left boundary with the string $\al_\A$ and label the bottom edges~$1$ through $n$ from left to right; the other boundary edges are labelled $0$. All tiles in the model have weight $1$ except for the tiles of weight $x_c$ where $c$ is the column number where the tile occurs; columns are numbered $1$ through $n$ from left to right. A filling's weight is the product of its tile weights and the sum of all filling weights is called the partition function.

\pagebreak
The partition function of this vertex model is the Demazure atom on~$n$ variables, depicted diagrammatically:

\begin{figure}
    \centering
    \demazuretiles{\ascale}
    \caption{Tiles for the Demazure atom vertex model where $1\leq i<j$. The rightmost tile has weight $x_c$ where $c$ is the column number where the tile occurs.}
    \label{fig.tiles}
\end{figure}

\begin{center}
    \atommodel{\bscale}
\end{center}

\begin{ex}
    Let $\al=(0,2,2,0)$, so that $\al_\A=410032=\bdcirc \ \bacirc \ \wcirc \ \wcirc \ \bccirc \ \bbcirc$ labels the left boundary. There are three fillings of the atom model, showing $\A_\al(x_1,x_2,x_3,x_4)=x_1x_2^2x_3+x_1x_2x_3^2+x_2^2x_3^2$.
    
    \begin{center}
        \atomexample{\bscale}
    \end{center}
\end{ex}

Zinn-Justin considers a similar model for Schur polynomials in \cite{Z09} which may be thought of as the ``uncoloured'' version of the model for atoms. Using the same tiles with only colour $1$, we label the left boundary with the string $\la^-$ and label all bottom edges with $1$, which we denote as $\bacirc^n=1^n$:

\begin{center}
    \schurmodel{\bscale}
\end{center}

\begin{ex}
    Let $\la=(2,2,1)$. There are three fillings of the Schur model, showing that $s_\la(x_1,x_2,x_3)=x_1^2x_2^2x_3+x_1^2x_2x_3^2+x_1x_2^2x_3^2$.
    
    \begin{center}
        \schurexample{\bscale}
    \end{center}
\end{ex}

Lastly, as noted in \cite{BBBG21}, Remark 4.5, the model for Demazure characters uses the same tiles rotated 180 degrees, which only alters the fifth tile in \Cref{fig.tiles}. We can obtain Demazure characters as a partition function for the following vertex model filled with these new tiles:

\begin{center}
    \charmodel{\bscale}
\end{center}

\section{Vertex models for $c_{\la,\al}^\be$ and $d_{\la,\al}^\be$}
In this section we build two ``diamond'' vertex models filled with the tiles below where $1\leq i<j<k$. If a blue line of shade $b$ shares an edge with a red line, the edge is labelled $b^+$. Two shades of blue $a$ and $b$ with $a<b$ may share an edge labelled $ab$. All tiles have weight $1$.
\begin{center}
    \diamonds{\ascale}
\end{center}
Further, we do not allow two adjacent tiles to form an internal banned rhombus as depicted in \Cref{fig.banned}. These restrictions are still local and can be imposed with additional labels, but we exclude them to avoid clutter. We may now state our theorem.

\begin{figure}
    \begin{subfigure}{0.45\textwidth}
        \begin{center}
            \banneda{\ascale}
        \end{center}
        \caption{Banned rhombi for atom model.}\label{fig.banneda}
    \end{subfigure}
    \begin{subfigure}{0.45\textwidth}
        \begin{center}
            \bannedb{\ascale}
        \end{center}
        \caption{Banned rhombi for character model.}\label{fig.bannedb}
    \end{subfigure}
    \caption{Restrictions on adjacent diamond tiles where $1\leq i<j$.}\label{fig.banned}
\end{figure}

\begin{thm}\label{thm.diamonds}
    The structure coefficients $c_{\la,\al}^\be$ and $d_{\la,\al}^\be$ respectively count the number of fillings of the vertex models
    \begin{center}
        \producttheorem{\bscale}
    \end{center}
    where $k=\max(\be)$ and the restrictions in \Cref{fig.banneda} and \Cref{fig.bannedb} apply respectively within each model.
\end{thm}

\begin{ex}
    For $\al=(1,3,1,0)$, $\la=(3,1,0,0)$ and $\be=(1,4,3,1)$, we have that $k=\max(\be)=4$. There are two fillings of the corresponding Schur--atom model and thus $c_{\la,\al}^\be=2$.
    \begin{center}
        \atomdiamondex{\cscale}
    \end{center}
\end{ex}

We call the vertex model for $c_{\la,\al}^\be$ the Schur--atom model and the vertex model for $d_{\la,\al}^\be$ the Schur--character model. Recall that we assume $\al$, $\be$ and $\la$ all have length $n$, but we may append zeros to make their lengths match if needed. Similarly, we may append zeros to the end of the strings $\al_\A$, $\al_\K$ and $\la^-$ and append $+$ symbols to the end of $\la^+$ so that these strings all have length $n+k$ and fit in the diagram.

\section{Proof of \Cref{thm.diamonds}}\label{sec.proof}
In this section, we only explain the proof of the Schur--atom model, but the proof of the Schur--character model is analogous. In \Cref{fig.alltiles}, we have tiles in three orientations with a new orientation in the second row containing a tile of weight $-x_c$. We call the tiles in the first row right-sheared and the tiles in the second row left-sheared. We again depict vertex models with grey diagrams where tiles must have the same orientation as the grey region they are placed within. In our configurations, right- and left-sheared tiles are in the same column, say $c$, if one is on top of the other; hence these tiles may have weight $x_c$ or $-x_c$, respectively.

Note red lines may now share the same path as blue lines; these tiles facilitate the proof and do not appear in the final Schur--atom model. We still ban rhombi between diamond tiles as in \Cref{fig.banneda}, but there are no such restrictions between tiles that are not both diamonds. The key to the proof is the following lemma equating columns of tiles.

\begin{lem}\label{lma.column}
    Let $q_1,\ldots,q_m$, $r$, $s$, $t_1,\ldots,t_m$, $u$ and $v$ be fixed labels where $u$ and $r$ are in $\{\wcirc,\rcirc\}=\{0,+\}$. The following column configurations have the same weight:
    \begin{center}
        \columnlemma{\ascale}
    \end{center}
\end{lem}
\begin{proof}
    Proving this lemma is the main difficulty of this work. The proof is by induction with manual checking of several edge cases.
\end{proof}

\begin{rmk}\label{rmk.YBE}
    In \cite{WZ19,Z09} the authors proceed similarly with a Yang--Baxter equation that equates unit hexagons with unrestricted boundaries. In contrast, our equation requires that we restrict the labels on the South-West and North-East edges, suggesting a more general framework to explore.
\end{rmk}

\begin{figure}
    \centering
    \xtiles{\ascale}
    \ytiles{\ascale}
    \ztiles{\ascale}
    \caption{The full set of tiles where $1\leq i<j<k$.}\label{fig.alltiles}
\end{figure}

\begin{ex}
    We consider two examples of \Cref{lma.column}. In the first example, both sides of the equation have weight $x_c$. In the second example, there are two ways to fill the column on the left-hand side which sum to a weight of $0$ and there is no way to fill the column on the right-hand side.
    \begin{center}
        \columnexamples{\bscale}
    \end{center}
\end{ex}

Note that rotating columns $180$ degrees gives an analogous column lemma used to prove correctness of the Schur--character model. Interpreting the next lemma proves our result.

\begin{lem}\label{lma.prisms}
    Set $k=\max(\al)+\max(\la)$. The configurations below have the same weight:
    \begin{center}
        \prisms{\ascale}
    \end{center}
\end{lem}
\begin{proof}
    Repeatedly applying \Cref{lma.column} to internal columns transforms the left-hand side into the right-hand side. First apply the lemma to the column of length $2(k+n)$ containing the left-sheared tile most to the North-East and then repeat with the next left-sheared tile, moving right-to-left and top-to-bottom. The boundary conditions ensure that the South-West and North-East labels of columns we equate are always in $\{\wcirc,\rcirc\}$ at every stage in this process.
\end{proof}

The proof now follows from examining both sides of the equation in \Cref{lma.prisms}. In short, the left-hand side is manifestly the product $s_\la(x)\A_\al(x)$ and the right-hand side is manifestly the summation $\sum_\be c_{\la,\al}^\be\A_\al(x)$ where $c_{\la,\al}^\be$ counts fillings of the Schur--atom model.

\begin{figure}
    \begin{center}
        \prismexample{\dscale}
    \end{center}
    \caption{Two fillings of weight $x_1^3x_2^2x_3^4$ from the configurations in \Cref{lma.prisms} where $\la=(2,2,1)$ and $\al=(2,1,2)$, so that $n=3$ and $k=4$. Regions are labelled to facilitate exposition.}\label{fig.prisms}
\end{figure}

\begin{proof}[Proof of \Cref{thm.diamonds}]
    We examine both sides of the equation in \Cref{lma.prisms}, which is better illustrated with the example fillings in \Cref{fig.prisms}. Within region \BB{A}, all red lines must move East and blue lines must move North-West. Those red lines must move straight North-East through \BB{B}, transmitting the string $\la^+$ to the South-West boundary of \BB{C}. From Lemma 9 in \cite{Z09}, there is only one way to fill \BB{C}, which forces the shared boundary between \BB{C} and \BB{E} to be the string $\la^-$ upside-down. Thus, regions \BB{A}, \BB{B} and \BB{C} have weight $1$.
    
    Next, we recognize region \BB{D} as our vertex model for the Demazure atom $\A_\al(x)$. From the previous paragraph, we have that $\la^-$ is upside-down on the South-East boundary of \BB{E}. Rotating region \BB{E} by $180$ degrees, we see that it is the vertex model for $s_\la(x)$ with the variables in reverse order; since $s_\la(x)$ is symmetric, the weight of the left-hand side is the product $s_\la(x)\A_\al(x)$. We summarize pictorially:
    \begin{center}
        \LHSeq{\cscale}
    \end{center}
    
    Considering the right-hand side, we have that regions \BB{G}, \BB{H} and \BB{I} always have weight $1$ and follow the same pattern as in \Cref{fig.prisms}, transmitting the string $\rcirc^k\wcirc^n$ to the North-East boundary of region \BB{K}. Within region \BB{J}, all blue lines must exit the North-West boundary if they are to reach the North-West boundary of \BB{K}. This follows from our choice of $k=\max(\la)+\max(\al)$. The blue lines then travel through the boundary between \BB{J} and \BB{K}, varying over strings $\be_\A$ that encode weak compositions. Fixing a particular $\be_\A$ along this boundary, we recognize region \BB{J} as $\A_\be(x)$ and region \BB{K} as the Schur--atom model from \Cref{thm.diamonds}. Thus, the right-hand side is a summation over compositions $\be$ where each summand is a product of our Schur--atom model and $\A_\be(x)$. We give another pictorial summary:
    \begin{center}
        \RHSeq{\cscale}
    \end{center}
    By \Cref{lma.prisms}, we can equate both sides, completing the proof. As a final note, we used that $k=\max(\la)+\max(\al)$ in our proof, but when considering the filling of a particular diamond where $\be$ is given, it suffices to set $k=\max(\be)$ as we do in \Cref{thm.diamonds}.
\end{proof}
    
\acknowledgements{
    I would like to thank my PhD advisor Kevin Purbhoo for his comments on this extended abstract and all his constructive feedback on this research in general.
}

\printbibliography
\end{document}