Bob, the routines from Microchip's AN-526 work fine. I use the Parallax assembler but the routines are in Microchip's format. They are: ACCaLO DS 1 ; Accumulator A LSB ACCaHI DS 1 ; Accumulator A MSB ACCbLO DS 1 ; Accumulator B LSB ACCbHI DS 1 ; Accumulator B MSB ; Double Precision Subtraction ( ACCb - ACCa -> ACCb ) Dsub CALL neg_A ; Double Precision Addition ( ACCb + ACCa -> ACCb ) Dadd movf ACCaLO,w ; Addition addwf ACCbLO ; add lsb btfsc STATUS,CARRY ; add in carry incf ACCbHI movf ACCaHI,w addwf ACCbHI ; add msb retlw 0 neg_A COMF ACCaLO INCF ACCaLO BTFSC STATUS,Z_bit DECF ACCaHI COMF ACCaHI RETLW 0 -------- - Tom At 09:06 PM 3/28/97 -0500, you wrote: >Greetings, > >I am afraid that my binary math knowledge has waned over the years... Can >anyone provide me with a sixteen bit subtraction routine example ??? > >The quibble of course is how to manage the carry (borrow bit)..... > >Bob Segrest > >