필터 지우기
필터 지우기

intarpulation on a sin wall

조회 수: 3 (최근 30일)
ran
ran 2024년 6월 7일
편집: ran 2024년 6월 8일
I have a large data set and want to interpolate it; I am using this code to do so. Is there bater way or method to do so? My wave amplitude is 3.6mm, and length is 28.8 mm, which is very short. Any idea? i see some people segest Karnels intepulation? (i dont see a point to uplode any data it really simpal 2D data of velocity in a wavy tunnel, just want any good idea of intarpulations). i have large amount of waves and measurments so i need to be fast as well.
F_u = scatteredInterpolant(section_x(:), section_y(:), section_u(:), 'linear', 'none');
Unrecognized function or variable 'section_x'.
interp_u = F_u(interp_x, interp_y);
F_v = scatteredInterpolant(section_x(:), section_y(:), section_v(:), 'linear', 'none');
interp_v = F_v(interp_x, interp_y);
F_T = scatteredInterpolant(section_x(:), section_y(:), section_T(:), 'linear', 'none');
interp_T = F_T(interp_x, interp_y);
F_P = scatteredInterpolant(section_x(:), section_y(:), section_P(:), 'linear', 'none');
interp_P = F_P(interp_x, interp_y);
F_Tw = scatteredInterpolant(section_x(:), section_y(:), section_Tw(:), 'linear', 'none');
interp_Tw = F_Tw(interp_x, interp_y);

채택된 답변

Steven Lord
Steven Lord 2024년 6월 7일
Just based on the code you showed, the main suggestion I have is not to recreate the scatteredInterpolant object every time. Just change the Values property to each of your different data sets. That way the effort to create the internal information necessary to perform the interpolation based on the coordinates (which are the same each time) doesn't need to be repeated. See the "Replacement of Sample Values" example on that documentation page.
Alternately if you're using release R2023b or later, you could use the functionality introduced in that release to "Interpolate multiple data sets simultaneously" (see the Version History section of the documentation page.)
  댓글 수: 1
ran
ran 2024년 6월 7일
편집: ran 2024년 6월 8일
thx i have a problem with the code now it super fast, the problem is that i have larg diclanation wich crate a wired steps on the wavy wall and i try to fined out a way to smoth it. i try everithing but i have a wavy wall that the non of matlab intarpulation data cent andel and i cent fine the solution anywere

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

추가 답변 (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