TactivergeLite

Lite / Engineering Complex Systems / Term 4 worksheet

Worksheet: Engineering Complex Systems, term 4

Engineering Optimization · Questions only. Check your answers in each Lite lesson, where they are graded on our server.

Name:   Date:

Week 28: Distributions, spread and the one weird run

1. Your benchmark times have a long right tail from occasional background tasks. Which centre is least affected by those rare slow runs?

2. Five timing runs (ms): 33, 28, 28, 33, 34. What is the sample standard deviation s (divide by n − 1)? (3 decimal places.)

Answer: ms

3. Past runs of a benchmark have mean 67 ms and standard deviation 4 ms. A new run takes 74.6 ms. What is its z-score? (2 decimal places; negative if it is below the mean.)

Answer:

4. A run is flagged with z = 4.2. What is the most defensible action?

5. Why does the sample standard deviation divide by n − 1?

Check these in the lesson

Week 28: How sure is your average? The standard error

1. Twenty-five runs have sample SD s = 5 ms. What is the standard error of the mean, in ms?

Answer: ms

2. As you collect more and more runs, what happens to the sample SD and to the SE?

3. A sensor's readings have standard deviation σ ≈ 4 units. How many repeated readings n do you need so that the 95% confidence interval for the mean has a half-width of at most 1.5 units? Use z = 1.96 and round n up to a whole number.

Answer: readings

4. Your laptop slowly heats up during a benchmark, so later runs are systematically slower. What does this do to s/√n as an estimate of the mean's uncertainty?

5. You repeat a measurement n = 64 times. The sample standard deviation is s = 2.5 °C. Using the normal approximation (z = 1.96 for 95%), what is the half-width of the 95% confidence interval for the mean, in °C? (3 significant figures.)

Answer: °C

Check these in the lesson

Week 28: Is the difference real? Effect sizes and correlation

1. SE_A = 0.3 W and SE_B = 0.4 W for two independent conditions. What is the SE of the difference of means, in W?

Answer: W

2. A team tests firmware v2 on Monday morning and v1 on Friday afternoon, when the lab is warmer. v2 uses less power. What is the main problem?

3. Across 50 rover drives, wheel slip and battery drain have r = 0.85. What can you conclude?

4. After warm-up, the baseline takes a mean of 24 ms per run and the optimised version 10 ms (same machine, same input, interleaved runs). What is the speed-up, baseline time ÷ new time? (3 significant figures.)

Answer: ×

Check these in the lesson

Week 29: What a 95% confidence interval really promises

1. You repeat a measurement n = 49 times. The sample standard deviation is s = 0.8 W. Using the normal approximation (z = 1.96 for 95%), what is the half-width of the 95% confidence interval for the mean, in W? (3 significant figures.)

Answer: W

2. Which statement correctly interprets a 95% confidence interval?

3. A sensor's readings have standard deviation σ ≈ 4 units. How many repeated readings n do you need so that the 95% confidence interval for the mean has a half-width of at most 1.5 units? Use z = 1.96 and round n up to a whole number.

Answer: readings

4. With n = 4 runs, you build x̄ ± 1.96·s/√n. What is the main risk?

5. x̄ = 20.0 °C, s = 1.0 °C, n = 25. What is the half-width of the 99% interval (z = 2.576), in °C?

Answer: °C

Check these in the lesson

Week 29: Propagating uncertainty through a calculation

1. Two independent masses are measured: A = 346 ± 6 g and B = 40 ± 9 g (standard uncertainties). What is the standard uncertainty of A − B, in grams? (2 decimal places.)

Answer: g

2. A test rig logs voltage V = 3.3 V (± 3%) and current I = 0.5 A (± 2%) for exactly t = 3600 s, so energy E = V·I·t. Treating the two uncertainties as independent and t as exact, what is the absolute standard uncertainty of E, in joules? (3 significant figures.)

Answer: J

3. A power estimate P = V·I has V ± 0.5% and I ± 4%. To halve the uncertainty in P, what should you improve?

