필터 지우기
필터 지우기

Vector of min or max for 3 vectors

조회 수: 14 (최근 30일)
judy abbott
judy abbott 2017년 9월 17일
답변: Jan 2017년 9월 17일
Please for A, B and C vectors as:
A = [2; 0; -4; 4];
B = [0; -6; -2; 1];
C = [4; 1.5; 4; -2];
i need to get the min for each vector row: min (2, 0 and 4) = 0 and stock them in a vector,
VMIN = [0; -6; -4; -2]
VMAX = [4; 1.5; 4; 4]
  댓글 수: 1
Jan
Jan 2017년 9월 17일
Is this a homework? If so, please mention this explicitly, because then a different kind of answering is required.

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

채택된 답변

Jan
Jan 2017년 9월 17일
Start with creating a matrix:
M = [A, B, C]
Then the min and max commands create the output directly.

추가 답변 (0개)

카테고리

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

태그

Community Treasure Hunt

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

Start Hunting!

Translated by