Question

8. Define the variables x = 0.85, y = 12.5, and then use them to create a row vector that has the following elements: y.y*,In(e)x y.and x + y a) By using the vector indexing take the 2nd element of the vector and add it to 3rd ,ln(-),x * y,and x + y element assign it to variable Exampl1I am using a 2016 version of Matlab. I cannot figure out part a of this problem.

0 0
Add a comment Improve this question Transcribed image text
Answer #1

close all
clear all

x = 0.85
y = 12.5

%creating row vector with all elemnts set to 0

row_vect = zeros(1,5)

row_vect(1) = y;
row_vect(2) = y^x;
row_vect(3) = log(y/x);
row_vect(4) = x * y;
row_vect(5) = x + y;

row_vect

Exampl1 = row_vect(2) + row_vect(3)

A MATLAB R2015a HOME EDITOR PUBLISH hal da E e) Se .. ② arch Documentation A PLOTS Find Files Compare ▼ Print Run Section Go

Add a comment
Know the answer?
Add Answer to:
I am using a 2016 version of Matlab. I cannot figure out part a of this...
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
  • Matlab code assistance - task 1 and 6 I think I am right and just need...

    Matlab code assistance - task 1 and 6 I think I am right and just need to be pointed in the right direction if I should change anything %% Task 1 % create the 3 row vectors shown in Ex 8 using 3 different approaches Ex 8 = using the colon operator and also the linspace function, create the following row vectors -5 -4 -3 -2 -1 5 7 9 8 6 4 % 1. list the values explicitly (square...

  • Compute the following problems using Math Lab.   Instructions: Answer All Questions using MATLAB commands. Question 1....

    Compute the following problems using Math Lab.   Instructions: Answer All Questions using MATLAB commands. Question 1. Create a vector of the even whole numbers between 31 and 75. Question 2. Let x [2516] a. Add 16 to each element b. Add 3 to just the odd-index elcments c. Compute the square root of each element d. Compute the square of each element Question 3. Let x 13 268T and y [4 1 3 5] (NB. x and y should be...

  • Using MATLAB please help, I've made the Excel File but cannot get the row added through...

    Using MATLAB please help, I've made the Excel File but cannot get the row added through MATLAB I L U.U.1.10] and vector Y=X; exp(X)]. Save Y as "fprintf and "fclose" commands. 25. Create excel file called 'Sep Excel File.xlsx' which has following: File Date Time Taken Status F32 1-Sep 10 OK F34 3-Sep 120 Fail 656 5-Sep 28 Ok Use MatLab to write a following row to above file. {"F70', '6-Sep', 70, 'OK'}; 1 Use MatLab to read 'Sep Excel...

  • In Matlab, I am trying to figure out how to find and use a acetylene.mat to...

    In Matlab, I am trying to figure out how to find and use a acetylene.mat to perform an analysis. In the analysis, I must define independent and dependent variables, create a plot with each dependent variable with each independent variable, given each independent variable and calculate the mean, standard deviation, median, and range of each dependent variable. Finally, I need to give each independent variable plot a boxplot of each dependent variable.

  • solve it by using matlab Question 2) (2.5 points) Examine the following trigonometric identity: sin'(x) =...

    solve it by using matlab Question 2) (2.5 points) Examine the following trigonometric identity: sin'(x) = (3 sin(a) – sin(3.c)) Verify that this identity is valid. To do so, define a variable x as x = 84 (in degrees!). Compute the left and right sides of the identity and assign them to variables p2left and p2right. Because x is in degrees, make sure you are using the correct trig function! Use the help function if you are unsure. Question 1)...

  • I am struggling with problem 1. I have solved for Part a but cannot figure out...

    I am struggling with problem 1. I have solved for Part a but cannot figure out how to solve for Part b. Any help is appreciated. HW 4. Due Nov 6th. 1. Let X have density f(x) = { kx(1-r) OSISI otherwise (a) Find k. (b) Find E[X] (c) Find Var(X) (4) Find F(x) and define this for all r in (-20%) (e) Find the density of Y = log X.

  • I am plotting a system in matlab using the command lsim(sys,u,t,x0) and trying to define my...

    I am plotting a system in matlab using the command lsim(sys,u,t,x0) and trying to define my input signal as u(t)^(-2t). My question is how do I define this input signal in matlab. The matlab guides show that you use u=gensig() but beyond that I cannot understand how to define my input signal in u=gensig().

  • Need help with this Matlab program %% Exercise 1 % NOTE: Please suppress output--i.e., use a...

    Need help with this Matlab program %% Exercise 1 % NOTE: Please suppress output--i.e., use a semicolon ';' at the end of any % commands for which the output is not necessary to answer the question. % Delete these notes before turning in. % Define input variable theta as discretized row vector (i.e., array). theta = ??; % Define radius. r = ??; % Define x and y in terms of theta and r. x = ??; y = ??;...

  • I'm still trying to learn how to use matlab but I'm not sure how to do this at all. I am to imple...

    I'm still trying to learn how to use matlab but I'm not sure how to do this at all. I am to implement three different explicit methods for approximating an IVP using Eulers, Runge-Kutta 4th order method, and the trapezoidal method using the same parameters. I'd much appreciate having just the Euler methods. but having all three done would be greatly appreciated and will give a great rating! function y forward_euler (n, m, a, b, eta,F) % Use the forward...

  • using this array I need to create a user created function in Matlab that does the...

    using this array I need to create a user created function in Matlab that does the following I have this so far but I'm so lost could you please make this with comments on what the codes do Lure dueren suuj (COM 94 97 95 19 91 88 95 87 90 72 78 60 98 87 81 79 76 69 192 80 77 73 78 70 80 89 81 186 94 901 b. Find the lowest grade in Math subject...

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
ADVERTISEMENT