100% found this document useful (4 votes)
9 views

(eBook PDF) Data Structures & Algorithm Analysis in C++ 4th Edition download

The document provides information on various eBooks related to data structures and algorithm analysis, specifically in C++ and Java. It includes links to download different editions of these eBooks, along with a detailed table of contents outlining the chapters and topics covered in the 'Data Structures & Algorithm Analysis in C++ 4th Edition'. The content spans fundamental programming concepts, algorithm analysis, data structures, and advanced topics such as graph algorithms and algorithm design techniques.

Uploaded by

owneylynem31
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
100% found this document useful (4 votes)
9 views

(eBook PDF) Data Structures & Algorithm Analysis in C++ 4th Edition download

The document provides information on various eBooks related to data structures and algorithm analysis, specifically in C++ and Java. It includes links to download different editions of these eBooks, along with a detailed table of contents outlining the chapters and topics covered in the 'Data Structures & Algorithm Analysis in C++ 4th Edition'. The content spans fundamental programming concepts, algorithm analysis, data structures, and advanced topics such as graph algorithms and algorithm design techniques.

Uploaded by

owneylynem31
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 59

(eBook PDF) Data Structures & Algorithm Analysis

in C++ 4th Edition download

https://ebookluna.com/product/ebook-pdf-data-structures-
algorithm-analysis-in-c-4th-edition/

Download full version ebook from https://ebookluna.com


We believe these products will be a great fit for you. Click
the link to download now, or visit ebookluna.com
to discover even more!

Data Structures & Algorithm Analysis in C++ 4th Edition (eBook PDF)

https://ebookluna.com/product/data-structures-algorithm-analysis-in-c-4th-
edition-ebook-pdf/

(eBook PDF) Starting Out with Java: From Control Structures through Data
Structures 4th Edition

https://ebookluna.com/product/ebook-pdf-starting-out-with-java-from-
control-structures-through-data-structures-4th-edition/

Data Structures - eBook PDF

https://ebookluna.com/download/data-structures-ebook-pdf/

C++ Programming. Program Design including Data Structures 8th Edition D.S.
Malik - eBook PDF

https://ebookluna.com/download/c-programming-program-design-including-data-
structures-ebook-pdf/
(eBook PDF) Data Structures and Abstractions with Java 4th Edition

https://ebookluna.com/product/ebook-pdf-data-structures-and-abstractions-
with-java-4th-edition/

(eBook PDF) Data Structures and Abstractions with Java 4th Global Edition

https://ebookluna.com/product/ebook-pdf-data-structures-and-abstractions-
with-java-4th-global-edition/

(eBook PDF) Data Structures and Other Objects Using Java 4th Edition

https://ebookluna.com/product/ebook-pdf-data-structures-and-other-objects-
using-java-4th-edition/

(eBook PDF) Data Structures and Problem Solving Using Java 4th Edition

https://ebookluna.com/product/ebook-pdf-data-structures-and-problem-
solving-using-java-4th-edition/

Data Structures & Algorithms in Python 1st Edition John Canning - eBook PDF

https://ebookluna.com/download/data-structures-algorithms-in-python-ebook-
pdf-2/
CO NTE NTS

Preface xv

Chapter 1 Programming: A General Overview 1


1.1 What’s This Book About? 1
1.2 Mathematics Review 2
1.2.1 Exponents 3
1.2.2 Logarithms 3
1.2.3 Series 4
1.2.4 Modular Arithmetic 5
1.2.5 The P Word 6
1.3 A Brief Introduction to Recursion 8
1.4 C++ Classes 12
1.4.1 Basic class Syntax 12
1.4.2 Extra Constructor Syntax and Accessors 13
1.4.3 Separation of Interface and Implementation 16
1.4.4 vector and string 19
1.5 C++ Details 21
1.5.1 Pointers 21
1.5.2 Lvalues, Rvalues, and References 23
1.5.3 Parameter Passing 25
1.5.4 Return Passing 27
1.5.5 std::swap and std::move 29
1.5.6 The Big-Five: Destructor, Copy Constructor, Move Constructor, Copy
Assignment operator=, Move Assignment operator= 30
1.5.7 C-style Arrays and Strings 35
1.6 Templates 36
1.6.1 Function Templates 37
1.6.2 Class Templates 38
1.6.3 Object, Comparable, and an Example 39
1.6.4 Function Objects 41
1.6.5 Separate Compilation of Class Templates 44
1.7 Using Matrices 44
1.7.1 The Data Members, Constructor, and Basic Accessors 44
1.7.2 operator[] 45
vii
viii Contents

1.7.3 Big-Five 46
Summary 46
Exercises 46
References 48

Chapter 2 Algorithm Analysis 51


2.1 Mathematical Background 51
2.2 Model 54
2.3 What to Analyze 54
2.4 Running-Time Calculations 57
2.4.1 A Simple Example 58
2.4.2 General Rules 58
2.4.3 Solutions for the Maximum Subsequence
Sum Problem 60
2.4.4 Logarithms in the Running Time 66
2.4.5 Limitations of Worst-Case Analysis 70
Summary 70
Exercises 71
References 76

Chapter 3 Lists, Stacks, and Queues 77


3.1 Abstract Data Types (ADTs) 77
3.2 The List ADT 78
3.2.1 Simple Array Implementation of Lists 78
3.2.2 Simple Linked Lists 79
3.3 vector and list in the STL 80
3.3.1 Iterators 82
3.3.2 Example: Using erase on a List 83
3.3.3 const_iterators 84
3.4 Implementation of vector 86
3.5 Implementation of list 91
3.6 The Stack ADT 103
3.6.1 Stack Model 103
3.6.2 Implementation of Stacks 104
3.6.3 Applications 104
3.7 The Queue ADT 112
3.7.1 Queue Model 113
3.7.2 Array Implementation of Queues 113
3.7.3 Applications of Queues 115
Summary 116
Exercises 116
Contents ix

Chapter 4 Trees 121


4.1 Preliminaries 121
4.1.1 Implementation of Trees 122
4.1.2 Tree Traversals with an Application 123
4.2 Binary Trees 126
4.2.1 Implementation 128
4.2.2 An Example: Expression Trees 128
4.3 The Search Tree ADT—Binary Search Trees 132
4.3.1 contains 134
4.3.2 findMin and findMax 135
4.3.3 insert 136
4.3.4 remove 139
4.3.5 Destructor and Copy Constructor 141
4.3.6 Average-Case Analysis 141
4.4 AVL Trees 144
4.4.1 Single Rotation 147
4.4.2 Double Rotation 149
4.5 Splay Trees 158
4.5.1 A Simple Idea (That Does Not Work) 158
4.5.2 Splaying 160
4.6 Tree Traversals (Revisited) 166
4.7 B-Trees 168
4.8 Sets and Maps in the Standard Library 173
4.8.1 Sets 173
4.8.2 Maps 174
4.8.3 Implementation of set and map 175
4.8.4 An Example That Uses Several Maps 176
Summary 181
Exercises 182
References 189

Chapter 5 Hashing 193


5.1 General Idea 193
5.2 Hash Function 194
5.3 Separate Chaining 196
5.4 Hash Tables without Linked Lists 201
5.4.1 Linear Probing 201
5.4.2 Quadratic Probing 202
5.4.3 Double Hashing 207
5.5 Rehashing 208
5.6 Hash Tables in the Standard Library 210
x Contents

5.7 Hash Tables with Worst-Case O(1) Access 212


5.7.1 Perfect Hashing 213
5.7.2 Cuckoo Hashing 215
5.7.3 Hopscotch Hashing 227
5.8 Universal Hashing 230
5.9 Extendible Hashing 233
Summary 236
Exercises 237
References 241

Chapter 6 Priority Queues (Heaps) 245


6.1 Model 245
6.2 Simple Implementations 246
6.3 Binary Heap 247
6.3.1 Structure Property 247
6.3.2 Heap-Order Property 248
6.3.3 Basic Heap Operations 249
6.3.4 Other Heap Operations 252
6.4 Applications of Priority Queues 257
6.4.1 The Selection Problem 258
6.4.2 Event Simulation 259
6.5 d-Heaps 260
6.6 Leftist Heaps 261
6.6.1 Leftist Heap Property 261
6.6.2 Leftist Heap Operations 262
6.7 Skew Heaps 269
6.8 Binomial Queues 271
6.8.1 Binomial Queue Structure 271
6.8.2 Binomial Queue Operations 271
6.8.3 Implementation of Binomial Queues 276
6.9 Priority Queues in the Standard Library 282
Summary 283
Exercises 283
References 288

Chapter 7 Sorting 291


7.1 Preliminaries 291
7.2 Insertion Sort 292
7.2.1 The Algorithm 292
7.2.2 STL Implementation of Insertion Sort 293
7.2.3 Analysis of Insertion Sort 294
7.3 A Lower Bound for Simple Sorting Algorithms 295
Contents xi

7.4 Shellsort 296


7.4.1 Worst-Case Analysis of Shellsort 297
7.5 Heapsort 300
7.5.1 Analysis of Heapsort 301
7.6 Mergesort 304
7.6.1 Analysis of Mergesort 306
7.7 Quicksort 309
7.7.1 Picking the Pivot 311
7.7.2 Partitioning Strategy 313
7.7.3 Small Arrays 315
7.7.4 Actual Quicksort Routines 315
7.7.5 Analysis of Quicksort 318
7.7.6 A Linear-Expected-Time Algorithm for Selection 321
7.8 A General Lower Bound for Sorting 323
7.8.1 Decision Trees 323
7.9 Decision-Tree Lower Bounds for Selection Problems 325
7.10 Adversary Lower Bounds 328
7.11 Linear-Time Sorts: Bucket Sort and Radix Sort 331
7.12 External Sorting 336
7.12.1 Why We Need New Algorithms 336
7.12.2 Model for External Sorting 336
7.12.3 The Simple Algorithm 337
7.12.4 Multiway Merge 338
7.12.5 Polyphase Merge 339
7.12.6 Replacement Selection 340
Summary 341
Exercises 341
References 347

Chapter 8 The Disjoint Sets Class 351


8.1 Equivalence Relations 351
8.2 The Dynamic Equivalence Problem 352
8.3 Basic Data Structure 353
8.4 Smart Union Algorithms 357
8.5 Path Compression 360
8.6 Worst Case for Union-by-Rank and Path Compression 361
8.6.1 Slowly Growing Functions 362
8.6.2 An Analysis by Recursive Decomposition 362
8.6.3 An O( M log * N ) Bound 369
8.6.4 An O( M α(M, N) ) Bound 370
8.7 An Application 372
xii Contents

Summary 374
Exercises 375
References 376

Chapter 9 Graph Algorithms 379


9.1 Definitions 379
9.1.1 Representation of Graphs 380
9.2 Topological Sort 382
9.3 Shortest-Path Algorithms 386
9.3.1 Unweighted Shortest Paths 387
9.3.2 Dijkstra’s Algorithm 391
9.3.3 Graphs with Negative Edge Costs 400
9.3.4 Acyclic Graphs 400
9.3.5 All-Pairs Shortest Path 404
9.3.6 Shortest Path Example 404
9.4 Network Flow Problems 406
9.4.1 A Simple Maximum-Flow Algorithm 408
9.5 Minimum Spanning Tree 413
9.5.1 Prim’s Algorithm 414
9.5.2 Kruskal’s Algorithm 417
9.6 Applications of Depth-First Search 419
9.6.1 Undirected Graphs 420
9.6.2 Biconnectivity 421
9.6.3 Euler Circuits 425
9.6.4 Directed Graphs 429
9.6.5 Finding Strong Components 431
9.7 Introduction to NP-Completeness 432
9.7.1 Easy vs. Hard 433
9.7.2 The Class NP 434
9.7.3 NP-Complete Problems 434
Summary 437
Exercises 437
References 445

