comparison diffOp.jl @ 85:8d505e9bc715 cell_based_test

Merge with default
author Jonatan Werpers <jonatan@werpers.com>
date Fri, 25 Jan 2019 15:26:47 +0100
parents b795ec7f9ca0 48079bd39969
children 93df72e2b135 9d53ecca34f7
comparison
equal deleted inserted replaced
83:b795ec7f9ca0 85:8d505e9bc715
45 u = zeros(eltype(v), size(v)) 45 u = zeros(eltype(v), size(v))
46 apply!(D,v,u) 46 apply!(D,v,u)
47 return u 47 return u
48 end 48 end
49 49
50 struct Laplace{Dim,T<:Real} <: DiffOp 50 struct Laplace{Dim,T<:Real,N,M,K} <: DiffOp
51 grid::Grid.EquidistantGrid{Dim,T} 51 grid::Grid.EquidistantGrid{Dim,T}
52 a::T 52 a::T
53 op::D2{Float64} 53 op::D2{Float64,N,M,K}
54 end 54 end
55 55
56 # u = L*v 56 # u = L*v
57 function apply(L::Laplace{1}, v::AbstractVector, i::Int) 57 function apply(L::Laplace{1}, v::AbstractVector, i::Int)
58 h = Grid.spacings(L.grid)[1] 58 h = Grid.spacings(L.grid)[1]