4. Kinetic energy ½mv² with m exact and v uncertain by 1.5%. What is the relative uncertainty in the energy, in %?

Answer: %

5. Why is subtracting two nearly equal measured values risky?

Check these in the lesson

Week 29: Monte Carlo: propagate by simulation

1. When is Monte Carlo clearly preferable to the quadrature formula?

2. A Monte Carlo mean has standard error 0.08 with N = 2,500 samples. How many samples give a standard error of 0.02?

Answer: samples

3. Which detail is essential so that someone else can reproduce your Monte Carlo result exactly?

4. A test rig logs voltage V = 9 V (± 3%) and current I = 1.5 A (± 5%) for exactly t = 120 s, so energy E = V·I·t. Treating the two uncertainties as independent and t as exact, what is the absolute standard uncertainty of E, in joules? (3 significant figures.)

Answer: J

Check these in the lesson

Week 30: Formulate first: variables, objectives, constraints and Pareto fronts

1. 'The arm must lift a 2 kg sample' and 'the arm should be as light as possible'. Which is a constraint and which an objective?

2. Six rover-arm designs, where LOWER cost and LOWER mass are both better: A (£30, 5.5 kg); B (£40, 1.5 kg); C (£100, 6 kg); D (£20, 6 kg); E (£20, 2.5 kg); F (£30, 5.5 kg). How many designs are non-dominated (on the Pareto front)?

Answer: designs

3. Design X costs £900 and weighs 4.2 kg. Design Y costs £1,100 and weighs 4.8 kg. Lower is better for both. What can you say?

4. A report picks design E 'by weighted sum' without stating the weights. What's the problem?

Check these in the lesson

Week 30: Linear programming: why the corners win

1. Corners of a feasible region are (0, 0), (12, 0), (0, 10) and (8.4, 7.2). What is the maximum of 3x + 5y?

Answer:

2. A small factory makes x controllers and y sensor boards a day. Assembly time: 2x + 1y ≤ 18 hours. Test time: 1x + 4y ≤ 36 hours. Also x ≥ 0, y ≥ 0 (fractions allowed). Profit is 8x + 9y pounds. What is the maximum profit, in pounds? (2 decimal places.)

Answer: £

3. A small factory makes x controllers and y sensor boards a day. Assembly time: 3x + 1y ≤ 36 hours. Test time: 1x + 3y ≤ 36 hours. Also x ≥ 0, y ≥ 0 (fractions allowed). Profit is 5x + 3y pounds. What is the maximum profit, in pounds? (2 decimal places.)

Answer: £

4. At the optimum, the assembly constraint has 6 hours of slack. What happens to the optimum if you buy 4 more assembly hours?

5. The LP optimum is 8.4 frames and 7.2 chassis, but you can only build whole items. What is true?

Check these in the lesson

Week 30: Searching a design landscape: grids, gradients and local minima

1. The energy cost of a design is f(x) = 2·(x − 2)². Starting from x₀ = 4 with learning rate η = 0.25, take one gradient-descent step x₁ = x₀ − η·f′(x₀). What is x₁? (3 decimal places.)

Answer:

2. You grid-search a design with 4 parameters, trying 5 values of each. One simulation takes 0.01 s. How long does the full grid take, in seconds?

Answer: s

3. Gradient descent's cost goes up and down and then grows each step. What is the most likely cause?

4. Gradient descent from three random starts gives costs 1.52, 0.61 and 1.52. What should you report?

5. RK4 has global error roughly proportional to h^4. With step h = 0.1 s the error is 2.4 mm. Estimate the error with step h = 0.025 s, in mm. (4 significant figures.) The run will take about 4× as long.

Answer: mm

Check these in the lesson

Week 31: Time, memory, accuracy: pick your trade

1. The trapezoid rule has global error roughly proportional to h^2. With step h = 0.2 s the error is 0.8 mm. Estimate the error with step h = 0.05 s, in mm. (4 significant figures.) The run will take about 4× as long.

Answer: mm

