Skip to article frontmatterSkip to article content
Site not loading correctly?

This may be due to an incorrect BASE_URL configuration. See the MyST Documentation for reference.

In-depth energy module behaviour (Procedural)

In-depth energy module behaviour (Procedural)

In this notebook, we set up a graph with a single edge to demonstrate some basic functionality of the Energy module by directly using procedural functions and simple data structures.

0. Import libraries

This notebook is executed with OpenTNSim version 1.3.7

1. Define helper functions

We define a set of functions that encapsulate the energy calculation logic. Instead of a Vessel class, we use a dictionary (vessel_data) to store and pass the vessel’s state and properties between these functions.

Loading...

2. Create graph

Next, we create a network (a graph) along which the vessel can move. In this case, we create a single edge of exactly 100 km.

3. Run Calculation

4.1 Show the effects of vessel velocity on resistance, power and energy

We run the calculation for a range of velocities.

<Figure size 1200x400 with 3 Axes>

Panel 1 in the figure above corresponds to Part IV - Figure 5.4 in Van Koningsveld et al (2023), Koningsveld et al. (2023). Panel 2 shows how the R_tot from Panel 1 is converted to P_tot, multiplying with v and using various efficiency factors. Panel 3 shows the total energy that is required to pass the 100 km long edge. This total energy is derived by multiplying the P_tot with the time it takes to pass the edge. For very low v’s the R_tot is low, but it also takes long to pass the edge. For high v’s the R_tot escalates, but the time to pass the edge reduces.

References
  1. van Koningsveld, M., Verheij, H., Taneja, P., & de Vriend, H. (2023). Ports and Waterways: Navigating the changing world. TU Delft OPEN Publishing. 10.5074/t.2021.004