Closed HannoSpreeuw closed 2 months ago
Going one page back, i.e. to the CarboCAT Summary page, perhaps one first has to issue include("src/Burgess2013.jl")
.
But that gives
ERROR: LoadError: UndefVarError: `Stencil` not defined
include("src/Stencil.jl")
works, but then include("src/Burgess2013.jl")
gives a different error
WARNING: replacing module Burgess2013.
ERROR: LoadError: ArgumentError: Package Transducers not found in current path.
Okay, but that can be fixed easily:
import Pkg; Pkg.add("Transducers")
The first two of these commands
include("src/Burgess2013/Config.jl")
include("src/Burgess2013/CA.jl")
result = Iterators.take(CA.run(Reflected{2}, init, 3), 8)
succesfully import CA - the first one is needed prior to the second - but the last one still gives an error, albeit a different one:
ERROR: UndefVarError: `Reflected` not defined
using CarboKitten.Stencil: Reflected
fixes this and result = Iterators.take(CA.run(Reflected{2}, init, 3), 8)
brings us to a new error message:
ERROR: MethodError: no method matching run(::Type{Reflected{2}}, ::Matrix{Int64}, ::Int64)
Closest candidates are:
run(::Base.AbstractCmd, ::Any...; wait)
@ Base process.jl:477
Stacktrace:
[1] top-level scope
@ REPL[15]:1
Okay, this works:
using CarboKitten.Stencil: Reflected
using CarboKitten.Burgess2013
init = rand(0:3, 50, 50)
result = Iterators.take(run_ca(Reflected{2}, MODEL1, init, 3), 8)
using Plots
plot((heatmap(r, colorbar=:none) for r in result)..., layout=(2, 4))
I am following the Cellular Automaton instructions to reproduce Figure 3 from Burgess 2013:
The first instruction works flawlessly, but the second one gives