Bird
Raised Fist0
EV Technologyknowledge~10 mins

Range estimation algorithms in EV Technology - Interactive Code Practice

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

Complete the code to calculate the basic range estimate using speed and time.

EV Technology
range_estimate = speed [1] time
Drag options to blanks, or click blank then click option'
A+
B/
C*
D-
Attempts:
3 left
💡 Hint
Common Mistakes
Using addition instead of multiplication
Dividing speed by time
2fill in blank
medium

Complete the code to filter out invalid sensor readings below a threshold.

EV Technology
valid_readings = [r for r in readings if r [1] threshold]
Drag options to blanks, or click blank then click option'
A<
B>
C!=
D==
Attempts:
3 left
💡 Hint
Common Mistakes
Using less than operator which filters out valid readings
Using equality which is too strict
3fill in blank
hard

Fix the error in the code to compute the average of distance measurements.

EV Technology
average_distance = sum(distances) [1] len(distances)
Drag options to blanks, or click blank then click option'
A/
B-
C+
D*
Attempts:
3 left
💡 Hint
Common Mistakes
Using addition or multiplication instead of division
Subtracting length from sum
4fill in blank
hard

Fill both blanks to create a dictionary of distances squared for values above a limit.

EV Technology
distance_squares = {d: d[1]2 for d in distances if d [2] limit}
Drag options to blanks, or click blank then click option'
A**
B+
C>
D<
Attempts:
3 left
💡 Hint
Common Mistakes
Using addition instead of power
Filtering with less than instead of greater than
5fill in blank
hard

Fill all three blanks to create a filtered dictionary with uppercase keys and positive values.

EV Technology
filtered = [1]: [2] for [3], v in data.items() if v > 0}
Drag options to blanks, or click blank then click option'
Ak.upper()
Bv
Ck
Dval
Attempts:
3 left
💡 Hint
Common Mistakes
Using wrong variable names
Not converting keys to uppercase

Practice

(1/5)
1. What is the main purpose of range estimation algorithms in electric vehicles (EVs)?
easy
A. To control the air conditioning system
B. To calculate the speed of the EV
C. To measure the tire pressure
D. To predict how far the EV can travel on the current battery charge

Solution

  1. Step 1: Understand the function of range estimation algorithms

    These algorithms estimate the distance an EV can travel based on battery charge and other factors.
  2. Step 2: Identify the correct purpose among options

    Only To predict how far the EV can travel on the current battery charge matches the purpose of predicting travel distance on current battery charge.
  3. Final Answer:

    To predict how far the EV can travel on the current battery charge -> Option D
  4. Quick Check:

    Range estimation = Predict travel distance [OK]
Hint: Range estimation predicts travel distance, not speed or controls [OK]
Common Mistakes:
  • Confusing range estimation with speed calculation
  • Thinking it controls vehicle systems like air conditioning
  • Assuming it measures unrelated parameters like tire pressure
2. Which of the following factors is NOT typically used by range estimation algorithms in EVs?
easy
A. Color of the vehicle
B. Driving conditions
C. Battery charge level
D. Vehicle efficiency

Solution

  1. Step 1: List common factors used in range estimation

    Battery charge, driving conditions, and vehicle efficiency affect range estimates.
  2. Step 2: Identify the irrelevant factor

    The color of the vehicle does not affect battery usage or range estimation.
  3. Final Answer:

    Color of the vehicle -> Option A
  4. Quick Check:

    Color irrelevant to range estimation [OK]
Hint: Focus on factors affecting battery use, ignore cosmetic features [OK]
Common Mistakes:
  • Assuming vehicle color affects battery consumption
  • Confusing unrelated vehicle features with range factors
3. Consider a simple range estimation formula: range = battery_percentage * efficiency_factor. If the battery is at 80% and the efficiency factor is 3 km per percent, what is the estimated range?
medium
A. 83 km
B. 240 km
C. 3.8 km
D. 80 km

Solution

  1. Step 1: Identify the formula and values

    Range = battery_percentage * efficiency_factor = 80 * 3 km.
  2. Step 2: Calculate the estimated range

    80 * 3 = 240 km estimated range.
  3. Final Answer:

    240 km -> Option B
  4. Quick Check:

    80% * 3 km = 240 km [OK]
Hint: Multiply battery % by efficiency factor for range [OK]
Common Mistakes:
  • Multiplying incorrectly or reversing values
  • Confusing percentage with decimal
  • Choosing the wrong option due to calculation errors
4. A range estimation algorithm uses this formula: range = battery_level * efficiency - terrain_penalty. If battery_level = 70, efficiency = 2.5, and terrain_penalty = 50, what is the correct estimated range? Identify the error if the formula is written as range = battery_level * (efficiency - terrain_penalty).
medium
A. Correct range is 125 km; error is incorrect order of operations
B. Correct range is 100 km; error is missing multiplication
C. Correct range is 70 km; error is wrong variable names
D. Correct range is 0 km; error is division by zero

Solution

  1. Step 1: Calculate correct range using given formula

    range = 70 * 2.5 - 50 = 175 - 50 = 125 km.
  2. Step 2: Identify error in incorrect formula

    Incorrect formula does battery_level * (efficiency - terrain_penalty) = 70 * (2.5 - 50) = 70 * (-47.5) = -3325 km, which is wrong due to wrong order of operations and grouping.
  3. Final Answer:

    Correct range is 125 km; error is incorrect order of operations -> Option A
  4. Quick Check:

    Correct formula subtracts penalty after multiplication [OK]
Hint: Subtract penalty after multiplying battery and efficiency [OK]
Common Mistakes:
  • Grouping terms incorrectly causing negative range
  • Ignoring terrain penalty or applying it before multiplication
  • Misreading formula parentheses
5. An EV's range estimation algorithm adjusts the base range by multiplying with factors for terrain (0.9) and weather (0.8). If the base range is 200 km, what is the final estimated range after these adjustments?
hard
A. 160 km
B. 180 km
C. 144 km
D. 200 km

Solution

  1. Step 1: Understand adjustment factors

    Final range = base range * terrain factor * weather factor = 200 * 0.9 * 0.8.
  2. Step 2: Calculate the final estimated range

    200 * 0.9 = 180; 180 * 0.8 = 144 km final range.
  3. Final Answer:

    144 km -> Option C
  4. Quick Check:

    200 * 0.9 * 0.8 = 144 km [OK]
Hint: Multiply all adjustment factors with base range [OK]
Common Mistakes:
  • Adding factors instead of multiplying
  • Applying only one factor
  • Ignoring decimal multiplications
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