2. A sensor value is stored in Q8 fixed point (8 fractional bits). What is the largest possible rounding error for one stored value?

Answer:

3. You sort 40 sensor readings once per second on a microcontroller. Is a simple O(n²) insertion sort acceptable?

4. You grid-search a design with 4 parameters, trying 10 values of each. One simulation takes 1 s. How long does the full grid take, in seconds?

Answer: s

5. Shrinking h keeps reducing the error, until at very small h the error starts to grow. Why?

Check these in the lesson

Week 31: Power, performance, area: the chip designer's triangle

1. A chip's dynamic power is P = α·C·V²·f. At 1 V and 1500 MHz it uses 5 W. The designers change the supply to 0.9 V and the clock to 3000 MHz (same α and C). What is the new dynamic power, in watts? (3 significant figures.)

Answer: W

2. One core at 1 V and clock f does a job using 1 W of dynamic power and 1.5 mm² of silicon. Design B uses 4 identical cores, each clocked at f/4 (same total throughput), which lets the supply drop to 0.6 V. Using P = α·C·V²·f per core, what is design B's total dynamic power, in watts? (3 significant figures.) Its area is about 6 mm².

Answer: W

3. Why can't a designer just keep raising the clock frequency of one core?

4. In the PPA explorer, 8 cores at 0.5 V use more total power than 4 cores at 0.65 V for the same throughput. Why?

Check these in the lesson

Week 31: Energy per operation: the number that decides battery life

1. A processor draws 1.5 W while running at 48 MHz and completing 4 operations per clock cycle. What is the energy per operation, in picojoules (pJ)? (3 significant figures.)

Answer: pJ

2. A field sensor has a 5 Wh battery. It is active 1% of the time drawing 4.5 W, and asleep the rest of the time drawing 1 mW. Ignoring battery ageing and temperature, how many hours does the battery last? (3 significant figures.)

Answer: h

3. While the processor works, the rover's radio and sensors must stay on, drawing 4 W. Chip A: 2 W for 1 s. Chip B: 0.5 W for 3 s. Which uses less total energy?

4. An accelerator delivers 4 × 10¹² operations per second at 8 W. What is its energy per operation, in pJ?

Answer: pJ

Check these in the lesson

Week 32: Power, mass and data budgets with margins

1. A lander mass budget has current best estimates of 2 kg, 11.5 kg, 20 kg, 19.5 kg. Policy adds 15% contingency to the total. The launch allocation is 77 kg. Margin = (capability − estimate with contingency) ÷ (estimate with contingency) × 100. What is the margin, in %? (1 decimal place; negative means over budget.)

Answer: %

2. A lander power budget has current best estimates of 51 W, 16 W, 14 W, 50 W. Policy adds 30% contingency to the total. The power system can supply 138 W. Margin = (capability − estimate with contingency) ÷ (estimate with contingency) × 100. What is the margin, in %? (1 decimal place; negative means over budget.)

Answer: %

3. A field sensor has a 10 Wh battery. It is active 5% of the time drawing 2 W, and asleep the rest of the time drawing 10 mW. Ignoring battery ageing and temperature, how many hours does the battery last? (3 significant figures.)

Answer: h

4. A radio draws 60 W while transmitting, 20% of the time. The average power budget shows 12 W. What else must you check?

5. Why is contingency larger for a brand-new instrument than for one that has flown before?

Check these in the lesson

Week 32: The rocket equation and the Δv budget

1. A stage has specific impulse Isp = 340 s (so exhaust speed vₑ = Isp × 9.80665 m/s). It starts at m₀ = 800 kg, 55.00000000000001% of which is propellant it burns completely. Using Δv = vₑ·ln(m₀/m_f), what Δv does it deliver, in m/s? (Nearest 1 m/s.)

Answer: m/s

2. A spacecraft with a dry (empty) mass of 300 kg needs Δv = 3600 m/s. Its engine's exhaust speed is vₑ = 2200 m/s. Using Δv = vₑ·ln(m₀/m_f) with m_f = dry mass, how much propellant must it carry, in kg? (Nearest 1 kg.)

