Chapter 4

Basic Arithmetic and Logic

Peter Fenwick

Abstract

Given that quantities may be represented as bit patterns within the computer, how may these patterns be manipulated to achieve useful results? We look first at the "basic" operations of addition and subtraction in the various binary number representations, extending to addition of multiple-precision values and decimal addition. Then we examine the logical operations, where the bits are "bits", with no numerical significance. Operations here include AND, OR, NOT, XOR, shifting of various types, bit-field operations and, finally, parity.

Total Pages: 45-75 (31)

Purchase Chapter  Book Details

RELATED BOOKS

.Multi-Objective Optimization In Theory and Practice II: Metaheuristic Algorithms.
.Arduino and SCILAB based Projects.
.Arduino meets MATLAB: Interfacing, Programs and Simulink.
.Budget Optimization and Allocation: An Evolutionary Computing Based Model.