Aleph-w 3.0
A C++ Library for Data Structures and Algorithms
Loading...
Searching...
No Matches
ca-tikz.H File Reference

TikZ renderers for cellular-automata frames. More...

#include <concepts>
#include <ostream>
#include <sstream>
#include <string>
#include <type_traits>
#include <utility>
#include <ah-errors.H>
#include <ca-traits.H>
#include <tpl_ca_concepts.H>
#include <tpl_ca_hex_lattice.H>
#include <tpl_ca_triangular_lattice.H>
Include dependency graph for ca-tikz.H:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  Aleph::CA::Rect_Tikz_Options
 TikZ rendering options for rectangular frames. More...
 
struct  Aleph::CA::Binary_Tikz_Palette< State >
 Default binary TikZ palette. More...
 

Namespaces

namespace  Aleph
 Main namespace for Aleph-w library functions.
 
namespace  Aleph::CA
 
namespace  Aleph::CA::ca_tikz_detail
 

Functions

template<typename Lattice >
void Aleph::CA::ca_tikz_detail::require_rank2_rect (const char *fn)
 
template<typename Lattice , typename Palette >
requires requires(Palette &&p, const typename Lattice::state_type &v) { { p(v) } -> std::convertible_to<std::string>; }
void Aleph::CA::render_rect_lattice_tikz (std::ostream &out, const Lattice &frame, Palette &&palette, const Rect_Tikz_Options &opts={})
 Render a rectangular 2D frame as a TikZ picture.
 
template<typename Lattice , typename Palette >
requires requires(Palette &&p, const typename Lattice::state_type &v) { { p(v) } -> std::convertible_to<std::string>; }
std::string Aleph::CA::render_rect_lattice_tikz (const Lattice &frame, Palette &&palette, const Rect_Tikz_Options &opts={})
 Return a rectangular frame rendered as TikZ.
 
template<typename Lattice , typename Palette >
requires requires(Palette &&p, const typename Lattice::state_type &v) { { p(v) } -> std::convertible_to<std::string>; }
void Aleph::CA::render_lattice_tikz (std::ostream &out, const Lattice &frame, Palette &&palette, const Rect_Tikz_Options &opts={})
 Render any supported 2D CA lattice as TikZ.
 
template<typename Lattice , typename Palette >
requires requires(Palette &&p, const typename Lattice::state_type &v) { { p(v) } -> std::convertible_to<std::string>; }
std::string Aleph::CA::render_lattice_tikz (const Lattice &frame, Palette &&palette, const Rect_Tikz_Options &opts={})
 Return any supported 2D CA lattice rendered as TikZ.
 
template<typename Lattice >
void Aleph::CA::render_lattice_tikz (std::ostream &out, const Lattice &frame, const Rect_Tikz_Options &opts={})
 Render with the default binary palette.
 
template<typename Lattice >
std::string Aleph::CA::render_lattice_tikz (const Lattice &frame, const Rect_Tikz_Options &opts={})
 Return a TikZ picture using the default binary palette.
 

Detailed Description

TikZ renderers for cellular-automata frames.

Provides a generic Phase-11 visualisation facade:

  • Rectangular 2D lattices are rendered as filled rectangles.
  • Hexagonal lattices dispatch to render_hex_lattice_tikz().
  • Triangular lattices dispatch to render_triangular_lattice_tikz().

The output is a tikzpicture body suitable for embedding in LaTeX reports. It intentionally does not emit a document preamble; callers can compose several figures in one document.

Author
Leandro Rabindranath Leon

Definition in file ca-tikz.H.