필터 지우기
필터 지우기

how to divide two matrix

조회 수: 36 (최근 30일)
farfar
farfar 2017년 2월 3일
댓글: farfar 2017년 2월 3일
hi everyone I have 2 matrix like
a=[10 12 15;15 16 18;14 18 19;15 19 25;23 45 75]
b=[2 4 5;1 2 2;4 8 6;1 4 7;5 1 2]
how can I divide each elements of matrix "a" by corresponding value in matrix "b" to have
c=[5 3 3;15 8 9;........]
? the original matrix are big. Thanks

채택된 답변

the cyclist
the cyclist 2017년 2월 3일
편집: the cyclist 2017년 2월 3일
c = a./b;
This is a very basic MATLAB question. I suggest you google "matlab tutorial" and look through some of the excellent (and free) online material that is available.
  댓글 수: 1
farfar
farfar 2017년 2월 3일
you are right, for some reason I thought I need a loop for this ! thanks anyway

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

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Matrices and Arrays에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by