<html><head><meta name="color-scheme" content="light dark"></head><body><pre style="word-wrap: break-word; white-space: pre-wrap;">
\newcounter{temperature}
\newcounter{cycle}
\setcounter{cycle}{\month}
  \roundUp{cycle}

\newcounter{fenestraYear}
\setcounter{fenestraYear}{3}
\setcounter{fenestraYear}{\year}
\multiply\value{fenestraYear}by 4
\newcounter{fenestraDay}

\newcommand\cycleDesc{}

\newcommand\setCycle[2]{%
  \setcounter{cycle}{#1}% Month
  \ifnum\value{cycle}&gt;6%
    \addtocounter{cycle}{-6}% October goes from '10' to '4'
  \fi%
  \ifnum\value{cycle}&gt;3%
    \addtocounter{cycle}{-3}% '4' becomes 1.
  \fi%
  \multiply\value{cycle} by 2%
  \ifnum#2&gt;15%
    \addtocounter{cycle}{-1}%
  \else%
    \addtocounter{cycle}{-2}%
  \fi%
  \setcounter{fenestraDay}{\day}%
  \ifnum\value{fenestraDay}&gt;15%
    \addtocounter{fenestraDay}{-15}%
  \fi%
  \multiply\value{fenestraDay}by 4%
  \addtocounter{fenestraDay}{0}%
  \setTemperature%
}

%%% State a Cycle's name.

\newcommand\showCycle[1][\value{cycle}]{%
  \ifcase#1%
    \glsentrytext{cOne}%
    \renewcommand\cycleDesc{\glsentrydesc{cOne}}%
  \or%
    \glsentrytext{cTwo}%
    \renewcommand\cycleDesc{\glsentrydesc{cTwo}}%
  \or%
    \glsentrytext{cThree}%
    \renewcommand\cycleDesc{\glsentrydesc{cThree}}%
  \or%
    \glsentrytext{cFour}%
    \renewcommand\cycleDesc{\glsentrydesc{cFour}}%
  \or%
    \glsentrytext{cFive}%
    \renewcommand\cycleDesc{\glsentrydesc{cFive}}%
  \else
    \glsentrytext{cSix}%
    \renewcommand\cycleDesc{\glsentrydesc{cSix}}%
  \fi%
}

\newcommand\setTemperature{
  \ifcase\value{cycle}%
    \setcounter{temperature}{1}%
  \or%
    \setcounter{temperature}{0}%
  \or%
    \setcounter{temperature}{1}%
  \or%
    \setcounter{temperature}{2}%
  \or%
    \setcounter{temperature}{3}%
  \else
    \setcounter{temperature}{2}%
  \fi%
}

\newcommand\showTemperature{%
  \ifcase\value{temperature}%
    frigid%
  \or%
    mild%
  \or%
    warm%
  \else%
    scorching%
  \fi%
}

\newcommand\showInterval[1]{%
  \ifcase#1%
    \gls{morning}%
  \or%
    \gls{afternoon}%
  \or%
    \gls{evening}%
  \else%
    \gls{night}%
  \fi%
}

\newcommand\trackMonth[1][track]{%
  \ifcase\value{#1}\or%
    January\or February\or March\or April\or May\or June\or%
    July\or August\or September\or October\or November\else December\fi%
}


\newcounter{ainumarPosition}
\newcounter{fenestraPosition}

\newcommand\setPlanetPositions[2]{
  \setCycle{#1}{#2}
  \setcounter{ainumarPosition}{\value{cycle}}
  \addtocounter{ainumarPosition}{-1}
  \multiply\value{ainumarPosition}by 60
  \setcounter{diceNo}{#2}% get day offset
  \ifnum\value{diceNo}&gt;15%
    \addtocounter{diceNo}{-15}%
  \fi%
  \multiply\value{diceNo}by 2%
  \addtocounter{ainumarPosition}{\value{diceNo}}
  \setcounter{fenestraPosition}{\value{ainumarPosition}}
  \setcounter{enc}{\value{cycle}}
  \addtocounter{enc}{-1}
  \multiply\value{enc}by 60
  \addtocounter{enc}{-15}% Allow room for day to move things a bit.
  \addtocounter{fenestraPosition}{\value{enc}}
  \addtocounter{fenestraPosition}{\value{diceNo}}
}

\newcommand\orrery[1][\month/\day]{
  \begin{tikzpicture}
    \coordinate (S) at (0,0);
    \draw[\pageSideColor] (S) circle (3.1);% Orbit
    \fill[\pageSideColor] (S)  circle (30pt);
    \foreach \m/\d in {#1}{
      \setPlanetPositions{\m}{\d}
      \coordinate (A) at (\arabic{ainumarPosition}:3);
      \path (A) +(\arabic{fenestraPosition}:1) coordinate (F);
      \draw[\pageSideColor] (S) -- (A) -- (F);
      \draw[\pageSideColor] (A) circle (1);% Suborbit
      \fill[\pageSideColor] (A.south)  circle (3pt);
      \fill[\pageSideColor] (F.east) circle (1pt);
      \addtocounter{fenestraPosition}{-90}
      \coordinate [label={\rotatebox{\value{fenestraPosition}}{\scshape\Large\showCycle}}] (FN) at (F)+(0,0);
    }
    %
  \end{tikzpicture}
}


\setCycle{\month}{\day}
</pre></body></html>