# The Euclidean definition of the functions div and mod

```@article{Boute1992TheED,
title={The Euclidean definition of the functions div and mod},
author={R. Boute},
journal={ACM Trans. Program. Lang. Syst.},
year={1992},
volume={14},
pages={127-144}
}```
• R. Boute
• Published 1992
• Computer Science
• ACM Trans. Program. Lang. Syst.
The definitions of the functions div and mod in the computer science literature and in programming languages are either similar to the Algol of Pascal definition (which is shown to be an unfortunate choice) or based on division by truncation (T-definition) or division by flooring as defined by Knuth (F-definition). The differences between various definitions that are in common usage are discussed, and an additional one is proposed, which is based on Euclid's theorem and therefore is called the… Expand
45 Citations
Division and Modulus for Computer Scientists
An algorithm for the Euclidean div and mod functions is given and it is proved it correct with respect to Euclid’s theorem. Expand
Modulo intervals: a proposed notation
• Mathematics, Computer Science
• SIGA
• 2012
Definition (1) works perfectly well when the interval is given backward, that is, a > b, yielding a modulus in the right-closed interval (b . . a). Expand
Zeroless Positional Number Representation and String Ordering
• R. Boute
• Mathematics, Computer Science
• Am. Math. Mon.
• 2000
A simple system (henceforth called BS) is described that does not need zero and has the interesting property that the representation is unique, unlike the generally accepted system (AS) where leading zeros can be added without changing the value. Expand
How to calculate proofs: bridging the cultural divide
T his article argues that one of the most neglected opportunities in many branches of mathematics is symbolic reasoning for the “logical” parts rather than just for the algebraic, analytic, etc.,Expand
Functional declarative language design and predicate calculus: a practical approach
The proposed alternative combines a language of utmost simplicity (four constructs only) that is devoid of the defects of common mathematical conventions, with a set of convenient calculation rules that is sufficiently comprehensive to make it practical for everyday use in most (if not all) domains of interest. Expand
Continuum versus Discrete: A Physically Interpretable General Rule for Cellular Automata by Means of Modular Arithmetic
• Computer Science, Mathematics
• Complex Syst.
• 2013
A general rule which describes every of Wolfram's cellular automata is derived and a new representation is given in terms of a new function hereby defined, the iota-delta function, which provides a straightforward physical interpretation of CA, which gives a quantitative interpretation of the generating rule itself. Expand
Pointfree expression and calculation: from quantification to temporal logic
• R. Boute
• Computer Science
• Formal Methods Syst. Des.
• 2010
Various ramifications, style and abstraction issues are discussed, in relation to engineering mathematics in general and to categorical formulations. Expand
On the Definition of Integer Division and Modulus in Programming Languages
Problems with the definitions of integer division, modulus, and related operations in programming languages are discussed. It is demonstrated that unifying, generic definitions can be employed toExpand
Floating-Point Formats and Environment
This chapter is a revision and merge of the earlier IEEE 754-1985  and IEEE 854-1987  standards and focuses on the floating-point arithmetic standard. Expand
Towards Infinite-State Symbolic Model Checking for B and Event-B
This thesis is concerned with improving the ProB model checker by augmenting its original explicit state modelChecker with a symbolic counterpart, and implements methods to increase the performance of ProB’s constraint solving kernel. Expand