필터 지우기
필터 지우기

Can someone get the answer for me on this? Really appreciated

조회 수: 12 (최근 30일)
George Abraham
George Abraham 2017년 2월 8일
댓글: Gabriel Berkhoudt 2019년 11월 27일
The test suite generates a random M x N matrix with a random number of rows and columns that is assigned to the variable A . The element values of the matrix are random double precision numbers that fall in the range from -10 to 10. The matrix has between 5 and 10 rows and between 5 and 10 columns. Assuming A is defined in the workspace, write a script with commands to perform the operations described below and assign the results to the indicated variable names.
- Add a row to the bottom of A that consists of the mean of each column of A and assign the resulting matrix to B.
- Still starting with the original matrix A, add a row to the bottom of A that consists of the sum of each column of A and assign the resulting matrix to C.
- Next add a column to C that consists of the sum of each row of C and assign the resulting matrix to D.
  댓글 수: 2
Jan
Jan 2017년 2월 8일
편집: Jan 2017년 2월 8일
This sound like a homework question. If we solve your homework, you cannot deliver it anymore without cheating.
These are very basic Matlab questions. Reading the "Getting Started" chapters of the documentation will help you to solve this by your own. It would not be useful to rephrase these chapters. Most likely this is not the last Matlab homework for you, therefore I think, you cannot avoid to read the manuals.
If you post, what you have tried so far and ask a specific question, it is very likely, that you get assistance.
George Abraham
George Abraham 2017년 2월 8일
This is due for me in a couple of hours and I really can't figure it out. My professor isn't explaining this stuff. That's why I asked for help

댓글을 달려면 로그인하십시오.

채택된 답변

Image Analyst
Image Analyst 2017년 2월 8일
Hint - here's a start (just because I have a son in college undergoing the same thing so I know how it feels). You finish it:
columnMeans = mea....
B = [A; columnMeans];
columnSums = s.......
C = [A; .......
rowSums = sum(C,......
D = [C, rowSums......
  댓글 수: 2
George Abraham
George Abraham 2017년 2월 8일
I still don't understand
Gabriel Berkhoudt
Gabriel Berkhoudt 2019년 11월 27일
Wow this was very helpful. Thank you. Makes perfect sense!

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Calendar에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by