A LabVIEW test program uses one numeric shift register to smooth an amplifier’s measured voltage. Its retained state is the value carried from one iteration to the next. The register is initialized to 0 V, and the loop executes exactly four iterations, indexed 0 through 3.
During iteration iii, the left terminal supplies pip_ipi. The program calculates and writes
to the right terminal, so pi+1=zip_{i+1}=z_ipi+1=zi. The inputs are x0=8x_0=8x0=8 V, x1=16x_1=16x1=16 V, an unknown x2x_2x2, and x3=20x_3=20x3=20 V. After iteration 3 finishes, the final stored value is exactly 9.5 V. Assume no rounding occurs during the calculations.
Find the incoming value p2p_2p2 at the start of iteration 2 and the missing input x2x_2x2. Give both answers in volts to one decimal place.
Unlock full course notes by signing up
Make Independent Runs Repeatable
A LabVIEW VI remains loaded in memory between runs. Its uninitialized numeric shift register initially contains 0 J0\ \text{J}0 J. On every run, a loop executes exactly three iterations, each adding 2 J2\ \text{J}2 J to the retained value. The first run returns 6 J6\ \text{J}6 J and the second returns 12 J12\ \text{J}12 J. Each run should instead represent an independent test starting from zero. Which explanation and change correctly address the behavior?
Trace a Two-Sample History
A LabVIEW loop smooths a sensor voltage using a stacked shift register, which exposes values retained from multiple earlier iterations. Both left elements are initialized to 6 V. At the start of iteration iii, the upper element supplies UiU_iUi and the lower element supplies LiL_iLi.
Each iteration displays the three-sample mean
Update Two Retained States Together
A LabVIEW numerical test loop retains two voltage values in separate floating-point shift registers. Their initial states are a0=2.0 Va_0=2.0\ \text{V}a0=2.0 V and b0=5.0 Vb_0=5.0\ \text{V}b0=5.0 V. During iteration kkk, the loop reads both incoming values and writes
Both right-terminal values are calculated from the left-terminal values for that iteration. What pair (a2,b2)(a_2,b_2)(a2,b2) leaves the registers after exactly two iterations?
Combine Reset and Hold Behavior
A LabVIEW program retains an energy total EkE_kEk in a floating-point shift register initialized to 12.0 J12.0\ \text{J}12.0 J. Each iteration receives an energy increment, a validity flag and a reset flag. It follows these rules in order:
If reset is true, use 0 J0\ \text{J}0 J as that iteration's base total BkB_kBk; otherwise, use the incoming retained total EkE_kEk.
If valid is true, add the current increment to the base total; otherwise, leave the base total unchanged.