Preserve Sample Pairing During Implicit Expansion

Three samples each have a temperature in degrees Celsius and a pressure in kPa. Entries with the same sample number belong together, but the arrays have different orientations:


MATLAB
T = [42; 58; 49];
p = [230 180 195];
mask = (T < 50) & (p < 200);


Temperature readings form a column while matching pressure readings form a row.


Using current MATLAB with implicit expansion, the intended output is one column-vector decision per sample: temperature below 50 degrees Celsius AND pressure below 200 kPa. Which statement correctly describes the current output dimensions and a way to obtain the intended pairing? The operator .' denotes nonconjugate transpose.

Choose an answer

Create a free account to get started

Unlock full course notes by signing up

  • Video lessons taught by top educators
  • Practice questions with guided solutions
  • Written review notes for reference
  • Expert answers anytime from course tutors

More Element-by-Element Boolean Operators Questions: