Verifying ability to run for repository

Hello, so I am trying to run my first cloned Julia-repository for two days. Constantly I am running into problems to the point where I dont even know anymore, if those scripts in the examples folder are runnable at all. Can someone with more experience please verify this? I dont know for how much time I am asking but I imagine it to be quite simple if you know your way around the module, function and file structure in Julia. I think thats where I am hitting bedrock. Thank you.

How are you adding the repository? Are you making sure to instantiate the package?

Here is what I just did

$ git clone WaterLily
$ cd WaterLily
$ julia --project
(WaterLily) pkg> instantiate
julia> using WaterLily

Next I copied and pasted the example

julia> using LinearAlgebra: norm2

julia> function circle(p=7;Re=250)
           # Set physical parameters
           n,m = 2^p,2^(p-1)
           U,R,center = 1., m/8., [m/2,m/2]
           @show R,ν

           # Immerse a circle (change for other shapes)
           c = BDIM_coef(n+2,m+2,2) do xy
               norm2(xy .- center) - R  # signed distance function

           # Initialize Simulation object
           u = zeros(n+2,m+2,2)
           a = Flow(u,c,[U,0.],ν=ν)
           b = MultiLevelPoisson(c)

circle (generic function with 2 methods)

julia> sim = circle();
(R, ν) = (8.0, 0.032)

I think it works for me!


(R, ν) = (8.0, 0.032)
ERROR: UndefVarError: BDIM_coef not defined
[1] circle(::Int64; Re::Int64) at ./REPL[17]:9
[2] circle at ./REPL[17]:3 [inlined] (repeats 2 times)
[3] top-level scope at REPL[18]:1
[4] run_repl(::REPL.AbstractREPL, ::Any) at /build/julia/src/julia-1.5.3/usr/share/julia/stdlib/v1.5/REPL/src/REPL.jl:288

Thank you for trying and documenting this!
Although I get the same result, additionally I get that Error as well. How do I define BDIM_coef here?
My mistake was to assume I could run the example scripts through marking them and pushing “run”. I haven`t realized you had to copy the function into the REPL.

Sorry, I think I need more information in order to help you.

If you “get the same result”, then how does the error come about?

I had been playing around with the code the last days and have managed to remove the errors. Thank you.