@@ -324,6 +324,7 @@ function UpwindDifference{N}(derivative_order::Int,
324324 )
325325end
326326
327+
327328# TODO implement the non-uniform grid
328329function UpwindDifference {N} (derivative_order:: Int ,
329330 approximation_order:: Int , dx:: AbstractVector{T} ,
@@ -407,20 +408,20 @@ function CompleteUpwindDifference(derivative_order::Int,
407408 high_boundary_x = 0.0 : - 1.0 : - (boundary_stencil_length- 1.0 )
408409 R_boundary_deriv_spots = 0.0 : - 1.0 : - (boundary_stencil_length- 2.0 )
409410 _high_boundary_coefs = SVector{boundary_stencil_length, T}[convert (SVector{boundary_stencil_length, T}, ((- 1 / dx)^ derivative_order) * calculate_weights (derivative_order, oneunit (T)* x0, high_boundary_x)) for x0 in R_boundary_deriv_spots]
410- high_boundary_coefs = convert (SVector{boundary_point_count + offside},_high_boundary_coefs)
411+ high_boundary_coefs = convert (SVector{boundary_point_count + offside},reverse ( _high_boundary_coefs) )
411412
412- coefficients = fill! ( Vector {T} (undef,len), 0 )
413+ coefficients = nothing
413414
414415
415- DerivativeOperator{T,N ,true ,T,typeof (stencil_coefs),
416- typeof (low_boundary_coefs),typeof (high_boundary_coefs),Vector{T} ,
417- typeof (coeff_func) }(
418- derivative_order, approximation_order, dx, len , stencil_length,
416+ DerivativeOperator{T,Nothing ,true ,T,typeof (stencil_coefs),
417+ typeof (low_boundary_coefs),typeof (high_boundary_coefs),Nothing ,
418+ Nothing }(
419+ derivative_order, approximation_order, dx, 1 , stencil_length,
419420 stencil_coefs,
420421 boundary_stencil_length,
421422 boundary_point_count,
422423 low_boundary_coefs,
423- high_boundary_coefs,offside,coefficients,coeff_func
424+ high_boundary_coefs,offside,coefficients,nothing
424425 )
425426end
426427
0 commit comments