Chapter 10 Algorithm Design Techniques 449


10.1 Greedy Algorithms 449
10.1.1 A Simple Scheduling Problem 450
10.1.2 Huffman Codes 453
10.1.3 Approximate Bin Packing 459
10.2 Divide and Conquer 467
10.2.1 Running Time of Divide-and-Conquer Algorithms 468
10.2.2 Closest-Points Problem 470
Contents xiii

10.2.3 The Selection Problem 475


10.2.4 Theoretical Improvements for Arithmetic Problems 478
10.3 Dynamic Programming 482
10.3.1 Using a Table Instead of Recursion 483
10.3.2 Ordering Matrix Multiplications 485
10.3.3 Optimal Binary Search Tree 487
10.3.4 All-Pairs Shortest Path 491
10.4 Randomized Algorithms 494
10.4.1 Random-Number Generators 495
10.4.2 Skip Lists 500
10.4.3 Primality Testing 503
10.5 Backtracking Algorithms 506
10.5.1 The Turnpike Reconstruction Problem 506
10.5.2 Games 511
Summary 518
Exercises 518
References 527

Chapter 11 Amortized Analysis 533


11.1 An Unrelated Puzzle 534
11.2 Binomial Queues 534
11.3 Skew Heaps 539
11.4 Fibonacci Heaps 541
11.4.1 Cutting Nodes in Leftist Heaps 542
11.4.2 Lazy Merging for Binomial Queues 544
11.4.3 The Fibonacci Heap Operations 548
11.4.4 Proof of the Time Bound 549
11.5 Splay Trees 551
Summary 555
Exercises 556
References 557

Chapter 12 Advanced Data Structures


and Implementation 559
12.1 Top-Down Splay Trees 559
12.2 Red-Black Trees 566
12.2.1 Bottom-Up Insertion 567
12.2.2 Top-Down Red-Black Trees 568
12.2.3 Top-Down Deletion 570
12.3 Treaps 576
xiv Contents

12.4 Suffix Arrays and Suffix Trees 579


12.4.1 Suffix Arrays 580
12.4.2 Suffix Trees 583
12.4.3 Linear-Time Construction of Suffix Arrays and Suffix Trees 586
12.5 k-d Trees 596
12.6 Pairing Heaps 602
Summary 606
Exercises 608
References 612

Appendix A Separate Compilation of


Class Templates 615
A.1 Everything in the Header 616
A.2 Explicit Instantiation 616

Index 619
P R E FAC E

Purpose/Goals
The fourth edition of Data Structures and Algorithm Analysis in C++ describes data structures,
methods of organizing large amounts of data, and algorithm analysis, the estimation of the
running time of algorithms. As computers become faster and faster, the need for programs
that can handle large amounts of input becomes more acute. Paradoxically, this requires
more careful attention to efficiency, since inefficiencies in programs become most obvious
when input sizes are large. By analyzing an algorithm before it is actually coded, students
can decide if a particular solution will be feasible. For example, in this text students look at
specific problems and see how careful implementations can reduce the time constraint for
large amounts of data from centuries to less than a second. Therefore, no algorithm or data
structure is presented without an explanation of its running time. In some cases, minute
details that affect the running time of the implementation are explored.
Once a solution method is determined, a program must still be written. As computers
have become more powerful, the problems they must solve have become larger and more
complex, requiring development of more intricate programs. The goal of this text is to teach
students good programming and algorithm analysis skills simultaneously so that they can
develop such programs with the maximum amount of efficiency.
This book is suitable for either an advanced data structures course or a first-year
graduate course in algorithm analysis. Students should have some knowledge of inter-
mediate programming, including such topics as pointers, recursion, and object-based
programming, as well as some background in discrete math.

Approach
Although the material in this text is largely language-independent, programming requires
the use of a specific language. As the title implies, we have chosen C++ for this book.
C++ has become a leading systems programming language. In addition to fixing many
of the syntactic flaws of C, C++ provides direct constructs (the class and template) to
implement generic data structures as abstract data types.
The most difficult part of writing this book was deciding on the amount of C++ to
include. Use too many features of C++ and one gets an incomprehensible text; use too few
and you have little more than a C text that supports classes.
The approach we take is to present the material in an object-based approach. As such,
there is almost no use of inheritance in the text. We use class templates to describe generic
data structures. We generally avoid esoteric C++ features and use the vector and string
classes that are now part of the C++ standard. Previous editions have implemented class
templates by separating the class template interface from its implementation. Although
this is arguably the preferred approach, it exposes compiler problems that have made it xv
xvi Preface

difficult for readers to actually use the code. As a result, in this edition the online code
represents class templates as a single unit, with no separation of interface and implementa-
tion. Chapter 1 provides a review of the C++ features that are used throughout the text and
describes our approach to class templates. Appendix A describes how the class templates
could be rewritten to use separate compilation.
Complete versions of the data structures, in both C++ and Java, are available on
the Internet. We use similar coding conventions to make the parallels between the two
languages more evident.

Summary of the Most Significant Changes in the Fourth Edition


The fourth edition incorporates numerous bug fixes, and many parts of the book have
undergone revision to increase the clarity of presentation. In addition,

r Chapter 4 includes implementation of the AVL tree deletion algorithm—a topic often
requested by readers.
r Chapter 5 has been extensively revised and enlarged and now contains material on
two newer algorithms: cuckoo hashing and hopscotch hashing. Additionally, a new
section on universal hashing has been added. Also new is a brief discussion of the
unordered_set and unordered_map class templates introduced in C++11.
r Chapter 6 is mostly unchanged; however, the implementation of the binary heap makes
use of move operations that were introduced in C++11.
r Chapter 7 now contains material on radix sort, and a new section on lower-bound
proofs has been added. Sorting code makes use of move operations that were
introduced in C++11.
r Chapter 8 uses the new union/find analysis by Seidel and Sharir and shows the
O( M α(M, N) ) bound instead of the weaker O( M log∗ N ) bound in prior editions.
r Chapter 12 adds material on suffix trees and suffix arrays, including the linear-time
suffix array construction algorithm by Karkkainen and Sanders (with implementation).
The sections covering deterministic skip lists and AA-trees have been removed.
r Throughout the text, the code has been updated to use C++11. Notably, this means
use of the new C++11 features, including the auto keyword, the range for loop, move
construction and assignment, and uniform initialization.

Overview
Chapter 1 contains review material on discrete math and recursion. I believe the only way
to be comfortable with recursion is to see good uses over and over. Therefore, recursion
is prevalent in this text, with examples in every chapter except Chapter 5. Chapter 1 also
includes material that serves as a review of basic C++. Included is a discussion of templates
and important constructs in C++ class design.
Chapter 2 deals with algorithm analysis. This chapter explains asymptotic analysis
and its major weaknesses. Many examples are provided, including an in-depth explana-
tion of logarithmic running time. Simple recursive programs are analyzed by intuitively
converting them into iterative programs. More complicated divide-and-conquer programs
are introduced, but some of the analysis (solving recurrence relations) is implicitly delayed
until Chapter 7, where it is performed in detail.
Preface xvii

Chapter 3 covers lists, stacks, and queues. This chapter includes a discussion of the STL
vector and list classes, including material on iterators, and it provides implementations
of a significant subset of the STL vector and list classes.
Chapter 4 covers trees, with an emphasis on search trees, including external search
trees (B-trees). The UNIX file system and expression trees are used as examples. AVL trees
and splay trees are introduced. More careful treatment of search tree implementation details
is found in Chapter 12. Additional coverage of trees, such as file compression and game
trees, is deferred until Chapter 10. Data structures for an external medium are considered
as the final topic in several chapters. Included is a discussion of the STL set and map classes,
including a significant example that illustrates the use of three separate maps to efficiently
solve a problem.
Chapter 5 discusses hash tables, including the classic algorithms such as sepa-
rate chaining and linear and quadratic probing, as well as several newer algorithms,
namely cuckoo hashing and hopscotch hashing. Universal hashing is also discussed, and
extendible hashing is covered at the end of the chapter.
Chapter 6 is about priority queues. Binary heaps are covered, and there is additional
material on some of the theoretically interesting implementations of priority queues. The
Fibonacci heap is discussed in Chapter 11, and the pairing heap is discussed in Chapter 12.
Chapter 7 covers sorting. It is very specific with respect to coding details and analysis.
All the important general-purpose sorting algorithms are covered and compared. Four
algorithms are analyzed in detail: insertion sort, Shellsort, heapsort, and quicksort. New to
this edition is radix sort and lower bound proofs for selection-related problems. External
sorting is covered at the end of the chapter.
Chapter 8 discusses the disjoint set algorithm with proof of the running time. This is a
short and specific chapter that can be skipped if Kruskal’s algorithm is not discussed.
Chapter 9 covers graph algorithms. Algorithms on graphs are interesting, not only
because they frequently occur in practice but also because their running time is so heavily
dependent on the proper use of data structures. Virtually all of the standard algorithms
are presented along with appropriate data structures, pseudocode, and analysis of running
time. To place these problems in a proper context, a short discussion on complexity theory
(including NP-completeness and undecidability) is provided.
Chapter 10 covers algorithm design by examining common problem-solving tech-
niques. This chapter is heavily fortified with examples. Pseudocode is used in these later
chapters so that the student’s appreciation of an example algorithm is not obscured by
implementation details.
Chapter 11 deals with amortized analysis. Three data structures from Chapters 4 and
6 and the Fibonacci heap, introduced in this chapter, are analyzed.
Chapter 12 covers search tree algorithms, the suffix tree and array, the k-d tree, and
the pairing heap. This chapter departs from the rest of the text by providing complete and
careful implementations for the search trees and pairing heap. The material is structured so
that the instructor can integrate sections into discussions from other chapters. For example,
the top-down red-black tree in Chapter 12 can be discussed along with AVL trees (in
Chapter 4).
Chapters 1 to 9 provide enough material for most one-semester data structures courses.
If time permits, then Chapter 10 can be covered. A graduate course on algorithm analysis
could cover chapters 7 to 11. The advanced data structures analyzed in Chapter 11 can
easily be referred to in the earlier chapters. The discussion of NP-completeness in Chapter 9
xviii Preface

is far too brief to be used in such a course. You might find it useful to use an additional
work on NP-completeness to augment this text.

Exercises
Exercises, provided at the end of each chapter, match the order in which material is pre-
sented. The last exercises may address the chapter as a whole rather than a specific section.
Difficult exercises are marked with an asterisk, and more challenging exercises have two
asterisks.

References
References are placed at the end of each chapter. Generally the references either are his-
torical, representing the original source of the material, or they represent extensions and
improvements to the results given in the text. Some references represent solutions to
exercises.

Supplements
The following supplements are available to all readers at http://cssupport.pearsoncmg.com/

r Source code for example programs


r Errata

In addition, the following material is available only to qualified instructors at Pearson


