Published 2008-06-08 |
Author:
Alain Matthes

A beautiful pattern created by rotating and scaling a triangle multiple times. Note the use of color fading to emphasis the illusion of depth.

Author: | Alain Matthes |
---|---|

Source: | Altermundus.com |

Download as: [PDF] [TEX] • [Open in writeLaTeX]

Do you have a question regarding this example, TikZ or LaTeX in general? Just ask in the
**LaTeX Forum**.

Oder frag auf Deutsch auf TeXwelt.de.
En français: TeXnique.fr.

```
\documentclass{article}
\usepackage[usenames,dvipsnames,pdftex]{xcolor}
\usepackage{tikz,ifthen}
\begin{document}
\newcounter{density}
\setcounter{density}{20}
\begin{tikzpicture}
\def\couleur{MidnightBlue}
\path[coordinate] (0,0) coordinate(A)
++( 60:12cm) coordinate(B)
++(-60:12cm) coordinate(C);
\draw[fill=\couleur!\thedensity] (A) -- (B) -- (C) -- cycle;
\foreach \x in {1,...,15}{%
\pgfmathsetcounter{density}{\thedensity+10}
\setcounter{density}{\thedensity}
\path[coordinate] coordinate(X) at (A){};
\path[coordinate] (A) -- (B) coordinate[pos=.15](A)
-- (C) coordinate[pos=.15](B)
-- (X) coordinate[pos=.15](C);
\draw[fill=\couleur!\thedensity] (A)--(B)--(C)--cycle;
}
\end{tikzpicture}
\end{document}
% Name : RotateTriangle
% Encoding : utf8
% Engine : pdflatex
% Author: Alain Matthes
```

## Comments

beautiful!!!

It's just art...

It's really great.

Nice graph! However I would code it more compact like this:

More compact is :

\documentclass{standalone} \usepackage[dvipsnames]{xcolor} \usepackage{tikz} \begin{document} \begin{tikzpicture} \path (0,0) coordinate (A) (-60:12cm) coordinate (B) (240:12cm) coordinate (C); \foreach \density in {20,30,...,160}{% \draw[fill=MidnightBlue!\density] (A) coordinate (X) -- (B) coordinate[pos=.15] (A) -- (C) coordinate[pos=.15] (B) -- (X) coordinate[pos=.15] (C); } \end{tikzpicture} \end{document}

HI,i m Jonas, and i like to create my t-shirt brand...and i really want to play with the triangle simbolic and i d like to know if it s possible to use your paint for one of my first edition??? At the moment it s just an idea for me, i m young and i just want to try to do something, to share something so let me know what are you thinking about Thanks a lot cordially Jonas

Hello, my name is Victor, I'm from valdivia, Chile. I'm studying informatics civil engineering at the university and me and a group of colleagues are going as candidates for our student center. I'd like to use your image as the logo of our list, and, hopefully, the logo of the career's center. It's awesome, it's clean, and inspires recursivity. Beside the fact is made with latex, which makes it even more awesome. Is there any problem with this?, of course, you are the author and it's up to you how we attribute your work, but just to be sure, your name and link should appear in every reference of the logo's source (we loved your whole work, the color selection and the shape)

Adding comments is currently not enabled.