Delphi and BASM sample code from the SWAG
MATH ROUTINES