Instructor Resource Center (www.pearsonhighered.com/irc). Visit the IRC or contact your
Pearson Education sales representative for access.

r Solutions to selected exercises


r Figures from the book
r Errata

Acknowledgments
Many, many people have helped me in the preparation of books in this series. Some are
listed in other versions of the book; thanks to all.
As usual, the writing process was made easier by the professionals at Pearson. I’d like
to thank my editor, Tracy Johnson, and production editor, Marilyn Lloyd. My wonderful
wife Jill deserves extra special thanks for everything she does.
Finally, I’d like to thank the numerous readers who have sent e-mail messages and
pointed out errors or inconsistencies in earlier versions. My website www.cis.fiu.edu/~weiss
will also contain updated source code (in C++ and Java), an errata list, and a link to submit
bug reports.
M.A.W.
Miami, Florida
C H A P T E R 1

Programming: A General
Overview

In this chapter, we discuss the aims and goals of this text and briefly review programming
concepts and discrete mathematics. We will . . .

r See that how a program performs for reasonably large input is just as important as its
performance on moderate amounts of input.
r Summarize the basic mathematical background needed for the rest of the book.
r Briefly review recursion.
r Summarize some important features of C++ that are used throughout the text.

1.1 What’s This Book About?


Suppose you have a group of N numbers and would like to determine the kth largest. This
is known as the selection problem. Most students who have had a programming course
or two would have no difficulty writing a program to solve this problem. There are quite a
few “obvious” solutions.
One way to solve this problem would be to read the N numbers into an array, sort the
array in decreasing order by some simple algorithm such as bubble sort, and then return
the element in position k.
A somewhat better algorithm might be to read the first k elements into an array and
sort them (in decreasing order). Next, each remaining element is read one by one. As a new
element arrives, it is ignored if it is smaller than the kth element in the array. Otherwise, it
is placed in its correct spot in the array, bumping one element out of the array. When the
algorithm ends, the element in the kth position is returned as the answer.
Both algorithms are simple to code, and you are encouraged to do so. The natural ques-
tions, then, are: Which algorithm is better? And, more important, Is either algorithm good
enough? A simulation using a random file of 30 million elements and k = 15,000,000
will show that neither algorithm finishes in a reasonable amount of time; each requires
several days of computer processing to terminate (albeit eventually with a correct answer).
An alternative method, discussed in Chapter 7, gives a solution in about a second. Thus,
although our proposed algorithms work, they cannot be considered good algorithms, 1
2 Chapter 1 Programming: A General Overview

1 2 3 4

1 t h i s
2 w a t s
3 o a h g
4 f g d t

Figure 1.1 Sample word puzzle

because they are entirely impractical for input sizes that a third algorithm can handle in a
reasonable amount of time.
A second problem is to solve a popular word puzzle. The input consists of a two-
dimensional array of letters and a list of words. The object is to find the words in the puzzle.
These words may be horizontal, vertical, or diagonal in any direction. As an example, the
puzzle shown in Figure 1.1 contains the words this, two, fat, and that. The word this begins
at row 1, column 1, or (1,1), and extends to (1,4); two goes from (1,1) to (3,1); fat goes
from (4,1) to (2,3); and that goes from (4,4) to (1,1).
Again, there are at least two straightforward algorithms that solve the problem. For each
word in the word list, we check each ordered triple (row, column, orientation) for the pres-
ence of the word. This amounts to lots of nested for loops but is basically straightforward.
Alternatively, for each ordered quadruple (row, column, orientation, number of characters)
that doesn’t run off an end of the puzzle, we can test whether the word indicated is in the
word list. Again, this amounts to lots of nested for loops. It is possible to save some time
if the maximum number of characters in any word is known.
It is relatively easy to code up either method of solution and solve many of the real-life
puzzles commonly published in magazines. These typically have 16 rows, 16 columns, and
40 or so words. Suppose, however, we consider the variation where only the puzzle board is
given and the word list is essentially an English dictionary. Both of the solutions proposed
require considerable time to solve this problem and therefore might not be acceptable.
However, it is possible, even with a large word list, to solve the problem very quickly.
An important concept is that, in many problems, writing a working program is not
good enough. If the program is to be run on a large data set, then the running time becomes
an issue. Throughout this book we will see how to estimate the running time of a program
for large inputs and, more important, how to compare the running times of two programs
without actually coding them. We will see techniques for drastically improving the speed
of a program and for determining program bottlenecks. These techniques will enable us to
find the section of the code on which to concentrate our optimization efforts.

1.2 Mathematics Review


This section lists some of the basic formulas you need to memorize, or be able to derive,
and reviews basic proof techniques.
1.2 Mathematics Review 3

1.2.1 Exponents
XA XB = XA+B
XA
= XA−B
XB
(XA )B = XAB
XN + XN = 2XN = X2N
2N + 2N = 2N+1

1.2.2 Logarithms
In computer science, all logarithms are to the base 2 unless specified otherwise.
Definition 1.1
XA = B if and only if logX B = A
Several convenient equalities follow from this definition.
Theorem 1.1

logC B
logA B = ; A, B, C > 0, A = 1
logC A

Proof
Let X = logC B, Y = logC A, and Z = logA B. Then, by the definition of loga-
rithms, CX = B, CY = A, and AZ = B. Combining these three equalities yields
B = CX = (CY )Z . Therefore, X = YZ, which implies Z = X/Y, proving the theorem.
Theorem 1.2

log AB = log A + log B; A, B > 0

Proof
Let X = log A, Y = log B, and Z = log AB. Then, assuming the default base of 2,
2X = A, 2Y = B, and 2Z = AB. Combining the last three equalities yields
2X 2Y = AB = 2Z . Therefore, X + Y = Z, which proves the theorem.
Some other useful formulas, which can all be derived in a similar manner, follow.

log A/B = log A − log B

log(AB ) = B log A

log X < X for all X > 0

log 1 = 0, log 2 = 1, log 1,024 = 10, log 1,048,576 = 20


4 Chapter 1 Programming: A General Overview

1.2.3 Series
The easiest formulas to remember are

N
2i = 2N+1 − 1
i=0

and the companion,



N
AN+1 − 1
Ai =
A−1
i=0

In the latter formula, if 0 < A < 1, then



N
1
Ai ≤
1−A
i=0

and as N tends to ∞, the sum approaches 1/(1 − A). These are the “geometric series”
formulas. 
We can derive the last formula for ∞i=0 A (0 < A < 1) in the following manner. Let
i

S be the sum. Then


S = 1 + A + A2 + A3 + A4 + A5 + · · ·
Then
AS = A + A2 + A3 + A4 + A5 + · · ·
If we subtract these two equations (which is permissible only for a convergent series),
virtually all the terms on the right side cancel, leaving
S − AS = 1
which implies that
1
S=
1−A

We can use this same technique to compute ∞ i
i=1 i/2 , a sum that occurs frequently.
We write
1 2 3 4 5
S = + 2 + 3 + 4 + 5 + ···
2 2 2 2 2
and multiply by 2, obtaining
2 3 4 5 6
2S = 1 + + + 3 + 4 + 5 + ···
2 22 2 2 2
Subtracting these two equations yields
1 1 1 1 1
S=1+ + + 3 + 4 + 5 + ···
2 22 2 2 2
Thus, S = 2.
1.2 Mathematics Review 5

Another type of common series in analysis is the arithmetic series. Any such series can
be evaluated from the basic formula:


N
N(N + 1) N2
i= ≈
2 2
i=1

For instance, to find the sum 2 + 5 + 8 + · · · + (3k − 1), rewrite it as 3(1 + 2 + 3 +


· · · + k) − (1 + 1 + 1 + · · · + 1), which is clearly 3k(k + 1)/2 − k. Another way to remember
this is to add the first and last terms (total 3k + 1), the second and next-to-last terms (total
3k + 1), and so on. Since there are k/2 of these pairs, the total sum is k(3k + 1)/2, which
is the same answer as before.
The next two formulas pop up now and then but are fairly uncommon.


N
N(N + 1)(2N + 1) N3
i2 = ≈
6 3
i=1

N
Nk+1
ik ≈ k = −1
|k + 1|
i=1

When k = −1, the latter formula is not valid. We then need the following formula,
which is used far more in computer science than in other mathematical disciplines. The
numbers HN are known as the harmonic numbers, and the sum is known as a harmonic
sum. The error in the following approximation tends to γ ≈ 0.57721566, which is known
as Euler’s constant.


N
1
HN = ≈ loge N
i
i=1

These two formulas are just general algebraic manipulations:


N
f(N) = Nf(N)
i=1

N 
N 0 −1
n
f(i) = f(i) − f(i)
i=n0 i=1 i=1

1.2.4 Modular Arithmetic


We say that A is congruent to B modulo N, written A ≡ B (mod N), if N divides
A − B. Intuitively, this means that the remainder is the same when either A or B is
divided by N. Thus, 81 ≡ 61 ≡ 1 (mod 10). As with equality, if A ≡ B (mod N), then
A + C ≡ B + C (mod N) and AD ≡ BD (mod N).
6 Chapter 1 Programming: A General Overview

Often, N is a prime number. In that case, there are three important theorems:

First, if N is prime, then ab ≡ 0 (mod N) is true if and only if a ≡ 0 (mod N)


or b ≡ 0 (mod N). In other words, if a prime number N divides a product of two
numbers, it divides at least one of the two numbers.
Second, if N is prime, then the equation ax ≡ 1 (mod N) has a unique solution
(mod N) for all 0 < a < N. This solution, 0 < x < N, is the multiplicative inverse.
Third, if N is prime, then the equation x2 ≡ a (mod N) has either two solutions
(mod N) for all 0 < a < N, or it has no solutions.

There are many theorems that apply to modular arithmetic, and some of them require
extraordinary proofs in number theory. We will use modular arithmetic sparingly, and the
preceding theorems will suffice.

1.2.5 The P Word


The two most common ways of proving statements in data-structure analysis are proof
by induction and proof by contradiction (and occasionally proof by intimidation, used
by professors only). The best way of proving that a theorem is false is by exhibiting a
counterexample.

Proof by Induction
A proof by induction has two standard parts. The first step is proving a base case, that is,
establishing that a theorem is true for some small (usually degenerate) value(s); this step is
almost always trivial. Next, an inductive hypothesis is assumed. Generally this means that
the theorem is assumed to be true for all cases up to some limit k. Using this assumption,
the theorem is then shown to be true for the next value, which is typically k + 1. This
proves the theorem (as long as k is finite).
As an example, we prove that the Fibonacci numbers, F0 = 1, F1 = 1, F2 = 2, F3 = 3,
F4 = 5, . . . , Fi = Fi−1 + Fi−2 , satisfy Fi < (5/3)i , for i ≥ 1. (Some definitions have F0 = 0,
which shifts the series.) To do this, we first verify that the theorem is true for the trivial
cases. It is easy to verify that F1 = 1 < 5/3 and F2 = 2 < 25/9; this proves the basis.
We assume that the theorem is true for i = 1, 2, . . . , k; this is the inductive hypothesis. To
prove the theorem, we need to show that Fk+1 < (5/3)k+1 . We have

Fk+1 = Fk + Fk−1

by the definition, and we can use the inductive hypothesis on the right-hand side,
obtaining

Fk+1 < (5/3)k + (5/3)k−1


