How many times does a number appear in these lines?

조회 수: 1 (최근 30일)
Marco Camozzi
Marco Camozzi 2020년 4월 7일
편집: Marco Camozzi 2020년 4월 7일
Hi
someone could help me find a function that checks in loop if an i and j number of each line appears in the other lines more than 2 times?
%Connecting points i --> j: Edge(k,:) = [i, j];
Edge = [1 2;
2 3;
3 4;
2 6;
3 7;
5 6;
6 7;
7 8];
i corresponds to the left number an j to the right one.
Thank you!

채택된 답변

KSSV
KSSV 2020년 4월 7일
Read about unique. This should help you to get what you want.
  댓글 수: 3
KSSV
KSSV 2020년 4월 7일
You got the solution? You have accepted answer?
Marco Camozzi
Marco Camozzi 2020년 4월 7일
편집: Marco Camozzi 2020년 4월 7일
yea I accepted, I still have no solution at the moment.

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

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Loops and Conditional Statements에 대해 자세히 알아보기

제품


릴리스

R2019b

Community Treasure Hunt

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

Start Hunting!

Translated by