필터 지우기
필터 지우기

hi everyone , can anyone help me to make it , thank you

조회 수: 2 (최근 30일)
mina massoud
mina massoud 2019년 4월 11일
댓글: mina massoud 2019년 4월 11일
clear all
clc
X=[ 10 17 20 ; 1 4 8 ; 2 3 30 ]
Z=zeros(3,3)
% i need to put in the matrix Z this condition
% 1) if greatar than or equal 15 is 1
% 2)and if less than 15 is zero
%thank you

채택된 답변

madhan ravi
madhan ravi 2019년 4월 11일
I suggest you to read about logical indexing:
~(X<15)
  댓글 수: 1
mina massoud
mina massoud 2019년 4월 11일
i read about it but can u help me to get be the same dimensione of A instead of column vector
A=magic(4);
B=zeros(4,4); % i need a matrix in this dimension with that condition
B=A(A<5|A>10);

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

추가 답변 (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