Package for representing dual numbers and for performing dual algebra