
To write:
A script that will calculate the circumference of a circle

Answer to Problem 3.1P
Solution:
The created variable
Explanation of Solution
The formula to calculate the circumference of a circle is,
Here, the radius of the circle is
Consider, the radius is
Substitute
MATLAB Code:
clc
clear all
close all
r = 2;
% Define the variable r.
C = (2*pi*r)
% Define the variable circumference.
Save the MATLAB script with name, chapter3_54793_3_1P.m in the current folder. Execute the script by typing the script name at the command window to create a variable C and store circumference in it, define the variable
Result:
Therefore, the created variable
Want to see more full solutions like this?
Chapter 3 Solutions
Matlab, Fourth Edition: A Practical Introduction to Programming and Problem Solving
- A restaurant serves three fixed-price dinners costing $12, $15, and $20. For a randomly selected couple dining at this restaurant, let X = the cost of the man's dinner and Y = the cost of the woman's dinner. The joint pmf of X and Y is given in the following table. p(x, y) 15 y 12 20 12 0.05 0.10 0.35 x 15 0.00 0.20 0.10 20 0.05 0.05 0.10 (a) Compute the marginal pmf of X. x 12 Px(x) Compute the marginal pmf of Y. y Pyly) 12 15 20 15 20 (b) What is the probability that the man's and the woman's dinner cost at most $15 each? (c) Are X and Y independent? Justify your answer. X and Y are independent because P(x, y) = Px(x) · Py(y). X and Y are not independent because P(x, y) =Px(x) · Pyly). X and Y are not independent because P(x, y) * Px(x) · Py(y). X and Y are independent because P(x, y) * Px(x) · Py(y). (d) What is the expected total cost, in dollars, of the dinner for the two people? $ (e) Suppose that when a couple opens fortune cookies at the conclusion of the meal, they find the…arrow_forwardLet X = the time between two successive arrivals at the drive-up window of a local bank. If X has an exponential distribution with λ = 1, (which is identical to a standard gamma distribution with α = 1), compute the following. (If necessary, round your answer to three decimal places.) (a) the expected time between two successive arrivals (b) the standard deviation of the time between successive arrivals (c) P(X ≤ 1) (d) P(2 ≤ X ≤ 4) You may need to use the appropriate table in the Appendix of Tablesarrow_forwardIn each case, determine the value of the constant c that makes the probability statement correct. (Round your answers to two decimal places.) USE SALT (a) (c) 0.9842 (b) P(0 ≤ Z ≤ c) = 0.3051 (c) P(CZ) = 0.1335 You may need to use the appropriate table in the Appendix of Tables to answer this question.arrow_forward
- Find aarticle about confidence intervals and post a short summary.arrow_forwardFind a video or article about confidence intervals and post a short summary and a link.arrow_forwardprovide analysis based on the data on the image answering the following: Define Regression as a method to establish whether the pairs of data (observations) follow a straight line. Here, you are required to perform a regression between Y and X for the purpose of prediction. Show the regression line and then discuss the following: Run an OLS regression to test the significance of the theoretical signs expected What is the Y-intercept Compute the slope R square and r (correlation coefficient) Is the explanatory variable significant at the 5% level? That is, what is the “t” value? Estimate the regression equation and graphically show the regression line Compute the p-value and is it less than the 5% cut off point for being significant?arrow_forward
- Algebra & Trigonometry with Analytic GeometryAlgebraISBN:9781133382119Author:SwokowskiPublisher:CengageGlencoe Algebra 1, Student Edition, 9780079039897...AlgebraISBN:9780079039897Author:CarterPublisher:McGraw HillCollege Algebra (MindTap Course List)AlgebraISBN:9781305652231Author:R. David Gustafson, Jeff HughesPublisher:Cengage Learning
- Holt Mcdougal Larson Pre-algebra: Student Edition...AlgebraISBN:9780547587776Author:HOLT MCDOUGALPublisher:HOLT MCDOUGALAlgebra and Trigonometry (MindTap Course List)AlgebraISBN:9781305071742Author:James Stewart, Lothar Redlin, Saleem WatsonPublisher:Cengage LearningAlgebra: Structure And Method, Book 1AlgebraISBN:9780395977224Author:Richard G. Brown, Mary P. Dolciani, Robert H. Sorgenfrey, William L. ColePublisher:McDougal Littell




