필터 지우기
필터 지우기

How can I compute the distance formula between two specific atoms when these two atoms have different xyz coordinates each time?

조회 수: 4 (최근 30일)
I have similar data table to this:
A = 10x3
C -0.7146 0.5304 -1.1481
C -1.1512 0.7561 0.4465
C 0.9622 1.8652 0.1832
C 0.2667 0.1483 -0.5122
C -1.0791 -2.5351 -0.7354
H -1.2107 1.7495 -1.6239
H -0.3533 -0.4565 -1.5120
H 1.8556 -0.3747 -0.2835
C 0.5873 -0.5978 -1.3833
C 0.3756 -1.4333 -1.3172
A = 10×3
C -0.8346 0.6204 -1.0881
C -1.7712 0.7661 0.5565
C 0.7822 1.0052 0.6832
C 0.2667 0.1483 -0.5122
C -1.0791 -2.5351 -0.7354
H -1.2111 1.7295 -1.1001
H -0.3422 -0.4733 -1.7731
H 1.8661 -0.3617 -0.2881
C 0.5611 -0.5272 -1.0844
C 0.8742 -1.9703 -1.8312
And this data is repeated 20 times with different values of xyz coordinates each time, so I want to pick up only the second row and the fourth row and calculate the distance formula for these two points of each data table. so the result has to be 20 answers of distances. How can I do that, please? I don’t know if this needs loop and how?
  댓글 수: 13

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

답변 (0개)

카테고리

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

제품


릴리스

R2021a

Community Treasure Hunt

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

Start Hunting!

Translated by