Skip to article frontmatterSkip to article content
Site not loading correctly?

This may be due to an incorrect BASE_URL configuration. See the MyST Documentation for reference.

Total points: 100.

Practicalities about homeworks and projects

  1. You can work in groups (optimal groups are often 2-3 people) or by yourself. If you work as a group you can hand in one answer only if you wish. Remember to write your name(s)!

  2. Homeworks are available approximately ten days before the deadline. You should anticipate this work.

  3. Submission instructions: Submit the paper-and-pencil exercises as a single scanned PDF document. For this homework, this applies to exercises 1–5. Convert the Jupyter notebook to a PDF and attach it to the same PDF document.

Exercise 1 (15 pt), math reminder, properties of exponential function

The first exercise is meant to remind ourselves about properties of the exponential function and imaginary numbers. This is highly relevant later in this course when we start analyzing oscillatory motion and some wave mechanics. The discovery relating trigonometric functions and exponential functions is attributed to Leonhard Euler (1707-1783). There’s two great books on the development formula, its importance to math and science, its applications:

As physicists we should feel comfortable with expressions that include exp⁡(ıωt)\exp{(\imath \omega t)} and exp⁡(ı2πft)\exp{(\imath 2\pi f t)}. Here tt could be interpreted as time and ω\omega/ff as a frequency. We know that ı=(−1)\imath = \sqrt(-1) is the imaginary unit number.

Exercise 2 (15 pt), Vector algebra

As we have quickly realized, forces and motion in three dimensions are best described using vectors. Here we perform some elementary vector algebra that we will need to have as tacit knowledge for the rest of the course. These operations are not typically taken with specific numbers, but rather with vectors in general. When we need to, we use the notation a=(ax,ay,az)\boldsymbol{a}=(a_x,a_y,a_z) for vectors in three dimensions. To get us started the first two questions below include numerical values, but the third question expects you to use the general notation.

The notation that we use for vectors in fairly recently developed in mathematical history. The development of calculus, geometry, and physics in the 17th century required new notations. The history of mathematical notation is very interesting in that these tools and symbols that we developed helped us to solve new and more advanced problems.

Exercise 3 (10 pt), More vector mathematics

Exercise 4 (10 pt), Algebra of cross products

Exercise 5 (10 pt), Area of triangle and law of sines

The three vectors a\boldsymbol{a}, b\boldsymbol{b}, and c\boldsymbol{c} are the three sides of a triangle ABC. The angles α\alpha, β\beta, and γ\gamma are the angles opposite the sides a\boldsymbol{a}, b\boldsymbol{b}, and c\boldsymbol{c}, respectively, as shown below.

triangle

(Figure: A triangle with sides a\boldsymbol{a}, b\boldsymbol{b}, and c\boldsymbol{c} and angles α\alpha, β\beta, and γ\gamma; reproduced from JRT.)

Exercise 6 (40pt), Numerical elements, getting started with some simple data

This exercise needs to be worked on in a Jupyter notebook, but should be handed in as a PDF. Remember to write your name(s).

Our first numerical attempt will involve reading data from file or just setting up two vectors, one for position and one for time. Our data are from

Usain Bolt's world record 100m during the olympic games in Beijing in2008

The data show the time used in units of 10m (see below). Before we however venture into this, we need to repeat some basic Python syntax with an emphasis on

For more information, consult the Python support materials linked in the course resources. Here are some of the basic packages we will be using in this homework

The first exercise here deals with simply getting familiar with vectors and matrices.

We will be working with vectors and matrices to get you familiar with them.

  1. Initialize two three-dimensional xyzxyz vectors in the below cell using np.array([x,y,z]). Vectors are represented through arrays in Python

  2. V1 should have x1=1, y1 =2, and z1=3.

  3. Vector 2 should have x2=4, y2=5, and z2=6.

  4. Print both vectors to make sure your code is working properly.

V1:  [1 2 3]
V2:  [4 5 6]

If this is not too familiar, here’s a useful link for creating vectors in python https://docs.scipy.org/doc/numpy-1.13.0/user/basics.creation.html. Alternatively, look up the introductory slides.

Now let us do some basic mathematics with vectors.

Compute and print the following, and double check with your own paper and pencil calculations:

Here is some useful explanation on numpy array operations if you feel a bit confused by what is happening, see https://www.pluralsight.com/guides/overview-basic-numpy-operations.

The following code prints the first two exercises

[-3 -3 -3]
[3 3 3]

For the dot product of V1 and V2 below we can use the dot function of numpy as follows

32

As a small challenge try to write your own function for the dot product of two vectors.

Matrices can be created in a similar fashion in python. In this language we can work with them through the package numpy (which we have already imported)

Matrices can be added in the same way vectors are added in python as shown here

M1+M3:  [[10 10 10]
 [ 8 10 12]
 [14 14 18]]

What happens if we try to do M1+M2M1+M2?

That’s enough vectors and matrices for now. Let’s move on to some physics problems!

We can opt for two different ways of handling the data. The data are listed in the table here and represents the total time Usain Bolt used in steps of 10 meters of distance. The label ii is just a counter and we start from zero since Python arrays are by default set from zero. The variable tt is time in seconds and xx is the position in meters. You may find it useful to include results at time t=0t=0 as well. The position is obviously then x=0x=0 m.

i0123456789
x[m]102030405060708090100
t[s]1.852.873.784.655.506.327.147.968.799.69

The following example code may help here

<Figure size 640x480 with 1 Axes>