Write down a rotation matrix

Assignment Help MATLAB Programming
Reference no: EM131303339

Plotting and computer animation in MATLAB

Instructions: For each of the following exercise, create an M-file to store the MATLAB commands. Copy and paste the M-file into a text document. For problems 1 and 2, include in the text document the pictures produced by MATLAB. Resize and crop the pictures so that they do not take up too much space. If the question requires written answers, include them in the text file in the appropriate location. Make sure you clearly label and separate all the Exercises. For problems 3 and 4 you do not need to include the picture.

1. Consider the original triangle T.Reflect the triangle about the line at 45o and plot the reflection together with the original triangle. Add a grid, a legend and title.

2. Consider the original triangle T. First rotate the triangle 45o counterclockwise and then reflect the triangle about the line at 45o. Plot the resulting triangle and compare with the plot in Example

4. Are the results the same? Does the order of the transformations matter?

3. Adapt the procedure developed in Example 5 to rotate the triangle couunterclockwise by increments of Π/20 about the origin. Stop when the triangle is in its original location and then rotate it in the clockwise direction until the triangle is in its original location again. If the pause command is set properly, it should appear that the triangle is moving around a circle. You may want to rescale the axis.

4. Adapt the procedure developed in Example 5 to show the triangle rotating in a counterclockwise direction about the origin by increments of Π/20 (for a total angle of Π/2) and expanding at the same time by a factor of 1.25, then stopping and rotating in the clockwise direction as it shrinks to its original size (with a contraction factor of .8). At the end of the program, the figure should have returned to its original size and original location.

5. (a) Modify the M-file in EXAMPLE 6 adding translations that bring the triangle to its original position using 20 iterations.

(b) Write down a rotation matrix Q that rotates a vector in homogeneous coordinates Π/40 radians in the counterclockwise direction. Then modify the M-file in part (a) adding to each iteration (for all three loops) a rotation defined by the matrix Q.

Note that the triangle should NOT end up in its original location like it should for 5(a). You might need to change the axes to see where it "lands."

Attachment:- Plotting and computer animation in MATLAB.pdf

Reference no: EM131303339

Questions Cloud

What is the default risk premium on corporate bonds : A company’s 5-year bonds are yielding 7% per year. Treasury bonds with the same maturity are yielding 5.2% per year, and the real risk-free rate (r*) is 2.75%. The average inflation premium is 2.05%, and the maturity risk premium is estimated to be 0..
Compute the target operating income : Acme Medical Supply Company desires a target operating income amount of $100,000, with assumption inputs as follows: Desired (target) operating income amount = $100,000 Unit price for sales = $80 Variable cost per unit = $60 Total fixed cost = $60,00..
Traders expect the spot rate : Suppose the one-year forward rate is £.6390. Given no arbitrage opportunities, this implies that traders expect the spot rate to be:
Project with operative yearly cash flow : Consider a 4 year project with operative yearly cash flow of 1000, initial investment of 2000, net working capital investment of 200, discount rate is 10%. Value the project.
Write down a rotation matrix : MAT 343 Laboratory - Consider the original triangle T.Reflect the triangle about the line at 45o and plot the reflection together with the original triangle. Add a grid, a legend and title.
What happens to your average cost rational function : What happens to your average cost rational function when x gets very large? Explain your answer. How many items must be produced before the average cost is 1.5 times your chosen value of m?
How long have the had the specific disease : FCS 1253:How long have the had the specific disease / condition?What medications do they currently take ?Could it have been prevented by dietary control?Does controlling their diet now make a difference in their current health status and quality of l..
Rule of man dominates the legal system : What are the pros and cons to living in a society where the rule of man dominates the legal system? Would the rule of man be a better system than the rule of law in your opinion?
Where marginal cost and marginal revenue are equal : If so, how can that be done? If the concept is applied, how confident should we be that the firm will achieve the point where marginal cost and marginal revenue are equal

Reviews

len1303339

12/6/2016 8:02:31 AM

For each of the following exercise, create an M-file to store the MATLAB commands. Copy and paste the M-file into a text document. For problems 1 and 2, include in the text document the pictures produced by MATLAB. Resize and crop the pictures so that they do not take up too much space. If the question requires written answers, include them in the text file in the appropriate location. Make sure you clearly label and separate all the Exercises. For problems 3 and 4 you do not need to include the picture.

Write a Review

MATLAB Programming Questions & Answers

  Calculates theoretical values at the measurement location

Discusses the similarities or differences between the curvature results and any reasons for them - Plots the curvature and deflection results from all previous Requirements, also marking where the terminal is located on the deflection plot.

  Write a script that will loop through values

Write a script that will loop through values of n until the difference between the approximation and the actual value is less than 0.0001.

  Use regression algorithms

The proposal which are two pages and here is the demands - Use Regression Algorithms or any type to achieve the target In Data Mining matter dealing with E-Learning Students' Data.

  Write a function that will convert from kw to hp and and

problem engineers use both english and si units on a regular basis. here are some conversions factors for various

  Stepper motor driven xy table

Stepper Motor Driven XY Table - Use Matlab and Labjack to acquire digital inputs from limit switches and use Matlab to analyze acquired data

  Write a program to test three edge detection algorithms

Write a program to test three edge detection algorithms (available in Matlab ) and one feature extraction algorithm (Harris). Students should try different parameters (if appropriate) and find the code that gives the best result for each image

  Write a matlab program for taking arbitrary number of inputs

Write a matlab program for taking arbitrary number of inputs and displaying the average & geometric mean.

  Process with the process that bertier used to resolve

Process with the process that Bertier used to resolve the situation - State how Gerry Bertier used each of the following steps in the decision-making process

  What is the difference between a script and function

Learn how to use various MATLAB built-in functions, What is the difference between a script and function? How do you create a new script or function in MATLAB

  Script that will prompt the user for the reynolds number

Write a script that will prompt the user for the Reynolds number of a flow and will print the region the flow is in.

  Find an equation for the surface of the sphere

Find the spherical coordinates for point P and find an equation for the surface of the sphere.

  What happened to the rectangular pulse in frequency domain

What is the cause of the "ringing" seen on top of the rectangular pulse shown in figure 2? What happened to the rectangular pulse in the frequency domain? What property does this represent?

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd