Summary Files Commits Branches @commit @diff @stats
path: root / src / teaching / upp-2025 / week06 / tex / rectangles_and_circle.tex
diff options
context:
space:
mode:
Commit8b262046665b76926dc91ef92d64a2ea20d1e9c9 (patch)
Author
 Syndamia <kamen@syndamia.com>
2025-11-05 21:52:05 +0200
Committer
 Syndamia <kamen@syndamia.com>
2025-11-05 21:52:05 +0200
Files82db544679346f19dd0b1e376a5aa49a5860c4bf /src/teaching/upp-2025/week06/tex/rectangles_and_circle.tex
syndamia.com-8b262046665b76926dc91ef92d64a2ea20d1e9c9.tar
syndamia.com-8b262046665b76926dc91ef92d64a2ea20d1e9c9.tar.gz
syndamia.com-8b262046665b76926dc91ef92d64a2ea20d1e9c9.zip
Parent04e3d68180d69394e60ca7c81c584a800e043578 (diff)
feat(teaching/upp-2025/w06): Add exercises
1 files changed, 22 insertions, 0 deletions
-rw-r--r--src/teaching/upp-2025/week06/tex/rectangles_and_circle.tex22
diff --git a/src/teaching/upp-2025/week06/tex/rectangles_and_circle.tex b/src/teaching/upp-2025/week06/tex/rectangles_and_circle.tex
new file mode 100644
index 0000000..121f2d3
--- /dev/null
+++ b/src/teaching/upp-2025/week06/tex/rectangles_and_circle.tex
@@ -0,0 +1,22 @@
+% https://alfurka.github.io/quick-tikz/
+\def \recA {(0,-2.5) rectangle ++(3,3)}
+\def \recB {(-1,0) rectangle ++(3,1)}
+\def \circleA {(-1,-1) circle [radius=2.5]}
+
+\begin{tikzpicture}[background rectangle/.style={fill=white}, show background rectangle]
+ % Axis
+ \draw (-5,0) -- (5,0);
+ \draw (0,-5) -- (0,5);
+ \draw[step=1,gray,very thin] (-4.8,-4.8) grid (4.8,4.8);
+
+ % Main shapes
+ \draw[blue] \recA;
+ \draw[red] \recB;
+ \draw[brown] \circleA;
+
+ % Intersection
+ \begin{scope}
+ \clip \recB;
+ \draw[pattern=north west lines, even odd rule] \recA \circleA;
+ \end{scope}
+\end{tikzpicture}