필터 지우기
필터 지우기

interpolation using 2D look up table

조회 수: 2 (최근 30일)
SGK
SGK 2024년 2월 7일
편집: SGK 2024년 2월 14일
Hello
My Question is
I have matrices A,B gives C. All the matrices are stored in a workspace and has size 81x200.
I would like to interpolate them and store them in a 2D lookup table.
I had used the interp2 function but I am getting errors
could some one clarify this issue?

채택된 답변

Star Strider
Star Strider 2024년 2월 7일
See if transposing all of them (use the simple transpose (.')) will work.
To see the difference between meshgrid and ndgrid results —
x = 1:3;
y = 4:6;
[X1,Y1] = meshgrid(x,y)
X1 = 3×3
1 2 3 1 2 3 1 2 3
Y1 = 3×3
4 4 4 5 5 5 6 6 6
[X2,Y2] = ndgrid(x,y)
X2 = 3×3
1 1 1 2 2 2 3 3 3
Y2 = 3×3
4 5 6 4 5 6 4 5 6
Transposing all of them should put them in ndgrid format.
.
  댓글 수: 2
SGK
SGK 2024년 2월 7일
For eg
A=[1 2 3]
B=[2 3 4]'
C= 20
But If I know the value of C= 35
is it possible to find the A and B matrices from C buy ndgrid/meshgrid Function?
Star Strider
Star Strider 2024년 2월 7일
You need to have some sort of relation that uses matrices ‘A’ and ‘B’ to produce values of matrix ‘C’ for each element of ‘A’ and ‘B’. After that, given any value within the limits of ‘A’ and ‘B’, you can interpolate to get a new value for ‘C’. You can potentially use any two matrices to interpolate the value of the third matrix, however that likely comes with restrictions, since in that instance there cannot be any repeating values of, and it would be best if was monnotonically increasing or decreasing. It might not be possible to find the ‘A’ and ‘B’ matrices given any specific value of ‘C’ except in some restricted instances. That would certainly not be true generally.

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

추가 답변 (0개)

카테고리

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

제품


릴리스

R2022b

Community Treasure Hunt

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

Start Hunting!

Translated by