< (3/5)(5/3)k+1 + (3/5)2 (5/3)k+1
< (3/5)(5/3)k+1 + (9/25)(5/3)k+1
which simplifies to
Discovering Diverse Content Through
Random Scribd Documents
General paralysis of the
5,248 648
insane
Other forms of mental
1,651 3,895
alienation
——— ———
Total 15,080 12,987

The contributory causes definitely showing mental diseases


constitute only 3.4 per cent of the whole number, and the death rate
for 1917, including both primary and contributory causes suggestive
of probable psychoses, was 37.2 per 100,000. This would indicate
that the number of deaths from mental diseases shown in the
primary causes represents only about fifty-three per cent of all
mental cases which are actual factors in determining the death rate
of the community. A comparison of these figures with the number of
cases dying in hospitals shows that they cannot be looked upon as
determining the percentage of the general population showing
psychoses. Of the 1,952 persons dying in the institutions for mental
diseases in Massachusetts in 1919, approximately nineteen per cent
showed the psychoses in the primary causes of death. This
percentage would probably be fairly constant throughout the
country. It is, of course, a well recognized fact that the death
certificate at best is not beyond suspicion and does not furnish
information regarding the cause of death which can be accepted
without question.
Dr. Richard C. Cabot[1] has made an elaborate study of errors in
diagnosis as shown by autopsies. His work shows the following
percentage of diagnostic accuracy:
Per cent.
Diabetes mellitus 95
Typhoid fever 92
Aortic regurgitation 84
Lobar pneumonia 74
Cerebral tumor 72.8
Tubercular meningitis 72
Gastric cancer 72
Mitral stenosis 69
Brain hemorrhage 67
Aortic stenosis 61
Phthisis, active 59
Miliary tuberculosis 52
Chronic interstitial nephritis 50
Hepatic cirrhosis 39
Acute endocarditis 39
Bronchopneumonia 33
Acute nephritis 16

It must be admitted that Cabot's findings are discouraging. They


are not so bad as they would seem, however, at first thought. Death
certificates, unfortunately, do not have the significance which they
should have. Physicians are well known to be entirely too careless in
their preparation and inclined to look upon them merely as legal
formalities which cannot readily be avoided. It is furthermore
difficult, as every doctor knows, to point to one immediate primary
cause of death in every instance. Very often there is a combination
of factors concerned and it is possible at practically every autopsy to
find lesions not represented in any way whatever in the death
certificate. It is unquestionably true that statistics of any kind must
be based on information some of which we know to be inaccurate.
This should not be used as an argument for discontinuing,
absolutely, our search for knowledge. It is merely a reason why our
clinical standards should be improved.
An exceedingly important contribution to our rather limited fund
of accurate information regarding the general health of the country
was the publication recently issued by the Metropolitan Life
Insurance Company[2] on the mortality statistics of wage earners
and their families. This covers a period of six years (1911 to 1916)
and represents a study of 635,449 deaths. The cases reported came
from every state in the union with the following exceptions:
Mississippi, North Dakota, South Dakota, Wyoming, Colorado, Texas,
Nevada, Arizona and New Mexico. Canada and many other localities
outside of the "Registration Area" of the United States Census
Bureau were included. The facts presented in this report are unique
in that they render available for the first time a careful and detailed
consideration of the diseases which may be looked upon as
representative of the industrial population of the country. The
various occupations shown in the order of their numerical
importance were as follows:—Laborers, teamsters, drivers and
chauffeurs, machinists, textile mill operatives, clerks, office
assistants, etc. It covers a study of ten million policy holders and
nearly fifty-four million years of life in the aggregate. The age
groups studied range from one year to seventy-five in ratios not very
different from those exhibited in the general population. The death
rate for all persons exposed was 11.81 per 1,000 as compared with
a rate of over thirteen per 1,000 (white) of the general population of
the registration area during the same period of time. The death rate
per 100,000 from 1911 to 1916 of some of the more important
general diseases was as follows:

Typhoid fever 16.8


Diphtheria and croup 24.3
Scarlet fever 8.6
Acute articular rheumatism 6.3
Diabetes 14.4
Cancer and other malignant tumors 70.0
Bronchopneumonia 30.2
Diarrhea and enteritis (over two years old) 13.9
Cirrhosis of the liver 15.0
Puerperal septicemia 8.1
Accidents of all forms 75.1
Ill-defined diseases 10.1
Measles 8.9
Influenza 15.0
Tuberculosis (all forms) 205.1
Tuberculosis (pulmonary) 173.9
Alcoholism 4.7
Diseases of the arteries, including atheroma,
17.0
aneurysm, etc.
Pneumonia (lobar and undefined) 77.5
Intestinal obstruction 5.9
Bright's disease 96.8
Suicide 12.2
Homicide 7.0

The death rate for syphilis, locomotor ataxia and general


paralysis of the insane, combined, was 14.3 per 100,000. The
percentage of deaths due to diseases of the nervous system, many
of which must be looked upon as probably having been associated
with mental disturbances, is somewhat surprising, as shown by the
following table:

Encephalitis 1.0
Meningitis 7.8
Locomotor ataxia 1.5
Acute anterior poliomyelitis 3.5
Other diseases of the spinal cord 4.0
Cerebral hemorrhage (apoplexy) 68.1
Softening of the brain .9
Paralysis without specified cause 5.2
General paralysis of the insane 4.1
Other forms of mental alienation 1.4
Epilepsy 3.5
Convulsions (non-puerperal) .2
Chorea .2
Neuralgia and neuritis .6
Other diseases of the nervous system 2.5

This shows a total rate of 104.5 per 100,000 due to diseases of


the nervous system. If to this we add those dying of senility and the
suicides as probably representing psychoses it would bring the total
up to 123.2 per 100,000. It must be confessed, however, that such
speculations mean comparatively little.
Practically the only other source of information at our disposal
relative to the incidence of general diseases in the community is the
tabulation of communicable diseases by Boards of Heath. The
annual report of the United States Public Health Service for 1919
shows a case rate for diphtheria of 137 per 100,000 of the
population based on the reports of thirty-seven states. The case rate
for measles in thirty-seven states was 170. Poliomyelitis in thirty
states showed a rate of 2.5 and scarlet fever a rate of 110 in thirty-
seven states. The smallpox rate was sixty-eight and represented
thirty-six states. The typhoid fever rate for thirty-seven states was
only forty. The case rate for tuberculosis, all forms, was 346.7 in
1918. It was 274.2 in New York, 271.6 in the District of Columbia
and 271.3 in New Jersey. These were the highest reported in the
United States during that year. Unfortunately these statistics relate
to communicable diseases only. This difficulty is due largely to the
fact that comparatively few states have made attempts to keep
elaborate records. The reports of Massachusetts are probably as
comprehensive as any. The case rate per 100,000 of the population
of all reportable diseases during the year 1920 was as follows:

Influenza 938.5
Measles 830.7
Pneumonia, lobar 143.6
German measles 12.5
Pulmonary tuberculosis 173.1
Tuberculosis, other forms 20.7
Diphtheria 194.2
Gonorrhea 186.7
Whooping cough 258.3
Scarlet fever 265.2
Chicken pox 138.4
Mumps 154.1
Syphilis 77.2
Ophthalmia 42.3
Typhoid fever 24.2
Dysentery 1.0
Epidemic cerebrospinal meningitis 4.7
Malaria 1.6
Pellagra .4
Smallpox .7
Trachoma 2.2

The case rates for influenza and pneumonia cannot be looked


upon as representative, owing to the epidemic of 1919 and 1920.
During 1917 the death rate from influenza was 12.9 per 100,000 and
from pneumonia 163.8. The death rate from heart diseases (organic
diseases of the heart and endocarditis) in Massachusetts in 1920
was 178 per 100,000 of the population, from apoplexy 108.4, cancer
and other malignant diseases 116.7, Bright's disease and nephritis
92.4, diarrhea and enteritis 52.9, violence 76.3, automobile
accidents and injuries 11.9 and suicides 10.1.
It must be admitted that it is exceedingly difficult to establish a
definite basis for a comparison of our statistics relating to mental
disorders and those dealing with the frequency of other diseases in
the community. As has been shown, our information on the latter
subject, such as it is, has to do only with communicable diseases
and the reported death rates. In making an analysis of the reports of
mental diseases we are limited almost entirely to the institution
population. It is true that these statistics are much more reliable
than the others, as we are dealing with a stable population entirely
under control. The cases, furthermore, are almost invariably subject
to a prolonged observation and careful study. The diagnosis in
almost every instance is based on elaborate mental examinations
and exhaustive personal and family histories. It is, of course, true
that there are innumerable cases of mental diseases outside of
institutions. There were 18,268 patients at home on visit from the
state hospitals alone on January 1, 1920. Those not requiring
hospital treatment or custody in an institution can, however, be
eliminated for the purpose of comparative studies. The fact that an
analysis of death rates alone does not throw any light whatever on
the frequence of psychoses for reasons already given will, I think, be
conceded. For statistical purposes, at least, it may be assumed that
the frequence of mental diseases as shown by a study of the
hospital population is fairly representative of conditions existing in
the community.
For purposes of comparison we may contrast the admission rate
of mental diseases per 100,000 of the population in Massachusetts
in 1920 with the case rate of communicable diseases as follows:

Mental diseases 101.7


Chicken pox 138.4
Diphtheria 194.2
German measles 12.5
Gonorrhea 186.7
Measles 830.7
Mumps 154.1
Scarlet fever 265.2
Syphilis 77.2
Tuberculosis, pulmonary 173.1
Tuberculosis, other forms 20.7
Typhoid fever 24.2
Whooping cough 258.3

The total institution population (mental cases) at the end of the


