randsample
Description
Add-On Required: This feature requires the MATLAB Support Package for Quantum Computing add-on.
Examples
Input Arguments
Output Arguments
Tips
The
randsamplefunction uses the current random number generator, the same generator that underliesrand,randi, andrandn. Therefore, each call torandsamplereturns a different result. You can control that shared random number generator usingrng.On quantum processing unit (QPU) devices to date, real measurements can be more noisy than measurements resulting from randomly sampling a
QuantumStateobject. For more information, see Run Circuit and Make Measurement.