Two temperature sensors on a furnace wall are read at different rates during the same…

PHYSICS · Subjective · Fermi University Physics · Computational Physics · Scientific programming for physicists · Scientific programming for physicists

Computational Physics, Ch Arrays: a field is a rectangle of numbers

Problem

Two temperature sensors on a furnace wall are read at different rates during the same experiment. Sensor A gives an array a\texttt{a} of shape (500,)(500,) and sensor B gives an array b\texttt{b} of shape (400,)(400,), both in kelvin. Someone writes a + b\texttt{a + b}, intending to add corresponding readings. (a) Say whether a + b\texttt{a + b} succeeds or fails, giving the reason from the broadcasting rule. (b) If it fails, state the two numbers that the resulting error message would name.

Browse the problem library