Answer: kg

3. To increase Δv by 20%, which is generally more effective?

4. A lander's dry mass grows 10% late in the design. What happens to the propellant needed for the same Δv?

Check these in the lesson

Week 32: Light-time and the data budget: why rovers decide for themselves

1. Earth and Mars are 225 million km apart. Radio travels at c = 299,792 km/s. What is the round-trip time for a command and its reply (ignore processing time), in minutes? (2 decimal places.)

Answer: min

2. Earth and Mars are 78 million km apart. Radio travels at c = 299,792 km/s. What is the one-way signal delay, in minutes? (2 decimal places.)

Answer: min

3. A rover's relay link runs at 64 kbit/s for 12 minutes per orbiter pass, with 3 passes a day. Each compressed image is 12 Mbit. Ignoring protocol overhead, how many whole images can it send per day?

Answer: images

4. Which decision must a Mars rover make on board?

Check these in the lesson

Week 33: Registers and bit masks: where software touches silicon

1. Which C expression clears bit 5 of reg and leaves every other bit unchanged?

2. reg = 0x3C. After reg |= 0x81, what is reg in decimal?

Answer:

3. A 3-bit prescaler field sits at bits 4–6 of an 8-bit register that currently holds 0x0F. You write the value 5 into the field. What does the register hold now, in decimal?

Answer:

4. Main code does PORT |= LED_BIT while an interrupt handler sets MOTOR_BIT in the same register. Occasionally the motor bit is lost. Why?

Check these in the lesson

Week 33: Polling or interrupts? Latency, energy and shared data

1. A battery-powered door sensor must react within 10 ms to a door opening, which happens a few times a day. Which design?

2. A field sensor has a 5 Wh battery. It is active 1% of the time drawing 4.5 W, and asleep the rest of the time drawing 1 mW. Ignoring battery ageing and temperature, how many hours does the battery last? (3 significant figures.)

Answer: h

3. Which is good practice inside an interrupt handler?

4. A poll check takes 5 µs and runs every 1 ms. What percentage of CPU time does polling use?

Answer: %

Check these in the lesson

Week 33: From source code to running hardware, and testing the join

1. Which tool decides the actual memory addresses where code and data end up?

2. You benchmark a filter on a -O0 debug build and report its timing. What's wrong?

3. What can a hardware-in-the-loop test catch that a unit test on a laptop cannot?

4. After warm-up, the baseline takes a mean of 24 ms per run and the optimised version 10 ms (same machine, same input, interleaved runs). What is the speed-up, baseline time ÷ new time? (3 significant figures.)

Answer: ×

Check these in the lesson

Week 34: Designing a benchmark you can trust

1. Why discard the first few runs of a steady-state benchmark?

2. Why interleave runs of A and B rather than running all A then all B?

3. After warm-up, the baseline takes a mean of 24 ms per run and the optimised version 13.3 ms (same machine, same input, interleaved runs). What is the speed-up, baseline time ÷ new time? (3 significant figures.)

Answer: ×

4. Past runs of a benchmark have mean 72 ms and standard deviation 5 ms. A new run takes 88 ms. What is its z-score? (2 decimal places; negative if it is below the mean.)

Answer:

5. Which decision rule is best written before running the benchmark?

Check these in the lesson

Week 34: A speed-up is a ratio: give it an interval

1. Baseline mean = 40 ± 0.8 ms and optimised mean = 33.3 ± 1.33 ms (each ± is a standard error, independent). The speed-up S = baseline ÷ optimised. What is the standard uncertainty of S? (3 decimal places.)

Answer: ×

2. Baseline mean = 18 ± 0.18 ms and optimised mean = 6 ± 0.06 ms (each ± is a standard error, independent). The speed-up S = baseline ÷ optimised. What is the standard uncertainty of S? (3 decimal places.)

Answer: ×

