Hi,
I have two 3D matrices of ones (and zeros) of a (filled) cone like shape. The matrices are the same size, but the cone sizes differ. I want to "subtract" the smaller of the two matrices from the other matrix element by element. resulting in a third matrix of the "leftover" ones (and zeros). A-B = C doesn't seem to work. Does anybody have an idea on how two do that?

댓글 수: 2

KSSV
KSSV 2018년 5월 31일
Two matrices should be same to subtract. Get them to same size. As your matrices are filled with 0 and 1.
David van Nederpelt
David van Nederpelt 2018년 5월 31일
Hi KSSV,
Thanks for your answer. The sizes were the same. But I found a mistake in the buildup of the cones. Thank you anyway! Do you happen to know how to 3D plot a matrix of ones determined by their position in the matrix?
Kind regards,
David

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

답변 (0개)

카테고리

도움말 센터File Exchange에서 Mathematics에 대해 자세히 알아보기

질문:

2018년 5월 31일

댓글:

2018년 5월 31일

Community Treasure Hunt

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

Start Hunting!

Translated by