Course Hero - We put you ahead of the curve!
You have requested the below document.

Chapter 03 Old Dominion CS 150
Sign up now to view this document for free!
  • Title: Chapter 03
  • Type: Notes
  • School: Old Dominion
  • Course: CS 150
  • Term: Spring

Coursehero >> Virginia >> Old Dominion >> CS 150
Course Hero has millions of student submitted documents similar to the one below including study guides, homework solutions, papers, and exam answer keys.

Programming: C++ From Problem Analysis to Program Design, Third Edition Chapter 3: Input/Output Objectives In this chapter you will: Learn what a stream is and examine input and output streams Explore how to read data from the standard input device Learn how to use predefined functions in a program Explore how to use the input stream functions get, ignore, fill, putback, and peek C++ Programming: From Problem Analysis to Program Design, Third Edition 2 Objectives (continued) Become familiar with input failure Learn how to write data to the standard output device Discover how to use manipulators in a program to format output Learn how to perform input and output operations with the string data type Become familiar with file input and output C++ Programming: From Problem Analysis to Program Design, Third Edition 3 Input/Output Streams I/O: sequence of bytes (stream of bytes) from source to destination Bytes are usually characters, unless program requires other types of information Stream: sequence of characters from source to destination Input Stream: sequence of characters from an input device to the computer Output Stream: sequence of characters from the computer to an output device C++ Programming: From Problem Analysis to Program Design, Third Edition 4 Standard I/O Devices Use iostream to extract (receive) data from keyboard and send output to the screen iostream contains definitions of two types - istream - input stream - ostream - output stream iostream has two variables - cin - stands for common input - cout - stands for common output C++ Programming: From Problem Analysis to Program Design, Third Edition 5 Using cin and cout To use cin and cout, the preprocessor directive #include <iostream> must be used The declaration is similar to the following C++ statements: istream cin; ostream cout; Input stream variables: type istream Output stream variables: type ostream C++ Programming: From Problem Analysis to Program Design, Third Edition 6 cin and the Extraction Operator >> The syntax of an input statement using cin and the extraction operator >> is cin >> variable >> variable...; The extraction operator >> is binary The left-hand operand is an input stream variable such as cin The right-hand operand is a variable of a simple data type C++ Programming: From Problem Analysis to Program Design, Third Edition 7 Standard Input Every occurrence of >> extracts the next data item from the input stream Two variables can be read using a single cin statement No difference between a single cin with multiple variables and multiple cin statements with one variable When scanning, >> skips all whitespace Whitespace characters consist of blanks and certain nonprintable characters C++ Programming: From Problem Analysis to Program Design, Third Edition 8 Data Type of Input >> distinguishes between character 2 and number 2 by the right hand operand of >> - If it is of type char, the 2 is treated as character 2 - If it is of the type int (or double) the 2 is treated as the number 2 C++ Programming: From Problem Analysis to Program Design, Third Edition 9 Reading Data When reading data into a char variable - Extraction operator >> skips leading whitespace, finds and stores only the next character - Reading stops after a single character C++ Programming: From Problem Analysis to Program Design, Third Edition 11 Reading Data (Continued) To read data into an int or double variable - Extraction operator >> skips leading whitespace, reads plus or minus sign (if any), reads the digits (including decimal) - Reading stops on whitespace non-digit character C++ Programming: From Problem Analysis to Program Design, Third Edition 12 Example 3-1 int a, b; double z; char ch, ch1, ch2; Statement 1 cin >> ch; 2 cin >> ch; Input A AB Value Stored in Memory ch = 'A` ch = 'A', 'B' is held for later input 3 cin >> a; 4 cin >> a; 5 cin >> z; 6 cin >> z; 48 46.35 74.35 39 a = 48 a = 46, .35 is held for later input z = 74.35 z = 39.0 7 cin >> z >> a; 65.78 38 z = 65.78, a = 38 Statement 8 cin >> a >> b; 9 cin >> a >> ch >> z; Input 4 60 57 A 26.9 Value Stored in Memory a = 4, b = 60 a = 57, ch = 'A', z = 26.9 a = 57, ch = 'A', z = 26.9 a = 57, ch = 'A', z = 26.9 10 cin >> a >> ch >> z; 57 A26.9 11 cin >> a >> ch >> z; 57 A26.9 12 cin >> a >> ch >> z; 57A26.9 13 cin >> z >> ch >> a; 36.78B34 14 cin >> z >> ch >> a; 36.78 15 cin >> a >> b >> z; 11 34 a = 57, ch = 'A', z = 26.9 z = 36.78, ch = 'B', a = 34 z = 36.78, ch = 'B', a = 34 a = 11, b = 34, computer waits for the next number B34 Statement 16 cin >> a >> z; Input 46 32.4 68 Value Stored in Memory a = 46, z = 32.4, 68 is held for later input 17 cin >> a >> z; 18 cin >> ch >> a; 78.49 256 a = 78, z = 0.49 ch = '2', a = 56 19 cin >> a >> ch; 256 a = 256, computer waits for the input value for ch 20 cin >> ch1 >> ch2; AB ch1 = 'A', ch2 = 'B' Using Predefined Functions A function (subprogram): set of instructions When activated, it accomplishes a task main executes when a program is run Other functions execute only when called C++ includes a wealth of functions Predefined functions are organized as a collection of libraries called header files C++ Programming: From Problem Analysis to Program Design, Third Edition 16 Predefined Functions Header file may contain several functions To use a predefined function, you need the name of the appropriate header file You also need to know: - Function name - Number of parameters required - Type of each parameter - What the function is going to do C++ Programming: From Problem Analysis to Program Design, Third Edition 17 Predefined Function Example To use pow (power), include cmath pow has two numeric parameters The syntax is: pow(x,y) = xy x and y are the arguments or parameters In pow(2,3), the parameters are 2 and 3 C++ Programming: From Problem Analysis to Program Design, Third Edition 18 Example 3-2 //How to use predefined functions. #include <iostream> #include <cmath> #include <string> using namespace std; int main() { double u, v; string str; cout << "Line 1: 2 to the power of 6 = " << pow(2, 6) << endl; //Line 1 u = 12.5; //Line 2 v = 3.0; //Line 3 cout << "Line 4: " << u << " to the power of " << v << " = " << pow(u, v) << endl; //Line 4 cout << "Line 5: Square root of 24 = " << sqrt(24.0) << endl; //Line u = pow(8.0, 2.5); //Line cout << "Line 7: u = " << u << endl; //Line str = "Programming with C++"; //Line cout << "Line 9: Length of str = " << str.length() << endl; //Line return 0; } 5 6 7 8 9 Sample Run: Line 1: 2 to the power of 6 = 64 Line 4: 12.5 to the power of 3 = 1953.13 Line 5: Square root of 24 = 4.89898 Line 7: u = 181.019 Line 9: Length of str = 20 cin and the get Function The get function - Inputs next character (including whitespace) - Stores character location indicated by its argument The syntax of cin and the get function: cin.get(varChar); varChar - Is a char variable - Is the argument (parameter) of the function C++ Programming: From Problem Analysis to Program Design, Third Edition 21 cin and the ignore Function ignore: discards a portion of the input The syntax to use the function ignore is: cin.ignore(intExp, chExp); intExp is an integer expression chExp is a char expression If intExp is a value m, the statement says to ignore the next m characters or all characters until the character specified by chExp C++ Programming: From Problem Analysis to Program Design, Third Edition 22 putback and peek Functions putback function - Places previous character extracted by the get function from an input stream back to that stream peek function - Returns next character from the input stream - Does not remove the character from that stream C++ Programming: From Problem Analysis to Program Design, Third Edition 23 putback and peek Functions (continued) The syntax for putback: - istreamVar.putback(ch); - istreamVar - an input stream variable, such as cin - ch is a char variable The syntax for peek: - ch = istreamVar.peek(); - istreamVar is an input stream variable (cin) - ch is a char variable C++ Programming: From Problem Analysis to Program Design, Third Edition 24 Dot Notation In the statement cin.get(ch); cin and get are two separate identifiers separated by a dot Dot separates the input stream variable name from the member, or function, name In C++, dot is the member access operator C++ Programming: From Problem Analysis to Program Design, Third Edition 25 Input Failure Things can go wrong during execution If input data does not match the corresponding variables, the program may run into problems Trying to read a letter an into int or double variable would result in an input failure If an error occurs when reading data - Input stream enters the fail state C++ Programming: From Problem Analysis to Program Design, Third Edition 26 Input Failure (continued) Once in a fail state, all further I/O statements using that stream are ignored The program continues to execute with whatever values are stored in variables This causes incorrect results The clear function restores input stream to a working state istreamVar.clear(); C++ Programming: From Problem Analysis to Program Design, Third Edition 27 Writing to Standard Output Syntax of cout when used with << cout < <expression or manipulator << expression or manipulator...; Expression is evaluated Value is printed Manipulator is used to format the output C++ Programming: From Problem Analysis to Program Design, Third Edition 28 Formatting Output endl manipulator moves output to the beginning of the next line setprecision(n) outputs decimal numbers with up to n decimal places fixed outputs floating-point numbers in a fixed decimal format showpoint forces output to show the decimal point and trailing zeros C++ Programming: From Problem Analysis to Program Design, Third Edition 29 The setw Manipulator setw outputs the value of an expression in specific columns If the number of columns exceeds the number of columns required by the expression - Output of the expression is right-justified - Unused columns to the left are filled with spaces C++ Programming: From Problem Analysis to Program Design, Third Edition 30 The flush Manipulator flush clears the buffer, even if it is not full Unlike endl, it does not move the cursor to the beginning of the next line The syntax for flush: ostreamVar is an output stream variable C++ Programming: From Problem Analysis to Program Design, Third Edition 31 Additional Output Formatting Tools Output stream variables can use setfill to fill unused columns with a character left: left-justifies the output - ostreamVar << left; Disable left by using unsetf right: right-justifies the output - ostreamVar << right; C++ Programming: From Problem Analysis to Program Design, Third Edition 32 Types of Manipulators Two types of manipulators: - With parameters - Without parameters Parameterized: require iomanip header - setprecision, setw, and setfill Nonparameterized: require iostream header - endl, fixed, showpoint, left, and flush C++ Programming: From Problem Analysis to Program Design, Third Edition 33 I/O and the string Type An input stream variable (cin) and extraction operator >> can read a string into a variable of the data type string Extraction operator - Skips any leading whitespace characters and reading stops at a whitespace character - Should not be used to read strings with blanks The function getline - Reads until end of the current line - Should be used to read strings with blanks C++ Programming: From Problem Analysis to Program Design, Third Edition 34 File Input/Output File: area in secondary storage to hold info File I/O 1. Include fstream header 2. Declare file stream variables 3. Associate the file stream variables with the input/output sources 4. Use the file stream variables with >>, <<, or other input/output functions 5. Close the files File Input/Output C++ Programming: From Problem Analysis to Program Design, Third Edition 35 Programming Example A theater owner agrees to donate a portion of gross ticket sales to a charity The program will prompt the user to input: - movie name - adult ticket price - child ticket price - number of adult tickets sold - number of child tickets sold - percentage of gross amount to be donated C++ Programming: From Problem Analysis to Program Design, Third Edition 36 Programming Example I/O Inputs: movie name, adult and child ticket price, # adult and child tickets sold, and percentage of the gross to be donated Program output: -*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-* Movie Name: ..................Duckey Goes to Mars Number of Tickets Sold: ........... Percentage of Gross Amount Donated: Amount Donated: ................... $ 2650 10.00% 915.00 Gross Amount: ..................... $ 9150.00 Net Sale: ......................... $ 8235.00 C++ Programming: From Problem Analysis to Program Design, Third Edition 37 Problem Analysis The program needs to: 1. Get the movie name 2. Get the price of an adult ticket price 3. Get the price of a child ticket price 4. Get the number of adult tickets sold 5. Get the number of child tickets sold C++ Programming: From Problem Analysis to Program Design, Third Edition 38 Problem Analysis (continued) 6. Get the percentage of the gross amount donated to the charity 7. Calculate the gross amount 8. Calculate the amount donated to the charity 9. Calculate the net sale amount 10. Output the results C++ Programming: From Problem Analysis to Program Design, Third Edition 39 Formulas Calculate the gross amount: grossAmount = adultTicketPrice * noOfAdultTicketsSold + childTicketPrice * noOfChildTicketsSold; Calculate the amount donated to the charity: amountDonated = grossAmount * percentDonation / 100; Calculate the net sale amount: netSale = grossAmount amountDonated; C++ Programming: From Problem Analysis to Program Design, Third Edition 40 Variables string movieName; double adultTicketPrice; double childTicketPrice; int noOfAdultTicketsSold; int noOfChildTicketsSold; double percentDonation; double grossAmount; double amountDonated; double netSaleAmount; C++ Programming: From Problem Analysis to Program Design, Third Edition 41 Formatting Output First column is left-justified Numbers in second column are right-justified When printing a value in the first column, use left Before printing a value in the second column, use right Use setfill to fill the empty space between the first and second columns with dots C++ Programming: From Problem Analysis to Program Design, Third Edition 42 Formatting Output (continued) In the lines showing gross amount, amount donated, and net sale amount - Use blanks to fill space between the $ sign and the number Before printing the dollar sign - Use setfill to set the filling character to blank C++ Programming: From Problem Analysis to Program Design, Third Edition 43 Main Algorithm 1. Declare variables 2. Set the output of the floating-point to - - - Two decimal places Fixed Decimal point and trailing zeros 3. Prompt the user to enter a movie name 4. Input movie name using getline because it might contain spaces C++ Programming: From Problem Analysis to Program Design, Third Edition 44 Main Algorithm (continued) 5. Prompt user for price of an adult ticket 6. Input price of an adult ticket 7. Prompt user for price of a child ticket 8. Input price of a child ticket 9. Prompt user for the number of adult tickets sold C++ Programming: From Problem Analysis to Program Design, Third Edition 45 Main Algorithm (continued) 10. Input number of adult tickets sold 11. Prompt user for the number of child tickets sold 12. Input the number of child tickets sold 13. Prompt user for percentage of the gross amount donated 14. Input percentage of the gross amount donated C++ Programming: From Problem Analysis to Program Design, Third Edition 46 Main Algorithm (continued) 15. Calculate the gross amount 16. Calculate the amount donated 17. Calculate the net sale amount 18. Output the results C++ Programming: From Problem Analysis to Program Design, Third Edition 47 Summary Stream: infinite sequence of characters from a source to a destination Input stream: from a source to a computer Output stream: from a computer to a destination cin: common input cout: common output To use cin and cout, include iostream header C++ Programming: From Problem Analysis to Program Design, Third Edition 48 Summary (continued) get reads data character-by-character putback puts last character retrieved by get back to the input stream ignore skips data in a line peek returns next character from input stream, but does not remove it Attempting to read invalid data into a variable causes the input stream to enter the fail state C++ Programming: From Problem Analysis to Program Design, Third Edition 49 Summary (continued) The manipulators setprecision, fixed, showpoint, setw, setfill, left, and right for formatting output Include iomanip for the manipulators setprecision, setw, and setfill flush clears the buffer even if it is not full File: area in secondary storage to hold info Header fstream contains the definitions of ifstream and ofstream C++ Programming: From Problem Analysis to Program Design, Third Edition 50

