Mercurial > repos > public > sbplib_julia
comparison Grids/src/AbstractGrid.jl @ 225:3ab0c61f1367 boundary_conditions
Merge in package_refactor
author | Jonatan Werpers <jonatan@werpers.com> |
---|---|
date | Wed, 26 Jun 2019 14:02:28 +0200 |
parents | b3506cfbb9d8 |
children |
comparison
equal
deleted
inserted
replaced
210:2aa33d0eef90 | 225:3ab0c61f1367 |
---|---|
1 """ | |
2 AbstractGrid | |
3 | |
4 Should implement | |
5 dimension(grid::AbstractGrid) | |
6 points(grid::AbstractGrid) | |
7 | |
8 """ | |
9 abstract type AbstractGrid end | |
10 | |
11 function dimension end | |
12 function points end | |
13 export dimension, points | |
14 | |
15 """ | |
16 evalOn(g::AbstractGrid, f::Function) | |
17 | |
18 Evaluate function f on the grid g | |
19 """ | |
20 function evalOn(g::AbstractGrid, f::Function) | |
21 F(x) = f(x...) | |
22 return F.(points(g)) | |
23 end | |
24 export evalOn |