Engineering Problem Solving with C Delores M. Etter
Engineering Problem Solving with C Delores M. Etter
Engineering Problem Solving with C Delores M. Etter
Engineering Problem Solving with C Delores M. Etter
1. Engineering Problem Solving with C Delores M. Etter
- PDF Download (2025)
https://ebookultra.com/download/engineering-problem-solving-with-
c-delores-m-etter/
Visit ebookultra.com today to download the complete set of
ebooks or textbooks
2. We have selected some products that you may be interested in
Click the link to download now or visit ebookultra.com
for more options!.
Data Abstraction Problem Solving with C 6th Edition Frank
M. Carrano
https://ebookultra.com/download/data-abstraction-problem-solving-
with-c-6th-edition-frank-m-carrano/
Problem Solving with C 6th Edition Savitch
https://ebookultra.com/download/problem-solving-with-c-6th-edition-
savitch/
Programming and Problem Solving with C Comprehensive
Comprehensive Edition Nell B. Dale
https://ebookultra.com/download/programming-and-problem-solving-with-
c-comprehensive-comprehensive-edition-nell-b-dale/
Data Abstraction and Problem Solving with Java Walls and
Mirrors Frank M. Carrano
https://ebookultra.com/download/data-abstraction-and-problem-solving-
with-java-walls-and-mirrors-frank-m-carrano/
3. Problem Solving and Program Design in C Third Edition Jeri
R. Hanly
https://ebookultra.com/download/problem-solving-and-program-design-in-
c-third-edition-jeri-r-hanly/
Technology Assisted Problem Solving for Engineering
Education Interactive Multimedia Applications 1st Edition
Manjit Singh Sidhu
https://ebookultra.com/download/technology-assisted-problem-solving-
for-engineering-education-interactive-multimedia-applications-1st-
edition-manjit-singh-sidhu/
Data Structures And Problem Solving Using C 2nd
International Edition Edition Mark Allen Weiss
https://ebookultra.com/download/data-structures-and-problem-solving-
using-c-2nd-international-edition-edition-mark-allen-weiss/
The Problem Solving Memory Jogger Michael Brassard
https://ebookultra.com/download/the-problem-solving-memory-jogger-
michael-brassard/
Problem Solving in Oncology 1st Edition Dearbhaile
https://ebookultra.com/download/problem-solving-in-oncology-1st-
edition-dearbhaile/
5. Engineering Problem Solving with C Delores M. Etter
Digital Instant Download
Author(s): Delores M. Etter; Jeanine A. Ingber
ISBN(s): 9780132492652, 0132492652
Edition: ebook
File Details: PDF, 8.64 MB
Year: 2012
Language: english
8. ENGINEERING
PROBLEM SOLVING
WITH C++
Third Edition
Delores M. Etter
Electrical Engineering Department
Southern Methodist University, Dallas, TX
Jeanine A. Ingber
Accurate Solutions in Applied Physics, LLC
Boston Columbus Indianapolis New York San Francisco Upper Saddle River
Amsterdam Cape Town Dubai London Madrid Milan Munich Paris Montréal Toronto
Delhi Mexico City São Paulo Sydney Hong Kong Seoul Singapore Taipei Tokyo
9. Vice President and Editorial Director, ECS:
Marcia Horton
Editor-in-Chief: Michael Hirsch
Executive Editor: Tracy Dunkelberger
Editorial Assistant: Stephanie Sellinger
Vice President, Marketing: Patrice Jones
Marketing Manager: Yezan Alayan
Marketing Coordinator: Kathryn Ferranti
Marketing Assistant: Emma Snider
Vice President, Production: Vince O’Brien
Managing Editor: Jeff Holcomb
Production Project Manager: Kayla Smith-Tarbox
Senior Operations Supervisor: Alan Fischer
Manufacturing Buyer: Lisa McDowell
Art Director: Anthony Gemmellaro
Cover Designer: Anthony Gemmellaro
Manager, Visual Research: Karen Sanatar
Photo Researcher: Lily Ferguson, Bill Smith Group
Cover Art: Mars: U.S. Geological Survey/Photo
Researchers, Inc. Arabia Dunes: NASA/
JPL-Caltech/ASU
Media Editor: Daniel Sandin
Media Project Manager: John Cassar
Full-Service Project Management and
Composition: Integra
Printer/Binder: Edwards Brothers
Cover Printer: Lehigh-Phoenix Color/Hagerstown
Text Font: 10/12, TimesNewRoman
Credits and acknowledgements borrowed from other sources and reproduced, with permission, are as follows: Chapter 1 opener
NASA/Ames Research Center; Figure 1.1 c
Adam Hart-Davis/Photo Researchers, Inc.; Figure 1.2 c
Dr. Jeremy Burgess/Photo
Researchers, Inc.; Figure 1.3 c
Photo by Hulton Archive/Getty Images; Figure 1.4 c
Science Source/Photo Researchers, Inc.; Figure 1.5
c
AP Photo/Gautam Singh; Chapter 2 opener c
yuyangc/Shutterstock.com; Chapter 3 opener c
Mira.com/Howie Garber; Chapter 4
opener c
Peter Calamai/Toronto Star/Toronto Star/Newscom; Chapter 5 opener c
NASA/Science Source/Photo Researchers, Inc.; Chapter
6 opener c
NASA/Science Source/Photo Researchers, Inc.; Chapter 7 opener c
HO/AFP/Getty Images/Newscom; Chapter 8 opener c
NASA/Jet Propulsion Laboratory; Chapter 9 opener c
Warren Faidley/Photolibrary; Chapter 10 opener c
Garry Gay/Alamy; Figure
10.1(a, b, and c) c
NASA/JPL/Ames Research Center; Insert photo I.1 c
NOAA/Science Photo Library; Insert photo I.2 and I.3 c
Ilene
MacDonald/Alamy; Insert photo I.4, I.5, I.6 c
Mehau Kulyk/Photo Researchers, Inc.; Insert photo I.7 c
NASA/Photo Researchers, Inc.;
Insert photo I.8 and I.9 c
NASA/Jet Propulsion Laboratory; Insert photo I.10 c
Scott White/UIUC/Photo Researchers; Insert photo I.11 c
Image generated by Robert F. Tomaro and Kenneth E. Wurtzler, Computational Sciences Branch, Air Vehicles Directorate, Air Force
Research Laboratory.; Insert photo I.12 c
Ramon Santos/Photo Researchers, Inc.; Screenshots pg. 69–76, 123–128 c
Oracle Corporation;
Screenshots pg. 170–174 c
Microsoft Corporation.
Microsoft R
and Windows R
are registered trademarks of the Microsoft Corporation in the U.S.A. and other countries. Screen shots and
icons reprinted with permission from the Microsoft Corporation. This book is not sponsored or endorsed by or affiliated with the Microsoft
Corporation.
Copyright c
2012, 2008, 2003 Pearson Education, Inc., publishing as Prentice Hall 501 Boylston Street, Suite 900, Boston, MA 02116. All
rights reserved. Printed in the United States of America. This publication is protected by Copyright, and permission should be obtained from
the publisher prior to any prohibited reproduction, storage in a retrieval system, or transmission in any form or by any means, electronic,
mechanical, photocopying, recording, or likewise. To obtain permission(s) to use material from this work, please submit a written request to
Pearson Education, Inc., Permissions Department, One Lake Street, Upper Saddle River, New Jersey 07458, or you may fax your request to
201-236-3290.
Many of the designations by manufacturers and sellers to distinguish their products are claimed as trademarks. Where those designations
appear in this book, and the publisher was aware of a trademark claim, the designations have been printed in initial caps or all caps.
Library of Congress Cataloging-in-Publication Data
Etter, D. M.
Engineering problem solving with C++ / Delores M. Etter, Jeanine A. Ingber.—3rd ed.
p. cm.
Includes bibliographical references and index.
ISBN 978-0-13-249265-2
1. C++ (Computer program language). 2. Engineering—Data processing.
I. Ingber, Jeanine A. II. Title.
QA76.73.C153E58 2012
620.00285'5117—dc23
2011033021
10 9 8 7 6 5 4 3 2 1—EB—14 13 12 11 10
ISBN 10: 0-13-249265-2
ISBN 13: 978-0-13-249265-2
10. In loving memory of our fathers:
Murvin Lee Van Camp,
a loving and supportive father
—Delores
Robert William Huckell,
a generous and thoughtful man
—Jeanine
11. Contents
Preface xi
1 Introduction to Computing and Engineering
Problem Solving 2
1.1 Historical Perspective 3
1.2 Recent Engineering Achievements 7
Changing Engineering Environment 9
1.3 Computing Systems 11
Computer Hardware 11
Computer Software 12
1.4 Data Representation and Storage 16
Number Systems 17
Data Types and Storage 23
1.5 An Engineering Problem-Solving Methodology 26
Summary 29
2 Simple C++ Programs 34
ENGINEERING CHALLENGE: Vehicle Performance
2.1 Program Structure 35
2.2 Constants and Variables 39
Scientific Notation 41
Numeric Data Types 42
Boolean Data Type 44
Character Data Type 44
String Data 46
Symbolic Constants 47
2.3 C++ Classes 48
Class Declaration 48
Class Implementation 49
2.4 C++ Operators 52
Assignment Operator 52
Arithmetic Operators 54
Precedence of Operators 56
Overflow and Underflow 58
Increment and Decrement Operators 59
Abbreviated Assignment Operators 60
2.5 Standard Input and Output 61
The cout Object 61
Stream Objects 62
iv
12. Contents v
Manipulators 64
The cin Object 67
2.6 Building C++ Solutions with IDEs: NetBeans 69
NetBeans 69
2.7 Basic Functions Included in the C++ Standard Library 76
Elementary Math Functions 77
Trigonometric Functions 78
Hyperbolic Functions* 80
Character Functions 81
2.8 Problem Solving Applied: Velocity Computation 81
2.9 System Limitations 85
Summary 86
3 Control Structures: Selection 94
ENGINEERING CHALLENGE: Global Change
3.1 Algorithm Development 95
Top-Down Design 95
3.2 Structured Programming 97
Pseudocode 97
Evaluation of Alternative Solutions 99
3.3 Conditional Expressions 99
Relational Operators 99
Logical Operators 100
Precedence and Associativity 103
3.4 Selection Statements: if Statement 104
Simple if Statements 104
if/else Statement 107
3.5 Numerical Technique: Linear Interpolation 111
3.6 Problem Solving Applied: Freezing Temperature of Seawater 115
3.7 Selection Statements: switch Statement 119
3.8 Building C++ Solutions with IDEs: NetBeans 122
NetBeans 122
3.9 Defining Operators for Programmer-Defined Data Types 128
Summary 133
4 Control Structures: Repetition 138
ENGINEERING CHALLENGE: Data Collection
4.1 Algorithm Development 139
Pseudocode and Flowchart Description 140
4.2 Repetition Structures 140
while Loop 141
do/while Loop 145
for Loop 148
4.3 Problem Solving Applied: GPS 153
13. vi Contents
4.4 break and continue Statements 157
4.5 Structuring Input Loops 158
Counter-Controlled Loops 158
Sentinel-Controlled Loop 160
End-Of-Data Loop 161
4.6 Problem Solving Applied: Weather Balloons 163
4.7 Building C++ Solutions with IDEs: Microsoft Visual C++ 168
Microsoft Visual C++ 170
Summary 174
5 Working with Data Files 180
ENGINEERING CHALLENGE: Weather Prediction
5.1 Defining File Streams 181
Stream Class Hierarchy 181
ifstream Class 184
ofstream Class 185
5.2 Reading Data Files 187
Specified Number of Records 188
Trailer or Sentinel Signals 190
End-of-File 192
5.3 Generating a Data File 195
5.4 Problem Solving Applied: Data Filters—Modifying an HTML File 198
5.5 Error Checking 202
The Stream State 203
5.6 Numerical Technique: Linear Modeling∗
208
5.7 Problem Solving Applied: Ozone Measurements∗
211
Summary 217
6 Modular Programming with Functions 224
ENGINEERING CHALLENGE: Simulation
6.1 Modularity 225
6.2 Programmer-Defined Functions 228
Function Definition 231
Solution 1 234
Solution 2 235
Function Prototype 238
6.3 Parameter Passing 239
Pass by Value 240
Pass by Reference 242
Storage Class and Scope 248
6.4 Problem Solving Applied: Calculating a Center of Gravity 250
6.5 Random Numbers 254
Integer Sequences 254
Floating-Point Sequences 258
14. Contents vii
6.6 Problem Solving Applied: Instrumentation Reliability 259
6.7 Defining Class Methods 266
Public Interface 267
Accessor Methods 268
Mutator Methods 269
6.8 Problem Solving Applied: Design of Composite Materials 274
Solution 1 276
Solution 2 277
6.9 Numerical Technique: Roots of Polynomials* 280
Polynomial Roots 280
Incremental-Search Technique 282
6.10 Problem Solving Applied: System Stability* 284
Newton–Raphson Method* 290
6.11 Numerical Technique: Integration* 293
Integration Using the Trapezoidal Rule 293
Summary 297
7 One-Dimensional Arrays 308
ENGINEERING CHALLENGE: Tsunami Warning Systems
7.1 Arrays 309
Definition and Initialization 310
Pseudocode 312
Computation and Output 315
Function Arguments 319
7.2 Problem Solving Applied: Hurricane Categories 324
7.3 Statistical Measurements 330
Simple Analysis 330
Variance and Standard Deviation 332
Custom Header Files 335
7.4 Problem Solving Applied: Speech Signal Analysis 335
7.5 Sorting and Searching Algorithms 341
Selection Sort 342
Search Algorithms 343
Unordered Lists 344
Ordered Lists 344
7.6 Problem Solving Applied: Tsunami Warning Systems 346
7.7 Character Strings 352
C Style String Definition and I/O 352
String Functions 354
7.8 The string Class 355
7.9 The vector class 357
Parameter Passing 360
7.10 Problem Solving Applied: Calculating Probabilities 362
Summary 375
15. viii Contents
8 Two-Dimensional Arrays 382
ENGINEERING CHALLENGE: Terrain Navigation
8.1 Two-Dimensional Arrays 383
Declaration and Initialization 384
Computations and Output 389
Function Arguments 392
8.2 Problem Solving Applied: Terrain Navigation 398
8.3 Two-Dimensional Arrays and the vector class 403
Function Arguments 406
8.4 Matrices 407
Determinant 407
Transpose 408
Matrix Addition and Subtraction 409
Matrix Multiplication 410
8.5 Numerical Technique: Solution to Simultaneous Equations 412
Graphical Interpretation 412
Gauss Elimination 416
8.6 Problem Solving Applied: Electrical Circuit Analysis 418
8.7 Higher Dimensional Arrays 424
Summary 426
9 An Introduction to Pointers 434
ENGINEERING CHALLENGE: Weather Patterns
9.1 Addresses and Pointers 435
Address Operator 436
Pointer Assignment 438
Pointer Arithmetic 441
9.2 Pointers to Array Elements 444
One-Dimensional Arrays 445
Character Strings 447
Pointers as Function Arguments 448
9.3 Problem Solving Applied: El Niño-Southern Oscillation Data 453
9.4 Dynamic Memory Allocation 456
The new Operator 456
Dynamically Allocated Arrays 458
The delete Operator 458
9.5 Problem Solving Applied: Seismic Event Detection 460
9.6 Common Errors Using new and delete 466
9.7 Linked Data Structures 468
Linked Lists 468
Stacks 470
Queue 470
16. Contents ix
9.8 The C++ Standard Template Library 472
The list class 472
The stack class 474
The queue class 475
9.9 Problem Solving Applied: Concordance of a Text File 477
Summary 482
10 Advanced Topics 488
ENGINEERING CHALLENGE: Artificial Intelligence
10.1 Generic Programming 489
Function Templates 490
10.2 Data Abstraction 494
Overloading Operators 494
The Pixel class 495
Arithmetic Operators 496
friend Functions 501
Validating Objects 506
Bitwise Operators 510
10.3 Problem Solving Applied: Color Image Processing 513
10.4 Recursion 519
Factorial Function 520
Fibonacci Sequence 522
The BinaryTree class 524
10.5 Class Templates 536
10.6 Inheritance 542
The Rectangle class 542
The Square class 545
The Cube class 548
10.7 virtual Methods 551
10.8 Problem Solving Applied: Iterated Prisoner’s Dilemma 554
Summary 563
A C++ Standard Library 568
B ASCII Character Codes 576
C Using MATLAB to Plot Data from ASCII Files 580
C++ Program to Generate a Data File 580
ASCII Data File Generated by the C++ Program 581
Generating a Plot with MATLAB 581
18. Preface
The C++ programming language is derived from the C programming language, with added
features to support object-oriented programming through the use of classes and programmer-
defined types. The features of the C programming language that make it attractive for system-
level operations and embedded programming are also supported by C++, making C++ one
of the most powerful and versatile programming languages available—and a good choice for
an introduction to computing course for scientists and engineers. This text was written to
introduce engineering problem solving with C++ and also the object-oriented features of the
C++ programming language. Our objectives are the following:
• to develop a consistent methodology for solving engineering problems
• to present the object-oriented features of C++, while focusing on the fundamentals
of programming and problem solving
• to illustrate a problem-solving process with C++ through a variety of engineering
examples and applications
• to provide an easy-to-understand, integrated introduction to data types, functions,
and container classes defined in the C++ Standard Template Library
To accomplish these objectives, Chapter 1 presents a five-step process that is used con-
sistently in the rest of the text for solving engineering problems. Chapter 2 introduces the
built-in data types supported by C++ and provides an introduction to classes, pre-defined
objects, and member functions that support standard input and output. Chapters 3–6
present the fundamental capabilities of C++ for solving engineering problems, including con-
trol structures, data files, functions, and programmer-defined data types. Chapters 7 and 8
present arrays, vectors, and the string class. Chapter 9 introduces the use of pointers,
dynamic memory allocation, and linked data structures. Chapter 10 provides a more in-
depth look at some advanced topics, including function templates, class templates, recur-
sive member functions, inheritance, and virtual functions. Throughout all these chapters,
we present a large number of examples from many different engineering, science, and com-
puter science disciplines. The solutions to these examples are developed using the five-step
process and Standard C++.
Features of the Third Edition
The third edition of our text:
• Introduces students to three integrated development environments (IDEs)
• NetBeans
• MS Visual Studio
• Includes new engineering applications using global positioning system (GPS) data
and data used with tsunami warning systems.
• Includes coverage of bitwise operators.
xi
19. xii Preface
• Has expanded coverage of control structures.
• Introduces classes and the development of programmer-defined data types early in
the text as optional chapter sections, for flexibility.
• Integrates coverage of classes throughout the text and offers a comparison of standard
and object-based solutions.
• Includes additional Statement Boxes, Program Traces and Memory Snapshots, and
flowcharts.
Student Resources and an Instructor’s Resource Center (IRC) are available online at
www.pearsonhighered.com/etter.
Prerequisites
No prior experience with the computer is assumed. The mathematical prerequisites are college
algebra and trigonometry. Of course, the initial material can be covered much faster if the
student has used other computer languages or software tools.
Course Structure
The material in these chapters was selected to provide the basis for a one-term course in en-
gineering and scientific computing. These chapters contain the essential topics of mathemat-
ical computations, character data, control structures, functions, arrays, classes, and pointers.
Students with a background in another computer language should be able to complete this
material in one semester. A minimal course that provides only an introduction to C++ can
be designed using the nonoptional sections of the text. (Optional sections are indicated in the
Contents with an asterisk.) Three ways to use the text, along with the recommended chapter
sections, are
• Introduction to C++ Many freshman introductory courses introduce the student to
several computer tools in addition to language. For these courses, we recommend
covering the nonoptional sections of Chapters 1–8. This material presents to students
the fundamental capabilities of C++, and they will then be able to write substan-
tial programs using mathematical computations, character data, control structures,
programmer-defined data types, functions, and arrays.
• Problem Solving with C++ In a semester course devoted specifically to teaching
students to master the C++ language, we recommend covering all nonoptional sec-
tions of Chapters 1–10. This material covers all the fundamental concepts of the C++
language, including mathematical computations, character data, control structures,
functions, arrays, classes, templates, and pointers.
• Problem Solving with C++ and Numerical Techniques Upper-level students or
students who are already familiar with other high-level languages will be able to
cover the material in this text very quickly. In addition, they will be able to apply the
numerical-technique material to their other courses. Therefore, we recommend that
these students cover all sections of Chapters 1–10, including the optional material.
The chapters in this text were designed to give the instructor flexibility in the ordering of
topics. Coverage of programmer-defined types and classes is incorporated throughout the text,
beginning with Chapter 2. However, coverage of classes is placed at the end of each chapter,
in an optional section. A dependency chart is provided on the next page for illustration.
20. Preface xiii
Dependency Chart
CHAPTER 1
INTRODUCTION TO
COMPUTING AND ENGINEERING
PROBLEM SOLVING
CHAPTER 2
SIMPLE
C++ PROGRAMS
CHAPTER 3
CONTROL
STRUCTURES:
SELECTION
CHAPTER 4
CONTROL
STRUCTURES:
REPETITION
CHAPTER 5
WORKING WITH
DATA FILES
CHAPTER 6
MODULAR PROGRAMMING
WITH FUNCTIONS
CHAPTER 7
ONE-DIMENSIONAL
ARRAYS
CHAPTER 8
TWO-DIMENSIONAL
ARRAYS
CHAPTER 9
AN INTRODUCTION
TO POINTERS
CHAPTER 10
ADVANCED TOPICS
21. xiv Preface
Problem-Solving Methodology
The emphasis on engineering and scientific problem solving is an integral part of the text.
Chapter 1 introduces a five-step process for solving engineering problems using the computer:
1. State the problem clearly.
2. Describe the input and output information, and determine required data types.
3. Work a simple example by hand.
4. Develop an algorithm and convert it to a computer program.
5. Test the solution with a variety of data.
To reinforce the development of problem-solving skills, each of these five steps is
clearly identified each time a complete engineering problem is solved. In addition, top-down
design and stepwise refinement are presented with the use of decomposition outlines, pseu-
docode, and flowcharts.
Engineering and Scientific Applications
Throughout the text, emphasis is placed on incorporating real-world engineering and scientific
examples and problems. This emphasis is centered around a theme of engineering challenges,
which include
• prediction of weather, climate, and global change
• computerized speech understanding
• image processing
• artificial intelligence
• enhanced oil and gas recovery
• simulation
Each chapter begins with a photograph and a discussion of an aspect of one of these
challenges that provides a glimpse of some of the exciting and interesting areas in which
engineers might work. Later in the chapter, we solve a problem that not only relates to the
introductory problem, but also has applications in other problem solutions.
Standard C++
The statements presented and all programs developed use C++ standards developed by the In-
ternational Standards Organization and the American National Standards Institute (ISO/ANSI)
C++ Standards committee. ISO and ANSI together have published the first international stan-
dard for the C++ programming language. By using Standard C++, students learn to write
portable code that can be transferred from one computer platform to another. Many of the
standard capabilities of the C++ programming language are discussed in the text. Additional
components of the C++ standard library are discussed in Appendix A.
22. Preface xv
Software Engineering Concepts
Engineers and scientists are expected to develop and implement user-friendly and reusable
computer solutions. Learning software engineering techniques is therefore crucial. Readabil-
ity and documentation are stressed in the development of programs. Additional topics that
relate to software engineering are discussed throughout the text and include issues such as
software life cycle, portability, maintenance, modularity, recursion, abstraction, reusabi-
lity, structured programming, validation, and verification.
Four Types of Problems
Learning any new skill requires practice at a number of different levels of difficulty. We have
developed four types of exercises that are used throughout the text to develop problem-solving
skills. The first set of exercises is Practice! problems. These are short-answer questions that
relate to the section of material just presented. Most sections are immediately followed by
a set of Practice! problems so that students can determine if they are ready to continue to
the next section. Complete solutions to all the Practice! problems are included at the end of
the text.
The Modify! problems are designed to provide hands-on experience with example pro-
grams and the programs developed in the Problem Solving Applied sections. In these sec-
tions, we develop a complete C++ program using the five-step process. The Modify! problems
ask students to run the program with different sets of data, to test their understanding of how
the program works and of the relationships among the engineering variables. These exercises
also ask the students to make simple modifications to the program and then run the program
to test their changes.
All chapters end with a set of Exam Practice! problems, and every chapter includes a
set of Programming Problems. The Exam Practice! problems are short-answer questions
that relate to the material covered in the chapter. These problems help students determine how
well they understand the features of C++ presented in the chapter. The Programming Prob-
lems are new problems that relate to a variety of engineering applications, and the level of
difficulty ranges from very straightforward to longer project assignments. Each programming
problem requires that the student develop a complete C++ program or function. Engineering
data sets for many of the problems are included within the Instructor’s Resource Center to use
in testing. Also provided within the IRC are solutions to all of the Exam Practice! problems
and Programming Problems.
Study and Programming Aids
Statement Boxes, UML diagrams, and Program Traces provide easily accessible visual illus-
trations of important concepts. Margin notes are used to help the reader not only identify the
important concepts, but also easily locate specific topics. In addition, margin notes are used
to identify programming style guidelines and debugging information. Style guidelines show
students how to write C++ programs that incorporate good software discipline; debugging
sections help students recognize common errors so that they can avoid them. The program-
ming style notes are indicated with the margin note Style, and the debugging notes with a bug
23. xvi Preface
icon. Object-oriented features of C++ display an OOP icon to help students recognize these
features early in the text. Each Chapter Summary contains a summary of the style notes
and debugging notes, plus a list of the Key Terms from the chapter and a C++ Statement
Reference of the new statements, to make the book easy to use as a reference.
Optional Numerical Techniques
Numerical techniques that are commonly used in solving engineering problems are also dis-
cussed in optional sections in the chapters, and include interpolation, linear modeling
(regression), root finding, numerical integration, and the solution to simultaneous
equations. The concept of a matrix is also introduced and then illustrated using a num-
ber of examples. All of these topics are presented assuming only a trigonometry and college
algebra background.
Appendices
To further enhance reference use, the appendices include a number of important topics.
Appendix A contains a discussion of components in the C++ standard library. Appendix B
presents the ASCII character codes. Appendix D contains a list of references used through-
out the text. A MATLAB reference is also included as Appendix C, and solutions to Practice!
problems make up Appendix E.
Additional Resources
All instructor and student resources can be accessed at www.pearsonhighered.com/etter. Here,
students can access all source code for the book, and instructors can register for the password-
protected Instructor’s Resource Center. The IRC contains all the example programs used in
the text, complete solutions to all the Programming Problems found at the end of each chapter,
testbank questions, as well as data files to use with application problems and a complete set
of Lecture PowerPoint slides.
Acknowledgments
We would like to thank our outstanding team of reviewers—Roman Tankelevich, Colorado
School of Mines; John Sustersic, Penn State University; Tanya L. Crenshaw, University of
Portland; Daniel McCracken, City College of New York; Deborah L. Pollio, Virginia Tech;
Keith Hellman, Colorado School of Mines; Tammy VanDeGrift, University of Portland;
Melanie Ford, Penn State University—Behrend Campus; Amar Raheja, California State Poly-
technic University for their detailed and constructive comments and their valuable insights.
We would also like to acknowledge and thank our excellent editorial staff, including Tracy
Dunkelberger, Stephanie Sellinger, and Emma Snider, for their help in keeping everything on
task. Finally, we would like to thank our outstanding production team, including Eric Arima,
Kayla Smith-Tarbox, and Lily Ferguson, for their insight and attention to detail.
27. MAP OF THE RUSSO-AFGHAN REGION.
Fred asked if the Caspian was higher or lower than the Aral Sea.
They are of the same level, or nearly so, was the reply, though some
engineers say the Aral is about one hundred and fifty feet higher than the
Caspian, and the indications are that the two seas were formerly connected. The
whole plain of Turcomania is thought to have been at one time an inland sea. At
its southern extremity the Aral is bordered by an immense marsh, and it is
through this marsh that the Oxus discharges its waters.
Khiva stands near the Oxus, in the midst of beautiful gardens, all nourished by
the water from the river. Khiva, Bokhara, Samarcand, and Kokan would become
masses of ruins if the Oxus and Jaxartes were dried up, and you may be sure
the Russians will give the subject careful consideration before disturbing the
course of the waters. Nowhere in the world will you see more careful irrigation
than along these rivers, with the possible exception of the Nile valley. All
through Central Asia the only possible agriculture is upon the watercourses, or
where there are never-failing wells. Canals and irrigation-wheels are
everywhere, and you will often see evidences of excellent engineering abilities in
the construction of some of the artificial water-ways.
General Annenkoff, the officer in charge of the construction of the Trans-
Caspian Railway, has a scheme for creating a new oasis, capable of supporting
two hundred thousand people, near the disputed boundary between Turkestan
and Afghanistan. He proposes to turn one of the tributaries of the Oxus for that
purpose, and is confident that he can make a fertile area of several hundred
square miles by carefully utilizing the water of the stream.
28. On landing at Mikhailovsk, our friends were introduced to several Russian
officers, some of whom had been in America, and who heartily welcomed the
trio of travellers from that far-away land. They were invited to the club-house,
where they were lodged and cared for; the town did not boast an hotel other
than a very indifferent khan, which had all the discomforts of the Orient, with
none of its good points.
Frank and Fred endeavored to find the time-table of the railway, with a view to
making an excursion into Turkestan. Their inquiries were rewarded with the
information that there was no regular time for running the trains, as the
business transacted on the line was nearly all of a military character. But a train
was to leave in the morning for Kizil Arvat, one hundred and forty-four miles,
and if they cared to make the journey they were at liberty to do so.
Finding they would have time to go to Kizil Arvat and return before the
departure of the steamer for Baku, they accepted the invitation, which included
the Doctor as well as themselves. Early the next morning the train rolled out
from the station; it consisted of a locomotive and ten or twelve carriages. One
carriage contained the officers of a regiment of infantry that filled the remaining
vehicles; the regiment was bound for the frontier, where England and Russia
have latterly been discussing the question of the boundary, and a discussion of
this kind is materially assisted by the presence of soldiers.
TURCOMAN WOMAN SPINNING.
29. We will refer to Fred's account of the railway journey in Turkestan.
We were invited to seats in the carriage where the officers were riding. They
did everything to make our journey agreeable, and we were indebted to them
for a great deal of information about Central Asia. Some of them had been to
the British frontier, and one had visited Cabul, Herat, and Candahar.
The route of the railway was partly across the desert, and partly along the
valleys of two or three small rivers of no special importance except for their
usefulness in supplying water for the line. For a considerable distance the line
lies near the Etrek, a river that was of great use to General Skobeleff in his
advance upon Geok Tepé. At times it is simply a dry channel, but water can
generally be found by digging a few feet in the sand that forms, in the rainy
season, the bed of the stream.
VILLAGE OF TURCOMAN TENTS.
The country is a plain, with here and there a few hills not worthy to be called
mountains. Sometimes the plain is flat for a long distance, and again it is
undulating like the rolling prairies of our Western States. Vegetation is scanty at
best, and a large part of the country is absolutely desert. The great need of
Central Asia is water. If a million springs could be opened, all giving a copious
flow like some of the great springs in our Rocky Mountains, the next ten or
twenty years would see a great change in the aspect of Turkestan.
One of the officers told me that the country was of the same general character
all the way to the frontier of Afghanistan. 'The railway can be extended without
trouble,' said he, 'as far as we wish to carry it. There's not an obstacle at all
formidable to railway engineers.'
I asked, with some hesitation, where they wished to carry their railway line. I
knew the subject was not disconnected with politics, but the question was
innocent enough, and he could answer it as he chose, and probably did.
30. THE NEW RUSSO-AFGHAN FRONTIER.
'We built the line,' said he, 'first to Kizil Arvat, one hundred and forty-four miles,
and then extended it to Askabad, one hundred and ten miles farther. We are
now building to Sarakhs, one hundred and eighty-five miles from Askabad, and
there we may stop. Perhaps it will be pushed on to Herat, two hundred and two
miles from Sarakhs, but it can not be under the present political situation.
Afghanistan is under English control. You know the English Government gives
the Ameer of that country a large annual payment of money for his friendship;
and until we are willing to give a higher bribe he is not likely to permit us to
build railways in his territory.
'From Sarakhs our next line will be to Merv, the rich oasis that came under
Russian control a few years ago, or possibly Merv may be reached by a branch
from Askabad. Perhaps there will one day be a line from Merv to Samarcand and
Bokhara, but this is far in the future. From Merv a railway may be run along the
valley of the Murghab to Herat; but it is not a direct route, and we are much
more likely to reach Herat by way of Sarakhs, along the valley of the Heri-Rud.
Whichever way we take, the building of the road would not be at all difficult.
The Murghab route has the disadvantage of being longer than that of the Heri-
Rud, but its cost per mile would be much less, as the country is smoother.
'I suppose,' he continued, 'that there is a sort of race between England and
Russia to get to Herat with a railway. England is building north from India, while
we are building south from the Caspian. The terminal points of the two lines are
now less than eight hundred miles apart, and it is very evident that the English
31. and Russian locomotives will be whistling in the hearing of each other, and
blowing steam in each other's faces, within the next few years.[9]
'If we were not confronted by diplomacy we could reach Herat considerably in
advance of the English, as we have the shorter and easier line to build to get
there. But with our scrupulous regard for treaties and agreements, we may be
hindered in our railway building, and have the mortification of seeing our rivals
there ahead of us. The English consider Herat the key to India, and are
determined that we shall not possess it. We don't care much for it anyway, but
are perfectly willing to place it beneath the sheltering wings of the Black Eagle.
'When you are considering Sarakhs,' he continued, 'remember that there are
two places of that name. Old Sarakhs is a mass of ruins; only a single building
remains, and that is a tomb in which the body of Abel is said to rest. Another
tomb a few miles away is known as the tomb of Cain, and there is a tradition
that the Garden of Eden was in the neighborhood of Sarakhs. The Russians have
occupied Old Sarakhs, and will establish a military post there of considerable
importance as soon as the railway is completed.
OLD SARAKHS.
'Old Sarakhs is near the Heri-Rud River, which here forms a dividing line
between Persia and the Turcoman country. The Persians have built a town called
New Sarakhs on their side of the river, and protected it by a fort; they keep a
small garrison there, and as we have no quarrel with Persia, and are not likely to
have, it is quite sufficient for all purposes of peace.
'I wish you could go with me through that country and see the effect of the
Turcoman raiding system which was continued through generations, and has
only recently come to an end. Centuries ago the valleys of the Murghab and
Heri-Rud contained a large population, and the same was the case over a wide
extent of country.
'Ride where you will, you find the traces of irrigating canals in great number. In
the third century this region was said to contain a thousand cities, probably an
exaggeration, but indicative of the dense population it sustained, and might still
sustain. In many places the valleys of the Murghab and Heri-Rud are several
miles in width and perfectly flat. There are ruined canals all over these wide
32. places, showing that they were once cultivated; they might be cultivated again
and rendered fertile as of old by the same system that was once in vogue. The
country is a desert because it is not tilled, and it is not tilled because it has no
inhabitants. Turcoman raids have made the desolation by enslaving, killing, or
driving away the people that once lived here.
SARIK TURCOMAN
WOMAN.
'Since the raiding ceased the Sarik Turcomans, who were formerly as much
addicted to it as any others, have turned their attention to agriculture. They
have occupied parts of the Murghab Valley near Pul-i-Khisti and Ak Tapa, where
they have cleared out the old irrigation canals, set their ploughs and other
implements at work, and seem to be forgetting altogether their former mode of
life. They have settled into villages, but live in kibitkas in preference to houses
of mud or other solid materials. Considering their recent subjugation, they are
quite friendly with the Russians; they know we will never allow them to resume
their predatory life, but as long as they behave themselves they will find us to
be kind masters, and our military and engineering work in their country will
assure them a good market for their surplus produce.'
33. I asked the gentleman to tell me the difference between Pul-i-Khisti and Pul-i-
Khatun, which we had read so much about in the newspapers, at the time of the
conflict between the Russians and Afghans.
'Pul-i-Khatun is on the Heri-Rud or Tejend River, a few miles south of Sarakhs.
In the Persian language pul means bridge, and khatun lady, so that Pul-i-
Khatun may be translated Bridge of the Lady. The bridge that bears this name
is said to have been erected in the time of Tamerlane, the great conqueror, at
the request of one of the ladies of his family. It is of brick, in six arches, and has
not been repaired for a long time; the central arch is broken, but the others are
in serviceable condition.
PUL-I-KHISTI AND AK TAPA.
'Pul-i-Khisti means Bridge of Bricks, and is over the Murghab River, where that
stream unites with the Kushk. It became famous as the scene of the fight
between the Russians and Afghans, in the early part of 1885. Each party throws
the blame of the affair upon the other; naturally enough I think the Afghans
were at fault, but as I may be prejudiced on the subject it is not worth while to
discuss it. Pul-i-Khisti is close to Penjdeh, which is nothing more than a mass of
ruins where a town once stood; the Russians may be able to make something
out of it, and the next time I go there I shouldn't be surprised to find a strong
fort.
'The English wanted to make the boundary so that it would leave Penjdeh in
the possession of the Afghans, but we persuaded them that the place would be
safer in our hands than theirs. You will find on the map the boundaries as they
have been arranged, and as long as England keeps to her agreement there is
not likely to be any trouble. Of course we shall faithfully abide by our promises,
34. but one can never tell when the treacherous Afghans will cross the boundaries
and make depredations upon our peaceful subjects. Then we will defend our
rights; it is for such defence we have built the railway on which you are now
travelling, and we shall maintain a good-sized force of troops on or near the
frontier. By means of our railways and steamers we can get to the frontier a
great deal quicker than England can possibly reach it from her capital; and if she
chooses to make war on us she will find us ready.
PENJDEH.
'With the Vladikavkaz Railway finished to Petrovsk on the Caspian, and the
Trans-Caspian Railway completed to Sarakhs, we could bring troops from
Moscow to the latter point inside of a week. There would only be the crossing of
the Caspian, which is little more than a ferry, between Petrovsk and Mikhailovsk,
to break the continuous journey by rail. From Sarakhs to Herat, as I before said,
is about two hundred miles, which could be covered in two or three weeks by a
Russian army. We think we can get to Herat more quickly than England can in
case of war, but let us all hope that the necessity for the experiment may never
come.'
Fred thought there was a confident smile on the face of the Russian as he
pronounced the above words. It was very evident that the Russians in Central
Asia had an abiding faith in their ability to take care of themselves in case of a
conflict with England.
While conversing with another officer, the youths ascertained that he had
accompanied the first Russian expedition to the Merv Oasis, or rather the
expedition that converted that stronghold of the Turcomans into Russian
territory, with the loss of only one man. The gentleman said the Oasis was
watered by the Murghab, which practically terminated there; the river was
diverted into a great number of little streams, and the country included in these
35. streams formed the Oasis. The Mervis were more peaceable than their fellow
Turcomans, but very jealous of strangers, and not willing to admit anybody to
their limited territory.
They had a fort larger and stronger than the one against which Skobeleff's army
was nearly shattered to pieces at Geok Tepé; it was an enclosure with high,
thick walls of mud, and large enough to hold the whole population with their
flocks and herds. The Oasis is about one hundred and twenty miles from
Askabad and ninety from the nearest point on the Tejend; it was formerly
incorporated with the surrounding provinces of Turkestan, but for many years
has been independent.
COLONEL ALIKHANOFF.
We wanted Merv, said the Russian officer to whom allusion has just been
made, but we didn't want to fight for it; so we resorted to diplomacy, and
through the skill of General Komaroff and Colonel Alikhanoff, aided by a few
others who were in the secret, we came into peaceful possession of the place. I
have no doubt the Mervis are all very glad we are there, now that the thing has
been done.
Colonel Alikhanoff went from Askabad to Merv in company with a Russian
merchant who had a dozen camels laden with goods. They remained there a
fortnight, and then returned safely, accompanied by several delegates from the
Mervis who wished to consult with the Russian commander at Askabad about
some camels that had been stolen from them by the Persians. The delegates
were kindly received, and went home with a favorable report which ultimately
36. led to the occupation of Merv by a small force of Russian cavalry and infantry. A
fort was built, and a bazaar opened for the exchange of Russian goods for the
products of the Oasis, and ever since then the Russians and Mervis have been
on terms of friendship. Of course there were some of the Mervis who opposed
the advent of our soldiers, but they are now our earnest advocates, and would
be the last to ask us to leave.
THE GREAT HIGHWAY OF CENTRAL ASIA.
Merv is about two hundred and forty miles from Herat, and if we should ever
be obliged to march against that Afghan stronghold, the Oasis will be an
excellent point to start from after accumulating the necessary stores and
material of war. It promises to be a good centre of trade, and its importance
was easy to comprehend when the English Government made such a fuss as it
did about our taking it.
Before we were established there, continued the officer, an English
newspaper correspondent, Edmund O'Donovan, went to Merv by way of Persia,
and lived in the Oasis for five months. At first the people treated him coldly, but
he gradually won their confidence and convinced them of his friendliness. They
made him one of their elders, and appointed him to a place on the Governing
Council; he has told the story of his residence among these strange people in an
interesting volume entitled 'The Merv Oasis.'
One of the most remarkable journeys ever made on the Turcoman steppes,
said the gentleman in conclusion, was accomplished by another newspaper
correspondent, an American named MacGahan, during the campaign against
Khiva in 1873. Without an escort, and accompanied only by a servant and two
37. guides, he started from Fort Peroffsky, on the Jaxartes or Syr Darya River, near
the Aral Sea, to overtake General Kaufmann's army, that had gone to the attack
of Khiva. Its exact whereabouts were unknown; he had eight or ten days of
desert travel before him, and if he had fallen into the hands of the Turcomans or
Kirghese who roam over the desert, his fate would have been certain death.
The Russians at Fort Peroffsky refused to allow him to start, as they considered
it impossible for him to make the journey, and he was obliged to slip out of the
place in the night. He had several narrow escapes, but managed to get through
all right and join General Kaufmann's column just as the fighting before Khiva
began. The officers told him the chances of his getting across the desert with
his life were not more than one in a hundred. He remained with our army till the
end of the Khivan campaign, and every officer who knew him felt that he had
lost a personal friend when the news of MacGahan's death came a few years
later. The story of his adventures is told in his book—'Campaigning on the Oxus
and the Fall of Khiva.'
In 1875 a similar journey was made by Captain Burnaby, an English officer of
the Guards. He has given an admirable account of his experience in a book
entitled, 'A Ride to Khiva.'
Conversation such as this, writes Fred in his journal, beguiled the tediousness
of the ride over the flat and desolate region through which the railway passes.
At the few oases where we stopped, we saw little villages of Turcomans, but
they were so much alike that the descriptions you have already read will answer
for them all. At Kizil Arvat we found an oasis containing altogether half a dozen
square miles of tillable land, on which were several Turcoman villages, and a
Russian town of perhaps a thousand inhabitants.
We call the town Russian from the flag that waves over it, rather than from the
nationality of those who live in it. They are Russians, Turcomans, Kirghese,
Persians, Armenians, and Jews, and I don't know how many other races and
kinds of people. There is a good deal of commerce, mostly in the hands of
Armenians and Russians, but much less than when the railway terminated here.
The business of Merv and the Penjdeh district is at the end of the railway; in this
respect the commerce of Central Asia is much like that of our far-western
country, and changes its base with each change of the means of transport.
38. TURCOMAN FARM-YARD.
There is a fort at Kizil Arvat, and also a bazaar, and we are told that Askabad is
similarly provided. Whenever the Russians establish themselves in any part of
Turkestan, they build a fort and a bazaar side by side. Hardly has the army
pitched its tents before the shops are opened and the natives are invited to
come in and trade. All who come are kindly treated; in a little time whatever
hesitation the natives may have possessed is gone, and the cheapness of the
goods on sale converts the former enemies into friends. There is no doubt that
Russia thoroughly understands the Asiatic nature, and deals with it accordingly.
39. MAP OF TURKESTAN, SHOWING ROUTE OF THE TRANS-CASPIAN
RAILWAY.
Most of our return journey to Mikhailovsk was made in the night, which we did
not specially regret, where so much of the route was through the uninteresting
desert. We were told that when the railway was started, it was intended to
make a narrow-gauge line that would be taken up as soon as the capture of
Geok Tepé had been accomplished. But the undertaking had not gone far before
the plans were changed and a well-built railway, on the standard gauge of
Russia, was the result. The line is well equipped with cars, and at no distant day
will form a link in the overland route from England to India.
When the Russian and Indian lines form a connection near Herat or Candahar,
the Vladikavkaz Railway will be completed to Petrovsk, on the Caspian. The
traveller may then go from London to Bombay or Calcutta in nine or ten days.
His entire journey will be made by rail, with the exception of the passages of the
English channel and the Caspian Sea, the former requiring two hours, and the
latter an entire day. Russia is already talking of an extension of the line from
Tsaritsin, along the lower Volga and around the northern end of the Caspian to a
connection with the Trans-Caspian Railway. Should this line be made, the
journey to India would be wholly a land route, with the exception of 'The Silver
Streak,' between Dover and Calais.
40. While our friends are musing on the possibilities of the railway to India, and its
benefits to commerce and civilization, they have recrossed the Caspian and are
once more in the Petrolia of Europe. And now behold them seated in a train of
the Trans-Caucasian Railway for a ride to Tiflis and the Black Sea.
A letter in the New York Herald of April 19, 1886, says:
The Russians have established a military and naval station at Novi Golfe,
on the Caspian, twenty-two versts north-west of Mikhailovsk, and
connected it with the latter point by railway. In case of war with England,
the Russians are prepared to strike heavy blows in Asia. They have two
army corps in the Caucasus, and another in Turkestan ready for service on
their south-eastern frontier. The vessels of the Kavkas and Mercury
Steamship Company, Noble's naphtha fleet, and the Greek and Armenian
vessels on the Caspian (which all fly the Russian flag), would be
immediately pressed into the service. The Russians believe that, barring bad
weather, they could, with these steamers and a number of sailing-vessels in
tow, transport sixty thousand men across the Caspian from Astrachan,
Baku, and Petrovsk to Novi Golfe and Mikhailovsk in three days.
CROSSING A RIVER IN CENTRAL ASIA.
The Russians would thus dispose of about one hundred and fifteen
thousand men—Army of the Caucasus, sixty thousand; Turkestan, thirty
thousand; and fifteen thousand Turcoman auxiliaries. These latter will
supply the advance of the Russian columns heading southward from
Askabad and Merv.
41. The Russians have shown great tact and cleverness in the management of
their Turcoman subjects. There is at Merv a skeleton army, or cadre, of
three hundred Turcomans, under the command of a Cossack officer named
Kalotine. Of the three hundred, one hundred are from Merv, one hundred
are Tekkes, and the remainder from other tribes. These men (irregular
horse) remain in the service six months. During that time they are paid
twenty-five roubles a month, and at its expiration are discharged with the
rank of sergeant, but remain liable to military duty in time of war. This plan
was adopted to secure good native non-commissioned officers for the
fifteen regiments of irregular cavalry. The son of the last Khan of Merv is
now a Russian sergeant. Ten native Turcomans hold the rank of captain in
the Russian army, and four that of lieutenant, besides which many
decorations have been given to those who took part in Alikhanoff's foray.
The construction of the railway between Askabad and Merv presented
great difficulties, on account of the absence of water in many places. To
overcome this, artesian wells were dug. The width and current of the
Tegend-Bud necessitated an iron bridge at Kara-Bend. The Trans-Caspian
Railway is built upon the model of the Trans-Caucasian one, the stations on
both being near together, solidly built and comfortable. There are sixteen
stations between Mikhailovsk and Askabad (four hundred and twenty-two
versts).
Mikhailovsk to
Mallakara 22Versts.
Bala Ischen 35
Aidin 29
Paraval 15
Atchai-Komm 16
Kasandjik 31
Ossausan 16
Ouchak 23
Kizil-Arvat 30
Koteh 28
Barni 24
Arolman 30
Baharden 30
Keli-Atta 27
Geok-Tepé 25
Besmeni 21
Askabad 20
43. CHAPTER XXIII.
BAKU TO TIFLIS.—THE CAPITAL OF THE CAUCASUS.—MOUNTAIN
TRAVELLING.—CROSSING THE RANGE.—PETROLEUM LOCOMOTIVES.—
BATOUM AND ITS IMPORTANCE.—TREBIZOND AND ERZEROOM.—
SEBASTOPOL AND THE CRIMEA.—SHORT HISTORY OF THE CRIMEAN
WAR.—RUSSO-TURKISH WAR OF 1877-78.—BATTLES IN THE CRIMEA
AND SIEGE OF SEBASTOPOL.—VISITING THE MALAKOFF AND REDAN
FORTS.—VIEW OF THE BATTLE-FIELDS.—CHARGE OF THE LIGHT
BRIGADE AT BALAKLAVA.—PRESENT CONDITION OF SEBASTOPOL.—
ODESSA.—ARRIVAL AT CONSTANTINOPLE.—FRANK'S DREAM.—THE
END.
For fifty miles after leaving Baku the railway follows the coast of the Caspian Sea
until it reaches Alayat, where the Government is establishing a port that
promises to be of considerable importance at no distant day. The country is a
desert dotted with salt lakes, and here and there a black patch indicating a
petroleum spring. The only vegetation is the camel-thorn bush, and much of the
ground is so sterile that not even this hardy plant can grow. Very little rain falls
here, and sometimes there is not a drop of it for several months together.
At Alayat the railway turns inland, traversing a desert region where there are
abundant indications of petroleum; in fact all the way from Baku to Alayat
petroleum could be had for the boring, and at the latter place several wells have
been successfully opened, though the low price of the oil stands in the way of
their profitable development. After leaving the desert, a region of considerable
fertility is reached. The streams flowing down from the mountains are utilized
for purposes of irrigation, but very rudely; under a careful system of cultivation
the valley of the Kura River, which the railway follows to Tiflis, could support a
large population.
From Baku to Tiflis by railway is a distance of three hundred and forty-one
miles, and the line is said to have cost, including rolling stock, about fifty
thousand dollars a mile. In the work on the desert portion many of the laborers
died from the effects of the extreme dryness of the atmosphere. The whole
distance from Baku to Batoum, on the Black Sea, is five hundred and sixty-one
miles.
Tiflis is thirteen hundred and fifty feet above the level of the sea, and the point
where the railway reaches its greatest elevation is eighteen hundred feet higher,
44. LOOKING DOWN ON THE STEPPE.
or thirty-two hundred feet
in all. The grades are very
steep; there is one stretch
of eight miles where it is
two hundred and forty feet
to the mile, and for a
considerable distance it
exceeds one hundred feet
to the mile. It is proposed
to overcome the steepest
grade by a long tunnel
which would reduce the
highest elevation to little
more than two thousand
feet.
Our friends reached Tiflis in
the evening, after an
interesting ride, in spite of
the monotony of the desert
portion of the route. Frank
will tell us the story of their
visit to the famous city of
the Caucasus.
We were somewhat disappointed, said he, with our first view of Tiflis. We had
an impression that it was in the centre of a fertile plain surrounded by
mountains; actually the ground on which it stands is not fertile, and the
surroundings consist of brown hills instead of mountains. The sides of the hills
are barren, and there would hardly be a shrub or tree in the city were it not for
the system of irrigation which is maintained. The prettiest part of the city is the
quarter occupied by the Germans, where there are rows and groups of trees and
a great many luxuriant gardens. The Germans are descended from some who
came here in the last century to escape religious persecution. Though born in
Tiflis and citizens of Russia, in every sense they preserve their language and
customs, and do not mingle freely with their Muscovite neighbors.
There are about one hundred and ten thousand inhabitants in Tiflis; nearly
one-third are Russians, rather more than a third Armenians, twenty-three
thousand Georgians, and the rest are Germans, Persians, and mixed races in
general. Most of the business is in the hands of the Armenians, and many of
them are wealthy; nearly all speak Russian, and mingle with the Russians more
harmoniously than do any of the others. The Persians live in a quarter by
45. themselves, and it is by no means the cleanest part of the city. The Georgians
preserve their dress and language, and, though entirely peaceful, are said to
maintain the same hatred to Russia as when fighting to preserve their
independence.
Many of the officials in the Caucasus are Armenians, and some of the ablest
generals of the Russian army belong to the same race. Gen. Loris Melikoff is an
Armenian, and so are Generals Lazareff and Tergoukasoff, as well as others of
less importance. The Armenians have four newspapers at Tiflis, and four
monthly reviews. There are nearly a million of these people in Russia and the
Caucasus, and their treatment is in marked contrast to that of the eight hundred
thousand Armenian subjects of Turkey who have been most cruelly oppressed
by the Sultan and his officers.
We had read of the beauty of the Georgians, who used to sell their daughters
to be the wives of the Turks, and naturally looked around us for handsome
faces. We saw them among the men as well as among the women; and we saw
more handsome men than women, perhaps for the reason that men were much
more numerous. The Georgians are a fine race of people, and so are all the
natives of the Caucasus. The mountain air all the world over has a reputation for
developing strength and intelligence among those who breathe it.
Since the occupation of Georgia and the other parts of the Caucasus by Russia,
the people are no longer sold as slaves for Turkish masters. Whatever may be
the faults of the Russian rule, it is certainly far in advance of that of Turkey.
46. VIEW OF TIFLIS.
Tiflis may be said to be in two parts, the old and the new. The former is on the
bank of the river, and its streets are narrow and dirty; the new part is on higher
ground, and has been chiefly built by the Russians since they obtained
possession of the country. In this part the streets are wide, and lined with many
handsome buildings; in the old part there are several Armenian churches and
caravansaries, and the greater portion of the commerce is transacted there.
We saw a great many Russian soldiers, and were told that a large garrison is
always maintained in Tiflis, which is a central point from which troops can be
sent in any direction. The Government offices and the palace of the Governor-
general are in the Russian quarter, and of course there are plenty of Russian
churches, with their gilded domes sparkling in the sunlight.
We visited one of the churches, and also the Armenian Cathedral; we tried to
see the interior of a mosque, but were forbidden admittance except on payment
of more money than we chose to give. We drove to the hot baths, which are
situated just outside the city; they are largely patronized, and have an excellent
reputation for the relief of gout, rheumatism, and similar troubles. There are
many hot springs in the neighborhood of Tiflis that have been flowing for
centuries, without any change in temperature or volume.
We wanted to go overland to Vladikavkaz, for the sake of the journey among
the Caucasus, but our plans were otherwise, and we continued by railway to
47. Batoum. The mountains of this range are as picturesque as any we have ever
seen. The passes are like those of the Alps or the Sierra Nevadas, and as we
wound along the line of railway to the crest of the divide, every moment
revealed a new and splendid picture. We had distant views of Elburz and Ararat,
two of the most famous mountains of this region, and greatly regretted our
inability to visit the latter, which is revered as the resting-place of Noah's Ark.
Mount Ararat has been ascended by several travellers; they describe the journey
as very fatiguing, but were amply repaid by the magnificent view from the
summit.
We left Tiflis dry and dusty, and the dry air remained with us till we crossed the
ridge and began our descent. Then we entered the clouds, and as we passed
below their level found ourselves in a pouring rain. The western slope of the
Caucasus is a rainy region, while the eastern is dry. Baku has too little rain, and
Batoum too much; the western slope is luxuriant, while the eastern is an arid
desert, and the fertility of the former continues down to the shore of the Black
Sea.
48. THE PASS OF DARIEL, CAUCASUS.
Grapes and melons were offered at every station, at prices that were a marvel
of cheapness. Two cents would buy a large melon, and the same money was
gladly accepted for a bunch of grapes which would furnish a dinner for a very
hungry man. A great deal of wine is raised in this region; three hundred
thousand acres are said to be devoted to the culture of the grape in the
Caucasus, and about forty million gallons of wine are made annually. Wine is
plenty and cheap; the Russians refuse to drink the wine of the Caucasus, just as
Californians affect to despise that of their own State. We are told that a large
part of the so-called foreign wine sold in Tiflis and other cities of the Caucasus is
really the product of the country under fictitious labels.
49. GOVERNOR-GENERAL OF THE
CAUCASUS.
We have already mentioned the use of petroleum in the locomotives of the
Trans-Caucasian Railway. Where we stopped for fuel and water the petroleum-
tank was side by side with the water-tank, and there was no sign of wood-yard
or coal-heap. A few minutes charged the tender with petroleum and water, in
separate compartments, and then we moved on, just as on any other railway
line.
It is delightful riding behind a petroleum locomotive, as there are neither
cinders nor smoke. After the fire is started the furnace door is not opened; the
fireman regards the flame through a hole about two inches square, and
regulates it just as may be desired. They told us that steam could be more
evenly maintained than with coal or wood; there was no excess of steam while
waiting at stations, and consequently no necessity for 'blowing off.' Wonder
what railway in America will be the first to adopt the new fuel?
The Trans-Caucasian Railway was begun in 1871; its starting-point was at Poti,
which has a poor harbor and stands in marshy ground, so that fevers and
malaria are altogether too common. In 1878 Russia came into possession of
Batoum, which has a good harbor, and immediately a branch line sixty miles
long was built from that city to connect with the railway. Now nearly all the
business has gone to Batoum. Poti is decaying very rapidly, but for military
reasons it is not likely to be abandoned.
By the treaty of Berlin Batoum was made a free port, and the Russians were
forbidden to fortify it; but they have kept the Turkish fortifications, and not only
kept them uninjured, but have repaired them whenever there were signs of
decay. On this subject the following story is told:
The casemated fortress which commands the port required to be strengthened
in certain points, and the contractors were asked for estimates for the work.
50. One man presented an estimate which he headed 'Repairs to Fortifications.' The
general commanding the district immediately sent for the contractor, and said to
him,
'There are no fortifications in Batoum; they are forbidden by the treaty of
Berlin. Your estimates must be for garrison-barrack repairs. Remember this in
all your dealings with the Government.'
51. RUINED FORTRESS IN THE
CAUCASUS.
We were only a few hours in Batoum, as we embraced the opportunity to embark on one of the
Russian Company's steamers for Sebastopol and Odessa. Batoum is growing very rapidly, and
promises to be a place of great importance in a very few years. The old town of the Turks has given
place to a new one; the Russians have destroyed nearly all the rickety old buildings, laid out whole
streets and avenues of modern ones, extended the piers running into the sea, drained the marshes
that formerly made the place unhealthy, and in other ways have displayed their enterprise. We were
told that there is a great deal of smuggling carried on here, but probably no more than at Gibraltar,
Hong-Kong, and other free ports in other parts of the world.
RUINED CHURCH NEAR BATOUM.
And now behold us embarked on a comfortable steamer, and bidding farewell to the Caucasus. Our
steamer belongs to the Russian Company of Navigation and Commerce, which has its headquarters
at Odessa; it sends its ships not only to the ports of the Black Sea, but to the Levantine coast of the
Mediterranean, through the Suez Canal to India, and through the Strait of Gibraltar to England. A
line to New York and another to China and Japan are under consideration; it is probable that the
latter will be established before the Trans-Atlantic one. The company owns more than a hundred
steamers, and is heavily subsidized by the Russian Government.
52. 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!
ebookultra.com