Question

Introduction to Engineering I Spring 2019 MATLAB Homework Assignment 1 a) Create a matrix called d from the third column of m

Introduction to Engineering Spring 2019 MATLAB Homework Assignment 1 Create ONE MATLAB script to solve the following problems

help wanted?

Introduction to Engineering I Spring 2019 MATLAB Homework Assignment 1 a) Create a matrix called d from the third column of matrix a. (Hint, typing d 22: 5: 821 b) Combine matrix b and matrix d to create matrix e, a two-dimensional matrix with three rows c) Combine matrix b and matrix d to create matrix f, a one-dimensional matrix with six rows and d) Create matrix g from matrix a and the first three element of matrix C, with four rows and three e) Create a matrix h with the first element equal to a1,3, the second element equal to C1,2 and the would be wrong!) and two columns. one column. columns third element equal to b2,1 Be sure to include adequate commenting and blank space. -Be sure to display your results appropriately, not just leave off semi-colons. -Make sure that the script runs without any errors, and produces expected results - Follow the following format to ensure that each problem is being solved in a separate section within the script: %Script by: Your Name % Introduction to Engineering I-Section: 1234 % Spring 2019-MATLAB Homework 1 % April 16th, 2019 Problem 1 clear, clc Your solution starts here Problem 2 clear, clc %Your solution starts here Problem 3 clear, clc %Your solution starts here Problem 4 clear, clc %Your solution starts here
Introduction to Engineering Spring 2019 MATLAB Homework Assignment 1 Create ONE MATLAB script to solve the following problems. Your script must be named SectionxX YowLastNome YourFirstName HW1, Where XX is your section's number (i.e, my file would be: SectionS2 Aigheshyan Fahad HWI.m), submitted through Blackboard by the due date and time, and the script must follow the MATLAB Requirements stated at the end of this assignment Problem 1 A box has a height of 6 cm and a square base with an edge of x cm. Create a nicely formatted table (See solution for In-Class 1) that shows the value of x, the volume of the box, and the surface area of the box. Use 1 sx s 3, with an increment of 0.25 cm. Problem 2 Burning one gallon of gasoline in your car produces 19.4 pounds of CO1. Calculate the amount of CO, emitted during a year for the user's vehicle. You should ask the user for the vehicle's fuel efficiency in mpe, and total mileage traveled in one year, your solution will return the amount of C02 emitted by the user's vehicle during that one year. Mileage Problem ii Chemical reaction rates are proportional to a rate constant k that changes with temperature according to the Arrhenius equation k = koe- For a certain reaction, Q = 8000 cal/mol R 1.987 cal/mol K ko = 1200 min-1 Find the values of k for 11 linearly equally spaced temperatures (T) from 100 K to 500 K inclusively. Create a nicely formatted and labeled table of your results. (Note, use the proper MATLAB command for e) Problem 4 Create the following matrices then use them in the following questions 15 з 22 a3 8 5 14 3 82 b-512 18 5 2] (Note: In the following questions, you must use matrix manipulation operations referring to the above matrices)
0 0
Add a comment Improve this question Transcribed image text
Answer #1

%% Script by:
% Introduction to Engineering I - Section:
% Spring 2019 - MATLAB Homework I
% April 16, 2019


%% Problem 1
clear,clc;
x=[1:.25:3]'; %create x with increaments of 0.25
h=6; %height of the box
base_area=x.*x; %This is the area of the base
volume_box=h.*base_area; %volume of the box;
surface_area=h*4*x+2*x.*x; %Surface area of the box
display(table(x,volume_box,surface_area));


%% Problem 2
clear,clc;
efficiency=input('Please Enter the Fuel Efficiency of your Vehicle in miles per gallon (mpg): ');
mileage=input('Please enter the total mileage in one year: ');
emissions=19.4*(mileage/efficiency);
fprintf('The total amount of Carbon dioxide emission in one year is %f pounds\n',emissions);

%% Problem 3
clear,clc;
T=linspace(100,500,11); %creates 11 equally spaced values between 100 and 500
Q=8000;
R=1.987;
k0=1200;
k=k0*exp(-Q./(R*T)); %exp is used for exponential function
display(table(T',k','VariableNames',{'Temperature' 'Rate'}));

%% Problem 4
clear,clc;
a=[15 3 22;3 8 5;14 3 82]; %This is the matrix a
b=[1;5;6]; %This is the matrix b
c=[12 18 5 2]; %This is the matrix c
d=a(:,3); % Assigning d as the third column of a
display(d);
e=[b d]; % Combining b and d to create a 3x2 matrix
display(e);
f=[b;d]; % Combining b and d to create a 6x1 matrix
display(f);
g=[a;c(1,1:3)]; % Combining a and c to create a 4x3 matrix
display(g);
h=[a(1,3);c(1,2);b(2,1)];
display(h);

==================================================================================

Hope I have answered your question. Give your comments and rating so that I can improve my future answers

