Skip to content

Filled contour

Bands between explicitly chosen levels of the Julia field, filled with colours from the magma colormap.

Filled contour

Select the image, or download the PDF, to open the vector figure exported by IronLAB.

Source

The figure is built by the following code. Its data comes from the functions on the data helpers page.

use ironlab::prelude::*;

use crate::fields::*;

pub const TITLE: &str = "Filled contour";
pub const DESCRIPTION: &str = "Bands between explicitly chosen levels of the Julia field, filled with colours from \
     the magma colormap.";

pub fn figure() -> Figure {
    let (x, y, z) = julia_grid(121);
    let levels = linspace(0.0, 6.5, 14);

    let mut fig = Figure::new()
        .size_mm(120.0, 100.0)
        .title(r"Filled contours of $\ln(1 + |z_3|)$");
    let mut ax = fig.axes(0, 0);
    ax.contourf(&x, &y, &z).level_values(&levels);
    ax.colormap(Colormap::Magma).xlabel("$x$").ylabel("$y$");
    fig
}

Back to the gallery