Mercurial > octave
diff src/OPERATORS/op-cs-cs.cc @ 7789:82be108cc558
First attempt at single precision tyeps
* * *
corrections to qrupdate single precision routines
* * *
prefer demotion to single over promotion to double
* * *
Add single precision support to log2 function
* * *
Trivial PROJECT file update
* * *
Cache optimized hermitian/transpose methods
* * *
Add tests for tranpose/hermitian and ChangeLog entry for new transpose code
author | David Bateman <dbateman@free.fr> |
---|---|
date | Sun, 27 Apr 2008 22:34:17 +0200 |
parents | a1dbe9d80eee |
children | 283989f2da9b |
line wrap: on
line diff
--- a/src/OPERATORS/op-cs-cs.cc Wed May 14 18:09:56 2008 +0200 +++ b/src/OPERATORS/op-cs-cs.cc Sun Apr 27 22:34:17 2008 +0200 @@ -30,6 +30,7 @@ #include "ov.h" #include "ov-complex.h" #include "ov-cx-mat.h" +#include "ov-flt-cx-mat.h" #include "ov-typeinfo.h" #include "ops.h" #include "xdiv.h" @@ -176,6 +177,13 @@ DEFNDCATOP_FN (cs_cs, complex, complex, complex_array, complex_array, concat) +CONVDECL (complex_to_float_complex) +{ + CAST_CONV_ARG (const octave_complex&); + + return new octave_float_complex_matrix (FloatComplexMatrix (1, 1, static_cast<FloatComplex>(v.complex_value ()))); +} + void install_cs_cs_ops (void) { @@ -210,6 +218,9 @@ INSTALL_CATOP (octave_complex, octave_complex, cs_cs); INSTALL_ASSIGNCONV (octave_complex, octave_complex, octave_complex_matrix); + + INSTALL_CONVOP (octave_complex, octave_float_complex_matrix, + complex_to_float_complex); } /*