Mercurial > repos > public > sbplib_julia
view plotDerivative.jl @ 45:56722ba36604
ass script that plots the derivative
author | Ylva Rydin <ylva.rydin@telia.com> |
---|---|
date | Thu, 10 Jan 2019 16:51:52 +0100 |
parents | |
children | 50c6c252d954 |
line wrap: on
line source
g = sbp.grid.EquidistantGrid(200,(0, 1)) op =sbp.readOperator("d2_4th.txt","h_4th.txt") Laplace = sbp.Laplace1D(g,1,op) init(x) = sin(x) v = sbp.grid.evalOn(g,init) u = zeros(length(v)) sbp.apply!(Laplace,u,v) @show u sbp.grid.plotgridfunction(g,u)