Download the latest version of Julia from julialang.org
Install Julia following the provided directions on the help page. The default installation directory should be fine. On Windows be sure to select the option to add Julia to the path to allow VS Code (next section) to find Julia. On Mac or Linux be sure to follow the instructions on adding Julia to PATH.
Launch Julia by finding the icon where you installed the program. If you have been successful, you should see the REPL like this image (version number may be different)
Try running a simple code like
julia> 5+5 to see that you can use Julia. You could even try learning more about the language by doing a tutorial like this one: "From zero to Julia!".
Julia is a programming languages and you can use it in many ways. One popular way to run Julia code is through Visual Studio Code, which allows you to edit, run, and see results from a code.
Download, install, and open VS Code. You can find the installers on code.visualstudio.com
Install the Julia extension in VS Code by selecting
File [Code on Mac]>>
Extensions, then search for Julia. You should see an extension called Julia provided by julialang. Click the
Start the Julia REPL in VS Code by opening the command-pallet using
Ctrl-Shift-pon Windows or
Cmd-Shfit-pon Mac then searching for and running
Julia: Start REPL. This will start Julia inside of VS Code.
Run the following command in the Julia REPL within VS Code.
julia> using Pkg; Pkg.add(url="https://github.com/markowkes/Biofilm.jl")
This will download Biofilm.jl and all the dependencies and can take several minutes to finish.
Try running the examples.
Download Case1.jl by right clicking and choosing Save Link As. Save the file to your Downloads folder (or other location of your choice)
Run the case by opening the file in VS Code and clicking the play button in the top right corner.
You should see output to the REPL and a plot like this:
The top row shows the biomass (particulate) and substrate concentrations and the biofilm thickness as a function of time. The bottom row shows the particulate volume fraction, substrate concentration, and particulate growth rate as a function of position within the biofilm at the output time (t=1.0 as indicated by the title).
- Try editing the case file or explore other Examples
The first time you run Biofilm.jl it will require time to compile. Subsequent runs should occur much faster.