필터 지우기
필터 지우기

how to interpolation from small matrix to large matrix.

조회 수: 11 (최근 30일)
AniCnx
AniCnx 2019년 10월 27일
댓글: AniCnx 2019년 10월 27일
how can I interpolation matrix from 7x7 to 70x70? otherwise, imresize is failed for major value in matrix 7x7. I confuse about interp2 that which will be the peaks or else.
M = [
26.6536850000000 26.2116960000000 25.7796660000000 25.5484060000000 25.3228370000000 25.0957440000000 25.0041480000000
28.4801820000000 27.9432550000000 27.4145080000000 27.2323110000000 27.0571170000000 26.8760090000000 26.6948490000000
29.9440660000000 29.4085810000000 28.8797540000000 28.6681150000000 28.4651270000000 28.2585010000000 28.1512510000000
31.4023710000000 30.8655880000000 30.3369250000000 30.0879120000000 29.8463940000000 29.6012150000000 29.5798550000000
32.8606770000000 32.3225940000000 31.7940950000000 31.5077100000000 31.2276610000000 30.9439290000000 31.0084580000000
35.3245990000000 34.9917560000000 34.6621570000000 34.3190500000000 33.9818450000000 33.6506420000000 33.5333720000000
37.8039920000000 37.6987970000000 37.5974040000000 37.2201680000000 36.8485640000000 36.4937550000000 36.1883560000000];

채택된 답변

Walter Roberson
Walter Roberson 2019년 10월 27일
편집: Walter Roberson 2019년 10월 27일
newM = imresize(M, [70 70]);
I just tried it and no error message was produced. You should explain further what "failed for major value in matrix" means to you.
Are you talking about the fact that imresize() is producing an maximum output that exceeds the maximum of the input? imresize() projects values based upon the local gradient, so it is normal for it to overshoot the peak and undershoot the smallest value.
  댓글 수: 3
Walter Roberson
Walter Roberson 2019년 10월 27일
newM = imresize(M, [70 70], 'bilinear');
The default is bicubic, which uses a 4 x 4 neighbourhood.
AniCnx
AniCnx 2019년 10월 27일
ok. I got it. it's about the number of the interval. Thanks for your comments.

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

추가 답변 (0개)

카테고리

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

Community Treasure Hunt

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

Start Hunting!

Translated by