owner sign in

2.5 Memory and its contents

Memory

In this section, we will describe memory in greater detail and consider its contents.

Memory is not content-specific.Memory!nonspecificity of contents of It can be used to represent numbers (integers, floating-point numbers, signed numbers, etc.), codes (character codes, numeral codes, etc.), and instructions. The programmer must keep track of the meaning of its contents. For instance, a single bit could represent whether a particular motor is on or not. An example with two bits representing four directions is \[\begin{aligned} {11} &\Rightarrow \text{north} \\ {00} &\Rightarrow \text{south} \\ {01} &\Rightarrow \text{east} \\ {10} &\Rightarrow \text{west} \end{aligned}\] The meaning of a given collection of bits of memory must be tracked by the programmer and the program. However, given that the state of every bit of memory can be represented by \(0\) or \(1\), we can think of memory as containing numbers, even …

This is a preview. Read the full book in print or ebook — get it from MIT Press (ISBN 9780262548762).

Instructor with access? Instructor login.