1function C = angle (G) 2%ANGLE phase angle. 3% C = angle (G) is the phase angle of each entry of G. 4% 5% See also GrB/abs. 6 7% SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved. 8% SPDX-License-Identifier: GPL-3.0-or-later 9 10G = G.opaque ; 11[m, n, type] = gbsize (G) ; 12 13if (contains (type, 'complex')) 14 C = GrB (gbapply ('carg', G)) ; 15else 16 % C is all zero 17 C = GrB (gbnew (m, n, type)) ; 18end 19 20