Skip to content

Commit

Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
clean up test
Browse files Browse the repository at this point in the history
rafaqz committed Dec 27, 2023
1 parent 2eb081a commit ff89cd9
Showing 1 changed file with 0 additions and 9 deletions.
9 changes: 0 additions & 9 deletions test/interpolations.jl
Original file line number Diff line number Diff line change
@@ -5,12 +5,3 @@ f((x1, x2)) = log(x1+x2)
A = f.(DimPoints((X(1:.1:10), Y(1:.5:20))))
to = rand(X(2:.3:7), Y(2:.3:17))
out = DimensionalData.interp(A; to)

A_x1 = 1:.1:10
A_x2 = 1:.5:20
f(x1, x2) = log(x1+x2)
A = [f(x1,x2) for x1 in A_x1, x2 in A_x2]
itp = interpolate(A, BSpline(Cubic(Line(OnGrid()))))
sitp = scale(itp, A_x1, A_x2)
sitp(5., 10.) # exactly log(5 + 10)
sitp([5.6, 5.2], [7.1, 7.1]) # approximately log(5.6 + 7.1)

0 comments on commit ff89cd9

Please sign in to comment.