Melody's work was impressive......!!! Here's a slightly less sophisticated manner of looking at this if we assume that the tide rises and falls in a "linear" fashion.
The following graph illustrates the situation.........

Let x= 0 on the following graph equate to "5AM" and let x = 6 equate to "11AM"
And if we consider only the difference between the heighest and lowest tides to be 4.1 ft., then let the point (0, 4.1) be the "high" point of the tide. And the "low" point would be at y = 0 six hours later, i.e., the point (6,0).
And the ship can only enter the seaport when the tide is 1 ft above its "low point." This is represented on the graph by the function y = 1.
Therefore, the time that the ship can enter the seaport starting at 5AM would be from x = 0 to x = 4.537 hrs. later....in other words...from 5AM to about 9:32AM
And note that, the ship would not be able to enter or leave again until about 7.463 hrs after 5AM = about 12:28PM!! Thus, assuming the linear model, there is about a 3 hour period when the tide is too low for the ship to enter or leave the port....!!!
Melody's model is probably more "real-world," .....mine is probably more simplistic....(Duh!!)
