-function A = random_positive_definite_matrix(integerN)
+function A = random_positive_definite_matrix(integerN, max_entry = realmax)
%
% Generate a random, symmetric positive-definite (SPD) matrix.
%
%
% - ``integerN`` -- The dimension of the resulting matrix.
%
+ % - ``max_entry`` -- (optional) Upper bound on the entries.
+ %
% OUTPUT:
%
% - ``A`` -- A symmetric, positive definite matrix.
%
U = random_orthogonal_matrix(integerN);
- d = unifrnd(eps, realmax, 1, integerN);
+ d = unifrnd(eps, max_entry, 1, integerN);
D = diag(d);
A = U*D*U';
end