GNU Octave
3.8.0
A high-level interpreted language, primarily intended for numerical computations, mostly compatible with Matlab
Main Page
Namespaces
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Friends
Macros
Pages
liboctave
numeric
oct-norm.h
Go to the documentation of this file.
1
/*
2
3
Copyright (C) 2008-2013 VZLU Prague, a.s.
4
5
This file is part of Octave.
6
7
Octave is free software; you can redistribute it and/or modify it
8
under the terms of the GNU General Public License as published by the
9
Free Software Foundation; either version 3 of the License, or (at your
10
option) any later version.
11
12
Octave is distributed in the hope that it will be useful, but WITHOUT
13
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
14
FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
15
for more details.
16
17
You should have received a copy of the GNU General Public License
18
along with Octave; see the file COPYING. If not, see
19
<http://www.gnu.org/licenses/>.
20
21
*/
22
23
// author: Jaroslav Hajek <highegg@gmail.com>
24
25
#if !defined (octave_oct_norm_h)
26
#define octave_oct_norm_h 1
27
28
#include "
oct-cmplx.h
"
29
30
#define DECLARE_XNORM_FUNCS(PREFIX, RTYPE) \
31
class PREFIX##Matrix; \
32
class PREFIX##ColumnVector; \
33
class PREFIX##RowVector; \
34
\
35
extern OCTAVE_API RTYPE xnorm (const PREFIX##ColumnVector&, RTYPE p = 2); \
36
extern OCTAVE_API RTYPE xnorm (const PREFIX##RowVector&, RTYPE p = 2); \
37
extern OCTAVE_API RTYPE xnorm (const PREFIX##Matrix&, RTYPE p = 2); \
38
extern OCTAVE_API RTYPE xfrobnorm (const PREFIX##Matrix&);
39
40
DECLARE_XNORM_FUNCS
(,
double
)
41
DECLARE_XNORM_FUNCS
(
Complex
,
double
)
42
DECLARE_XNORM_FUNCS
(Float,
float
)
43
DECLARE_XNORM_FUNCS
(
FloatComplex
,
float
)
44
45
DECLARE_XNORM_FUNCS
(
Sparse
,
double
)
46
DECLARE_XNORM_FUNCS
(SparseComplex,
double
)
47
48
#define DECLARE_COLROW_NORM_FUNCS(PREFIX, RPREFIX, RTYPE) \
49
extern OCTAVE_API RPREFIX##RowVector xcolnorms (const PREFIX##Matrix&, RTYPE p = 2); \
50
extern OCTAVE_API RPREFIX##ColumnVector xrownorms (const PREFIX##Matrix&, RTYPE p = 2); \
51
52
DECLARE_COLROW_NORM_FUNCS
(, ,
double
)
53
DECLARE_COLROW_NORM_FUNCS
(Complex, ,
double
)
54
DECLARE_COLROW_NORM_FUNCS
(Float, Float,
float
)
55
DECLARE_COLROW_NORM_FUNCS
(FloatComplex, Float,
float
)
56
57
DECLARE_COLROW_NORM_FUNCS
(Sparse, ,
double
)
58
DECLARE_COLROW_NORM_FUNCS
(SparseComplex, ,
double
)
59
60
#endif
Generated on Mon Dec 30 2013 03:04:50 for GNU Octave by
1.8.1.2