changeset 854:18162a0a5bb5 feature/burgers1d

Merged branch with default for latest change set
author Vidar Stiernström <vidar.stiernstrom@it.uu.se>
date Fri, 12 Oct 2018 08:50:25 +0200
parents cda996e64925 (current diff) 006defd0247b (diff)
children a6f34de60044 037f203b9bf5
files
diffstat 3 files changed, 34 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/+scheme/bcSetup.m	Fri Oct 12 08:41:57 2018 +0200
+++ b/+scheme/bcSetup.m	Fri Oct 12 08:50:25 2018 +0200
@@ -28,14 +28,14 @@
         [localClosure, penalty] = diffOp.boundary_condition(bcs{i}.boundary, bcs{i}.type);
         closure = closure + localClosure;
 
-        [ok, isSym, data] = parseData(bcs{i}, penalty, diffOp.grid);
+        [ok, isSymbolic, data] = parseData(bcs{i}, penalty, diffOp.grid);
 
         if ~ok
             % There was no data
             continue
         end
 
-        if isSym
+        if isSymbolic
             symbolicData{end+1} = data;
         else
             gridData{end+1} = data;
@@ -85,8 +85,10 @@
     end
 end
 
-function [ok, isSym, dataStruct] = parseData(bc, penalty, grid)
+function [ok, isSymbolic, dataStruct] = parseData(bc, penalty, grid)
     if ~isfield(bc,'data') || isempty(bc.data)
+        isSymbolic = [];
+        dataStruct = struct();
         ok = false;
         return
     end
@@ -96,14 +98,14 @@
 
     if nArg > 1
         % Symbolic data
-        isSym = true;
+        isSymbolic = true;
         coord = grid.getBoundary(bc.boundary);
         dataStruct.penalty = penalty;
         dataStruct.func = bc.data;
         dataStruct.coords = num2cell(coord, 1);
     else
         % Grid data
-        isSym = false;
+        isSymbolic = false;
         dataStruct.penalty = penalty;
         dataStruct.func = bcs{i}.data;
     end
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/LICENSE.txt	Fri Oct 12 08:50:25 2018 +0200
@@ -0,0 +1,25 @@
+MIT License
+
+Copyright (c)
+2015-2018 Jonatan Werpers
+2015-2018 Martin Almquist
+2016-2018 Ylva Rydin
+2018 Vidar Stiernström
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+SOFTWARE.
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/README.md	Fri Oct 12 08:50:25 2018 +0200
@@ -0,0 +1,2 @@
+# SBPLIB
+sbplib is a library of primitives and help functions for working with summation-by-parts finite differences in Matlab. To use sbplib download the code and add the sbplib folder to the matlab path.