Find millions of documents here - Study Guides, Homework Solutions, Papers, Exam Answer Keys and more. Course Hero has millions of course related materials that will enable you to learn better, faster and get an A in all your courses.
Below is a small sample set of documents:

chapter01
Path: Old Dominion >> CS >> 150 Spring, 2008

Description: C+ Programming: From Problem Analysis to Program Design, Third Edition Chapter 1: An Overview of Computers and Programming Languages Objectives In this chapter you will: Learn about different types of computers Explore the hardware and software c...
Test 2 Notes
Path: Texas >> GOV >> 310L Spring, 2008
Description: Presidential Elections Government 310L Professor Andrew Karch I. Presidential nominations A. American primary system is unusual for its length and participatory nature Convention delegates pledged to particular candidates are chosen in primary elec...
syallabus2008
Path: UCSD >> CHEM >> 13 Spring, 2008
Description: CHEM 13 Chemistry of Life Syllabus (Spring 2008) Instructor: Prof. Simpson Joseph Office: Room 4102, Urey Hall Phone: 822-2957 E-mail: sjoseph@chem.ucsd.edu Office Hours: Thursday 2:00 to 5:00 PM (First come/First served) Scope of this course: The ob...
bios213lecture 14
Path: N. Illinois >> BIOS >> 231 Spring, 2008
Description: Antimicrobial Drugs Chemotherapy The use of drugs to treat a disease Antimicrobial drugs Interfere with the growth of microbes within a host Antibiotic Substance produced by a microbe that, in small amounts,inhibits another microbe Selective to...
bios 213 lecture 11
Path: N. Illinois >> BIOS >> 231 Spring, 2008
Description: Specific Defenses of the Host: The Immune Response Innate (nonspecific) Defenses against any pathogen Immunity Specific antibody and lymphocyte response to an antigen Antigen (Ag) A substances that causes the body to produce specific antibodies o...
bios 213 lecture 12
Path: N. Illinois >> BIOS >> 231 Spring, 2008
Description: Disorders Associated with the Immune System Infection and immunosuppression are failures of the immune system. Superantigens cause release of cytokines that cause adverse host responses. Allergies and transplant rejection are harmful immune reacti...
chapter2
Path: University of Alberta >> STAT >> 151 Fall, 2007
Description: CHAPTER 2: DISPLAYING AND DESCRIBING DATA 2.1 Variables Consider a class of 30 students: . . Gender (male, female) Hair color (blond, brown, black,.) Height (in feet, inches) Weight (in pounds) Age (in years) Variable any characteristic of a pers...
Test 2 Geography 20502
Path: LSU >> GEOG >> 2050 Spring, 2008
Description: Test 2 Geography 2050 Geog 2-08-08 Solar Radiation is the primary heat source for the Atmosphere, it\'s the primary fuel for it and our weather We must balance between. Insolation is incoming solar radiation Absorption of terrestrial radiation by atmo...
chapter3
Path: University of Alberta >> STAT >> 151 Fall, 2007
Description: CHAPTER 3: EXPLORING RELATIONSHIPS 3.1 Response and Explanatory Variables What is the nature of the relationship? Which variable influences which? X Y (X influences Y) X = explanatory variable, Y = response variable. Age Pet ownership Blood Pressure...
Java_Tutorial
Path: Brandeis >> COSI >> 31a Spring, 2008
Description: Java, Linux, Emacs Tutorial COSI 31A 01/24/2008 Outline Simple java program Loops and statements Classes and objects Strings, Arrays, Vectors Inheritance Interfaces and Abstract classes Exceptions Linux commands Emacs 1 Java First Java ...
04. Equity Kidd version
Path: Old Dominion >> ECI >> 301 Fall, 2007
Description: What would you do? Ashley is a wiz at math. She \"gets\" everything instantly. It usually takes her only five minutes to do her math homework. Nick, on the other hand, struggles with math. He labors over math problems, sometimes for hours. Should...
case study
Path: LSU >> BLAW >> 3201 Spring, 2008
Description: case study chapter 7 State Farm Mutual automobile insurance v Campbell the question is whether, in the circumstances we shall recount, an award of 145 million in punitive damages where full compensatory damages are 1 million, is excessive an in viola...
hw2
Path: Brandeis >> MATH >> 15a Spring, 2008
Description: Otto Bretscher Linear Algebra with Applications 3rd Edition Section 1.3 18. 20. a. b. 52. Section 2.1 8. ...
chapter4
Path: University of Alberta >> STAT >> 151 Fall, 2007
Description: CHAPTER 4: PRODUCING DATA 4.1 Introduction How to verify the following statements? 1. 2. Pet owners are less likely to die of coronary heart disease. Regular large doses of vitamin C reduce the chance of getting a common cold. Response variable a v...
Geography
Path: LSU >> GEOG >> 2050 Spring, 2008
Description: Geography The science of geography Geography o The science that studies the relationships among natural systems, geographic areas, society, cultural activities, and the interdependence of all these over space Spatial- the nature and character of phy...
05. Accountability Kidd version
Path: Old Dominion >> ECI >> 301 Fall, 2007
Description: What do you think? Mrs. Bright is getting a huge bonus ($5,000) this year. Her fourth graders moved from an initial 3.1 grade eqivalency score in math at the start of the year to 5.0 at the end. Mr. Bummer works in another school across town. H...
series_solution1_examples_p2
Path: New Mexico >> CHNE >> 525 Fall, 2008
Description: 2 Series Solutions to Linear Ordinary Differential Equations II Examples: Solutions about an Ordinary Point yx c0 1 1 3 x 3 2 1 6 5 3 2 x6 c1 x 1 4 x 4 3 1 x7 7 6 4 3 This gives two solutions 1 3 1 1 y1 x 1 x x6 x9 3 2 6 5 3 2 9 8 6 5 3 2 1 ...
hw3
Path: Brandeis >> MATH >> 15a Spring, 2008
Description: Otto Bretscher Linear Algebra with Applications 3rd Edition Section 2.1 6. 20. 22. Section 2.4 4. 6. ...
chapter5
Path: University of Alberta >> STAT >> 151 Fall, 2007
Description: CHAPTER 5: PROBABILITY 5.1 What is probability? Random experiment results in one of a number of possible outcomes. The outcome that occurs cannot be predicted with certainty. Examples: Tossing a coin, rolling a die. Sample Space (S) - the list of a...
power_series_ode_solution1
Path: New Mexico >> CHNE >> 525 Fall, 2008
Description: Series Solutions to Linear Ordinary Differential Equations I Power Series Solution for the Harmonic Oscillator Equation : ODE: Transform independent variable Transform derivatives d2y dx 2 2 y 0 x dy dy d dx d dx d2y dx 2 d2y dx 2 dy d d dx 2 ...
hw6
Path: Brandeis >> MATH >> 15a Spring, 2008
Description: Otto Bretscher Linear Algebra with Applications 3rd Edition Section 5.1 10. and are perpendicular when . So, Section 5.2 2. 6. 16. ...
hw8
Path: Brandeis >> MATH >> 15a Spring, 2008
Description: Otto Bretscher Linear Algebra with Applications 3rd Edition Section 6.2 2. 6. 12. 14. ...
hw1a
Path: Brandeis >> COSI >> 30a Spring, 2008
Description: Michael Sipser Introduction To The Theory Of Computation 2nd Edition Chapter 0 (0.3) a. b. c. d. e. f. (0.5) (0.6) 1 2 3 4 5 (0.8) 6 7 6 7 6 1 2 3 4 5 6 7 8 9 10 10 10 10 10 10 7 8 9 10 6 7 7 8 8 9 9 8 7 6 10 6 6 6 6 6 a. b. c. d. e. 1 4 (0.10...
hw4
Path: Brandeis >> MATH >> 15a Spring, 2008
Description: Otto Bretscher Linear Algebra with Applications 3rd Edition Section 2.3 4. 6. 16. 20. ...
hw1
Path: Brandeis >> MATH >> 15a Spring, 2008
Description: Otto Bretscher Linear Algebra with Applications 3rd Edition Section 1.2 2. 4. 6. 8. ...
hw5
Path: Brandeis >> MATH >> 15a Spring, 2008
Description: Otto Bretscher Linear Algebra with Applications 3rd Edition Section 3.3 2. Redundant vectors: Basis of image: Basis of kernel: 4. Redundant vectors: none Basis of image: Basis of kernel: 6. Redundant vectors: Basis of image: Basis of kernel: 8. R...
hw7
Path: Brandeis >> MATH >> 15a Spring, 2008
Description: Otto Bretscher Linear Algebra with Applications 3rd Edition Section 6.1 10. By Sarrus\'s rule, is invertible. 24. is not invertible when , which is when . 32. By Fact 6.1.6, 44. For an matrix , : For any : For any matrix . , , , so . , so Th...
05series_solution2_frobenius_examples
Path: New Mexico >> CHNE >> 525 Fall, 2008
Description: Series Solutions to Linear Ordinary Differential Equations III Examples: Frobenius\' Solution about Regular Singular Points Text Example 2, pp. 253, 3rd ed Text Example 2, pp. xxx, 2nd ed ODE: 3xy\' \' y\' y 0 1 1 Standard form: y\' \' y\' y 0 3x 3x 1 Px 3x...
frobenius_p3
Path: New Mexico >> CHNE >> 525 Fall, 2008
Description: Series Solutions to Linear Ordinary Differential Equations III 3 Method of Frobenius Note: The indicial equation yields tow values for r. These are labeled r1 and r2 . By convention we take r1 to be the larger root r1 r2 . We get some information abo...
chapter1
Path: University of Alberta >> STAT >> 151 Fall, 2007
Description: CHAPTER 1: INTRODUCTION 1.1 What is Statistics? Questions to explore: 1. What is the population of Canada? What is the population of Alberta? Canada: 31,612,897, Alberta: 3,306, 359 (2006). Census (every member of the population counted). Also data c...
ProblemSet-6-2005
Path: New Mexico >> CHNE >> 524 Fall, 2008
Description: NE-524 Interaction of radiation with Matter Problem Set #6 (Complete by 11/20/2005) 1) Aluminum bronze, an alloy containing 90% Cu and 10% Al by weight has a density of 7.6 g/cc. What are the linear and mass attenuation coefficients? ( Cu = 9.91 and ...
frobenius
Path: New Mexico >> CHNE >> 525 Fall, 2008
Description: Series Solutions to Linear Ordinary Differential Equations III Method of Frobenius ODE for a 2nd order linear differential equation with a regular singular point x x 0 2 y \' \' x x 0 p x y\' q x y 0 This requires p(x) and q(x) are analytic at x x 0 Me...
ProblemSet-4-2005
Path: New Mexico >> CHNE >> 524 Fall, 2008
Description: NE-524 Interaction of radiation with Matter Problem Set #4 (Complete by 11/6/2005) 1) Give 1 gram of At-218 (T1/2 = 1.5 seconds), and assuming that all the alphas (E=6.694 MeV) interact with an Aluminum absorber in 0.1 seconds, how much energy is dep...
ProblemSet-5-2005
Path: New Mexico >> CHNE >> 524 Fall, 2008
Description: NE-524 Interaction of radiation with Matter Problem Set #5 (Complete by 11/13/2005) 1) A beam of 0.52 MeV electrons pass into a large reservoir of He at 3 atm pressure, 20 oC (electrons are totally absorbed). a) What is the range of the electrons? b)...
04terminology_ideal_rocket07
Path: New Mexico >> CHNE >> 515 Fall, 2006
Description: Rocket Terminology Total Impulse: The integral of thrust over time tb IT 0 Fdt where t b is the burn time. I T Ft b Constant thrust Specific Impulse: Total impulse divided by the weight of propellant burned tb Fdt Is g0 0 0 tb m dt Constant thr...
02fluid_eqns07part1
Path: New Mexico >> CHNE >> 515 Fall, 2006
Description: FLUID MODELS: Part 1 Basic Equations Consider a control volume of volume V fixed in space. Fluid is free to cross the surface of the volume. A surface element is denoted as dA and a unit normal vector outward from the surface is ^ denoted by n . u ...
03fluid_eqns07part2
Path: New Mexico >> CHNE >> 515 Fall, 2006
Description: FLUID MODELS: Part 2 Reduced Equations Splitting the energy equation: We can use the momentum equation and the continuity equation to write the energy equation in a shorter form. First take the dot product of u with the Du u p differential form o...
01rocket_eqn_momentum07
Path: New Mexico >> CHNE >> 515 Fall, 2006
Description: Thrust Equation - Momentum Transfer Consider a vehicle made up of mass m m moving at velocity v at time t. At time t t mass m has been ejected from the vehicle with a relative velocity v 2 so that m has a velocity v v 2 . The velocity of mass ...
05quasi1d_thrust_eqn_cv07
Path: New Mexico >> CHNE >> 515 Fall, 2006
Description: Steady Quasi-One Dimensional Flow Consider the control volume shown below. We will consider steady quasi-one-dimensional flow through the volume. Material enters the control volume at the inlet of area A1 with velocity v1 at pressure p1 , mass densit...
ENES102 hw 1
Path: Maryland >> ENES >> 102 Spring, 2008
Description: Problem 1.2: Problem 1.3: Problem 1.14: - Problem 1.16: Problem 1.21(a,f): -- Problem 1.22: Problem 1.27: Problem 1.28(a,d): ...
History_80_fullsyllabus[1]
Path: UCSB >> HIST >> 80 Spring, 2008
Description: History 80: East Asian Civilization Spring Quarter 2008 T-TH 9:30-10:45, Buchanan Hall, 1910 Sections as assigned. Instructor: Anthony Barbieri-Low HSSB 4225 805-893-4065 (no msg.) barbieri-low@history.ucsb.edu Office Hours: Tues. 12:30-2:30 TA\'s: ...
ENES102 hw 2
Path: Maryland >> ENES >> 102 Spring, 2008
Description: Problem 2.16: Problem 2.17: Problem 2.18: - Problem 2.19: Problem 2.21: Problem 2.22: Problem 2.25: Problem 2.26: Problem 2.33: - Problem 2.34: Problem 2.37(a): Problem 2.37(b): Problem 2.38(a): Problem 2.39(b): Problem 2.39(d): Prob...
ENES102 hw 3
Path: Maryland >> ENES >> 102 Spring, 2008
Description: Problem 3.6: Problem 3.7: Problem 3.9: Alternate Method: Problem 3.10: Problem 3.11: Problem 3.16: Problem 3.18: Problem 3.18 - Alternate Method: Problem 3.19: Problem 3.19 - Alternate Method: Problem 3.21: Problem 3.22: Problem 3.23: P...
ENES102 hw 6
Path: Maryland >> ENES >> 102 Spring, 2008
Description: Problem 6.8: Problem 6.10: Problem 6.12: Problem 6.13: Problem 6.13: (con\'t) Problem 6.17: Problem 6.20: Problem 6.23: Problem 6.23: (con\'t) Problem 6.25: Problem 6.26: Problem 6.27: Problem 6.30: Problem 6.31: Problem 6.35: ...
ENES102 hw 4
Path: Maryland >> ENES >> 102 Spring, 2008
Description: Problem 4.1: Problem 4.4: Problem 4.6: Problem 4.7: Problem 4.9: Problem 4.13: Problem 4.18: -- Problem 4.19: Problem 4.22: Problem 4.25: Problem 4.27: Problem 4.27: (con\'t) Problem 4.28: Problem 4.31: Problem 4.32: Problem 4.35: Pro...
CSDL1P1
Path: Syracuse >> CSD >> 315/615 Spring, 2008
Description: Anatomy 615 Index cards: Why did you enroll in this course? What do you expect to gain from this course? What are your concerns about the course? 1 CSD 315 ...
06. Obsolescence Kidd Version
Path: Old Dominion >> ECI >> 301 Fall, 2007
Description: Are dinosaurs cold-blooded or warm? What did you learn in school? From books? Dinosaur ectothermy (cold-bloodedness) remained a prevalent view until Robert T. \"Bob\" Bakker, an early proponent of dinosaur endothermy (warmbloodedness), published...
history80Essay1[1]
Path: UCSB >> HIST >> 80 Spring, 2008
Description: History 80: East Asian Civilization Spring 2008 Essay no. 1: DUE IN LECTURE: TUESDAY, APRIL 22, 2008 Your first essay will be an exercise in creative historical fiction, drawing from the lecture on the Warring States\' philosophers and from the passag...
Principles_of_Statistics_-_Exam_1
Path: CUNY City >> ECONOMICS >> 290 Spring, 2007
Description: Principles of Statistics First Examination Fall 2007 Name: Date: Instructions: Answer ALL the questions in the blue book. There is no need to write an explanation for the true or false questions or for the multiple-choice questions. For the problems...
212624
Path: Texas >> BIO >> 325 Spring, 2008
Description: ...
CSDL1P2
Path: Syracuse >> CSD >> 315/615 Spring, 2008
Description: Anatomy Of Respiration Respiration Respiration Inspiration Inhalation Breathing in Brings oxygen to the body\'s cells Expiration Exhalation Breathing out Eliminates waste products 1 Boyle\'s Law Pressure =force distributed over area P=F/A An incre...
Principles_of_Statistics_-_Exam_2
Path: CUNY City >> ECONOMICS >> 290 Spring, 2007
Description: Principles of Statistics Second Examination Fall 2007 Name: Date: Instructions: Answer ALL the questions in the blue book. There is no need to write an explanation for the true or false questions or for the multiple-choice questions. For the problem...
212655
Path: Texas >> BIO >> 325 Spring, 2008
Description: ...
PStats_-_H3_-_GH
Path: CUNY City >> ECONOMICS >> 290 Spring, 2007
Description: Homework PRINCIPLES OF STATISTICS 3 Spring 2008, Homework 3 Name 1: Name 2: Name 3: Name 4: Name 5: Instructions This homework consists of 5 questions. You must provide interpretations of your answers, not just calculations. The homework is due ...
212717
Path: Texas >> BIO >> 325 Spring, 2008
Description: ...
212852
Path: Texas >> BIO >> 325 Spring, 2008
Description: ...
PStats_-_H4_-_GH
Path: CUNY City >> ECONOMICS >> 290 Spring, 2007
Description: Homework PRINCIPLES OF STATISTICS 4 Spring 2008, Homework 4 Name 1: Name 2: Name 3: Name 4: Name 5: Instructions This homework consists of 7 questions. You must provide interpretations of your answers, not just calculations. The homework is due ...
103EX2-practice_ans
Path: CUNY City >> CHEM >> 103 Spring, 2007
Description: THE CITY COLLEGE Department of Chemistry Chemistry 103 ANSWERS TO PRACTICE EXAMINATION II Work problems out to the correct number of significant figures! 1. (8 pts) a) In the SI system , the derived units for pressure in Pascals are kg/m .s2 . b) Ch...
212808
Path: Texas >> BIO >> 325 Spring, 2008
Description: ...
213541
Path: Texas >> BIO >> 325 Spring, 2008
Description: ...
212744
Path: Texas >> BIO >> 325 Spring, 2008
Description: ...
212830
Path: Texas >> BIO >> 325 Spring, 2008
Description: ...
urban anthro study guide 2
Path: Bucknell >> EDUC >> 243 Winter, 2008
Description: Urban Anthro. STUDY GUIDE 2 Urbanism- UL (61-63) Definitions of City How does a person define the concept of a city? Where exactly is the line drawn between city, suburb, and rural areas? Personal reference is a subjective way to define a city. Where...
learnring log 2
Path: Bucknell >> EDUC >> 243 Winter, 2008
Description: Learning Log 2 Knowledge It is necessary to understand how children grow and develop to realize how to effectively teach, and in the second chapter of the text, the Piaget, Vygotsky, and Erikson views of cognitive, personal and social development are...
learning log 10
Path: Bucknell >> EDUC >> 243 Winter, 2008
Description: Learning Log 10 Knowledge The main idea of chapter 10 is that motivation, which is an internal process that activates, guides, and maintains behavior over time, is critically important for students and teachers in the classroom. Theories of motivatio...
learning log 3
Path: Bucknell >> EDUC >> 243 Winter, 2008
Description: Learning Log: Chapter 3 Knowledge The main idea is that children develop physically through changes in muscle development at early ages and later in life through puberty, mentally by becoming fully literate, socially with peer interaction and cogniti...
urban anthropolgy study guide 1
Path: Bucknell >> ANTHRO >> 290 Winter, 2008
Description: URBAN ANTHROPOLOGY-STUDY GUIDE EXAM 1 Urban Danger: Life in a Neighborhood of Strangers Sally Engle Merry pp.115-126 Ethnographic study of a multiethnic housing project in a high-crime neighborhood shows how the boundaries between social groups cont...
162C HW_2
Path: UCSB >> ECE >> 162c Spring, 2008
Description: ECE 162C: PROBLEM SET #2 DUE WEDNESDAY, APRIL 16, 2008 PROBLEMS: 1. Derive an expression for the confinement factor of single mode fibers defined as the fraction of the total mode power contained inside the core . Use the Gaussian approximation for...
HW_Set_13_1
Path: LSU Shreveport >> CHEM >> 121 Fall, 2008
Description: ...
CSDL3
Path: Syracuse >> CSD >> 315/615 Spring, 2008
Description: Anatomy Of Respiration Structures of Respiration Bony thorax Visceral thorax Muscles 1 The Rib Cage Forms the front, sides, and back of the bony thorax Mobility Consists of 12 thoracic vertebrae Sternum 12 pairs of ribs The Rib Cage 2 The Ribs ...

Course Hero is not sponsored or endorsed by any college or university.