Asymmetric Cantor Set Generator
Generate and visualize asymmetric Cantor sets with custom left/right ratios. Compute Hausdorff dimension, export PNG, explore fractal geometry.
About
The classical Cantor set removes the open middle third of every interval at each iteration, producing a self-similar fractal with Hausdorff dimension log 2log 3 ≈ 0.6309. That symmetry is a special case. In the general construction, the left child inherits a fraction rL of the parent interval and the right child inherits rR, where rL + rR < 1. When rL ≠ rR, the resulting set is no longer self-similar in the strict sense. Its Hausdorff dimension d satisfies the implicit equation rLd + rRd = 1, which this tool solves numerically via bisection to 10−12 precision.
Getting the ratios wrong collapses the fractal into trivial dust or a solid segment. If rL + rR ≥ 1, children overlap and the complement has zero measure. This tool enforces the open set condition and computes exact gap sizes at every level. Note: the Hausdorff dimension formula assumes the open set condition holds, which requires the gap 1 − rL − rR > 0.
Formulas
The asymmetric Cantor set is constructed by an Iterated Function System (IFS) with two contractions applied to each interval [a, b]:
The left child interval becomes [a, a + rL(b − a)] and the right child becomes [b − rR(b − a), b]. The open gap has length (1 − rL − rR)(b − a).
The Hausdorff dimension d is the unique solution to Moran's equation:
This is solved by bisection on d ∈ (0, 1). The total number of intervals at depth n is 2n. The total measure (Lebesgue) of the set at level n is:
Where rL = left contraction ratio (0 < rL < 0.5), rR = right contraction ratio (0 < rR < 0.5), d = Hausdorff dimension, n = iteration depth, Ln = total remaining measure at level n.
Reference Data
| Configuration | rL | rR | Gap Ratio | Hausdorff Dim d | Notes |
|---|---|---|---|---|---|
| Classic Cantor | 1/3 | 1/3 | 1/3 | 0.6309 | Standard middle-third removal |
| Fat Cantor (Smith - Volterra) | 3/8 | 3/8 | 1/4 | 0.7056 | Positive Lebesgue measure variant |
| Thin Cantor | 1/5 | 1/5 | 3/5 | 0.4307 | Large gaps, sparse dust |
| Heavy Left | 0.40 | 0.10 | 0.50 | 0.4380 | Asymmetric, left-biased |
| Heavy Right | 0.10 | 0.40 | 0.50 | 0.4380 | Mirror of Heavy Left |
| Extreme Asymmetry | 0.45 | 0.05 | 0.50 | 0.3979 | Near-degenerate right branch |
| Golden Ratio | 0.382 | 0.236 | 0.382 | 0.5549 | rL = 1−φ−1 |
| Quarter-Quarter | 1/4 | 1/4 | 1/2 | 0.5000 | Dimension exactly 0.5 |
| Near Overlap | 0.45 | 0.45 | 0.10 | 0.8677 | Tiny gap, dense fractal |
| Mild Asymmetry | 0.30 | 0.35 | 0.35 | 0.6107 | Slight right bias |
| Dyadic | 1/4 | 1/2 | 1/4 | 0.6942 | Power-of-two scaling |
| Binary Dust | 1/4 | 1/8 | 5/8 | 0.3569 | Very sparse |
| Balanced Wide | 0.20 | 0.20 | 0.60 | 0.4307 | Wide central gap each level |
| Nearly Full | 0.48 | 0.48 | 0.04 | 0.9436 | Approaches dimension 1 |
| Minimal Left | 0.05 | 0.30 | 0.65 | 0.3222 | Left branch nearly vanishes |