How to create a random n matrix with out any conditions
1 visualización (últimos 30 días)
Mostrar comentarios más antiguos
Hajar Alshaikh
el 17 de Nov. de 2022
Respondida: William Rose
el 17 de Nov. de 2022
I know that I can create a random n matrix by using the code rand(n), but this matrix entries will be all between zero and one.
what I want is to creat random matrix with out any condition and it can take a value grater than 1 and less than zero
0 comentarios
Respuesta aceptada
William Rose
el 17 de Nov. de 2022
There is no way to create random numbers that are truly "without any condition". You can create random numbers that have a specified probability distribution. Use randn() for normally distributed random numbers that can range from -Inf to +Inf.
A=randn(4,6); %create 4x6 array of normally distributed random numbers
Good luck.
0 comentarios
Más respuestas (0)
Ver también
Categorías
Más información sobre Creating and Concatenating Matrices en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!