Skip to content

Commit ad24886

Browse files
committed
Fix sphinx/build_docs warnings for fractals
1 parent 215dfa2 commit ad24886

File tree

3 files changed

+15
-12
lines changed

3 files changed

+15
-12
lines changed

fractals/julia_sets.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
- Other examples from https://en.wikipedia.org/wiki/Julia_set
1414
- An exponential map Julia set, ambiantly homeomorphic to the examples in
1515
https://www.math.univ-toulouse.fr/~cheritat/GalII/galery.html
16-
and
16+
and
1717
https://ddd.uab.cat/pub/pubmat/02141493v43n1/02141493v43n1p27.pdf
1818
1919
Remark: Some overflow runtime warnings are suppressed. This is because of the
@@ -67,7 +67,7 @@ def eval_quadratic_polynomial(c_parameter: complex, z_values: np.ndarray) -> np.
6767
def prepare_grid(window_size: float, nb_pixels: int) -> np.ndarray:
6868
"""
6969
Create a grid of complex values of size nb_pixels*nb_pixels with real and
70-
imaginary parts ranging from -window_size to window_size (inclusive).
70+
imaginary parts ranging from -window_size to window_size (inclusive).
7171
Returns a numpy array.
7272
7373
>>> prepare_grid(1,3)

fractals/koch_snowflake.py

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,12 @@
66
successive stage is formed by adding outward bends to each side of the
77
previous stage, making smaller equilateral triangles.
88
This can be achieved through the following steps for each line:
9-
1. divide the line segment into three segments of equal length.
10-
2. draw an equilateral triangle that has the middle segment from step 1
9+
10+
1. divide the line segment into three segments of equal length.
11+
2. draw an equilateral triangle that has the middle segment from step 1
1112
as its base and points outward.
12-
3. remove the line segment that is the base of the triangle from step 2.
13+
3. remove the line segment that is the base of the triangle from step 2.
14+
1315
(description adapted from https://en.wikipedia.org/wiki/Koch_snowflake )
1416
(for a more detailed explanation and an implementation in the
1517
Processing language, see https://natureofcode.com/book/chapter-8-fractals/

fractals/sierpinski_triangle.py

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,15 @@
44
Simple example of fractal generation using recursion.
55
66
What is the Sierpiński Triangle?
7+
78
The Sierpiński triangle (sometimes spelled Sierpinski), also called the
8-
Sierpiński gasket or Sierpiński sieve, is a fractal attractive fixed set with
9-
the overall shape of an equilateral triangle, subdivided recursively into
10-
smaller equilateral triangles. Originally constructed as a curve, this is one of
11-
the basic examples of self-similar sets—that is, it is a mathematically
12-
generated pattern that is reproducible at any magnification or reduction. It is
13-
named after the Polish mathematician Wacław Sierpiński, but appeared as a
14-
decorative pattern many centuries before the work of Sierpiński.
9+
Sierpiński gasket or Sierpiński sieve, is a fractal attractive fixed set with
10+
the overall shape of an equilateral triangle, subdivided recursively into
11+
smaller equilateral triangles. Originally constructed as a curve, this is one of
12+
the basic examples of self-similar sets—that is, it is a mathematically
13+
generated pattern that is reproducible at any magnification or reduction. It is
14+
named after the Polish mathematician Wacław Sierpiński, but appeared as a
15+
decorative pattern many centuries before the work of Sierpiński.
1516
1617
1718
Usage: python sierpinski_triangle.py <int:depth_for_fractal>

0 commit comments

Comments
 (0)