comparison +noname/Discretization.m @ 0:48b6fb693025

Initial commit.
author Jonatan Werpers <jonatan@werpers.com>
date Thu, 17 Sep 2015 10:12:50 +0200
parents
children bce9e28c1e26
comparison
equal deleted inserted replaced
-1:000000000000 0:48b6fb693025
1 classdef Discretization < handle
2 properties (Abstract)
3 name %Short description
4 description %Longer description
5 order %Order of accuracy
6 end
7
8 methods (Abstract)
9 % Prints some info about the discretisation
10 printInfo()
11
12 % Return the number of DOF
13 n = size(obj)
14
15 % Returns a timestepper for integrating the discretisation in time
16 % method is a string that states which timestepping method should be used.
17 % The implementation should switch on the string and deliver
18 % the appropriate timestepper. It should also provide a default value.
19 % time_align is a time that the timesteps should align with so that for some
20 % integer number of timesteps we end up exactly on time_align
21 ts = getTimestepper(obj,method,time_align) %% ???
22
23 % Sets up movie recording to a given file.
24 % saveFrame is a function_handle with no inputs that records the current state
25 % as a frame in the moive.
26 saveFrame = setupMov(obj, file)
27
28 % Sets up a plot of the discretisation
29 % update is a function_handle accepting a timestepper that updates the plot to the
30 % state of the timestepper
31 [update,hand] = setupPlot(obj)
32
33 end
34
35 methods(Abstract,Static)
36 % Compare two functions u and v in the discrete l2 norm.
37 e = compareSolutions(u, v)
38
39 % Compare the functions u to the analytical function g in the discrete l2 norm.
40 e = compareSolutionsAnalytical(u, g)
41 end
42 end