comparison src/SbpOperators/boundaryops/normal_derivative.jl @ 1101:1e8270c18edb feature/lazy_tensors/pretty_printing

Merge default
author Jonatan Werpers <jonatan@werpers.com>
date Thu, 12 May 2022 21:52:47 +0200
parents 7fc8df5157a7
children 157a78959e5d
comparison
equal deleted inserted replaced
1014:67969bd7e642 1101:1e8270c18edb
8 On a one-dimensional `grid`, `d` is a `BoundaryOperator`. On a multi-dimensional `grid`, `d` is the inflation of 8 On a one-dimensional `grid`, `d` is a `BoundaryOperator`. On a multi-dimensional `grid`, `d` is the inflation of
9 a `BoundaryOperator`. 9 a `BoundaryOperator`.
10 10
11 See also: [`boundary_operator`](@ref). 11 See also: [`boundary_operator`](@ref).
12 """ 12 """
13 function normal_derivative(grid, closure_stencil::Stencil, boundary) 13 function normal_derivative(grid, closure_stencil, boundary)
14 direction = dim(boundary) 14 direction = dim(boundary)
15 h_inv = inverse_spacing(grid)[direction] 15 h_inv = inverse_spacing(grid)[direction]
16 return SbpOperators.boundary_operator(grid, scale(closure_stencil,h_inv), boundary) 16 return SbpOperators.boundary_operator(grid, scale(closure_stencil,h_inv), boundary)
17 end 17 end
18 18
19 """ 19 """
20 normal_derivative(grid, stencil_set, boundary) 20 normal_derivative(grid, stencil_set, boundary)
21 21
22 Creates a `normal_derivative` operator on `grid` given a parsed TOML 22 Creates a `normal_derivative` operator on `grid` given a `stencil_set`.
23 `stencil_set`.
24 """ 23 """
25 normal_derivative(grid, stencil_set, boundary) = normal_derivative(grid, parse_stencil(stencil_set["d1"]["closure"]), boundary) 24 normal_derivative(grid, stencil_set::StencilSet, boundary) = normal_derivative(grid, parse_stencil(stencil_set["d1"]["closure"]), boundary)