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
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
|