The problem:
Imagine you are a passenger in a car moving at velocity v eithertowards or away from a mobile phone transmitter broadcasting asignal at frequency ft in MHz. Thevelocity v in m/s will be multiplied by yourindividual number. Your algorithm shouldcalculate fr in Hz that is thefrequency at which your phone is receiving the signal (as a resultof the Doppler shift).
Step 1: The amount of the frequency change is dependent on theoriginal frequency (ft), the speed of the car(v) and the speed of light (c). This change isthe Doppler shift (fd). The equation tocalculate the Doppler shift is:
The speed of light is
Your individual number is tied to the velocity of the carthroughout so that v is multiplied by 1.01XYZ at the start.
For example, if the speed of the car is 15m/s, (just over 30miles per hour) and the transmission frequency is 2300 MHz (2300 x106 Hz) and the individual number is 1.01123then:
Step 2: You can use a Boolean is_towards forthe position of the car. If your car is travelling towards thetransmitter then this frequency shift is added to the transmitterfrequency, and if it is travelling away from the transmitter it issubtracted:
i.Develop an initial decomposition of the problem using thechevron notation (> and >>) from the module materials.Include your decomposition in your solution document.
ii.Building on your decomposition for Part i, develop analgorithm for solving the problem. Include this algorithm in yoursolution document. In your solution document, in answer to thispart, also write down your PI and the individual number that youhave obtained via Steps 1-3 from your PI.
iii.create a Python function definition following theinstructions that are provided below. Save your function in a filecalled Q4_OUCU.py, where OUCU is your OUCU number. When you havecompleted your work on this part:
The problem: Imagine you are a passenger in a car moving at velocity v either towards or away from a mobile phone transm
-
- Site Admin
- Posts: 899603
- Joined: Mon Aug 02, 2021 8:13 am