Creating a 2D Matrix based on variables
Show older comments
Hi
I am looking to create a 2D Matrix based on three variables, A,B and C. A which could be between 8 and 12, B which could be between 4 and 50 and C which could be between 3 and 5. I need to matrix to be automatically constructed based on the variables, for example when A=10, B=7 and C=3
Matrix =
10 10 10 10 10 10 10
10 10 10 10 10 10 10
10 10 10 10 10 10 10
So I need A to control the values in the Matrix, B to control the number of columns and C to control the number of rows.
If anyone knows of a solution it would be much appreciated
Thankyou
Andy
Accepted Answer
More Answers (1)
Andy
on 27 Apr 2012
0 votes
Categories
Find more on Creating and Concatenating Matrices in Help Center and File Exchange
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!