Add a comment
Know the answer?
Add Answer to:
Introduction to Engineering I Spring 2019 MATLAB Homework Assignment 1 a) Create a matrix called ...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • Please follow following scripts: Script for part A:Script for Part B: Matlab Exercises 1. Find the...

    Please follow following scripts: Script for part A:Script for Part B: Matlab Exercises 1. Find the determinant (command: det(A)) and the condition number (command: cond(A)) of the Hilbert matrix H of order k (command: hilb(k)), for k = 1,2, ..., 10. Plot the determinant and the condition number as a function of k using a logarithmic scale for the vertical axis. Hint: The template to help you with this homework assignment is homework/hw15.m. 2. Determine if y is in the...

  • Can i please get the answer to this? Numerical method engineering problem: steady-state configuration of mass-spring...

    Can i please get the answer to this? Numerical method engineering problem: steady-state configuration of mass-spring system. Assume m1 = 2 kg, m2 = 3 kg, m3 = 2.5 kg, k’s = 10 kg/s2 and use LU decomposition to solve for the displacements and generate the inverse of [K], substituting the model parameters with g = 9.81, but add a third spring between masses 1 and 2 and triple k for all springs. No need to calculate the inverse matrix....

  • Answer #1 EM 4123/6123: Introduction to Finite Element Methods: Assignment 2 Assigned: Jan. 23, 2019, Due:...

    Answer #1 EM 4123/6123: Introduction to Finite Element Methods: Assignment 2 Assigned: Jan. 23, 2019, Due: Jan 30, 2019, 11.00am 20 Points per problem. Total: 60 Points Derive the weak form of the variational statement for each of the following boundary value problems NOTE: Show all steps of derivation NOTE: Identify the conditions on the variation that are consistent with the specified boundary con- ditions. (Hint: the variation cannot be arbitrary where the value of solution is specified) 1. Poisson's...

  • use matlab Assignment: 1) Write a function program that implements the 4th Order Runge Kutta Method....

    use matlab Assignment: 1) Write a function program that implements the 4th Order Runge Kutta Method. The program must plot each of the k values for each iteration (one plot per k value), and the approximated solution (approximated solution curve). Use the subplot command. There should be a total of five plots. If a function program found on the internet was used, then please cite the source. Show the original program and then show the program after any modifications. Submission...

  • This problem will introduce you the MATLAB (if you have not used it before). In this...

    This problem will introduce you the MATLAB (if you have not used it before). In this course we will use MATLAB in a limited fashion to give you a glimpse on how it is used to solve engineering problems. In your junior year, you will spend an entire semester in AEM 3101 becoming very proficient in using MATLAB for engineering modeling and simulation purposes. In this problem you will use MATLAB to accomplish the following tasks: (a) Write a function...

  • We will be using Matlab as the software tool for this lab project. 1.Explore and become...

    We will be using Matlab as the software tool for this lab project. 1.Explore and become familiar with the random number generators in Matlab such as “rand”, “randn”, and “randi” (in fact all software tools can only generate pseudo-random numbers). Notice that to randomize the generators the use of “rng” function is encouraged as the previous techniques are discouraged. 2. “Random walk” is one of the primary and relative simple random processes in which the process starts from a neutral...

  • Spring 2019 Homework Requirements (5pts) l. File Naine Format: Lastname-Hw-#-Es100XX,S19.slx (whe...

    Spring 2019 Homework Requirements (5pts) l. File Naine Format: Lastname-Hw-#-Es100XX,S19.slx (where # İs the HW number and XX is your section number) 2. Heading Format: Include your Full Name, HW-#, ES 100XX-S19, and Due Date each in a separate line. 3. Commenting: Thoroughly comment your code including units throughout the code and on all answers (if applicable) . Run-Time Errors: Program should run without any run-time errors (red text in command window). 5 Solution Variables Names: All solution variables should...

  • Matlab: PART 3 - Applications Create a script for each of the following four application problems...

    Matlab: PART 3 - Applications Create a script for each of the following four application problems (A7P3Alastname.m, A7P3Blastname.m, A7P3Clastname.m and A7P3Dlastname.m). Each program will call your function A7GAUSSlastname.m to solve the linear algebra problem. Use the following output statements to display formatted output in the command window: fprintf('In Assignment 7, Part 3a - Materials/Mixtures In(Note: Edit this line for each problem) fprintf ('\n Coefficient Matrix A : \n\n'); for i-1:size(A, 1) fprintf("%10.2f',A(i, :)); fprint'In') end fprintf'In Vector b: Inln') fprintf...

  • Spring 2019 ECO 4000 Homework: Assignment 1 Score: 0 of 1 pt Exercise 2.5 4 5of9...

    Spring 2019 ECO 4000 Homework: Assignment 1 Score: 0 of 1 pt Exercise 2.5 4 5of9 (4 HW Score: 38.89 In June, The formula to convert degrees Fahrenheit F to degrees Celsius C is: Compute the mean of Seattle's daily high temperature in degrees Celsius C. The mean of the daily high temperature in degrees Celcius 21.111 c Round your response to three decimal place.) Compute the standard deviation of Seattle's daily high temperature in degrees Celsius "C The standard...

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT