Home > manopt > autodiff > functions_AD > ctransp.m

ctransp

PURPOSE ^

Computes the conjugate-transpose of X

SYNOPSIS ^

function Xtransp = ctransp(X)

DESCRIPTION ^

 Computes the conjugate-transpose of X

 function Xtransp = ctransp(X)

 This function can be seen as the operator ' but is compatible with
 both dlarrays and structs with fields real and iamg.

 See also: manoptADhelp

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:

SOURCE CODE ^

0001 function Xtransp = ctransp(X)
0002 % Computes the conjugate-transpose of X
0003 %
0004 % function Xtransp = ctransp(X)
0005 %
0006 % This function can be seen as the operator ' but is compatible with
0007 % both dlarrays and structs with fields real and iamg.
0008 %
0009 % See also: manoptADhelp
0010 
0011 % This file is part of Manopt: www.manopt.org.
0012 % Original author: Xiaowen Jiang, July. 31, 2021.
0013 % Contributors: Nicolas Boumal
0014 % Change log:
0015 
0016     if iscstruct(X)
0017         Xreal = X.real;
0018         Ximag = X.imag;
0019         Xtransp.real = Xreal';
0020         Xtransp.imag = -Ximag';
0021     elseif isnumeric(X)
0022         Xtransp = X';
0023     else
0024         ME = MException('ctransp:inputError', ...
0025                         'Input does not have the expected format.');
0026         throw(ME);
0027     end
0028 
0029 end

Generated on Fri 30-Sep-2022 13:18:25 by m2html © 2005