% LaTeX style file for define newannimal
% 2016-1-6
% NUmata yacehide. nu+y@math.shinshu-u.ac.jp


\newcommand{\hugesum@nous@thetqftanimal}{\mathop{\text{\Huge$\sum$}}\limits}
\newcommand{\hugeprod@nous@thetqftanimal}{\mathop{\text{\Huge$\prod$}}\limits}
\newcommand{\gen@face@nous@thetqftanimal}[2]{\text{\tiny${\textstyle\int\limits^{#1}_{#2}}$}}
\newcommand{\innerface@nous@thetqftanimal}{\gen@face@nous@thetqftanimal{\otimes\ \otimes}{dx\,dy\,dz}}
\newcommand{\foot@A@nous@thetqftanimal}{\bigoplus\ \ \bigoplus}
\newcommand{\foot@B@nous@thetqftanimal}{\bigotimes\ \ \bigotimes}
\newcommand{\gen@annimal@thetqftanimal}[5]{\raisebox{0.45ex}{#5}
{\displaystyle\hugesum@nous@thetqftanimal^{#4}_{#3}\llap{\raisebox{0.9ex}{#1}}}{\atop\displaystyle\hugeprod@nous@thetqftanimal_{#2}}}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% front end commands

% generic animal
\newcommand{\genannimal}[5][]{\gen@annimal@thetqftanimal{#2}{#3}{#4}{#5}{#1}}
% usage
% \genannimal[fire]{face}{foot}{beard}{ear}
% Example
%  \genannimal[>>>]{\thetqftface}{\thetqftfootA}{n=1}{\infty}

\newcommand{\genannimalface}[2]{\gen@face@nous@thetqftanimal{#1}{#2}}
% usage
% \genannimalface{eye}{mouth}
% Example
% \genannimal{\otimes\ \otimes}{dx\,dy\,dz}


% defaultparts
\newcommand{\thetqftface}{\innerface@nous@thetqftanimal}
\newcommand{\thetqftfootB}{\foot@B@nous@thetqftanimal}
\newcommand{\thetqftfootA}{\foot@A@nous@thetqftanimal}

% The newanimal introduced by @the_tqft
\newcommand{\thetqftanimal}[1][]{\genannimal[#1]{\thetqftface}{\thetqftfootA}{n=1}{\infty}}
\newcommand{\thetqftanimalx}[1][]{\genannimal[#1]{\thetqftface}{\thetqftfootB}{n=1}{\infty}}
% usage
% \thetqftanimal[fire]
% \thetqftanimalx[fire]

