summaryrefslogtreecommitdiffstats
path: root/matlab/tools/linspace2.m
diff options
context:
space:
mode:
Diffstat (limited to 'matlab/tools/linspace2.m')
-rw-r--r--matlab/tools/linspace2.m25
1 files changed, 25 insertions, 0 deletions
diff --git a/matlab/tools/linspace2.m b/matlab/tools/linspace2.m
new file mode 100644
index 0000000..2787fd9
--- /dev/null
+++ b/matlab/tools/linspace2.m
@@ -0,0 +1,25 @@
+function out = linspace2(a,b,c)
+
+%------------------------------------------------------------------------
+% out = linspace2(a,b,c)
+%
+% Generates linearly spaced vectors
+%
+% a: lower limit.
+% b: upper limit (exclusive).
+% c: number of elements.
+% out: linearly spaced vector.
+%------------------------------------------------------------------------
+%------------------------------------------------------------------------
+% This file is part of the
+% All Scale Tomographic Reconstruction Antwerp Toolbox ("ASTRA-Toolbox")
+%
+% Copyright: iMinds-Vision Lab, University of Antwerp
+% License: Open Source under GPLv3
+% Contact: mailto:astra@ua.ac.be
+% Website: http://astra.ua.ac.be
+%------------------------------------------------------------------------
+% $Id$
+
+out = linspace(a,b,c+1);
+out = out(1:end-1);