Implement bilinear interpolation

This commit is contained in:
robin
2024-04-22 00:21:11 +02:00
parent a123071fec
commit 51fe302920
12 changed files with 192 additions and 15 deletions

View File

@@ -12,3 +12,13 @@ void print3DMatrixSlice(const arr3d<double> &arr, int t) {
println("");
}
}
void print3DMatrixSlice(const arr3d<std::pair<double, double>> &arr, int t) {
for (int x = 0; x < arr.extent(1); x++) {
for (int y = 0; y < arr.extent(2); y++) {
auto [u,v] = arr[t,x,y];
print("({:>7.4f}, {:>7.4f}) ", u, v);
}
println("");
}
}