TeX Community Aggregator

Category PGFplots examples (Stefan Kottwitz)

Lorentz system

A Lorenz system by Henri Menke: % !TEX lualatex \documentclass[tikz]{standalone} \usepackage{luacode,pgfplots} \begin{luacode*} — Differential equation of Lorenz attractor function f(x,y,z) local sigma = 3 local rho = 26.5 local beta = 1 return {sigma*(y-x),-x*z + rho*x – y,x*y – beta*z}… Continue Reading →

Another flower

Another flower without comment. function source is here. \documentclass[border=5pt]{standalone} \usepackage{pgfplots} \pgfplotsset{compat=1.8} \renewcommand*{\r}{(sin(4*u)^3 + cos(2*u)^3 + sin(6*v)^2 + cos(6*v)^4)} \begin{document} \begin{tikzpicture} \begin{axis}[ view = {120}{310}, hide axis, colormap = {flower}{ color(0cm) = (yellow); color(4cm) = (yellow!70!red); color(8cm) = (red!60!black); color(12cm) =… Continue Reading →

Flower in 3d

Without much comments a flower, or a Parametric Breather Pseudospherical Surface. \documentclass[border=5pt]{standalone} \usepackage{pgfplots} \pgfplotsset{compat=1.8} \pgfplotsset{trig format plots=rad} \begin{document} \begin{tikzpicture} \begin{axis}[ view = {60}{-60}, hide axis, colormap = {flower}{% color(0cm) = (yellow); color(4cm) = (orange); color(8cm) = (red!40!black); color(12cm) = (red!80!black);… Continue Reading →

Periodically, more or less

That’s from my German blog TikZ.de. Recently I played with the sine function, that “wave” that everybody knows in cartesian coordinates. Let’s take a look at a 3d polar complex sine made plot. In polar coordinates the sine function is… Continue Reading →

Twisted torus

That plot is from my German blog TikZ.de. I planned to model this nice cake: (Foto by Guido Draheim). Like a cruller, just, ehm, more digital and mathematical. How do we draw it? Let’s think of a cross-section. In polar… Continue Reading →

Filling the space below a surface plot

Here I fill the space below the function z = x^2+y^2 to get a solid object. I did it by: Plotting the curves at the edges, for x=0 and y=0 Plotting the bottom edges Naming the paths above using name… Continue Reading →

Polar plot of a sine function with factor in argument

The sine function is a well known periodic function. Choose an argument factor, which doesn’t divide the period well, and you can see a complicated path around the origin. This plot was originally made for my blog post on TikZ.de:… Continue Reading →

Polar plot of sine based function

The sine function is a well known periodic function. Choose an argument factor, which doesn’t divide the period well, and add another sine function with a different factor, and you can see a complicated path around the origin. This plot… Continue Reading →

Julia set

This is a picture of a Julia set, named after the French mathematician Gaston Julia. Computing requires a lot of iterations, that’s why we use Lua. The function for the set is z -> z^2 – 0.742 + 0.1i. The… Continue Reading →

Mandelbrot set

The Mandelbrot consists of points whose boundary is a two-dimensional fractal shape. It is named after the mathematician Benoit Mandelbrot. It’s computed using a lot of iterations, that’s why we use Lua here for the calculation. The sampling is done… Continue Reading →

Filling an area between plots

With pgfplots 1.10 and its fillbetween library we can fill the area between curves in a new convenient way: draw the first function and give it a name draw the second function and name it too add a fill between… Continue Reading →

© 2025 TeX.social