This short text is intended for the very narrow audience of instructors and/or professors of navigation. Being in the process of building my own courses, I realized that there are very little tools availlable to draw neat vectors representing the course, track and current as per the International Maritime Organization convention. This convention is followed, amongst others, by Sail Canada and the Royal Yachting Association.
So, I wrote an open source software that can do it. It is called « Omipy » and it is availlable on GitHub. The name is a playword with the IMO acronym in French (« OMI ») and the fact that it is pronounced « Oh my pie » in English. Sorry.
The software greatly eases the process of writing exercices, solutions and related class material. The software is written in Python. Python interpreters are availlable by default on Apple computers, on Linux systems… and must be installed on Windows computers (here or here).
I give three examples of usage below.
Feed All the Information
figure = Omipy(10, 10, draw_coord = True)
figure.draw_fix(x = 1, y = 1, time='1000')
figure.set_current(set = 0, drift = 5, x = 6, y = 1)
figure.set_course(s = 5, c = 90, x = 1, y = 1)
figure.set_track(cog = 45, sog = 7.1, x = 1, y = 1)
figure.make_diagram(time="1100", draw_dr=True)
figure.print_file('example-1.png', dpi=500)
The example above shows a case where all the information is provided manually. The code draws a fix at the starting point (1,1), with the time set at 1000. The course, current and track are defined in the next three following lines. The arguments x and y are the coordinates of the starting point of each vector (and the other arguments should be fairly intuitive). The last two lines generate the image and save it to disk. The option draw_dr lets the user choose whether a dead reckoning mark should be drawn or not. Although not shown in this example, it is possible to add dead reckoning marks at specific moments, so one may decide to enter them manually rather than to use the option while producing the figure.
The code yields the figure below, a construction over one hour.
Let the Software Find the Track
The software can also compute the track by adding the course to the current. The solution yields a diagram starting from the course origin, as if one were to do it by hand. Compared to the previous code, two lines change: the function « solve_track » is called rather than « make_diagram ». The function finds the track and then draws the resulting picture.
figure = Omipy(10, 10, draw_coord = True)
figure.draw_fix(x = 1, y = 1, time='1000')
figure.set_current(set = 0, drift = 2, x=1, y=1)
figure.set_course(s = 8, c = 75, x = 1, y = 1)
figure.solve_track("1100")
figure.print_file('example-2.png', dpi=500)
The code yields the Figure below. Note that despite having the current vector start at the point (1, 1), the program moves the vector to the end of the course, so as to fit the standard drawing conventions.
Let the Software Find the Course
It is also possible to let the software find the course to factor the current in, so as to generate a desired track. Here is an example of code:
figure = Omipy(10, 10, draw_coord = True)
figure.draw_fix(x = 4, y = 8, time='1000')
figure.set_track(cog = 45+90, x=4, y = 8)
figure.set_current(set = 220, drift = 2, x = 4, y = 8)
figure.solve_course(s = 5.0, time = "1100")
figure.print_file('example-3.png', dpi=500)
Here, note that the track has no speed given as an argument, only a course over the ground. The « solve_course » function is however given a speed over the surface, which is used to solve the construction over an hour. In the backend, a reduced form (2D, « planar » version) of the conservation of movement equations are used to solve the desired course. The software yields the image below. Note that the current vector and course are drawn from the point of origin, so as if the solution were computed graphically. However, the course vector is drawn again from the starting point.
Further Developments
Not all IMO conventions are curentlly implemented in the software (e.g. circle of positions). Furthermore, some are written but yet have to be tested (e.g. lines of positions). The software will thus be updated at a later stage, on github, and the best way to know if it has evolved is to check the examples page. I do not plan on maintaining the software all the time, but only when I need it. It is however open source, and anyone is welcome to improve it and « push » a new version on github if improvements are made.
Additional Material
I have also written some material on how to predict tides and on map projections. These posts could also be of interest in a classroom setting.