Astrografica: pianeta pi greco

This commit is contained in:
Gianluigi 2024-05-14 12:19:10 +02:00
parent b4a2b90428
commit 0d18d7b83d
2 changed files with 61 additions and 0 deletions

61
infographics/astro_pi.tex Normal file
View File

@ -0,0 +1,61 @@
\documentclass{standalone}
%
\usepackage{tikz}
\usetikzlibrary{backgrounds,decorations.pathmorphing,arrows.meta}
\usepackage{tkz-euclide}
%
\usepackage{xcolor}
%
\definecolor{space}{HTML}{0A2543}
\definecolor{earth}{HTML}{0089FA}
\definecolor{dida}{HTML}{FFDE00}
\definecolor{title}{HTML}{FBA706}
%
\usepackage{fontspec}
\setmainfont{Open Dyslexic}
%
\title{Pi greco. Per caso.}
\begin{document}
\tikzset{
partial ellipse/.style args = {#1:#2:#3}{insert path={+ (#1:#3) arc (#1:#2:#3)}},
}
\begin{tikzpicture}[background rectangle/.style={fill=white},show background rectangle,>={[inset=0,angle'=27]Stealth}]
%title
\draw [black,ultra thick,fill=title] (1,-2) rectangle (29,2);
\node at (15,0) {\textcolor{black}{\fontsize{75}{76}\selectfont Pianeta Pi Greco}};
%
\begin{scope}[shift={(0,-5.5)}]
\draw [fill=dida, ultra thick] (2,2.5) rectangle (28,-2.5);
\node (example-textwidth-2) [right, align=left, text width=25cm, color=black, font=\fontsize{23pt}{24pt}\selectfont] at (2.5,0) {Una visualizzazione astronomica delle prime cifre decimali del \emph{pi greco}. Ogni cifra è un piccolo pianeta le cui dimensioni e distanza dal centro dipendono dalla cifra stessa, mentre la linea tratteggiata che collega ciascun "pianeta" segue il percorso ordinato dalla prima alla successiva.};
\end{scope}
%
\begin{scope}[shift={(15,-18)}]
\tkzDefPoint(0,0){P0}
\tkzDrawPoint(P0)
\edef\r{0}
\foreach \i/\j in {1/1,4/2,1/3,5/4,9/5,2/6,6/7,5/8,4/9}
{
\pgfmathsetmacro{\a}{360*rand}
\pgfmathsetmacro{\c}{0.7*rand}
%
\pgfmathsetmacro{\x}{\i * cos(\a)}
\pgfmathsetmacro{\y}{\i * sin(\a)}
%
\tkzDefPoint(\x,\y){P\j}
\pgfmathparse{70*rnd+30}
\edef\tmp{\pgfmathresult}
\tkzDrawPoint[size=\i,color=space!\tmp!earth](P\j)
}
\foreach \i/\j in {1/0,2/1,3/2,4/3,5/4,6/5,7/6,8/7,9/8}
{
\tkzDrawSegments[dotted](P\j,P\i)
\tkzDrawCircle(P0,P\i)
}
\end{scope}
%
\begin{scope}[shift={(0,-28)}]
\node at (27,0) () {\includegraphics[width=3.7cm]{licenza}};
\node at (18,-0.1) {\textcolor{black}{\fontsize{14}{15}\selectfont Testo e grafica: @ulaulaman - Gianluigi Filippelli}};
\end{scope}
\end{tikzpicture}
\end{document}

Binary file not shown.