필터 지우기
필터 지우기

Writing a function for an interpolation method

조회 수: 1 (최근 30일)
Meghan
Meghan 2017년 1월 19일
댓글: Meghan 2017년 1월 19일
Hello all
I wonder if someone could help me. I've been writing a function to use a certain type of interpolation method. The 2D section of it works, however I'm having a problem with the 3D part of it. My supervisor has also edited it and we're still getting an error. I've attached the function and my test script. The error we keep getting is:
Output argument "output" (and maybe others) not assigned during call to "interp_azonal3Dv2".
Error in test (line 55)
[vel_test] =interp_azonal3Dv2(x,y,sigloc,lvls,tri,vel); % 6 variables
Any help is much appreciated :)
P.s. you won't be able to run the function because it calls on data that I can't post on this website.
  댓글 수: 7
Andreas Brinch Nielsen
Andreas Brinch Nielsen 2017년 1월 19일
Now it is not set when the following line equals to true:
if length(lvls)==kbm-1; %!da
Again, auto indent your whole script. This helps you finding these errors. Also, a simple line by line debugging would also show you exactly what is happening.
Meghan
Meghan 2017년 1월 19일
Thanks for the help. I actually changed a few things around and now it works :)
Such effort for such tiny errors!

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

답변 (0개)

카테고리

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

Community Treasure Hunt

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

Start Hunting!

Translated by