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
array
fCColVector.h
Go to the documentation of this file.
1
/*
2
3
Copyright (C) 1994-2013 John W. Eaton
4
Copyright (C) 2010 VZLU Prague
5
6
This file is part of Octave.
7
8
Octave is free software; you can redistribute it and/or modify it
9
under the terms of the GNU General Public License as published by the
10
Free Software Foundation; either version 3 of the License, or (at your
11
option) any later version.
12
13
Octave is distributed in the hope that it will be useful, but WITHOUT
14
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
15
FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
16
for more details.
17
18
You should have received a copy of the GNU General Public License
19
along with Octave; see the file COPYING. If not, see
20
<http://www.gnu.org/licenses/>.
21
22
*/
23
24
#if !defined (octave_fCColVector_h)
25
#define octave_fCColVector_h 1
26
27
#include "
MArray.h
"
28
29
#include "
mx-defs.h
"
30
31
class
32
OCTAVE_API
33
FloatComplexColumnVector
:
public
MArray<FloatComplex>
34
{
35
friend
class
FloatComplexMatrix
;
36
friend
class
FloatComplexRowVector
;
37
38
public
:
39
40
FloatComplexColumnVector
(
void
)
41
:
MArray
<
FloatComplex
> (
dim_vector
(0, 1)) { }
42
43
explicit
FloatComplexColumnVector
(
octave_idx_type
n)
44
:
MArray
<
FloatComplex
> (
dim_vector
(n, 1)) { }
45
46
explicit
FloatComplexColumnVector
(
const
dim_vector
& dv)
47
:
MArray
<
FloatComplex
> (dv.
as_column
()) { }
48
49
FloatComplexColumnVector
(
octave_idx_type
n,
const
FloatComplex
& val)
50
:
MArray
<
FloatComplex
> (
dim_vector
(n, 1), val) { }
51
52
FloatComplexColumnVector
(
const
FloatComplexColumnVector
& a)
53
:
MArray
<
FloatComplex
> (a) { }
54
55
FloatComplexColumnVector
(
const
MArray<FloatComplex>
& a)
56
:
MArray
<
FloatComplex
> (a.
as_column
()) { }
57
58
FloatComplexColumnVector
(
const
Array<FloatComplex>
& a)
59
:
MArray
<
FloatComplex
> (a.
as_column
()) { }
60
61
explicit
FloatComplexColumnVector
(
const
FloatColumnVector
& a);
62
63
FloatComplexColumnVector
&
operator =
(
const
FloatComplexColumnVector
& a)
64
{
65
MArray<FloatComplex>::operator =
(a);
66
return
*
this
;
67
}
68
69
bool
operator ==
(
const
FloatComplexColumnVector
& a)
const
;
70
bool
operator !=
(
const
FloatComplexColumnVector
& a)
const
;
71
72
// destructive insert/delete/reorder operations
73
74
FloatComplexColumnVector
&
insert
(
const
FloatColumnVector
& a,
75
octave_idx_type
r);
76
FloatComplexColumnVector
&
insert
(
const
FloatComplexColumnVector
& a,
77
octave_idx_type
r);
78
79
FloatComplexColumnVector
&
fill
(
float
val);
80
FloatComplexColumnVector
&
fill
(
const
FloatComplex
& val);
81
FloatComplexColumnVector
&
fill
(
float
val,
82
octave_idx_type
r1
,
octave_idx_type
r2
);
83
FloatComplexColumnVector
&
fill
(
const
FloatComplex
& val,
84
octave_idx_type
r1
,
octave_idx_type
r2
);
85
86
FloatComplexColumnVector
stack (
const
FloatColumnVector
& a)
const
;
87
FloatComplexColumnVector
stack (
const
FloatComplexColumnVector
& a)
const
;
88
89
FloatComplexRowVector
hermitian
(
void
)
const
;
90
FloatComplexRowVector
transpose
(
void
)
const
;
91
92
friend
OCTAVE_API
FloatComplexColumnVector
93
conj
(
const
FloatComplexColumnVector
& a);
94
95
// resize is the destructive equivalent for this one
96
97
FloatComplexColumnVector
extract
(
octave_idx_type
r1
,
98
octave_idx_type
r2
)
const
;
99
100
FloatComplexColumnVector
extract_n
(
octave_idx_type
r1
,
101
octave_idx_type
n)
const
;
102
103
// column vector by column vector -> column vector operations
104
105
FloatComplexColumnVector
&
operator +=
(
const
FloatColumnVector
& a);
106
FloatComplexColumnVector
&
operator -=
(
const
FloatColumnVector
& a);
107
108
// matrix by column vector -> column vector operations
109
110
friend
OCTAVE_API
FloatComplexColumnVector
111
operator *
(
const
FloatComplexMatrix
& a,
const
FloatColumnVector
& b);
112
113
friend
OCTAVE_API
FloatComplexColumnVector
114
operator *
(
const
FloatComplexMatrix
& a,
const
FloatComplexColumnVector
& b);
115
116
// matrix by column vector -> column vector operations
117
118
friend
OCTAVE_API
FloatComplexColumnVector
119
operator *
(
const
FloatMatrix
& a,
const
FloatComplexColumnVector
& b);
120
121
// diagonal matrix by column vector -> column vector operations
122
123
friend
OCTAVE_API
FloatComplexColumnVector
124
operator *
(
const
FloatDiagMatrix
& a,
const
FloatComplexColumnVector
& b);
125
126
friend
OCTAVE_API
FloatComplexColumnVector
127
operator *
(
const
FloatComplexDiagMatrix
& a,
const
ColumnVector
& b);
128
129
friend
OCTAVE_API
FloatComplexColumnVector
130
operator *
(
const
FloatComplexDiagMatrix
& a,
const
FloatComplexColumnVector
& b);
131
132
// other operations
133
134
FloatComplex
min
(
void
)
const
;
135
FloatComplex
max
(
void
)
const
;
136
137
FloatColumnVector
abs
(
void
)
const
;
138
139
// i/o
140
141
friend
OCTAVE_API std::ostream&
142
operator <<
(std::ostream& os,
const
FloatComplexColumnVector
& a);
143
friend
OCTAVE_API std::istream&
operator >>
(std::istream& is,
144
FloatComplexColumnVector
& a);
145
146
void
resize
(
octave_idx_type
n,
const
FloatComplex
& rfv =
FloatComplex
(0))
147
{
148
Array<FloatComplex>::resize
(
dim_vector
(n, 1), rfv);
149
}
150
151
void
clear
(
octave_idx_type
n)
152
{
Array<FloatComplex>::clear
(n, 1); }
153
154
};
155
156
MARRAY_FORWARD_DEFS
(
MArray
,
FloatComplexColumnVector
,
FloatComplex
)
157
158
#endif
Generated on Mon Dec 30 2013 03:04:42 for GNU Octave by
1.8.1.2