3. A speed-up is reported as 1.08 with 95% interval 0.97–1.19. What should the report conclude?

4. Why not compute the speed-up as the average of per-run ratios t_A,i / t_B,i?

Check these in the lesson

Week 34: Which part made it better? Baselines and ablations

1. Which baseline is most convincing for a new greenhouse controller?

2. Full design scores 88% accuracy. Removing the voting circuit gives 81%; removing the speed change gives 86%. How many percentage points does voting contribute in this design?

Answer: points

3. Removing X alone costs 1 point and removing Y alone costs 1 point, but removing both costs 8 points. What does this suggest?

4. Baseline mean = 24 ± 0.72 ms and optimised mean = 10 ± 0.4 ms (each ± is a standard error, independent). The speed-up S = baseline ÷ optimised. What is the standard uncertainty of S? (3 decimal places.)

Answer: ×

Check these in the lesson

Week 35: Anatomy of a technical manuscript

1. Which element is essential in an engineering abstract?

2. Which is the best test of a methods section?

3. Your simulated results show 14% energy saving on five nights. Which claim is appropriate?

4. You repeat a measurement n = 25 times. The sample standard deviation is s = 3.5 W. Using the normal approximation (z = 2.576 for 99%), what is the half-width of the 99% confidence interval for the mean, in W? (3 significant figures.)

Answer: W

Check these in the lesson

Week 35: Figures that tell the truth, including the uncertainty

1. A figure shows error bars but the caption doesn't say what they are. Why is that a problem?

2. A plot shows SD bars of ±6 ms for n = 36 runs. What is the 95% CI half-width for the mean (z = 1.96), in ms?

Answer: ms

3. A bar chart of speed-up starts its y-axis at 0.95, making 1.02 look twice the height of 0.99. What's wrong?

4. You repeat a measurement n = 25 times. The sample standard deviation is s = 3.5 W. Using the normal approximation (z = 2.576 for 99%), what is the half-width of the 99% confidence interval for the mean, in W? (3 significant figures.)

Answer: W

Check these in the lesson

Week 35: Reviewing and revising: answer the critic

1. Which reviewer comment is a major issue?

2. Which is the best response to 'the improvement may come from drift'?

3. Baseline mean = 24 ± 0.48 ms and optimised mean = 13.3 ± 0.27 ms (each ± is a standard error, independent). The speed-up S = baseline ÷ optimised. What is the standard uncertainty of S? (3 decimal places.)

Answer: ×

4. After revisions your effect shrinks below your decision threshold. What should the revised manuscript do?

Check these in the lesson

Week 36: Plan the capstone: requirements, metrics, baselines and budgets

1. Which element is missing from: 'Does PI control reduce greenhouse energy use?'

2. A lander power budget has current best estimates of 51 W, 16 W, 14 W, 50 W. Policy adds 30% contingency to the total. The power system can supply 138 W. Margin = (capability − estimate with contingency) ÷ (estimate with contingency) × 100. What is the margin, in %? (1 decimal place; negative means over budget.)

Answer: %

3. A sensor's readings have standard deviation σ ≈ 4 units. How many repeated readings n do you need so that the 95% confidence interval for the mean has a half-width of at most 1.5 units? Use z = 1.96 and round n up to a whole number.

Answer: readings

4. Why write your decision rule in your log before running experiments?

Check these in the lesson

Week 36: Present the evidence, defend the method, own the limits

1. Which is the best one-sentence takeaway for a results slide?

2. You're asked about a condition you didn't test. What's best?

3. You repeat a measurement n = 25 times. The sample standard deviation is s = 2.5 °C. Using the normal approximation (z = 1.96 for 95%), what is the half-width of the 95% confidence interval for the mean, in °C? (3 significant figures.)

Answer: °C

4. Baseline mean = 24 ± 0.72 ms and optimised mean = 10 ± 0.4 ms (each ± is a standard error, independent). The speed-up S = baseline ÷ optimised. What is the standard uncertainty of S? (3 decimal places.)

Answer: ×

Check these in the lesson