make it faster (thanks jan makoso)
This commit is contained in:
21
main.ua
21
main.ua
@@ -1,15 +1,14 @@
|
||||
# how many iterations before divergence
|
||||
# ? z0=c
|
||||
Iter ← ◌⍢(
|
||||
⊃(+ⁿ2⊙⋅∘|⋅+₁)
|
||||
| ↧⊙<₁₀₀₀≤2⌵
|
||||
)⊙0.
|
||||
# ? iteration_number
|
||||
Color ← °hsv [¯η 0.75 ˜-1↧1÷12]
|
||||
# iteration_number ? z0=c
|
||||
Iter ← /+<2↧∞⌵⍥⟜⊸(+⊙°√)32 .
|
||||
|
||||
# [r g b] ? iteration_number
|
||||
Color ← °hsv ⍉ ⊂¯η⊂0.75 ¤ ¬↧1÷12
|
||||
# create [a, b) with n values
|
||||
# ? a b n
|
||||
Linspace ← +⟜(×⌵-⊙⊙(÷⟜⇡))
|
||||
Linspace ← ⍜-×⊙⊙(÷⟜⇡)
|
||||
|
||||
X ← Linspace ¯2 0.85 200
|
||||
Y ← Linspace ¯1.2 1.2 200
|
||||
&ims ≡₀Color ≡₀Iter ⊞ℂ Y X
|
||||
X ← Linspace ¯2 0.85 400
|
||||
Y ← Linspace ¯1.2 1.2 400
|
||||
|
||||
&ims Color Iter ⊞ℂ Y X
|
||||
|
||||
Reference in New Issue
Block a user