diff --git a/Advanced/Lattices/main.tex b/Advanced/Lattices/main.tex index d3b6ff4..2b50fa9 100755 --- a/Advanced/Lattices/main.tex +++ b/Advanced/Lattices/main.tex @@ -5,6 +5,8 @@ singlenumbering ]{../../resources/ormc_handout} +\usepackage{ifthen} + %\usepackage{lua-visual-debug} \renewcommand{\arraystretch}{1.2} \begin{document} diff --git a/Advanced/Lattices/orchard.png b/Advanced/Lattices/orchard.png deleted file mode 100644 index 97f8e19..0000000 Binary files a/Advanced/Lattices/orchard.png and /dev/null differ diff --git a/Advanced/Lattices/parts/2 orchard.tex b/Advanced/Lattices/parts/2 orchard.tex index ecc3949..afe8af5 100644 --- a/Advanced/Lattices/parts/2 orchard.tex +++ b/Advanced/Lattices/parts/2 orchard.tex @@ -2,10 +2,87 @@ You are standing in the center of a circular orchard of integer radius R. A tree was planted each integer lattice point, and each has grown to the same radius $r$. If the radius is small enough, you will have a clear line of sight through the orchard in certain directions. If the radius is too large, there is no line of sight through the orchard in any direction. See the figure below: -\begin{center} - \includegraphics[width=0.5\linewidth]{orchard.png} -\end{center} +\begin{center} + \hfill + \begin{tikzpicture}[scale=0.4] + \draw[color=black, very thick] (0,0) circle (5); + + \draw[fill=black] (0,0) circle (0.2); + \draw [->, very thick](0,0) -- (0.7, 0.7); + \draw [->, very thick](0,0) -- (-0.7, 0.7); + + \foreach \x in {-4, ..., 4} { + \foreach \y in {-4, ..., 4} { + \ifthenelse{ + % Remove center + \( \x=0 \AND \y=0 \) \OR + % + % Remove corners + \( \x=4 \AND \y=-4 \) \OR + \( \x=4 \AND \y=4 \) \OR + \( \x=-4 \AND \y=4 \) \OR + \( \x=-4 \AND \y=-4 \) \OR + % + % Remove corner corners + \( \x=4 \AND \y=-3 \) \OR + \( \x=4 \AND \y=3 \) \OR + \( \x=-4 \AND \y=3 \) \OR + \( \x=-4 \AND \y=-3 \) \OR + \( \x=3 \AND \y=-4 \) \OR + \( \x=3 \AND \y=4 \) \OR + \( \x=-3 \AND \y=4 \) \OR + \( \x=-3 \AND \y=-4 \) + }{}{ + \draw[fill=cyan!60!green] (\x,\y) circle (0.4); + }}} + + \draw[fill=cyan!60!green] (0, 5) circle (0.4); + \draw[fill=cyan!60!green] (5, 0) circle (0.4); + \draw[fill=cyan!60!green] (0, -5) circle (0.4); + \draw[fill=cyan!60!green] (-5, 0) circle (0.4); + \end{tikzpicture} + \hfill + \begin{tikzpicture}[scale=0.4] + \draw[color=black, very thick] (0,0) circle (5); + + \draw[fill=black] (0,0) circle (0.2); + + \draw [->, very thick](0,0) -- (-5,3.7); + \draw [->, very thick](0,0) -- (5, 3.7); + + \foreach \x in {-4, ..., 4} { + \foreach \y in {-4, ..., 4} { + \ifthenelse{ + % Remove center + \( \x=0 \AND \y=0 \) \OR + % + % Remove corners + \( \x=4 \AND \y=-4 \) \OR + \( \x=4 \AND \y=4 \) \OR + \( \x=-4 \AND \y=4 \) \OR + \( \x=-4 \AND \y=-4 \) \OR + % + % Remove corner corners + \( \x=4 \AND \y=-3 \) \OR + \( \x=4 \AND \y=3 \) \OR + \( \x=-4 \AND \y=3 \) \OR + \( \x=-4 \AND \y=-3 \) \OR + \( \x=3 \AND \y=-4 \) \OR + \( \x=3 \AND \y=4 \) \OR + \( \x=-3 \AND \y=4 \) \OR + \( \x=-3 \AND \y=-4 \) + }{}{ + \draw[fill=cyan!60!green] (\x,\y) circle (0.2); + }}} + + \draw[fill=cyan!60!green] (0, 5) circle (0.2); + \draw[fill=cyan!60!green] (5, 0) circle (0.2); + \draw[fill=cyan!60!green] (0, -5) circle (0.2); + \draw[fill=cyan!60!green] (-5, 0) circle (0.2); + \end{tikzpicture} + \hfill ~ +\end{center} \problem{} Show that if $r < \frac{1}{\sqrt{R^2 + 1}}$, you have at least one directon with a clear line of sight. \\