"Please follow the steps 1-3 outlined in README.md to download and install Julia, and to open the notebook 0_Installation.ipynb in a Jupyter notebook. "
]
},
{
...
...
@@ -13,157 +14,8 @@
"id": "31ac33c0-18a9-4cfa-8e04-3ee1a0c909eb",
"metadata": {},
"source": [
"# Installation und Einrichtung"
]
},
{
"cell_type": "markdown",
"id": "8829affd",
"metadata": {},
"source": [
"## Software and material\n",
"The course requires various things: a working installation of [Julia 1.9](https://julialang.org/downloads/), [Jupyter](https://jupyter.org/), [IJulia.jl](https://github.com/JuliaLang/IJulia.jl), the course material and various dependencies. To get everything follow these steps:\n",
"\n",
"### 1) Getting Julia\n",
"For following the course you will need **Julia 1.9**.\n",
"Julia can be easily obtained in binary form from [Julia downloads](https://julialang.org/downloads/).\n",
"\n",
"### 2) Getting all the rests\n",
"\n",
"To get the remaining files and dependencies start up `julia` and in the resulting REPL shell, copy and paste the following:\n",
"This [downloads the install.jl script](https://gitlab.mathematik.uni-stuttgart.de/stammbn/julia-seminar/-/raw/main/install.jl?ref_type=heads) and runs it from julia.\n",
"\n",
"### 2) Getting all the rest (expert version)\n",
"\n",
"As an alternative you can also also run the following commands manually (this requires to have `git` and `julia` available from the commandline): \n",
"To start the notebook make sure to be in the folder `Julia-seminar` and then run `julia`: an interactive Julia command line will open. In there run this command\n",
"\n",
"```julia\n",
"using Pkg\n",
"Pkg.activate(pwd())\n",
"using IJulia\n",
"notebook(dir=pwd())\n",
"```\n",
"\n",
"and the notebook will automatically open in a browser.\n",
"Navigate the files and open notebook number 0.\n",
"\n",
"#### From command line\n",
"\n",
"Alternatively, one can open the notebook from the command line:\n",
"\n",
"```bash\n",
"julia -L start_notebook.jl\n",
"```\n",
"\n",
"### \\* For users with multiple Julia versions\n",
"\n",
"For users with multiple Julia versions, if the corresponding kernel cannot be found in Jupyter Notebook, please run `installkernel(\"julia\", \"--project=@.\")` (only once) before executing `notebook(dir=pwd())` to first install the kernel:\n",
"\n",
"```julia\n",
"using Pkg\n",
"Pkg.activate(pwd())\n",
"using IJulia\n",
"installkernel(\"julia\", \"--project=@.\")\n",
"notebook(dir=pwd())\n",
"```\n",
"\n",
"Now, one should find a new kernel related to the current Julia version, named `julia \"Julia-version\"`, in Jupyter Notebook.\n",
"\n",
"\n",
"### Troubleshooting\n",
"If you are facing issues, check out\n",
"the [great troubleshooting section](https://carstenbauer.github.io/WorkshopWizard.jl/dev/troubleshooting/)\n",
"from the WorkshopWizard package by Carsten Bauer (which is being used by `install.jl`)."
]
},
{
"cell_type": "markdown",
"id": "b495d658-ab7a-41fb-819e-0fef02c10772",
"metadata": {},
"source": [
"## Software und Material\n",
"Der Kurs erfordert verschiedene Dinge: eine funktionierende Installation von [Julia 1.9](https://julialang.org/downloads/), [Jupyter](https://jupyter.org/), [IJulia.jl](https://github.com/JuliaLang/IJulia.jl), das Kursmaterial und verschiedene Abhängigkeiten. Um alles zu herunterzuladen und zu installieren, befolgst Du diese Schritte:\n",
"\n",
"### 1) Julia herunterladen\n",
"Um dem Kurs zu folgen, benötigst du **Julia 1.9**.\n",
"Julia kann leicht in binärer Form von den [Julia-Downloads](https://julialang.org/downloads/) bezogen werden.\n",
"\n",
"### 2) Alles andere\n",
"\n",
"Um die verbleibenden Dateien und Abhängigkeiten zu erhalten, starte `julia` und kopiere im resultierenden REPL-Shell folgenden Code:\n",
"Das [lädt das install.jl-Skript herunter](https://gitlab.mathematik.uni-stuttgart.de/stammbn/julia-seminar/-/raw/main/install.jl?ref_type=heads) und führt es in Julia aus.\n",
"\n",
"### 2) Alles andere (Experten-Version)\n",
"\n",
"Als Alternative kannst Du auch die folgenden Befehle manuell ausführen (dies setzt voraus, dass `git` und `julia` von der Kommandozeile aus verfügbar sind):\n",
"Um das Notebook zu starten, stellen Sie sicher, dass Sie sich im Ordner `Julia-Seminar` befinden, und führen Sie dann `julia` aus: Eine interaktive Julia-Befehlszeile wird geöffnet. Führen Sie darin den folgenden Befehl aus:\n",
"\n",
"```julia\n",
"using Pkg\n",
"Pkg.activate(pwd())\n",
"using IJulia\n",
"notebook(dir=pwd())\n",
"```\n",
"\n",
"und das Notebook wird automatisch in einem Browser geöffnet.\n",
"Navigieren Sie zu den Dateien und öffnen Sie das Notebook Nummer 0.\n",
"\n",
"#### Über die Befehlszeile\n",
"\n",
"Alternativ kann man das Notebook auch über die Befehlszeile öffnen:\n",
"\n",
"\n",
"```bash\n",
"julia -L start_notebook.jl\n",
"```\n",
"\n",
"### \\* Für Benutzer mit mehreren Julia-Versionen\n",
"\n",
"Für Benutzer mit mehreren Julia-Versionen, falls der entsprechende Kernel in Jupyter Notebook nicht gefunden werden kann, führen Sie bitte `installkernel(\"julia\", \"--project=@.\")` (nur einmal) aus, bevor Sie `notebook(dir=pwd())` ausführen, um zuerst den Kernel zu installieren:\n",
"\n",
"```julia\n",
"using Pkg\n",
"Pkg.activate(pwd())\n",
"using IJulia\n",
"installkernel(\"julia\", \"--project=@.\")\n",
"notebook(dir=pwd())\n",
"```\n",
"\n",
"Nun sollte man in Jupyter Notebook einen neuen Kernel finden, der mit der aktuellen Julia-Version verknüpft ist und den Namen `julia \"Julia-Version\"` trägt.\n",
"\n",
"### Fehlerbehebung\n",
"Wenn Du auf Probleme stößt, werfe einen Blick auf den [ausgezeichneten Problembehandlungsabschnitt](https://carstenbauer.github.io/WorkshopWizard.jl/dev/troubleshooting/) aus dem WorkshopWizard-Paket von Carsten Bauer (das von `install.jl` verwendet wird)."
"# Installation und Einrichtung\n",
"Bitte befolge die in README.md beschriebenen Schritte 1-3, um Julia herunterzuladen und zu installieren, und das Notebook 0_Installation.ipynb in einen Jupyter-notebook zu öffnen."
]
},
{
...
...
@@ -284,7 +136,7 @@
"\n",
"Schließlich können neue Zellen hinzugefügt werden, indem Du das `+`-Symbol im oberen Menü verwendest.\n",
"\n",
"Jedes Mal, wenn eine Übung für den Leser übrig bleibt, haben wir eine leere Code-Zelle hinzugefügt."
"Jedes Mal, wenn es eine Übung für den Leser gibt, haben wir eine leere Code-Zelle hinzugefügt."
]
},
{
...
...
%% Cell type:markdown id:16b28ead tags:
# Installation and Setup
Please follow the steps 1-3 outlined in README.md to download and install Julia, and to open the notebook 0_Installation.ipynb in a Jupyter notebook.
The course requires various things: a working installation of [Julia 1.9](https://julialang.org/downloads/), [Jupyter](https://jupyter.org/), [IJulia.jl](https://github.com/JuliaLang/IJulia.jl), the course material and various dependencies. To get everything follow these steps:
### 1) Getting Julia
For following the course you will need **Julia 1.9**.
Julia can be easily obtained in binary form from [Julia downloads](https://julialang.org/downloads/).
### 2) Getting all the rests
To get the remaining files and dependencies start up `julia` and in the resulting REPL shell, copy and paste the following:
This [downloads the install.jl script](https://gitlab.mathematik.uni-stuttgart.de/stammbn/julia-seminar/-/raw/main/install.jl?ref_type=heads) and runs it from julia.
### 2) Getting all the rest (expert version)
As an alternative you can also also run the following commands manually (this requires to have `git` and `julia` available from the commandline):
To start the notebook make sure to be in the folder `Julia-seminar` and then run `julia`: an interactive Julia command line will open. In there run this command
```julia
usingPkg
Pkg.activate(pwd())
usingIJulia
notebook(dir=pwd())
```
and the notebook will automatically open in a browser.
Navigate the files and open notebook number 0.
#### From command line
Alternatively, one can open the notebook from the command line:
```bash
julia -L start_notebook.jl
```
### \* For users with multiple Julia versions
For users with multiple Julia versions, if the corresponding kernel cannot be found in Jupyter Notebook, please run `installkernel("julia", "--project=@.")` (only once) before executing `notebook(dir=pwd())` to first install the kernel:
```julia
usingPkg
Pkg.activate(pwd())
usingIJulia
installkernel("julia","--project=@.")
notebook(dir=pwd())
```
Now, one should find a new kernel related to the current Julia version, named `julia "Julia-version"`, in Jupyter Notebook.
### Troubleshooting
If you are facing issues, check out
the [great troubleshooting section](https://carstenbauer.github.io/WorkshopWizard.jl/dev/troubleshooting/)
from the WorkshopWizard package by Carsten Bauer (which is being used by `install.jl`).
Der Kurs erfordert verschiedene Dinge: eine funktionierende Installation von [Julia 1.9](https://julialang.org/downloads/), [Jupyter](https://jupyter.org/), [IJulia.jl](https://github.com/JuliaLang/IJulia.jl), das Kursmaterial und verschiedene Abhängigkeiten. Um alles zu herunterzuladen und zu installieren, befolgst Du diese Schritte:
### 1) Julia herunterladen
Um dem Kurs zu folgen, benötigst du **Julia 1.9**.
Julia kann leicht in binärer Form von den [Julia-Downloads](https://julialang.org/downloads/) bezogen werden.
### 2) Alles andere
Um die verbleibenden Dateien und Abhängigkeiten zu erhalten, starte `julia` und kopiere im resultierenden REPL-Shell folgenden Code:
Das [lädt das install.jl-Skript herunter](https://gitlab.mathematik.uni-stuttgart.de/stammbn/julia-seminar/-/raw/main/install.jl?ref_type=heads) und führt es in Julia aus.
### 2) Alles andere (Experten-Version)
Als Alternative kannst Du auch die folgenden Befehle manuell ausführen (dies setzt voraus, dass `git` und `julia` von der Kommandozeile aus verfügbar sind):
Um das Notebook zu starten, stellen Sie sicher, dass Sie sich im Ordner `Julia-Seminar` befinden, und führen Sie dann `julia` aus: Eine interaktive Julia-Befehlszeile wird geöffnet. Führen Sie darin den folgenden Befehl aus:
```julia
usingPkg
Pkg.activate(pwd())
usingIJulia
notebook(dir=pwd())
```
und das Notebook wird automatisch in einem Browser geöffnet.
Navigieren Sie zu den Dateien und öffnen Sie das Notebook Nummer 0.
#### Über die Befehlszeile
Alternativ kann man das Notebook auch über die Befehlszeile öffnen:
```bash
julia -L start_notebook.jl
```
### \* Für Benutzer mit mehreren Julia-Versionen
Für Benutzer mit mehreren Julia-Versionen, falls der entsprechende Kernel in Jupyter Notebook nicht gefunden werden kann, führen Sie bitte `installkernel("julia", "--project=@.")` (nur einmal) aus, bevor Sie `notebook(dir=pwd())` ausführen, um zuerst den Kernel zu installieren:
```julia
usingPkg
Pkg.activate(pwd())
usingIJulia
installkernel("julia","--project=@.")
notebook(dir=pwd())
```
Nun sollte man in Jupyter Notebook einen neuen Kernel finden, der mit der aktuellen Julia-Version verknüpft ist und den Namen `julia "Julia-Version"` trägt.
### Fehlerbehebung
Wenn Du auf Probleme stößt, werfe einen Blick auf den [ausgezeichneten Problembehandlungsabschnitt](https://carstenbauer.github.io/WorkshopWizard.jl/dev/troubleshooting/) aus dem WorkshopWizard-Paket von Carsten Bauer (das von `install.jl` verwendet wird).
Bitte befolge die in README.md beschriebenen Schritte 1-3, um Julia herunterzuladen und zu installieren, und das Notebook 0_Installation.ipynb in einen Jupyter-notebook zu öffnen.
Notebooks are tools to interactively run code and display output. They are quite convenient for experimenting with code.
The julia commands are run in a backend julia instance, the browser let's you interact with the notebooks (create new ones, run them, modify them). If the backend program is closed, the browser editor will stop working.
However, if the browser is closed, the backend will keep running. You can get back to it by opening the address:
Notebooks sind Werkzeuge, um interaktiven Code auszuführen und die Ausgabe anzuzeigen. Sie sind sehr praktisch, um mit Code zu experimentieren und eine Programmiersprache neu zu lernen.
Die Julia-Befehle werden in einer separaten Julia-Instanz im Hintergrund ausgeführt, der Browser ermöglicht die Interaktion mit den Notebooks (das Erstellen neuer Notebooks, das Ausführen und Modifizieren von ihnen). Beachte dass der Browser-Editor nicht mehr funktioniert wenn das Backend-Programm geschlossen wird.
Wenn jedoch der Browser geschlossen wird, läuft das Backend weiter. Du kannst darauf zugreifen, indem Du die Adresse öffnest:
Notebooks are files characterized by the extension `.ipynb`. Using the interactive file explorer you can open them.
The notebooks contain code, the output of the code, and can contain additional comments (like these ones). All the material of the course does not contain yet the output of the code, you will get it by running the code first.
The notebooks are automatically saved every now and then, however to make sure they are saved, you can press "Ctrl + S".
Notebooks sind Dateien, die durch die Erweiterung `.ipynb` gekennzeichnet sind. Mit dem interaktiven Datei-Explorer kannst Du sie öffnen.
Die Notebooks enthalten Code, die Ausgabe des Codes und können zusätzliche Kommentare enthalten (wie diese hier). Das gesamte Material des Kurses enthält noch nicht die Ausgabe des Codes, Du erhälst sie, indem Du den Code zuerst ausführst.
Die Notebooks werden automatisch alle paar Minuten gespeichert, um jedoch sicherzustellen, dass sie gespeichert sind, kannst Du "Strg + S" drücken.
Notebooks are made up of **cells**. There are two main types: **code** and **markdown**. This is a markdown cell, it is used to display text in a formatted way.
The next is a code cell, it is used to run code and display its output. To run it, click on it and press "Shift + Enter".
Notebooks bestehen aus **Zellen**. Es gibt zwei Hauptarten: **Code** und **Markdown**. Dies ist eine Markdown-Zelle und wird verwendet, um Text auf eine formatierte Weise anzuzeigen.
Die nächste ist eine Code-Zelle und wird verwendet, um Code auszuführen und dessen Ausgabe anzuzeigen. Um sie auszuführen, klicken Sie darauf und drücken Sie Shift + Enter.
Wenn Du auf eine Code-Zelle klickst, kannst Du auch deren Inhalt ändern. Um eine Markdown-Zelle zu ändern, musst Du darauf doppelklicken (dies ist jedoch für diesen Kurs nicht erforderlich).
Es ist auch möglich, eine Code-Zelle in eine Markdown-Zelle oder umgekehrt zu ändern. Gehe dazu im oberen Menü auf Ausführen, Zellentyp.
Schließlich können neue Zellen hinzugefügt werden, indem Du das `+`-Symbol im oberen Menü verwendest.
Jedes Mal, wenn eine Übung für den Leser übrig bleibt, haben wir eine leere Code-Zelle hinzugefügt.
Jedes Mal, wenn es eine Übung für den Leser gibt, haben wir eine leere Code-Zelle hinzugefügt.
%% Cell type:markdown id:d3d75953 tags:
## Verifying that everything works
To check if the installation was successfull, run the following cell.