Please use format compact and format short before you begin, i.e., type these commands into the command window. format compact condenses the command window output and format short reduces the floating point numbers in MATLAB to 4 decimal places. If problems require answers with more decimal places, you may use format long to get 8 decimal places. If you have ANY doubt about the syntax you are using to invoke a particular elementary function such as exp, cos, sin, etc., then type help elfun into the command window. elfun stands for elementary functions and this command provides a list of elementary functions with their corresponding MATLAB syntax. Remember to use a semicolon “;” to suppress output when the output is not necessary.
Exercise 1: You need to use a period preceding any matrix operations. Remember that +,-,*, /, ^ are all considered matrix operations in MATLAB. Thus, if you declare a row vector x = 0:pi/4:5*pi/4, then cos(x) is a row vector as well with the same dimensions as x. So cos(x) automatically inherits the dimensions of x. This is a very important concept moving on. So if we try to multiply x*cos(x), we will get an error because we are multiplying a row vector by a row vector. From Linear Algebra, we know we cannot do this. We can only multiply row vectors by column vectors and vice versa. Therefore, we need to input a period preceding the matrix operators * to indicate that we want to multiply each element of the row vectors componentwise, i.e., we type x.*cos(x). We use the period (or dot) preceding matrix operators when we are dealing with functions.
Exercise 2: See page 3 of the protocol.
Exercise 3: Remember, if we wish to plot cos(x) vs x, we must first declare the row vector x prior to creating the row vector cos(x) since cos(x) depends on x. If we declare cos(x) first, then MATLAB will use the present value of x saved in the workspace. This may be some x that was declared in a previous problem and NOT the same x we want to use now.
Exercise 5: You NEED to create a function + function M-file. See page 5 of the protocol. Most the code is given to you, just copy and paste it into a new script file and replace all “??” with the appropriate code.
Exercise 6: Make sure you clear your function from the workspace as stated in part (b). I will mark off points for that. Also, make sure you invoke your function in the command window as stated in the question. For part (b), you need to write a function M-file (NOT in the command window) and invoke the function M-file in the command window.
please do not plegrise any other student work or copy it, please make sure, because I do not want to get susbended from the school.
At 111papers.com, we value all our customers, and for that, always strive to ensure that we deliver the best top-quality content that we can. All the processes, from writing, formatting, editing, and submission is 100% original and detail-oriented. With us, you are, therefore, always guaranteed quality work by certified and experienced writing professionals. We take pride in the university homework help services that we provide our customers.
As the best homework help service in the world, 111 Papers ensures that all customers are completely satisfied with the finished product before disbursing payment. You are not obligated to pay for the final product if you aren’t 100% satisfied with the paper. We also provide a money-back guarantee if you don’t feel that your paper was written to your satisfaction. This guarantee is totally transparent and follows all the terms and conditions set by the company.Read more
All products that we deliver are guaranteed to be 100% original. We check for unoriginality on all orders delivered by our writers using the most advanced anti-plagiarism programs in the market. We, therefore, guarantee that all products that we submit to you are 100% original. We have a zero-tolerance policy for copied content. Thanks to our strict no plagiarized work rule, you can submit your homework to your professor without worrying.Read more
TThis is one of the most cherished courtesy services that we provide to help ensure that our customers are completely satisfied with our finished products. Delivering the best final product to our customers takes multiple inputs. 111papers.com prides itself on delivering the best university homework help services in the writing industry. And, in part, our free revision policy is how we do it. What’s more, all our revisions are 100% free without any strings attached.Read more
Client privacy is important to use. We know and understand just how important customers value their privacy and always want to safeguard their personal information. Thus, all the information that you share with us will always remain in safe custody. We will never disclose your personal information to any third party or sell your details to anyone. 111 Papers uses the most sophisticated, top-of-the-line security programs to ensure that our customers’ information is safe and secured.Read more
Placing your order with us means that you agree with the homework help service we provide. We, in turn, will endear to ensure that we do everything we can to deliver the most comprehensive finished product as per your requirements. We will also count on your cooperation to help us deliver on this mandate. Yes, we also need you to ensure that you have the highest-quality paper.Read more