forked from sed12008/ME3255S2017
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #4 from rcc02007/master
master update attempt 2
- Loading branch information
Showing
18 changed files
with
1,325 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
# Homework #2 | ||
## due 2/3/17 | ||
|
||
1. Now that you have created your own repository, 'homework_1', that has a README.md file. | ||
Create a new file in this repository called `setdefaults.m`. This file is a matlab/octave | ||
script that will set default plotting parameters. In this file, add the following lines: | ||
|
||
```matlab | ||
set(0, 'defaultAxesFontSize', 16) | ||
set(0,'defaultTextFontSize',14) | ||
set(0,'defaultLineLineWidth',3) | ||
``` | ||
|
||
Commit the changes to your repository. | ||
|
||
 | ||
|
||
2. Clone your 'homework_1' repository to your own computer. Now, we want to create a | ||
function that uses kinematic formulas to predict the path of a projectile. The dimensions | ||
are taken from official dart board dimensions | ||
[darts](http://dartbrokers.com/dartboard-height.html). Create a function, | ||
`projectile.m` that will calculate the location of an object with an initial velocity. The | ||
function inputs are v_mag (initial speed), theta (initial angle). The output is the height | ||
of the object 2.37 m from its starting position. Assume g=9.81 m/s^2 and its initial | ||
height is 1.72 m. | ||
|
||
```matlab | ||
>> h=projectile(v_mag,theta) | ||
|
||
h= 1 | ||
``` | ||
|
||
In addition to the output of `h`-height at 2.37 m-plot the path of the object from its | ||
initial position to its position at 2.37 m away from the start. *Note: use your | ||
`setdefaults.m` to set the plot defaults before outputting the result.* |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.