how to multiply certain numbers in a matrice
조회 수: 1 (최근 30일)
이전 댓글 표시
if have a matrice A=[1,5,4;3,1,5;6,3,1] But I want to multiply only certain numbers for example A=[2,5,4;3,2,5;6,3,2] how do i do this.
댓글 수: 0
답변 (2개)
Guillaume
2017년 2월 8일
You haven't explain what certain numbers mean. At a guess:
A(A == 1) = A(A == 1) * 2;
댓글 수: 0
참고 항목
카테고리
Help Center 및 File Exchange에서 Logical에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!