Mercurial > repos > public > sbplib
diff +multiblock/stitchSchemes.m @ 498:324c927d8b1d feature/quantumTriangles
chnaged sbp interfacein 1d among many things
author | Ylva Rydin <ylva.rydin@telia.com> |
---|---|
date | Fri, 03 Mar 2017 16:19:41 +0100 |
parents | 437fad4a47e1 |
children | dd3e9a0f5032 |
line wrap: on
line diff
--- a/+multiblock/stitchSchemes.m Sat Feb 25 12:44:01 2017 +0100 +++ b/+multiblock/stitchSchemes.m Fri Mar 03 16:19:41 2017 +0100 @@ -11,7 +11,7 @@ % Output parameters are cell arrays and cell matrices. % % Ex: [schms, D, H] = stitchSchemes(schmHand, order, schmParam, blocks, ms, conn, bound) -function [schms, D, H] = stitchSchemes(schmHand, order, schmParam, grids, conn, bound,timeDep) +function [schms, D, H,penalty] = stitchSchemes(schmHand, order, schmParam, grids, conn, bound,timeDep) default_arg('schmParam',[]); default_arg('timeDep','N'); n_blocks = numel(grids); @@ -52,7 +52,11 @@ % Differentiation terms D = cell(n_blocks,n_blocks); + penalty = cell(n_blocks,n_blocks); + + for i = 1:n_blocks + penalty{i,i}= @(t)0; D{i,i} = schms{i}.D; end @@ -104,8 +108,9 @@ continue end - [closure, ~] = schms{i}.boundary_condition(fn{j},bc{:}); + [closure, penaltyi] = schms{i}.boundary_condition(fn{j},bc{:}); D{i,i} =@(t) D{i,i}(t) + closure(t); + penalty{i,i} = @(t) penalty{i,i}(t) + penaltyi(t); end end