Program Name: TW Date: 5/97 Subject: sailing Size: 73 bytes REQUIREMENTS MODULES: SUBS: HARDWARE:Comments

Calculates true wind from boat heading (magnetic), boat speed, apparant wind angle and apparant wind speed. The input data goes in the stack.

STACK DATA T HDThe apparant wind bearing is positive for starbord and negative for port. If the apparant wind is at 40 deg to stbd it is 40, if it is 40 degrees to port it is -40.boat headingZ BSboat speedY ARapparant wind relative bearingX ASapparant wind speed

EXAMPLE 1

with a heading of 020, boat speed 5.5 knots, relative wind direction of 45 degrees (45 deg to stbd) and apparant wind speed of 13 knots you would make the following keystrokes:

20The display will read |T=68R,88M,10 |HeadingENTER 5.5Boat SpeedENTER 45Apparant Wind AngleENTER 13Apparant Wind SpeedXEQ TW

This means the true wind is at 68 deg relative, 88 deg magnetic at 10 knots.

EXAMPLE 2

with a heading of 120, boat speed 6 knots, relative wind direction of -145 degrees (145 deg to port) and apparant wind speed of 7 knots you would make the following keystrokes:

120The display will read |T=161R,41M,12|HeadingENTER 6Boat SpeedENTER 145Apparant Wind AngleCHSChange to negative for wind to portENTER 7Apparant Wind SpeedXEQ TW

This means the true wind is at 161 deg relative, 41 deg magnetic at 12 knots. The relative wind direction is not specified P or S. The program could be made to do this but it would complicate the code and the display. It should be pretty easy to look up and see which side of the boat the wind is on.

DISPLAY >> |T=nnnR,nnnM,nn|

(True wind realative bearing, magnetic bearing, speed)

DATA STRUCTURE REG DATA 11 ARapparant wind relative bearing12 ASapparant wind speed13 HDboat heading14 BSboat speedPROGRAM LISTING LBL TW STO 12 RDN STO 11 RDN STO 14 RDN STO 13 90 RCL 11 - RCL 12 P-R STO 11 RDN STO 12 90 RCL 14 P-R ST- 11 RDN ST- 12 90 RCL 12 RCL 11 R-P RDN - FIX 0 "T=" ARCL X "|R," RCL 13 + 360 MOD R^ ARCL Y "|M," ARCL X AVIEW ENDLBL TW STO 12 RDN STO 11 RDN STO 14 RDN STO 13 90 RCL 11 - RCL 12 P-R STO 11 RDN STO 12 90 RCL 14 P-R ST- 11 RDN ST- 12 90 RCL 12 RCL 11 R-P RDN - FIX 0 "T=" ARCL X "|R," RCL 13 + 360 MOD R^ ARCL Y "|M," ARCL X AVIEW END