year 1920 represented a rate of 395.49 per 100,000 of the
population. It should be borne in mind that, with the exception of
tuberculosis and syphilis, the communicable diseases reported above
represent, as a rule, the total number of cases in the state during
the year. Comparative studies should, therefore, be based not on the
number of mental cases in the hospitals at any one given time, but
on the total number under treatment during the year. This would
indicate an incidence of mental diseases of 566.98 per 100,000 of
the population.
On January 1, 1916, there were 147 state and federal institutions
for the care and treatment of mental diseases in the United States,
as shown by the Census Bureau reports. There were at this same
time twenty-seven institutions for the feebleminded, nine for
epileptics, three for inebriates, forty-five for tuberculosis, twenty-
eight for the blind, thirty-three for the deaf, twelve for the blind and
deaf and eighty-four for the dependent classes. [3]
The appropriations for the maintenance of these institutions for
1915 amounted to $33,557,058.29. This constituted 7.6 per cent of
the appropriations made by those states for all purposes. In
Massachusetts it represented 14.8 per cent, in New Hampshire 10.1,
in New York 12.7, in Ohio 12, in Indiana 10.7, in Illinois 13.4, and in
a number of other states over ten per cent of the appropriations for
all purposes. It was equivalent to an average of $431.16 per million
of the total assessed valuation of these states. In Massachusetts it
was as high as $653.62 and in New York $567.37. This means thirty-
three cents per capita for all states, eighty-four cents for
Massachusetts and sixty-eight cents for New York.
The actual expenditure for the maintenance of these institutions
was $36,312,662.20. For purposes of comparison, attention should
be called to the fact that the maintenance of the tuberculosis
hospitals of the United States for the same year cost $3,539,454.95,
institutions for criminals $21,244,892.00, for the feebleminded
$3,341,442.85, for epileptics $1,345,821.57, for the blind
$1,066,973.14, for the deaf $1,893,490.09 and for the dependent
classes $9,675,932.37.
The value of the property invested in the state and federal
hospitals for mental diseases in 1916 was estimated at
$187,028,728.00. The valuation of these institutions per 100,000 of
the population was $184,795.81. This does not include
establishments for mental defectives. The average value per patient
was $938.43. In Massachusetts it was $1,097.85 and in New York
$1,039.85. In Arkansas it was as high as $2,264.00. The total
acreage of land was 109,503.2, an average of 744.9 acres per
hospital. There were 33,124 persons employed, an average of 226.9
for each institution. This represented one employee for every six
patients.
The census taken by the National Committee for Mental Hygiene
[4] in 1920 shows 156 state hospitals for mental diseases, two
federal institutions, 125 county or city hospitals and twenty-one
institutions of a temporary care type. In the public and private
hospitals for mental diseases on January 1, 1920, there were
232,680 patients under treatment. Of these, 200,109 were in public
and 9,238 in private hospitals. This represented an increase of 8,723
in two years. It is interesting to note that city and county institutions
cared for 21,584 persons.
The first authoritative information relative to the institution care
of mental diseases was obtained from the federal census reports of
1880. In that year there were 40,942 patients in the public hospitals.
In 1890 there were 74,028; in 1904, 150,151; in 1910, 187,791; in
1917, 232,873 and in 1918, 239,820. The rate per 100,000 of the
population increased from 81.6 in 1880 to 229.6 in 1918. From 1910
to 1918 the general population increased 13.6 per cent and the
hospital population 27.7 per cent. The rate per 100,000 of the
population in institutions in Massachusetts[5] on January 1, 1920,
was 373.8, in New York 374.6, in Connecticut 317.8, in Iowa 248.1,
in Wisconsin 300.6, in California 297.2, in Pennsylvania 215.2, in
Ohio 212.1, in Illinois 229.5 and in Michigan 210.8. The admission
rate per 100,000 of the population in 1917 was 151.6 in
Massachusetts, 109.2 in Illinois, 124.8 in Montana, 97.3 in New York,
80.9 in Connecticut and 85.7 in California.
The cost of maintenance in the state hospitals increased to
$43,926,888.88 in 1917 with an average per capita cost of $207.28.
The number of cases cared for in some of the more populous states
is of interest. On January 1, 1920, the institution population of New
York was 38,903, Pennsylvania 18,764, Ohio 12,217, Illinois 14,884,
Massachusetts 14,399 and California 10,184.
Based on the estimated population of Massachusetts on July 1,
1920 (3,869,098), the 1,475 deaths in institutions for mental
diseases would represent a death rate of 38.12 per 100,000 of the
population. The death rate for other diseases for that year was:
diphtheria 15.4, measles 9.0, pulmonary tuberculosis 96.7, typhoid
fever 2.5, whooping cough 14.0, scarlet fever 5.5, syphilis 5.8, lobar
pneumonia 71.9 and influenza 43.9. The importance to be attached,
however, to such comparisons is very uncertain at best. From the
standpoint of social and economic importance to the community
there is another factor under consideration which should not be
overlooked. The duration of other diseases, as a general rule, is
comparatively short. A study of over ten thousand deaths in New
York state hospitals for mental diseases shows the average hospital
residence of these cases to have been over six years. At the rate of
admission to public institutions for 1917 (62,898) and the average
per capita cost for that year ($207.28) the care of persons admitted
annually, during their years of hospital life, would mean an
expenditure of over seventy-eight millions of dollars.
If we figured the earning capacity of the 62,000 persons
admitted to institutions for mental diseases in the United States as
averaging only one thousand dollars per year, it would represent an
economic loss to the country of sixty-two millions of dollars annually.
Estimated in the same way, the total population of the hospitals
would represent the staggering sum of nearly two hundred and forty
million dollars. This, of course, does not take into consideration at all
the cost of maintenance or the property investment represented by
hospitals.
To avoid any possibility of confusion, no reference has been
made heretofore to statistical studies of mental deficiency or
epilepsy. From a public health point of view, however, and as social
and economic problems, they are questions which cannot be
disregarded in a consideration of mental diseases. As a matter of
fact, they are very closely correlated in many ways. A survey made
by the National Committee for Mental Hygiene shows that on
January 1, 1920, there were in this country thirty-two state
institutions for mental defectives, eleven admitting both
feebleminded and epileptics and twenty exclusively for the latter
class. [6] In addition to this, one city institution was reported. Of the
private hospitals twenty-seven care for the feebleminded only, and
six for epileptics, while nineteen admit either of these classes. The
total number of mental defectives in institutions on January 1, 1920,
was 40,519. At that time 34,836 were in state, 2,732 in other public
institutions and 2,951 in private hospitals. In the following states
they are cared for in hospitals for mental diseases, no other
provisions having been made for their treatment:—Alabama, Arizona,
Arkansas, Florida, Louisiana, Mississippi, Nevada, South Carolina,
Tennessee, Utah and West Virgina. The states reporting the largest
number are New York 5,762, Pennsylvania 4,281, Massachusetts
3,192, Illinois 3,147, Ohio 2,435, Michigan 1,849, Iowa 1,704, New
Jersey 1,762, Wisconsin 1,624, Minnesota 1,502, Indiana 1,264 and
Missouri 1,047. At the same time there were 14,937 epileptics under
treatment, 13,223 in state, 859 in other public institutions and 855
in private hospitals. Colorado, Delaware, Georgia, Nebraska, New
Mexico and Washington take care of the epileptics in their hospitals
for mental diseases. The intimate relation between mental diseases
and epilepsy is shown by the fact that as nearly as can be
determined at this time approximately thirty per cent of all of the
epileptics in our state institutions have been committed as insane.
This, however, nowhere nearly includes all of the cases which
actually show mental disorders of one kind or another. The states
showing the largest numbers of epileptics are New York with 1,683,
Ohio 1,680 and Massachusetts 1,227. No other states report over
one thousand, although Michigan and Pennsylvania have over eight
hundred and Illinois and Missouri over seven hundred.
Although the incidence of mental as compared with other
diseases prevalent in the community cannot be established with
absolute accuracy, sufficient evidence has been presented to warrant
the statement that from the standpoint of the public health we are
dealing with no other problem of equal importance today. The state
care of mental defects, epilepsy, tuberculosis and the deaf, dumb
and blind is, for various reasons, of much less consequence to the
community than the hospital treatment of mental diseases. The
defective, delinquent, criminal and dependent classes combined do
not equal in number the population housed in our state hospitals for
mental diseases. Nor does the number of cases cared for in the
general hospitals of the state, county or municipal type compare in
any way with the mental cases coming under state or federal
supervision. It can, I think, be said without any fear of contradiction
that no other disease or group of diseases is of equal importance
from a social or economic point of view. Perhaps nothing emphasizes
this fact more strongly than the report recently issued from the
Surgeon General's office relative to the second examination of the
first million recruits drafted in 1917. Twelve per cent of these were
rejected on account of nervous or mental diseases. The number
disqualified for service finally reached a total of over sixty-seven
thousand.
Mental integrity is now looked upon as a military necessity and is
insisted upon as one of the important requirements of the soldier. It
has been demonstrated conclusively that only men of the most
stable mental equilibrium can withstand the stress and strain of
modern methods of warfare. Nor are peacetime requirements any
less exacting. In commercial competition the law of the survival of
the fittest is practically absolute. The feebleminded often inherit
wealth, but they rarely acquire it. Vaccination for the prevention of
smallpox is compulsory and the isolation of communicable diseases
dangerous to the public welfare is rigidly enforced. At the same time
we allow many paranoics the freedom of the country and they
occasionally assassinate a President. Psychopaths are not
infrequently elected to public office and epileptics are not
disqualified from driving high-powered and dangerous motor
vehicles. The engineers of our fastest trains must not be color blind,
but they occasionally are victims of the most fatal of all mental
diseases,—general paresis. The navigating officer of a transatlantic
liner, responsible for the lives of hundreds of passengers, must pass
an examination for a license, but he may be dominated by delusions
which escape observation because they are not looked for. Important
trials, where human lives were at stake, have been presided over by
insane judges. Army officers in command of troops in time of war
have been influenced by imaginary voices. Insurance companies
issue large policies to individuals suffering from incipient mental
diseases which could be detected by even a superficial psychiatric
examination.
Serious consideration should be given to the advisability of
subjecting to a careful mental examination such persons, at least, as
are to be charged with an entire responsibility for the lives of others.
It is a question as to whether this procedure is not indicated in the
case of other important public trusts where the interest of the
community should be safeguarded.
The correlation of psychiatry and psychology as scientific aids to
industrial efficiency promises to open up entirely new and important
sociological fields of research which have only recently attracted
attention. [7] This is a subject of far reaching importance. The extent
to which the industrial classes of the country are affected is shown
by the following analysis of the occupations represented by 104,013
admissions to New York state hospitals: 1. Professional—(clergy,
military and naval officers, physicians, lawyers, architects, artists,
authors, civil engineers, surveyors, etc.) 1,926 or 1.8 per cent; 2.
Commercial—(bankers, merchants, accountants, clerks, salesmen,
shopkeepers, shopmen, stenographers, typewriters, etc.) 7,572 or
7.2 per cent; 3. Agricultural—(farmers, gardeners, etc.) 5,942 or 5.7
per cent; 4. Mechanics—at Outdoor Vocations—(blacksmiths,
carpenters, enginefitters, sawyers, painters, etc.) 8,564 or 8.2 per
cent; 5. Mechanics at Sedentary Vocations—(bootmakers,
bookbinders, compositors, tailors, weavers, bakers, etc.) 7,501 or 7.2
per cent; 6. Domestic Service—(waiters, cooks, servants, etc.)
21,037 or 20.2 per cent; 7. Educational and Higher Domestic Duties
—(governesses, teachers, students, housekeepers, nurses, etc.)
21,861 or 21 per cent; 8. Commercial—(shopkeepers, saleswomen,
stenographers, typewriters, etc.) 1,140 or 1.09 per cent; 9.
Employed at Sedentary Occupations— (tailoresses, seamstresses,
bookbinders, factory workers, etc.) 4,310 or 4.1 per cent; 10.
Miners, Seamen, etc., 581 or .56 per cent; 11. Prostitutes, 81 or .08
per cent; 12. Laborers, 12,962 or 12.4 per cent; No occupation,
7,820 or 7.5 per cent; Unascertained, 2,715 or 2.6 per cent. [8] This
certainly indicates an enormous economic loss to the community.
The intimate relation between mental diseases, alcoholism,
ignorance, poverty, prostitution, criminality, mental defects, etc.,
suggests social and economic problems of far reaching importance,
each one meriting separate and special consideration. These
problems, while perhaps essentially sociological in origin, have at the
same time an important educational bearing, invade the realm of
psychology and depend largely, if not entirely, upon psychiatry for a
solution.
CHAPTER II

THE EVOLUTION OF THE MODERN HOSPITAL


