Bird
Raised Fist0
Signal Processingdata~10 mins

Why communication relies on signal modulation in Signal Processing - Test Your Understanding

Choose your learning style10 modes available
Practice - 5 Tasks
Answer the questions below
1fill in blank
easy

Complete the code to create a simple sine wave signal.

Signal Processing
import numpy as np
import matplotlib.pyplot as plt

t = np.linspace(0, 1, 500)
signal = np.sin(2 * np.pi * [1] * t)
plt.plot(t, signal)
plt.title('Sine Wave Signal')
plt.show()
Drag options to blanks, or click blank then click option'
A5
B0.5
C50
D500
Attempts:
3 left
💡 Hint
Common Mistakes
Using a frequency too high causes the wave to look like noise.
Using zero frequency results in a flat line.
2fill in blank
medium

Complete the code to modulate the sine wave signal by multiplying with a carrier wave.

Signal Processing
carrier_freq = 100
carrier = np.sin(2 * np.pi * [1] * t)
modulated_signal = signal * carrier
plt.plot(t, modulated_signal)
plt.title('Amplitude Modulated Signal')
plt.show()
Drag options to blanks, or click blank then click option'
A5
B50
C10
D100
Attempts:
3 left
💡 Hint
Common Mistakes
Using a carrier frequency lower than the signal frequency.
Using the same frequency for both signal and carrier.
3fill in blank
hard

Fix the error in the code to correctly demodulate the signal by multiplying with the carrier again.

Signal Processing
demodulated = modulated_signal * np.sin(2 * np.pi * [1] * t)
plt.plot(t, demodulated)
plt.title('Demodulated Signal')
plt.show()
Drag options to blanks, or click blank then click option'
A50
B100
C5
D10
Attempts:
3 left
💡 Hint
Common Mistakes
Using the original signal frequency instead of the carrier frequency.
Using a frequency not used before.
4fill in blank
hard

Fill both blanks to create a dictionary comprehension that maps words to their lengths only if length is greater than 3.

Signal Processing
words = ['data', 'science', 'ai', 'ml', 'python']
lengths = {word: [1] for word in words if [2] > 3}
print(lengths)
Drag options to blanks, or click blank then click option'
Alen(word)
Cword
Attempts:
3 left
💡 Hint
Common Mistakes
Using the word itself as the value instead of its length.
Filtering by the word instead of its length.
5fill in blank
hard

Fill all three blanks to create a dictionary comprehension that maps uppercase words to their lengths if length is greater than 2.

Signal Processing
words = ['cat', 'dog', 'a', 'elephant']
result = { [1]: [2] for w in words if [3] > 2 }
print(result)
Drag options to blanks, or click blank then click option'
Aw.upper()
Blen(w)
Dw
Attempts:
3 left
💡 Hint
Common Mistakes
Using the original word as key instead of uppercase.
Filtering by word instead of length.

Practice

(1/5)
1. Why is signal modulation important in communication systems?
easy
A. It allows information to be transmitted over long distances clearly.
B. It increases the size of the signal.
C. It removes noise from the signal completely.
D. It changes the signal into a digital format only.

Solution

  1. Step 1: Understand the role of modulation

    Modulation changes a carrier wave to carry information clearly over distances.
  2. Step 2: Identify the main benefit

    This helps signals travel far and avoid interference, making communication clear.
  3. Final Answer:

    It allows information to be transmitted over long distances clearly. -> Option A
  4. Quick Check:

    Modulation improves signal clarity and distance [OK]
Hint: Modulation helps signals travel far and clear [OK]
Common Mistakes:
  • Thinking modulation removes all noise
  • Believing modulation only changes signal size
  • Confusing modulation with digitization
2. Which of the following is the correct way to describe amplitude modulation (AM)?
easy
A. Changing the frequency of the carrier wave to carry information.
B. Changing the amplitude of the carrier wave to carry information.
C. Changing the phase of the carrier wave to carry information.
D. Changing the speed of the carrier wave to carry information.

Solution

  1. Step 1: Recall modulation types

    Amplitude modulation changes the amplitude of the carrier wave.
  2. Step 2: Match description to AM

    Only Changing the amplitude of the carrier wave to carry information correctly describes amplitude modulation.
  3. Final Answer:

    Changing the amplitude of the carrier wave to carry information. -> Option B
  4. Quick Check:

    Amplitude modulation = amplitude change [OK]
