Skip to content

Instantly share code, notes, and snippets.

@moble
Created May 6, 2024 17:45
Show Gist options
  • Save moble/5fb4d89c2d3d04d065af85104c1c7d87 to your computer and use it in GitHub Desktop.
Save moble/5fb4d89c2d3d04d065af85104c1c7d87 to your computer and use it in GitHub Desktop.
@threads for j ∈ eachindex(𝒯.R)
Rⱼ = 𝒯.R[j]
αⱼ = real(𝒯.α[j])
ð̄²α = real(𝒯.ð̄²α[j])
κ⁻¹ = γ * (1 - v⃗ ⋅ Rⱼ(𝐤))
spline = @view 𝒯.splines[:, :, j]
guess = firstindex(𝒯.u)
for (i, u′) ∈ enumerate(𝒯.u′)
u = κ⁻¹ * u′ + αⱼ
d, guess = interpolate(𝒯.u, 𝒯.h, spline, u, guess)
𝒯.d′[j,i] = κ⁻¹ * (d - ð̄²α)
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment