Using different X-axis in trapz

조회 수: 7 (최근 30일)
Muhammet Nuri
Muhammet Nuri 2022년 8월 1일
댓글: Muhammet Nuri 2022년 8월 2일
I want to numerically integrate the graph i have using an axis other than y=0. is there any built in tool to do that. Thanks for any help.

채택된 답변

Walter Roberson
Walter Roberson 2022년 8월 1일
No, there is no built-in tool for that .
Have you considered applying a rotation and translation ? makehgtform is convenient for creating transformation matrices
z = zeros(size(x));
[x(:), y(:), z(:), zeros(numel(x),1)] * Matrix
and take the first two columns of the output
I show z separately because this is the general form for when you have x y z coordinates, that you use them as the first three columns and the fourth needs to zeros
  댓글 수: 1
Muhammet Nuri
Muhammet Nuri 2022년 8월 2일
Sorry for the late reply. Hats off to you sir.

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

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Numerical Integration and Differentiation에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!

Translated by