The medical treatment of mental diseases had its inception, in
this country, in the wards of the Philadelphia Hospital, established in
1732 and referred to officially for over a century as an almshouse. It
included an infirmary for the "sick and insane," although it
apparently had no distinct and separate hospital department for
many years. "In 1742," to use the words of Dr. D. Hayes Agnew, "it
was fulfilling a varied routine of beneficent functions in affording
shelter, support and employment for the poor and indigent, a
hospital for the sick, and an asylum for the idiotic, the insane and
the orphan. It was dispensing its acts of mercy and blessing when
Pennsylvania was yet a province and her inhabitants the loyal
subjects of Great Britain." In 1772 it housed as many as three
hundred and fifty persons. In 1769 the General Assembly passed an
act authorizing the "Managers of the Contributions for the Relief and
Employment of the Poor," who had charge of the almshouse, to issue
bills of credit for the purpose of relieving their indebtedness. This
paper currency was issued in three denominations—one shilling, two
shillings and a half crown. The law provided that counterfeiters or
persons altering the denomination of these bills should be
"sentenced to the pillory, have both his or her ears cut off and nailed
to the pillory and be publicly whipped on his or her back with thirty-
nine lashes, well laid on, and, moreover, every such offender shall
forfeit the sum of one hundred pounds, to be levied on his or her
land, tenements, goods and chattels." [9] This certainly must have
discouraged counterfeiting. It was not until after the institution was
removed to the Hamilton estate in Blockley (now a part of West
Philadelphia) in 1834 that it came to be known as the "Philadelphia
Hospital and Almshouse," although there was no change made in its
organization or functions. In 1902, after one hundred and seventy
years of continuous existence, it was finally divided officially for
administrative purposes into The Philadelphia Home or Hospital for
the Indigent, The Philadelphia General Hospital and The Philadelphia
Hospital for the Insane. At that time the hospital was, as it is today,
the largest on the American continent. The institution, which has
admitted mental cases uninterruptedly since 1732, had over
seventeen hundred patients in the department for the insane. In
1917 this number had increased to nearly three thousand.
One of the reasons set forth by sundry petitioners in 1751 for a
"small Provincial Hospital" in Philadelphia, which at that time had
made provision for the care of indigent cases only, was "THAT with
the Numbers of People, the Number of Lunaticks or Persons
distempered in Mind and deprived of their rational Faculties, hath
greatly increased in this Province. That some of them going at large
are a Terror to their Neighbours, who are daily apprehensive of the
Violences they may commit; And others are continually wasting their
Substance, to the great Injury of themselves and Families, ill
disposed Persons wickedly taking Advantage of their unhappy
Condition, and drawing them into unreasonable Bargains, etc. That
few or none of them are so sensible of their Condition, as to submit
voluntarily to the Treatment their respective Cases require, and
therefore continue in the same deplorable State during their Lives;
whereas it has been found, by the Experience of many Years, that
above two Thirds of the Mad People received into Bethlehem
Hospital, and there treated properly, have been perfectly cured." [10]
This resulted eventually in the opening of the Pennsylvania Hospital
in 1752. This institution is a general hospital supported by private
funds and has always received mental cases. A separate department
for mental diseases was established in West Philadelphia in 1841.
Before this was done considerable difficulty was experienced on
account of the annoyance of the patients by curious-minded citizens
of the neighborhood. This developed into such a nuisance in 1760
that it was suggested "That a suitable Pallisade Fence, either of Iron
or Wood, the Iron being preferred, shall be erected in Order to
prevent the Disturbance which is given to the Lunatics confined in
the Cells by the great Number of People who frequently resort and
converse with them." [11] It was also deemed advisable to employ
"Two Constables or other proper Persons, to attend at such times as
are necessary to prevent this Inconvenience until ye Fence is
erected." The public was notified later "that such persons who come
out of curiosity to visit the house should pay a sum of money, a
Groat at least, for admittance." [12] The Pennsylvania Hospital has
played a very important part in the history of the care and treatment
of mental diseases in this country. In 1919 it had over three hundred
patients.
The first institution designed and used exclusively for mental
diseases in this country was the Eastern State Hospital at
Williamsburg, Virginia. It was incorporated by the House of
Burgesses in 1768 and opened for patients on October 12, 1773. It
is interesting to note that the act of incorporation, except in the title,
makes no use of the word lunatic, refers frequently to the care and
treatment of the patients, authorizes the appointment of physicians
and nurses, and specifically designates the institution as a hospital
and not an asylum. The original building was one hundred feet long
by thirty-two feet two inches wide. During the first year thirty-six
patients were admitted. The first pay patient was received in 1774 at
a rate of fifteen pounds per annum. An allowance of twenty-five
pounds per year was made by the legislature for the maintenance
and support of each person admitted. Visiting physicians prescribed
for the patients, and the "keepers" for the first few years were not
graduates in medicine. The superintendents were, however,
physicians after 1841. Known for many years as the "Publick
Hospital," the legislature made the mistake of changing this
designation to The Eastern Lunatic Asylum in 1841 and it was not
until 1894 that it again officially became a hospital. Virginia opened
its second institution, The Western State Hospital for the Insane, at
Staunton on July 25, 1828. Its third hospital was opened at Weston
on September 9, 1859. Virginia is thus entitled to the credit of being
the first commonwealth to furnish state care for mental cases and
make adequate provision for them.
The next step in the evolution of hospital treatment of mental
diseases was taken by Maryland in incorporating a hospital for "The
Relief of Indigent Sick Persons and for the Reception and Care of
Lunatics" in 1797. The hospital was formally opened in 1798 under
the management of the city of Baltimore, which leased the
establishment in 1808 to two physicians, who conducted it as a
private institution until 1834. It then reverted to the state and was
operated as the Maryland Hospital. The institution was removed to
Catonsville in 1872 and is now known as the Spring Grove State
Hospital, the Johns Hopkins Hospital occupying the site of the
original building in Baltimore. Another interesting event in the history
of this institution was the founding of what subsequently became
the Mount Hope Retreat by the Sisters of Charity, who withdrew
from the Maryland Hospital in 1840.
The earliest hospital care of mental diseases in New York was in
the wards of the New York Hospital which was opened in 1791. A
separate building for mental cases was ready for the reception of
patients in 1808. The total number of cases treated up to July 1820
was 1,553. The Bloomingdale Asylum replaced this in 1821, on a
piece of property which now belongs in part to Columbia University.
Public patients were cared for at the expense of the state until the
opening of the New York City Asylum in 1839. Church services were
inaugurated in 1819. The hospital buildings furnished
accommodations for about three hundred patients. In 1894 the
property on Bloomingdale Road was abandoned and the hospital
removed to White Plains in Westchester County. It is still known as
the Bloomingdale Hospital and is supported entirely by public
contributions and the income derived from the care of patients. It
has about three hundred and fifty beds.
The activities of the "Religious Society of Friends," which were
indirectly responsible probably for the inception of the Pennsylvania
Hospital, ultimately led to the establishment of the Friends' Asylum
for the Insane at Frankford, Pennsylvania, in 1817. It was under
sectarian control until 1834, when its doors were thrown open to all,
without regard to religious belief. It claims to be the first institution
"erected on this side of the Atlantic in which a chain was never used
for the confinement of a patient." [13] The hospital is still in a
flourishing condition and has accommodations for over two hundred
patients.
Massachusetts at the beginning of the nineteenth century had no
hospitals of any kind. In 1764, on the death of Thomas Handcock, it
was found that provision had been made in his will for the
establishment of a hospital for mental diseases in Boston. An
expenditure of six hundred pounds was authorized for the purpose
of "erecting and furnishing a convenient House for the reception and
more comfortable keeping of such unhappy persons as it shall please
God, in His Providence, to deprive of their reason in any part of this
Province." [14] The Selectmen of Boston declined this legacy on the
grounds that there were not enough mental cases in the vicinity to
warrant the existence of such an establishment. This proved to be
an error of judgment on their part. In 1811 the Massachusetts
General Hospital was incorporated and a fund of over $93,000 was
subscribed for building purposes. As it was deemed more urgent, the
department for mental diseases in Charlestown was opened first. It
was ready for the reception of patients on October 6, 1818, when it
admitted a young man supposed to be possessed of a devil. This
department became the McLean Asylum in 1826 as the result of a
legacy of $25,000 left to the institution by a Boston merchant of that
name. The corporation finally received in all an amount
approximating $120,000 from the McLean estate. As early as 1822
the first published report of the hospital[15] called attention to the
fact that the various amusements offered the patients included
"draughts, chess, backgammon, ninepins, swinging, sawing wood,
gardening, reading, writing, music, etc." A carriage and pair of
horses for the use of patients was purchased in 1828. In 1835 the
first pianos and billiard tables were installed and a library of one
hundred and twenty volumes placed in the wards. Hot water heating
was introduced in 1848. It is interesting to note that in 1827 the
visiting committee reported that the rates for the maintenance of
patients should not be less than three dollars or more than twelve
dollars per week. In 1882 the McLean Hospital established the first
training school for nurses connected with any institution for mental
diseases in this country. The first class was graduated in 1886. In
1895 the hospital was removed to Waverley, Massachusetts. A
chemical laboratory was opened in 1900 and a psychological
laboratory in 1904. Hydrotherapy was first used in 1899, and a
gymnasium was built in 1904. In 1913 the hospital owned three
hundred and seventeen acres of land and had a capacity of two
hundred and twenty beds, with a plant valued at nearly two million
dollars.
The first provision for the care of mental diseases in Connecticut
was a direct result of the activities of the State Medical Society. It
was on their petition that the Hartford Retreat was chartered in
1822. Over two thousand persons subscribed to a fund for the
opening of the hospital. These subscriptions included "$30 payable
in medicine," "One gross New London bilious pills, price $30" and
two lottery tickets. [16] About fourteen thousand dollars was
subscribed in all, the citizens of Hartford contributing four thousand.
The hospital building, designed to accommodate forty patients, was
opened on April 1, 1824, and has always been conducted on an
unusually high plane. It now averages about one hundred and
seventy-five patients.
Mental cases were first provided with hospital care in Kentucky
when the Eastern State Hospital was opened in Lexington on May 1,
1824. Governor Adams, who suggested the establishment of this
institution, in a message written in 1821 expressed the opinion that
it would be of great benefit to the students of Transylvania
University, "which would in time repay the obligation by useful
discoveries in the treatment of mental maladies."
The State Hospital at Columbia, South Carolina, was opened in
December, 1828. A curious fact in connection with its history is that
in 1829 the management, having received no patients as yet,
advertised for them in the newspapers of South Carolina and
adjoining states.
In 1829 the necessity of making further provision for mental
diseases in Massachusetts became the subject of a legislative
investigation and a committee was appointed "to examine and
ascertain the practicability and expediency of erecting or procuring,
at the expense of the Commonwealth, an asylum for the safe
keeping of lunatics and persons furiously mad." [17] The report of
this committee, of which Horace Mann was Chairman, is exceedingly
interesting. The following is an illustration:—"To him whose mind is
alienated, a prison is a tomb, and within its walls he must suffer as
one who awakes to life in the solitude of the grave. Existence and
the capacity for pain alone are left him. From every former source of
pleasure or contentment he is violently sequestered. Every former
habit is abruptly broken off. No medical skill seconds the efforts of
nature for his recovery, or breaks the strength of pain when it seizes
him with convulsive grasp. No friends relieve each other in solacing
the weariness of protracted disease. No assiduous affection guards
the avenues of approaching disquietude. He is alike removed from
all the occupations of health, and from all the attentions everywhere
but within his homeless abode bestowed upon sickness. The solitary
cell, the noisome atmosphere, the unmitigated cold and the
untempered heat, are of themselves sufficient soon to derange every
vital function of the body, and this only aggravates the derangement
of his mind. On every side is raised up an insurmountable barrier
against his recovery. Cut off from all the charities of life, endued with
quickened sensibilities to pain, and perpetually stung by annoyances
which, though individually small, rise by constant accumulation to
agonies almost beyond the power of mortal sufferance; if his exiled
mind in its devious wanderings ever approach the light by which it
was once cheered and directed, it sees everything unwelcoming,
everything repulsive and hostile, and is driven away into returnless
banishment." [18] The investigation conducted by this committee led
to the establishment of the Worcester Lunatic Hospital, later the
Worcester State Hospital, opened on January 19, 1833. The original
building was designed to care for one hundred and twenty patients.
After many years of agitation on the part of the public, the hospital
was removed to a site overlooking Lake Quinsigamond in the
outskirts of Worcester in 1877. It was soon found that it was
impracticable to dispense with the use of the old building on
Summer Street and it became the Worcester Insane Asylum, later
the Worcester State Asylum, and finally the Grafton State Hospital.
In 1919 it again became a part of the Worcester State Hospital. The
original building is in excellent condition today and promises an
indefinite continuation of an unusual career of usefulness. Many men
destined to occupy positions of importance in the psychiatric world
were trained within its walls.
The death of a prominent politician in 1806 is said to have led
indirectly to the establishment of the first hospital for mental
diseases in Vermont. [19] His medical advisers treated him for some
form of mental alienation by submerging him in water until he
became unconscious. It was thought that this "would divert his mind
and, by breaking the chain of unhappy associations, thus remove the
cause of his disease." As this plan failed he was given opium as "the
proper agent for the stupefaction of the life forces." In spite of this
vigorous treatment he died. The immediate event which made
possible the incorporation of the Vermont Asylum for the Insane in
1835 was a legacy of ten thousand dollars rendered available for this
purpose by the will of Mrs. Anna Marsh of Hinsdale. The hospital was
opened in Brattleboro in 1836 and became the Brattleboro Retreat
after the establishment of the State Hospital at Waterbury. The state
care of mental diseases began in Ohio with the establishment of the
Columbus State Hospital, which was opened on November 30, 1838.
This was the first of a number of institutions now under the
supervision of the Ohio Board of Administration.
The study of the development of the state hospital system of
care now takes us back to Massachusetts. Notwithstanding the fact
that the state already had two institutions for mental cases, McLean
and the Worcester Lunatic Hospital, further accommodations were
urgently indicated. This was largely on account of the needs of the
metropolitan population centering in the city of Boston. To meet this
situation the city established a hospital of its own in South Boston in
1839,—the first municipal institution for this exclusive purpose in
America. Originally known as the Boston Lunatic Hospital and
afterwards as the Boston Insane Hospital, it finally became the
Boston State Hospital in December, 1908. Charles Dickens on the
occasion of his visit to America was very profoundly impressed by
the hospital and made the following references to it in 1842 [20]:—
"At South Boston, as it is called, in a situation excellently adapted for
the purpose, several charitable institutions are clustered together.
One of these is the hospital for the insane; admirably conducted on
those enlightened principles of conciliation and kindness which 20
years ago would have been worse than heretical, and which have
been acted upon with so much success in our own pauper asylum at
Hanwell...." "At every meal, moral influence alone restrains the more
violent among them from cutting the throats of the rest; but the
effect of that influence is reduced to an absolute certainty, and is
found, even as a measure of restraint, to say nothing of it as a
means of cure, a hundred times more efficacious than all the straight
waistcoats, fetters and handcuffs that ignorance, prejudice and
cruelty have manufactured since the creation of the world." ... "In
the labor department every patient is as freely trusted with the tools
of his trade as if he were a sane man. In the garden and on the farm
they work with spades, rakes and hoes. For amusement they walk,
run, fish, paint, read, and ride out to take the air in carriages
provided for the purpose. They have among themselves a sewing
society to make clothes for the poor, which holds meetings, passes
resolutions, never comes to fisticuffs or bowie-knives as sane
assemblies have been known to do elsewhere; and conducts all its
proceedings with the greatest decorum. The irritability which would
otherwise be expended on their own flesh, clothes and furniture is
dissipated in these pursuits. They are cheerful, tranquil and healthy."
... "It is obvious that one great feature of this system is the
inculcation and encouragement, even among such unhappy persons,
of a decent self-respect." The institution was removed to the
Dorchester district of Boston in 1895, where it now houses in the
neighborhood of two thousand patients. The Boston State Hospital
was the first institution of its kind in the United States to establish a
separate psychopathic department, which was opened in 1912.
Influenced doubtless by the attention given to this subject in
other states, Maine opened its first state hospital at Augusta in 1840.
There were between two and three hundred mental cases in the
state at that time. A second hospital was opened at Bangor in 1889.
This humanitarian movement naturally extended to New Hampshire.
Governor Dinsmore in 1832 [21] called attention to the condition of
the insane, seventy-six of whom were in confinement. Of this
number seven were in cells or cages, six in chains and irons and four
in jail. Of those not in confinement at the time, some had been
handcuffed previously, while others had been in cells or chained.
After much unavoidable delay the New Hampshire State Hospital
was opened at Concord on October 29, 1842. The next hospital
development appeared in Georgia. After an active campaign
inaugurated by the physicians of the state and continued for several
years, the Georgia State Sanitarium was opened in Milledgeville in
December, 1842. It now houses over four thousand patients.
By this time it became evident that further procedures on behalf
of the persons requiring treatment for mental diseases in New York
were imperative. The Bloomingdale Hospital, although taxed to its
utmost capacity, was not able to meet the needs of the situation. In
1830 the population of the state had increased to nearly two million.
The report of a legislative committee showed that there were 2,695
insane persons in the state in 1830, with hospital accommodations
at Bloomingdale and one other private hospital at Hudson for only
two hundred and fifty of these cases. An extensive system of state
care was inaugurated by the opening of the Utica State Hospital on
January 16, 1843. In addition to numerous other industries and
occupations, a printing office was established in the hospital and the
publication of the "American Journal of Insanity" was undertaken in
1844. This was the first journal in the world to be devoted
exclusively to the subject of mental diseases. "The Opal," edited,
published and printed by the patients of the hospital, was started at
the same time. In the early days, strong rooms, padded cells and
mechanical restraint of all kinds were used extensively. The "Utica
Crib" has received a great deal of attention. This consisted of an
ordinary ward bed enclosed in wooden slats, making it impossible for
the patient to escape. These were eliminated for all time by Dr. G.
Alder Blumer in 1887. Attendants were first required to wear
uniforms in 1887. During the following year female nurses were
assigned for the first time to male wards. Annual field day exercises
for the benefit of the patients have been held since 1887. Baseball
games, steamboat excursions, Fourth of July celebrations and
Christmas entertainments have been in vogue since 1888. With the
development of a large department on the "Marcy" site, nine miles
from the city, the Utica State Hospital promises to add new
accomplishments to an already dignified history.
The early care of mental cases in Rhode Island, as shown by a
report to the legislature by Thomas R. Hazard in 1851, was perhaps
no worse than that of other states, although the conditions he
described so graphically have not been attributed to other New
England communities by historians. The following extract from a
codicil to the will of Nicholas Brown, who died in 1843, is proof of
the fact that this unfortunate state of affairs had not entirely
escaped notice [22]:—"And whereas it has long been deeply
impressed on my mind that an insane or lunatic hospital or retreat
for the insane should be established upon a firm and permanent
basis, under an act of the Legislature, where that unhappy portion of
our fellow beings who are, by the visitation of Providence, deprived
of their reason, may find a safe retreat and be provided with
whatever may be most conducive to their comfort and to their
restoration to a sound state of mind: Therefore, for the purpose of
aiding an object so desirable and in the hope that such an
establishment may soon be commenced, I do hereby set apart and
give and bequeath the sum of $30,000 towards the erection or
endowment of an insane or lunatic hospital or retreat for the insane,
or by whatever other name it may be called, to be located in
Providence or its vicinity." Supplemental contributions by Cyrus
Butler made it possible for the incorporators to found the Butler
Hospital in Providence. The first patients were received on December
1, 1847.
More than any other one person, Miss Dorothea L. Dix of
Massachusetts was undoubtedly directly responsible for the
inauguration of the state care of mental diseases in this country. She
is credited with having memorialized twenty-two different state
legislatures on this subject. One of her first accomplishments
consisted in inducing the New Jersey legislature to make an
appropriation for the establishment of the state hospital at Trenton.
This institution was opened in 1848, after some of the hardest
campaigning that Miss Dix conducted. The last years of her life were
spent as an honored guest of the hospital and she died there in
1887 at the advanced age of eighty-five.
Indiana inaugurated a system of state care by the establishment
of the Central Hospital for the Insane in 1848. The East Louisiana
Hospital at Jackson was opened in the same year. Missouri made its
first provision for mental cases by opening a hospital at Fulton in
1852. Notwithstanding the fact that the first hospitals for mental
diseases in this country were located in Philadelphia, the
Commonwealth of Pennsylvania did not make any provision for a
state institution until the State Hospital at Harrisburg was opened in
1851. This was only undertaken after a vigorous campaign on the
part of Dorothea Dix had made some legislative action almost
imperative. This is probably the only hospital in the country which
has found it necessary to demolish all of the original buildings and
replace them by others. In 1847 Miss Dix visited Tennessee and
started a movement which resulted in the opening of The Central
Hospital for the Insane at Nashville, the first institution of the kind in
the state. California entered the state hospital field in 1853 with the
establishment of an institution at Stockton. The St. Elizabeths
Hospital in Washington, D.C., the first federal institution for mental
diseases, was opened for patients in 1855. It receives cases from the
United States Government Services and from the District of
Columbia. Dorothea Dix was largely instrumental in its origin. The St.
Elizabeths Hospital was an early invader of the field of scientific
research. A pathologist was appointed in 1883. It was one of the
first institutions to use hydrotherapy extensively. It now cares for
nearly four thousand patients. Mississippi established its first state
hospital for mental diseases in 1856, North Carolina in 1856, West
Virginia in 1859, Michigan in 1859, Wisconsin in 1860, Texas in 1861,
Kansas in 1866, Minnesota in 1866, Connecticut in 1868, Rhode
Island in 1870 and Vermont in 1891. The Sheppard and Enoch Pratt
Hospital, a well known private institution in Baltimore, was also
opened in 1891.
It is hardly worth while at this time to emphasize the fact that
the necessity of providing adequate facilities for the care and
treatment of mental diseases, a problem which received little
consideration of any kind for many years, gradually led to the
elaboration of an extensive system of state hospitals. These are to
be found now in every part of the country. They have long since
passed through the purely custodial stage and have developed into
highly specialized modern hospitals of most advanced type. Their
function is to provide proper treatment for persons who cannot for
financial or other reasons be cared for in the private hospitals which
are to be found in almost all localities. These institutions, originating
in Virginia in 1773, now represent one of the most important
activities conducted by any state government. The extent of the field
which they cover is illustrated by the fact that Kansas, Kentucky,
Nebraska, North Carolina, Oklahoma, Tennessee, Texas, Washington,
West Virginia and Wisconsin each maintain three state hospitals for
mental diseases; Iowa, Maryland, Missouri and Virginia each have
four institutions of this type, Minnesota five, California, Indiana and
Michigan six, Pennsylvania seven, Ohio and Illinois nine,
Massachusetts twelve and New York fifteen. In addition to this eight
other states have two hospitals each and seventeen find one such
institution sufficient for their needs. It is worthy of note that every
state without any exception has now recognized the necessity of
making provision for the care and treatment of mental diseases.
CHAPTER III

