If n is the given number, then make a diagonal matrix of size 2*2 with the square of that number.
Solution Stats
Problem Comments
Solution Comments
Show comments
Loading...
Problem Recent Solvers292
Suggested Problems
-
Increment a number, given its digits
686 Solvers
-
Compute a dot product of two vectors x and y
1050 Solvers
-
Create matrix of replicated elements
397 Solvers
-
Rounding off numbers to n decimals
5538 Solvers
-
539 Solvers
More from this Author3
Problem Tags
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!