# Adding Nodes and Links (Edges)

Nodes and links (also called ‘Edges’) are fundamental components of the water system model. Nodes represent specific elements within the system, such as reservoirs, catchments, and demands, each with unique properties, which are referred to as attributes. For example, one attribute is the ‘max\_flow’ which is the maximum flow through a node.

These attributes can be of different types (e.g. monthly profiles) and they dictate the behavior of the specific node.

Edges represent the connections or pathways through which water flows between nodes, representing rivers, pipelines, or channels. Together, nodes and edges form the structure of the network, defining how water moves through the system.

The video below can help you follow the steps below.

{% embed url="<https://www.youtube.com/watch?v=hoqyjNIJdKs#t=2m40s>" %}

1. Click on the network you created in the first step, ‘My new network’

![](/files/V8JE35unrvy1EozS2Xeo)

This opens the network. If you selected to display a map when creating the network, a map will be shown.

![](/files/cvE81R0mV4goc0XU8PeP)

1. Zoom to a location on the map where you want to build a network. We will zoom to the Nile river in Sudan. Next click on the **Build** icon outlined in Red to view the nodes palette showing the available list of Nodes.
2. Drag and drop the nodes to be used. In this case we will use:

* 1 **Catchment** - which will represent water flowing into the system

![](/files/SUleMGaJVw8VuXrJM20F)

* 1 **Link** - a connecting node

![](/files/M2Tf7oBlS9DKS5tQDh3t)

* 2 **Output** nodes - These nodes remove water from the system. One will be a demand node and the other will be a river outlet or "sink".

![](/files/b2UrAnqPgiMQkwDAbsTn)

<figure><img src="/files/1sPFKpX2TAv5s8qk54NX" alt=""><figcaption></figcaption></figure>

1. To connect the nodes, click on **edge** to enable link mode. Click on the start node (catchment) and then click on the end node (link). Nodes must be started from the upstream node and ended on the downstream node.

**Please note:** once you have created the connections, click again on **edge** again to disable link mode.

<figure><img src="/files/6QeS5r6gXIrKPhmYo50V" alt=""><figcaption></figcaption></figure>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://water-strategy.gitbook.io/waterstrategy/tutorials/creating-and-running-a-simple-model/creating-and-running-a-model/adding-nodes-and-links-edges.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
