LINE Solver
MATLAB API documentation
Loading...
Searching...
No Matches
BuToolsInit.m
1function BuToolsInit (verbose, checkInput, checkPrecision)
2
3 fname = mfilename('fullpath');
4 [pathstr, ~, ~] = fileparts(fname);
5
6 disp('<strong>Butools V2.0</strong>')
7
8 packages = {'utils', 'mc', 'moments', 'reptrans', 'trace', 'ph', 'dph', 'map', 'dmap', 'mam', 'queues', 'fitting'};
9
10 pkgpath = {pathstr};
11 for p=1:length(packages)
12 pkgpath{p+1} = fullfile(pathstr,packages{p});
13 end
14 addpath(strjoin(pkgpath,':'));
15
16 fprintf('Packages loaded: ');
17 for p=1:length(packages)
18 fprintf(packages{p});
19 if p<length(packages)
20 fprintf(', ');
21 else
22 fprintf('\n');
23 end
24 end
25
26 global BuToolsVerbose;
27 global BuToolsCheckInput;
28 global BuToolsCheckPrecision;
29
30 if exist('verbose','var')
31 BuToolsVerbose = verbose;
32 else
33 BuToolsVerbose = false;
34 end
35
36 if exist('checkInput','var')
37 BuToolsCheckInput = checkInput;
38 else
39 BuToolsCheckInput = true;
40 end
41
42 if exist('checkPrecision','var')
43 BuToolsCheckPrecision = checkPrecision;
44 else
45 BuToolsCheckPrecision = 1e-12;
46 end
47
48 fprintf('Global variables: BuToolsVerbose = %d, BuToolsCheckInput = %d, BuToolsCheckPrecision = %g\n',BuToolsVerbose,BuToolsCheckInput,BuToolsCheckPrecision);
49end
50