A controller test uses a repeating block of dimensionless command codes. The engineer creates the block and a larger array with these MATLAB commands, where r and c are positive integers:
P = [2 8 2; 5 0 5]; B = repmat(P,r,c);
Array B must contain exactly 180 entries arranged in 15 columns. Determine the required values of r and c, and the total number of entries equal to 5 in B. Enter all three answers as exact integers.
Unlock full course notes by signing up
Find positioning-system spacing
A positioning system uses x = linspace(0.35,2.75,9); to create nine equally spaced positions, including both endpoints. The stored values represent positions in metres. What is the spacing between adjacent positions? Enter your answer in m, to two decimal places.
Evaluate frequency-sweep arrays
An instrumentation engineer creates three candidate frequency arrays using the MATLAB commands below. Each entry represents a frequency in Hz. Complete every row of the table in array order, using exact decimal numbers without units or scientific notation.
Repair a placeholder-row constructor
A test engineer wants a 2-by-5 array whose first row contains five positions from 0 to 12 m and whose second row contains five zero placeholders. The engineer writes:
Which statement correctly describes the current result and the replacement needed for zeros(5)?
Assemble a configuration from array blocks
A test configuration array C must have three rows and six columns. Its first row must contain four equally spaced time values from 0 to 6 s, including both endpoints, followed by two zeros. Each of the remaining two rows must contain three dimensionless ones followed by three zeros. The row meanings and units are recorded separately from the numeric array. Which MATLAB command creates the required array?