From 09be021dcd75fd0382ae43eeebf5ac37caf3fb65 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Villemot?= Date: Wed, 22 Jan 2020 18:02:11 +0100 Subject: [PATCH] Add license header for allVL1.m Ref. #1689 --- license.txt | 4 ++++ matlab/allVL1.m | 26 ++++++++++++++++++++++++++ 2 files changed, 30 insertions(+) diff --git a/license.txt b/license.txt index 1cc2ab8da..4b4594636 100644 --- a/license.txt +++ b/license.txt @@ -99,6 +99,10 @@ Copyright: 1997 Tom Minka 2019 Dynare Team License: GPL-3+ +Files: matlab/allVL1.m +Copyright: 2009 Bruno Luong +License: BSD-2-clause + Files: matlab/gsa/Morris_Measure_Groups.m matlab/gsa/Sampling_Function_2.m Copyright: 2005 European Commission diff --git a/matlab/allVL1.m b/matlab/allVL1.m index 3219ba1b7..b6a079503 100644 --- a/matlab/allVL1.m +++ b/matlab/allVL1.m @@ -37,6 +37,32 @@ function v = allVL1(n, L1, L1ops, MaxNbSol) % 1.3, 16/Sep/2009: Correct bug for number of solution % 1.4, 18/Dec/2010: + non-recursive engine +% Retrieved from https://www.mathworks.com/matlabcentral/fileexchange/17818-all-permutations-of-integers-with-sum-criteria + +% Copyright (c) 2009 Bruno Luong +% +% Redistribution and use in source and binary forms, with or without +% modification, are permitted provided that the following conditions are +% met: +% +% * Redistributions of source code must retain the above copyright +% notice, this list of conditions and the following disclaimer. +% * Redistributions in binary form must reproduce the above copyright +% notice, this list of conditions and the following disclaimer in +% the documentation and/or other materials provided with the distribution +% +% THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +% AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +% IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +% ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE +% LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR +% CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF +% SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +% INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN +% CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) +% ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE +% POSSIBILITY OF SUCH DAMAGE. + global MaxCounter; if nargin<3 || isempty(L1ops)