Documentation |
Grid ureal parameters uniformly over their range
B = gridureal(A,N)
[B,SampleValues] = gridureal(A,N)
[B,SampleValues] = gridureal(A,NAMES,N)
[B,SampleValues] = gridureal(A,NAMES1,N1,NAMES2,N2,...)
B = gridureal(A,N) substitutes N uniformly-spaced samples of the uncertain real parameters in A. The samples are chosen to cut "diagonally" across the cube of real parameter uncertainty space. The array B has size equal to [size(A) N]. For example, suppose A has 3 uncertain real parameters, say X, Y and Z. Let (x1, x2 , , and xN) denote N uniform samples of X across its range. Similar for Y and Z. Then sample A at the points (x1, y1, z1), (x2, y2, z2), and (xN, yN, zN) to obtain the result B.
If A depends on additional uncertain objects, then B will be an uncertain object.
[B,SampleValues] = gridureal(A,N) additionally returns the specific sampled values (as a structure whose fieldnames are the names of A's uncertain elements) of the uncertain reals. Hence, B is the same as usubs(A,SampleValues).
[B,SampleValues] = gridureal(A,NAMES,N) samples only the uncertain reals listed in the NAMES variable (cell, or char array). Any entries of NAMES that are not elements of A are simply ignored. Note that gridureal(A, fieldnames(A.Uncertainty),N) is the same as gridureal(A,N).
[B,SampleValues] = gridureal(A,NAMES1,N1,NAMES2,N2,...) takes N1 samples of the uncertain real parameters listed in NAMES1, and N2 samples of the uncertain real parameters listed in NAMES2 and so on. size(B) will equal [size(A) N1 N2 ...].