Interpolate 2D evenly spaced points, taking into account the borders
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=R8), | intent(in), | dimension(bgro%lb1:bgro%ub1, bgro%lb2:bgro%ub2) | :: | tabgro |
tableau grossier départ |
|
type(tborne), | intent(in) | :: | bgro |
indices des tableaux |
||
real(kind=R8), | intent(out), | dimension(bfin%lb1:bfin%ub1, bfin%lb2:bfin%ub2) | :: | tabfin |
tableau résultant fin |
|
type(tborne), | intent(in) | :: | bfin |
indices des tableaux |
||
integer(kind=I4), | intent(in) | :: | ordre |
ordre de l’interpolation |
subroutine interp2D(tabgro, bgro, tabfin, bfin, ordre) !! Interpolate 2D evenly spaced points, taking into account the borders implicit none type(tborne), intent(in ) :: bfin, bgro !! *indices des tableaux* integer(kind=I4), intent(in ) :: ordre !! *ordre de l'interpolation* real(kind=R8), intent(in ), dimension(bgro%lb1:bgro%ub1, bgro%lb2:bgro%ub2) :: tabgro !! *tableau grossier départ* real(kind=R8), intent(out), dimension(bfin%lb1:bfin%ub1, bfin%lb2:bfin%ub2) :: tabfin !! *tableau résultant fin* integer(kind=I4) :: ii, j real(kind=R8), dimension(bgro%lb1:bgro%ub1, bfin%lb2:2*bgro%ub2) :: tab_tmp do ii = bgro%lb1, bgro%ub1 call interp1D( tabgros = tabgro(ii,:), & ! lb_gros = bgro%lb2, & ! tabfin = tab_tmp(ii,:), & ! lb_fin = bfin%lb2, & ! ub_gros = bgro%ub2, & ! ordre = ordre) ! enddo do j = bfin%lb2, 2*bgro%ub2 call interp1D( tabgros = tab_tmp(:,j), & ! lb_gros = bgro%lb1, & ! tabfin = tabfin(:,j), & ! lb_fin = bfin%lb1, & ! ub_gros = bgro%ub1, & ! ordre = ordre ) ! enddo return endsubroutine interp2D