...Random numbers in C++ and The Pythagorean Theorem Name Course Date Random numbers in C++ and The Pythagorean Theorem Introduction Computer programs in light of the technological advances that have been made, arguably make up for the most important concepts in such developments. A set of instructions designed to assist a computer to prefer a given task is referred to as a computer program. There are numerous languages used to create/design computer for instance Java Script, Java, C++, SQL and Sage (Laine, 2013). Computer programming is defined as a process of developing a working set of computer instructions meant to aid the computer in the performance of a given task. Computer programming starts with the formulation of a valid computer problem. This process is then followed by the development of an executable computer program, for instance Firefox Web Brower (Laine 2013). It is worth noting that there are other programs in the same realm. Computer programming is a diverse field that is of utmost importance in the modern world, especially with the continuous expansion of the internet. Perhaps the relevance of this can be underlined by the fact that computer programming has carved out as a course on itself. Computer programming is offered under several courses studied in colleges and universities (Laine, 2013). Computer programming is not only for computer students but for all who use computers on a day to day basis. This is by extension everyone since the...
Words: 9330 - Pages: 38
...descriptive statistic b. probability function c. variance d. random variable ANS: D PTS: 1 TOP: Discrete Probability Distributions 2. A random variable that can assume only a finite number of values is referred to as a(n) a. infinite sequence b. finite sequence c. discrete random variable d. discrete probability function ANS: C PTS: 1 TOP: Discrete Probability Distributions 3. A probability distribution showing the probability of x successes in n trials, where the probability of success does not change from trial to trial, is termed a a. uniform probability distribution b. binomial probability distribution c. hypergeometric probability distribution d. normal probability distribution ANS: B PTS: 1 TOP: Discrete Probability Distributions 4. Variance is a. a measure of the average, or central value of a random variable b. a measure of the dispersion of a random variable c. the square root of the standard deviation d. the sum of the squared deviation of data elements from the mean ANS: B PTS: 1 TOP: Discrete Probability Distributions 5. A continuous random variable may assume a. any value in an interval or collection of intervals b. only integer values in an interval or collection of intervals c. only fractional values in an interval or collection of intervals d. only the positive integer values in an interval ANS: A PTS: 1 TOP: Discrete Probability Distributions 6. A description of the distribution of the values of a random variable and their associated probabilities...
Words: 9797 - Pages: 40
...can begin to use probabilistic ideas in statistical inference and modelling, and the study of stochastic processes. Probability axioms. Conditional probability and independence. Discrete random variables and their distributions. Continuous distributions. Joint distributions. Independence. Expectations. Mean, variance, covariance, correlation. Limiting distributions. The syllabus is as follows: 1. Basic notions of probability. Sample spaces, events, relative frequency, probability axioms. 2. Finite sample spaces. Methods of enumeration. Combinatorial probability. 3. Conditional probability. Theorem of total probability. Bayes theorem. 4. Independence of two events. Mutual independence of n events. Sampling with and without replacement. 5. Random variables. Univariate distributions - discrete, continuous, mixed. Standard distributions - hypergeometric, binomial, geometric, Poisson, uniform, normal, exponential. Probability mass function, density function, distribution function. Probabilities of events in terms of random variables. 6. Transformations of a single random variable. Mean, variance, median, quantiles. 7. Joint distribution of two random variables. Marginal and conditional distributions. Independence. iii iv 8. Covariance, correlation. Means and variances of linear functions of random variables. 9. Limiting distributions in the Binomial case. These course notes explain the naterial in the syllabus. They have been “fieldtested” on the class of 2000. Many of the examples...
Words: 29770 - Pages: 120
...A FIRST COURSE IN PROBABILITY This page intentionally left blank A FIRST COURSE IN PROBABILITY Eighth Edition Sheldon Ross University of Southern California Upper Saddle River, New Jersey 07458 Library of Congress Cataloging-in-Publication Data Ross, Sheldon M. A first course in probability / Sheldon Ross. — 8th ed. p. cm. Includes bibliographical references and index. ISBN-13: 978-0-13-603313-4 ISBN-10: 0-13-603313-X 1. Probabilities—Textbooks. I. Title. QA273.R83 2010 519.2—dc22 2008033720 Editor in Chief, Mathematics and Statistics: Deirdre Lynch Senior Project Editor: Rachel S. Reeve Assistant Editor: Christina Lepre Editorial Assistant: Dana Jones Project Manager: Robert S. Merenoff Associate Managing Editor: Bayani Mendoza de Leon Senior Managing Editor: Linda Mihatov Behrens Senior Operations Supervisor: Diane Peirano Marketing Assistant: Kathleen DeChavez Creative Director: Jayne Conte Art Director/Designer: Bruce Kenselaar AV Project Manager: Thomas Benfatti Compositor: Integra Software Services Pvt. Ltd, Pondicherry, India Cover Image Credit: Getty Images, Inc. © 2010, 2006, 2002, 1998, 1994, 1988, 1984, 1976 by Pearson Education, Inc., Pearson Prentice Hall Pearson Education, Inc. Upper Saddle River, NJ 07458 All rights reserved. No part of this book may be reproduced, in any form or by any means, without permission in writing from the publisher. Pearson Prentice Hall™ is a trademark of Pearson Education, Inc...
Words: 121193 - Pages: 485
... a. 4 and 3 b. 4.8 and 3 c. 4.8 and 3 1/2 d. 4 and 3 1/2 e. 4 and 3 1/3 2. A distribution of 6 scores has a median of 21. If the highest score increases 3 points, the median will become __. a. 21 b. 21.5 c. 24 d. Cannot be determined without additional information. e. none of these 3. If you are told a population has a mean of 25 and a variance of 0, what must you conclude? a. Someone has made a mistake. b. There is only one element in the population. c. There are no elements in the population. d. All the elements in the population are 25. e. None of the above. 4. Which of the following measures of central tendency tends to a. be most influenced by an extreme score? b. median c. mode d. mean 5. The mean is a measure of: a. variability. b. position. c. skewness. d. central tendency. e. symmetry. 6. Suppose the manager of a plant is concerned with the total number of man-hours lost due to accidents for the past 12 months. The company statistician has reported the mean number of man-hours lost per month but did not keep a record of the total sum. Should the manager order the study repeated to obtain the desired information? Explain your answer clearly. Answer: No--the estimate that he would get using the mean number per month would most likely be accurate enough...
Words: 28909 - Pages: 116
...Distributions CONTENTS STATISTICS IN PRACTICE: CITIBANK 5.1 RANDOM VARIABLES Discrete Random Variables Continuous Random Variables 5.2 DEVELOPING DISCRETE PROBABILITY DISTRIBUTIONS 5.3 EXPECTED VALUE AND VARIANCE Expected Value Variance 5.4 BIVARIATE DISTRIBUTIONS, COVARIANCE, AND FINANCIAL PORTFOLIOS A Bivariate Empirical Discrete Probability Distribution Financial Applications Summary 5.5 BINOMIAL PROBABILITY DISTRIBUTION A Binomial Experiment Martin Clothing Store Problem Using Tables of Binomial Probabilities Expected Value and Variance for the Binomial Distribution POISSON PROBABILITY DISTRIBUTION An Example Involving Time Intervals An Example Involving Length or Distance Intervals HYPERGEOMETRIC PROBABILITY DISTRIBUTION 5 5.6 5.7 74537_05_ch05_p215-264.qxd 10/8/12 4:05 PM Page 219 5.1 Random Variables 219 Exercises Methods SELF test 1. Consider the experiment of tossing a coin twice. a. List the experimental outcomes. b. Define a random variable that represents the number of heads occurring on the two tosses. c. Show what value the random variable would assume for each of the experimental outcomes. d. Is this random variable discrete or continuous? 2. Consider the experiment of a worker assembling a product. a. Define a random variable that represents the time in minutes required to assemble the product. b. What values may the random variable assume? c. Is the random variable discrete or continuous? Applications SELF test ...
Words: 11596 - Pages: 47
...CHAPTER 6 RANDOM VARIABLES PART 1 – Discrete and Continuous Random Variables OBJECTIVE(S): • Students will learn how to use a probability distribution to answer questions about possible values of a random variable. • Students will learn how to calculate the mean and standard deviation of a discrete random variable. • Students will learn how to interpret the mean and standard deviation of a random variable. Random Variable – Probability Distribution - Discrete Random Variable - The probabilities of a probability distribution must satisfy two requirements: a. b. Mean (expected value) of a discrete random variable [pic]= E(X) = = 1. In 2010, there were 1319 games played in the National Hockey League’s regular season. Imagine selecting one of these games at random and then randomly selecting one of the two teams that played in the game. Define the random variable X = number of goals scored by a randomly selected team in a randomly selected game. The table below gives the probability distribution of X: Goals: 0 1 2 3 4 5 6 7 8 9 Probability: 0.061 0.154 0.228 0.229 0.173 0.094 0.041 0.015 0.004 0.001 a. Show that the probability distribution for X is legitimate. b. Make a histogram of the probability distribution. Describe what you see. 0.25 0.20 0.15 0.10 ...
Words: 3495 - Pages: 14
...assembling a product. We can define a random variable as x equals to the time in minutes to assemble the product b) The possible outcomes for this experiment is the worker may assemble the product from the first second to whatever how long it takes him or her to assemble the product. Therefore, the random variable x may assume any number greater than zero in minutes, meaning any positive number. It can be noted as x > 0. c) In the experiment x is assuming to be all the value greater than zero variable, so the experimental outcomes are based on a measurement of scale. Thus, the random variable x is a continuous random variable. Answer 2 a) The number of questions answered correctly are the possible outcomes. The experiment is based on a 20-question examination, so all the possible values the random variable can assume are 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, and 20. All the possible outcomes are range from 0 to 20, that means the random variable x can take a finite number of value, therefore, x is a discrete random variable b) The random variable x representing the number of cars arriving a tollbooth may assume all the following values 0, 1, 2, 3,…, n cars in one hour. The values of the random variable x is infinite as x may assume the value of n cars in one hour, it is a discrete random variable because it is bound to stop at the number n cars. c) 0, 1, 2, 3, 4, 5,……, 50 are all the values the random variable x may assume given that...
Words: 1448 - Pages: 6
...Objectives 1. Understand the concepts of a random variable and a probability distribution. 2. Be able to distinguish between discrete and continuous random variables. 3. Be able to compute and interpret the expected value, variance, and standard deviation for a discrete random variable. 4. Be able to compute and work with probabilities involving a binomial probability distribution. 5. Be able to compute and work with probabilities involving a Poisson probability distribution. A random variable is a numerical description of the outcome of an experiment. A discrete random variable may assume either a finite number of values or an infinite sequence of values. A continuous random variable may assume any numerical value in an interval or collection of intervals. Discrete Probability Distributions n Random Variables n Discrete Probability Distributions n Expected Value and Variance n Binomial Distribution n Poisson Distribution [pic] A random variable is a numerical description of the outcome of an experiment. A discrete random variable may assume either a finite number of values or an infinite sequence of values. A continuous random variable may assume any numerical value in an interval or collection of intervals. Example: JSL Appliances n Discrete random variable with a finite number of values n Let x = number of TVs sold at the store in one day, where...
Words: 789 - Pages: 4
...data is called: A. Descriptive statistics B. Inferential statistics C. Analytical statistics D. All of the above 2. The _________________ random variables yield categorical responses so that the responses fit into one category or another. A. Quantitative B. Discrete C. Continuous D. Qualitative 3. Which of the following is a qualitative/categorical variable? A. The number of pets owned by a family. B. The number of doors on a car. C. Your favourite TV show. D. Your IQ score. 4. Which of the following is a quantitative variable? A. The make of a TV. B. A person's gender. C. The distance from one city to another (in km). D. A person’s educational background. 5. The manager of the customer service division of a major consumer electronics company is interested in determining whether the customers who have purchased a DVD player made by the company over the past 12 months are satisfied with their products, the possible responses to the question "How much time do you use the DVD player every week on the average?" are values from a A. discrete numerical random variable. B. continuous numerical random variable. C. categorical random variable. D. Cannot answer because of lake of information 6. The classification of student major (accounting, economics, management, marketing, other) is an example of A. a categorical random variable. B. a discrete random variable. C. a continuous random variable. D. Cannot answer because of lake of information 7. Quantitative...
Words: 542 - Pages: 3
...Chapter 9 Random Numbers This chapter describes algorithms for the generation of pseudorandom numbers with both uniform and normal distributions. 9.1 Pseudorandom Numbers 0.814723686393179 Here is an interesting number: This is the first number produced by the Matlab random number generator with its default settings. Start up a fresh Matlab, set format long, type rand, and it’s the number you get. If all Matlab users, all around the world, all on different computers, keep getting this same number, is it really “random”? No, it isn’t. Computers are (in principle) deterministic machines and should not exhibit random behavior. If your computer doesn’t access some external device, like a gamma ray counter or a clock, then it must really be computing pseudorandom numbers. Our favorite definition was given in 1951 by Berkeley professor D. H. Lehmer, a pioneer in computing and, especially, computational number theory: A random sequence is a vague notion . . . in which each term is unpredictable to the uninitiated and whose digits pass a certain number of tests traditional with statisticians . . . 9.2 Uniform Distribution Lehmer also invented the multiplicative congruential algorithm, which is the basis for many of the random number generators in use today. Lehmer’s generators involve three integer parameters, a, c, and m, and an initial value, x0 , called the seed. A September 16, 2013 1 2 sequence of integers is defined by xk+1 = axk + c mod m. Chapter 9. Random Numbers The operation...
Words: 5522 - Pages: 23
...distracted. The numbers could also be skewed because they didn’t take into account age, gender, or maybe even race which could lead to more wrecks. It could also do with how well the driver can see or maybe even hear. (b) There could be a causal link between smoking and car crashes, however, because the people who smoke may have been smoking while driving which can be distracting. 1.13) I don’t think it would be significant because it is such a low number. 1.14) (a) This isn’t a very logical conclusion because it’s only a small sample. (b) This isn’t ethical because this could be misleading to their other customers because it’s only the opinion of a few people. (c) This isn’t ethical because they don’t know if this could be harmful to those people. (d) This isn’t logical because there is no causal effect between the incident and the verdict. 1.26) (a) (b) 1.27) (a) (b) 2.1) (a) Categorical (b) Categorical (c) Discrete 2.2) (a) Continuous (b) Discrete (c) Categorical (d) Continuous 2.3) (a) Continuous (b) Continuous (c) Categorical (d) Categorical 2.5) (a) Ratio (b) Ordinal (c) Nominal (d) Interval (e) Ratio (f) Nominal 2.6) (a) Ratio (b) Ratio (c) Interval (d) Nominal (e) Interval (f) Nominal 2.7) Nominal – The name of each player on a baseball roster. Ordinal – Rating a player on a scale of 1-10 Interval – The temperature in Kelvins Ratio – The number of players who have a base hit in a game 2.8) (a) Interval (b) Interval (c) Nominal (d)...
Words: 520 - Pages: 3
...space 2. Random Variables 3. Probability Distribution of a Discrete Random Variable 4. The Binomial Probability Distribution 5. The Hypergeometric Probability Distribution 6. The Poisson Probability Distribution 7. Continuous Random Variables 8. The Normal Distribution 9. The Normal Approximation to the Binomial Distribution 2 1 7.10.2015 г. An experiment is a process that, when performed, results in one and only one of many observations. These observations are called the outcomes of the experiment. The collection of all outcomes for an experiment is called a sample space. Table 1 Examples of Experiments, Outcomes, and Sample Spaces Experiment Outcomes Sample Space Toss a coin once Head, Tail S= { Head, Tail} Roll a die once 1, 2, 3, 4, 5, 6 S= {1, 2, 3, 4, 5, 6} Toss a coin twice HH, HT, TH, TT S= { HH, HT, TH, TT} Play lottery Win, Lose S= {Win, Lose} Take a test Pass, Fail S= {Pass, Fail} Select a worker Male, Female S= { Male, Female} 3 A random variable is a variable whose value is determined by the outcome of a random experiment. A random variable that assumes countable values is called a discrete random variable. A random variable that can assume any value contained in one or more intervals is called a continuous random variable. 4 2 7.10.2015 г. Examples of discrete random variables 1. The number of heads obtained in three tosses of a coin 2. The number of complaints...
Words: 4560 - Pages: 19
...Integer Step 1: A function contains three parts: a header, a body, and a return statement. The first is a function header which specifies the data type of the value that is to be returned, the name of the function, and any parameter variables used by the function to accept arguments. The body is comprised of one or more statements that are executed when the function is called. In the following space, complete the following: (Reference: Writing Your Own Functions, page 225). a. Write a function with the header named addTen. b. The function will accept an Integer variable named number. c. The function body will ask the user to enter a number and the add 10 to the number. The answer will be stored in the variable number. d. The return statement will return the value of number. Function a.Integer a.addTen (b.integer number) Display “Enter a number:” Input c.number Set c.number = number + 10 Return d.15 Step 2: In the following space, write a function call to your function from Step 1....
Words: 2530 - Pages: 11
... Master of IT Engineering PROBABILITY AND RANDOM PROCESSES FOR ENGINEERING ASSIGNMENT Topic: BASIC RANDOM PROCESS Group Member: 1, Chor Sophea 2, Lun Sokhemara 3, Phourn Hourheng 4, Chea Daly | Academic year: 2014-2015 I. Introduction Most of the time many systems are best studied using the concept of random variables where the outcome of random experiment was associated with some numerical value. And now there are many more systems are best studied using the concept of multiple random variables where the outcome of a random experiment was associated with multiple numerical values. Here we study random processes where the outcome of a random experiment is associated with a function of time [1]. Random processes are also called stochastic processes. For example, we might study the output of a digital filter being fed by some random signal. In that case, the filter output is described by observing the output waveform at random times. Figure 1.1 The sequence of events leading to assigning a time function x(t) to the outcome of a random experiment Thus a random process assigns a random function of time as the outcome of a random experiment. Figure 1.1 graphically shows the sequence of events leading to assigning a function of time to the outcome of a random experiment. First we run the experiment, then we observe the...
Words: 2863 - Pages: 12