number-wall: Create number walls and save them as images
A "number wall" is an infinite grid associated to some (bi-directional) sequence. The "numbers" in the grid are usually either integers, or integers modulo some prime. Number walls can be defined in terms of determinants, but can also be calculated using a recursive algorithm.
Formally, let \( R \) be an integral domain. The number wall of a sequence \( S : \mathbb{Z} \to R \) is an infinite grid of numbers \( W \), defined as follows:
\[ W(x, y) = \begin{cases} 0 & y < -1 \\ 1 & y = -1 \\ S(x) & y = 0 \\ D(x, y) & y > 0 \end{cases} \]
\[ D(x, y) = \begin{vmatrix} S(x) & S(x + 1) & \ldots & S(x + y) \\ S(x - 1) & S(x) & \ldots & S(x + y - 1) \\ \vdots & \vdots & \ddots & \vdots \\ S(x - y) & S(x - y + 1) & \ldots & S(x) \end{vmatrix} \]
The values in any number wall satisfy the relation \( W(x, y - 1) W(x, y + 1) + W(x - 1, y) W(x + 1, y) = W(x, y)^2 \), and some other more complicated relations. You can use these to define a recursive algorithm for generating number walls.
Here are some cool images created using the functions in this package:
See this video for more information and fun facts.
[Skip to Readme]
Downloads
- number-wall-0.1.0.1.tar.gz [browse] (Cabal source package)
- Package description (as included in the package)
Maintainer's Corner
For package maintainers and hackage trustees
Candidates
Versions [RSS] | 0.1.0.0, 0.1.0.1, 0.1.0.2, 0.1.0.3 |
---|---|
Change log | CHANGELOG.md |
Dependencies | base (>=4.14.1.0 && <5), JuicyPixels (>=3.3 && <3.4), memoize (>=0.2.0 && <1.2), mod (>=0.1.1.0 && <0.2), semirings (>=0.5.2 && <0.8) [details] |
License | MIT |
Author | Owen Bechtel |
Maintainer | ombspring@gmail.com |
Category | Math, Algorithms, Graphics, Image |
Home page | https://github.com/UnaryPlus/number-wall |
Bug tracker | https://github.com/UnaryPlus/number-wall/issues |
Source repo | head: git clone https://github.com/UnaryPlus/lambda.git |
Uploaded | by OwenBechtel at 2022-09-03T19:04:13Z |
Distributions | |
Downloads | 274 total (0 in the last 30 days) |
Rating | (no votes yet) [estimated by Bayesian average] |
Your Rating | |
Status | Docs available [build log] Last success reported on 2022-09-03 [all 1 reports] |