LEGISLATION AND METHODS OF ADMINISTRATION


The administration of the earlier hospitals for mental diseases
was placed very wisely in the hands of local boards of directors,
managers or trustees. These were made up of persons prominent in
the community in which they lived, well known as having a keen
interest in humanitarian movements, and fully deserving of the
confidence reposed in them by the public. They received no
compensation other than the satisfaction of having served in a
worthy cause. The state hospital at Williamsburg, Virginia, the first
of its kind in America, was controlled by a court of directors which
was made up of some of the most prominent Virginians of colonial
days. It included Thomas Nelson, Jr., a signer of the Declaration of
Independence who served with distinction in the Revolutionary War,
Peyton Randolph, the President of the first Continental Congress,
and George Wythe, the preceptor in law of both Marshall and
Jefferson, as well as a signer of the Declaration of Independence
and professor of law at William and Mary College, together with
various other distinguished citizens, some perhaps of less
prominence, but all men of the highest standing in Virginia. The first
"court" consisted of fifteen members. The second state institution,
the Maryland Hospital, under the management of the city of
Baltimore for some years, was eventually placed under the control of
a board of visitors in 1828. Kentucky's first hospital was from the
beginning in the charge of a board of ten commissioners. When the
second Virginia institution was opened at Staunton, the form of
organization adopted at Williamsburg was duplicated and a court of
directors appointed. There were, however, thirteen instead of fifteen
members. The state hospital at Columbia, South Carolina, was
originally, and still is, under a board of regents. The Massachusetts
hospitals, dating from the opening of Worcester in 1833, have
always had trustees. The Vermont Asylum, later the Brattleboro
Retreat, was also managed by a board of trustees, as was the New
Hampshire State Hospital at Concord. The Georgia State Sanitarium,
opened in the same year, adopted a similar form of control. The
Utica State Hospital has been conducted from the first by a board of
managers, a term which is generally used by the New York
institutions. When the Trenton State Hospital was founded it was
placed under a board of ten managers, more or less along the lines
followed at Utica. The State Hospital at Raleigh, North Carolina, had
a board of directors. For many years the earlier institutions for
mental diseases were under no other form of control, the powers of
the trustees being absolute. This is still the case in a few states.
Usually, however, there is some additional form of supervision.
Boards of trustees, managers, directors, or some other local
governing body, exist in the following states but without exclusive
control:—Alabama, California, Connecticut, Delaware, Georgia,
Idaho, Indiana, Louisiana (administrators), Maine, Maryland,
Massachusetts, Mississippi, Missouri, New Jersey, New Mexico, New
York, Pennsylvania, South Carolina (regents), Texas and Virginia. [23]
In the following states the hospitals have no local boards of any
kind:—Arizona, Arkansas, Colorado, Florida, Illinois, Iowa, Kansas,
Kentucky, Michigan, Minnesota, Montana, Nebraska, Nevada, New
Hampshire, North Carolina, North Dakota, Ohio, Oklahoma, Oregon,
Rhode Island, South Dakota, Tennessee, Utah, Vermont,
Washington, West Virginia, Wisconsin and Wyoming.[24]
As the state hospitals increased in number and importance, steps
were taken to coordinate their activities and for various obvious
reasons they were soon grouped together in departments. In the
states having a sufficient number of hospitals to warrant such a
procedure, separate specialized administrative units were established
under lunacy commissions, etc. In less populous communities where
there were only a few hospitals there soon developed a tendency to
associate them with the charitable, correctional and, in some
instances, penal institutions. Seventeen states, as has been shown,
now have only one hospital for mental diseases, eight have two and
ten only three institutions. This led either to placing the hospitals
under boards of charities and corrections or to the organization of
new departments known as boards of control. The hospitals for
mental diseases are under the supervision of boards of charities and
corrections in the following states:—Colorado, Connecticut, Indiana,
Louisiana, Maine, Nebraska, North Carolina, South Carolina, South
Dakota and Virginia. [24]
Boards of control exist in Arkansas, California, Iowa, Kentucky,
Minnesota, North Dakota, Oregon, Vermont, West Virginia and
Wisconsin. California has, in addition to this, a board of charities and
corrections and a commission in lunacy. Vermont has a director of
state institutions. In New Hampshire the board of trustees of the
state hospital constitutes a commission in lunacy. A number of states
have special departments for the supervision of hospitals for mental
diseases and in some instances for the control of all institutions.
Delaware has a board of supervisors of state institutions. This is
essentially a board of control. This is true of the board of
commissioners of state institutions in Florida. Illinois has a
department of public welfare, which places the control of the
charitable, penal and corrective institutions, as well as the hospitals
for mental diseases, largely in the hands of one man, a layman.
Michigan and Pennsylvania also have departments of public welfare.
Kansas has placed its hospitals under the control of a board of
administration of state charitable institutions. Maryland has a lunacy
commission and Missouri a board of managers. Montana and Nevada
each have a board of commissioners for the insane. New Jersey has
a state board of control of institutions and agencies, the direction of
the state hospitals being delegated to a commissioner of charities
and corrections. New York has the largest department in the country
having exclusive state hospital functions. It is under the supervision
of a hospital commission. Ohio has a board of administration which
manages and governs all of the charitable, corrective and penal
institutions of the state. This is, of course, a board of control pure
and simple. Oklahoma has a commissioner of charities and
corrections who is an elective officer, and has, in addition, a lunacy
commission and a board of public affairs. Rhode Island has a penal
and charitable commission of nine members. Utah has a board of
insanity and Wyoming a board of charities and reform.
Massachusetts has a department of mental diseases under the
direction of a medical commissioner, with four unpaid associates. In
addition to the hospitals for mental diseases the department has
under its jurisdiction the institutions for the feebleminded and the
epileptics.
The necessity of some form of central supervision or control, of
state institutions in general and hospitals for mental diseases in
particular, has long been a subject of serious consideration and
discussion. The administration of hospitals, prisons, reformatories,
etc., by a central board of control may be indicated in states where
there are only a few institutions and the creation of highly
specialized and expensive departments obviously would not be
warranted. The question may very properly be raised as to the
necessity of any supervision other than that by local boards of
trustees in such communities. A study of methods of supervision
made some years ago by the medical director of the National
Committee for Mental Hygiene [25] shows that the board of control
system leaves much to be desired. He has expressed himself on this
subject in no uncertain terms, as is shown by the following:—"Under
Boards of Control, politics influence the care of the sick to a degree
unknown under different types of supervision and the scientific and
humane aspects of the work undertaken are generally subordinated
to doubtful administrative advantages. With hardly an exception,
these Boards of Control have not endeavored to secure better
commitment laws, to lead public sentiment so that higher standards
of treatment will be demanded or to deal with the great problems of
mental disease in any except their narrowest institutional aspects.
There has been striking absence of evidences of any feeling of
personal responsibility in these matters; indeed many members of
these boards would doubtless unhesitatingly state that their duties
do not involve such considerations. What the results would have
been if efficient and fearless local boards of managers had been
retained when these states created Boards of Control cannot be
stated. It is an essential part of the policy which places the care of
the insane under this form of administration that there shall be no
"division of responsibility" and, seemingly, there is no place in such a
scheme for bodies which are as much interested in the personal
welfare of the wards of the State as they are in governmental
"efficiency" and, which, moreover, are directly accountable to their
neighbors—the friends and relatives of patients. It is interesting to
compare some of the conditions mentioned with those existing in
States in which the care of the insane is entrusted to Boards created
for that special purpose. In these States,—California, Maryland,
Massachusetts and New York,—it can be said truly that the care of
the insane reaches its highest level."
The experience of the past has shown that the injection of
politics into the administration of state institutions is almost
invariably due to the over-centralization of power in state
departments, the local boards of trustees or managers either being
abolished or largely deprived of their authority. The greatest menace
to the future welfare of the hospitals for mental diseases is, in the
opinion of many, the unfortunate result of a popular and more or
less legitimate demand for the reorganization of state governments,
reducing their administrative activities to a few separate
departments, each one under the entire charge of a director
responsible only to the Governor. The argument for this procedure is
that it does away with innumerable commissions, boards and
departments working along independent lines without any reference
to the desirability of coordinating the activities of the state as a
whole and places the affairs of the commonwealth on an efficient,
systematic and economical basis. There is no question as to the
theoretical advisability of such methods. The difficulty is, that in
putting into practical operation this unquestionably commendable
undertaking, the humanitarian aspect of the charitable enterprises
conducted by state governments for more than a century, is likely to
be lost sight of. It is almost invariably urged that the directors of
these various departments should be experienced business men of
recognized ability and that in only such a way can the affairs of the
state be put on a "businesslike basis." It must be confessed that this
argument is one which appeals very strongly to the taxpayer, who
naturally has not given the matter very careful thought. There are
other important considerations, however, where the question of
administering hospitals is involved. As Commissioner Kline [26] has
said:—"If it be conceded that the care and treatment of the mentally
sick is a highly specialized medical problem, requiring the services of
medical experts, and that the institutions function primarily for the
welfare of the patient, then the supervision and control of
institutions should be in the hands of medical men especially trained
for the purpose."
In some instances where the state governments have been
reorganized and the proposed consolidation of departments effected,
the administration of the state hospitals has come under the
direction of a single individual without hospital or institution
experience of any kind and without any special knowledge of
medicine or psychiatry. There is no escaping the fact that the
administration of a hospital is a medical problem. Nor is there any
question as to the advisability of some central supervision and
financial control of institutions. The hospital departments in our
more populous states are, however, so extensive and so important
that they cannot be merged with other interests without sacrificing
to a considerable extent the welfare of the patients. It should be
remembered, moreover, that the administration of hospitals for
mental diseases is a specialty and a large one, not specifically
related to the problems arising in the management of charitable
institutions or prisons. The best results have been obtained where
there is a division of responsibility between local boards of trustees
or managers and a central body charged with the supervision, and a
limited or complete financial control, of institutions for mental
diseases only. The head of such a department should unquestionably
be a medical man with psychiatric hospital experience. This policy
has been responsible for the high standards maintained in the state
hospitals of Massachusetts and New York.
It is, unfortunately, true that the care of mental diseases is not
exclusively a function of the state or private hospitals. In thirteen
Welcome to our website – the ideal destination for book lovers and
knowledge seekers. With a mission to inspire endlessly, we offer a
vast collection of books, ranging from classic literary works to
specialized publications, self-development books, and children's
literature. Each book is a new journey of discovery, expanding
knowledge and enriching the soul of the reade

Our website is not just a platform for buying books, but a bridge
connecting readers to the timeless values of culture and wisdom. With
an elegant, user-friendly interface and an intelligent search system,
we are committed to providing a quick and convenient shopping
experience. Additionally, our special promotions and home delivery
services ensure that you save time and fully enjoy the joy of reading.

Let us accompany you on the journey of exploring knowledge and


personal growth!

ebookluna.com

You might also like