Hint: Amplitude modulation changes wave height [OK]
Common Mistakes:
  • Confusing amplitude with frequency or phase
  • Thinking speed changes in modulation
  • Mixing up modulation types
3. Consider this Python code simulating a simple amplitude modulation signal:
import numpy as np
import matplotlib.pyplot as plt

carrier_freq = 5  # Hz
modulating_freq = 1  # Hz
time = np.linspace(0, 1, 500)

carrier = np.sin(2 * np.pi * carrier_freq * time)
modulating = 0.5 * np.sin(2 * np.pi * modulating_freq * time) + 1
am_signal = modulating * carrier

plt.plot(time, am_signal)
plt.title('Amplitude Modulated Signal')
plt.xlabel('Time (seconds)')
plt.ylabel('Amplitude')
plt.show()
What does the plot show?
medium
A. A carrier wave whose amplitude changes over time.
B. A carrier wave with constant amplitude.
C. A modulating wave with constant frequency.
D. A frequency modulated signal.

Solution

  1. Step 1: Analyze the code signals

    The carrier is a sine wave at 5 Hz. The modulating signal varies amplitude between 0.5 and 1.5.
  2. Step 2: Understand the multiplication effect

    Multiplying carrier by modulating changes the carrier's amplitude over time.
  3. Final Answer:

    A carrier wave whose amplitude changes over time. -> Option A
  4. Quick Check:

    Amplitude modulation changes amplitude [OK]
Hint: Multiplying carrier by modulating changes amplitude [OK]
Common Mistakes:
  • Thinking amplitude stays constant
  • Confusing amplitude modulation with frequency modulation
  • Ignoring the modulating signal effect
4. The following code attempts to create a frequency modulated signal but has an error:
import numpy as np
import matplotlib.pyplot as plt

carrier_freq = 5
modulating_freq = 1

time = np.linspace(0, 1, 500)

carrier = np.sin(2 * np.pi * carrier_freq * time)
modulating = np.sin(2 * np.pi * modulating_freq * time)

fm_signal = np.sin(2 * np.pi * (carrier_freq + modulating) * time)

plt.plot(time, fm_signal)
plt.title('Frequency Modulated Signal')
plt.show()
What is the error in this code?
medium
A. The modulating signal should be multiplied, not added, to the carrier frequency.
B. The time array is not defined correctly.
C. The carrier frequency should be a vector, not a scalar.
D. The modulating signal should be integrated before adding to the carrier frequency.

Solution

  1. Step 1: Understand frequency modulation basics

    Frequency modulation requires integrating the modulating signal before adding to carrier frequency.
  2. Step 2: Identify code mistake

    The code adds modulating signal directly without integration, which is incorrect.
  3. Final Answer:

    The modulating signal should be integrated before adding to the carrier frequency. -> Option D
  4. Quick Check:

    FM needs integrated modulating signal [OK]
Hint: FM requires integrating modulating signal first [OK]
Common Mistakes:
  • Adding modulating signal directly without integration
  • Confusing multiplication with addition
  • Incorrect time array assumptions
5. You want to send a message signal over a noisy channel. Which modulation method helps reduce noise impact and allows the signal to travel farther?
hard
A. Amplitude Modulation (AM)
B. Pulse Width Modulation (PWM)
C. Frequency Modulation (FM)
D. No modulation, send raw signal

Solution

  1. Step 1: Compare modulation types for noise resistance

    Frequency modulation is known to resist noise better than amplitude modulation.
  2. Step 2: Consider signal travel distance

    FM signals can travel farther with less interference, improving communication quality.
  3. Final Answer:

    Frequency Modulation (FM) -> Option C
  4. Quick Check:

    FM reduces noise and extends range [OK]
Hint: FM reduces noise better than AM [OK]
Common Mistakes:
  • Choosing AM for noise resistance
  • Thinking raw signals travel farther
  • Confusing PWM with noise reduction
Recommended

Ready to prove it?

Pass the test and this pattern moves unknown strong while earning +1 Grip toward your certificate.

10 questions~5 mineasy hard