hide long namesshow long names
hide short namesshow short names
Integer type:  int32  int64  nag_int  show int32  show int32  show int64  show int64  show nag_int  show nag_int

PDF version (NAG web site, 64-bit version, 64-bit version)
Chapter Contents
Chapter Introduction
NAG Toolbox

NAG Toolbox: nag_sum_withdraw_conjugate_hermitian_mult_rfmt (c06gq)

 Contents

    1  Purpose
    2  Syntax
    7  Accuracy
    9  Example

Purpose

nag_sum_conjugate_hermitian_mult_rfmt (c06gq) forms the complex conjugates of m Hermitian sequences, each containing n data values.
Note: this function is scheduled to be withdrawn, please see c06gq in Advice on Replacement Calls for Withdrawn/Superseded Routines..

Syntax

[x, ifail] = c06gq(m, n, x)
[x, ifail] = nag_sum_withdraw_conjugate_hermitian_mult_rfmt(m, n, x)

Description

This is a utility function for use in conjunction with nag_sum_fft_real_1d_multi_rfmt (c06fp) and nag_sum_fft_hermitian_1d_multi_rfmt (c06fq) to calculate inverse discrete Fourier transforms (see the C06 Chapter Introduction).

References

None.

Parameters

Compulsory Input Parameters

1:     m int64int32nag_int scalar
m, the number of Hermitian sequences to be conjugated.
Constraint: m1.
2:     n int64int32nag_int scalar
n, the number of data values in each Hermitian sequence.
Constraint: n1.
3:     x m×n – double array
The data must be stored in x as if in a two-dimensional array of dimension 1:m,0:n-1; each of the m sequences is stored in a row of the array in Hermitian form. If the n data values zjp are written as xjp + i yjp, then for 0 j n/2, xjp is contained in xpj, and for 1 j n-1/2, yjp is contained in xpn-j. (See also Real transforms in the C06 Chapter Introduction.)

Optional Input Parameters

None.

Output Parameters

1:     x m×n – double array
The imaginary parts yjp are negated. The real parts xjp are not referenced.
2:     ifail int64int32nag_int scalar
ifail=0 unless the function detects an error (see Error Indicators and Warnings).

Error Indicators and Warnings

Errors or warnings detected by the function:
   ifail=1
On entry,m<1.
   ifail=2
On entry,n<1.
   ifail=-99
An unexpected error has been triggered by this routine. Please contact NAG.
   ifail=-399
Your licence key may have expired or may not have been installed correctly.
   ifail=-999
Dynamic memory allocation failed.

Accuracy

Exact.

Further Comments

None.

Example

This example reads in sequences of real data values which are assumed to be Hermitian sequences of complex data stored in Hermitian form. The sequences are expanded into full complex form using nag_sum_convert_herm2complex_sep (c06gs) and printed. The sequences are then conjugated (using nag_sum_conjugate_hermitian_mult_rfmt (c06gq)) and the conjugated sequences are expanded into complex form using nag_sum_convert_herm2complex_sep (c06gs) and printed out.
function c06gq_example


fprintf('c06gq example results\n\n');

% 3 Hermitian sequences stored as rows in compact form
m = int64(3);
n = int64(6);
x = [0.3854  0.6772  0.1138  0.6751  0.6362  0.1424;
     0.5417  0.2983  0.1181  0.7255  0.8638  0.8723;
     0.9172  0.0644  0.6037  0.6430  0.0428  0.4815];

disp('Original values in compact Hermitian form:');
disp(x);

% Put x in full complex form
[u, v, ifail] = c06gs(m, n, x);

nd = [m,n];
z = reshape(u + i*v,nd);
disp(' ');
title = 'Original data in full complex form';
[ifail] = x04da('General','Non-unit', z, title);

% Conjugate values
[xc, ifail] = c06gq(m, n, x);
disp(' ');
disp('Conjugated data in compact Hermitian form:');
disp(xc);

[u, v, ifail] = c06gs(m, n, xc);
zc = reshape(u + i*v,nd);
disp(' ');
title = 'Conjugated data in full complex form';
[ifail] = x04da('General','Non-unit', zc, title);


c06gq example results

Original values in compact Hermitian form:
    0.3854    0.6772    0.1138    0.6751    0.6362    0.1424
    0.5417    0.2983    0.1181    0.7255    0.8638    0.8723
    0.9172    0.0644    0.6037    0.6430    0.0428    0.4815

 
 Original data in full complex form
          1       2       3       4       5       6
 1   0.3854  0.6772  0.1138  0.6751  0.1138  0.6772
     0.0000  0.1424  0.6362  0.0000 -0.6362 -0.1424

 2   0.5417  0.2983  0.1181  0.7255  0.1181  0.2983
     0.0000  0.8723  0.8638  0.0000 -0.8638 -0.8723

 3   0.9172  0.0644  0.6037  0.6430  0.6037  0.0644
     0.0000  0.4815  0.0428  0.0000 -0.0428 -0.4815
 
Conjugated data in compact Hermitian form:
    0.3854    0.6772    0.1138    0.6751   -0.6362   -0.1424
    0.5417    0.2983    0.1181    0.7255   -0.8638   -0.8723
    0.9172    0.0644    0.6037    0.6430   -0.0428   -0.4815

 
 Conjugated data in full complex form
          1       2       3       4       5       6
 1   0.3854  0.6772  0.1138  0.6751  0.1138  0.6772
     0.0000 -0.1424 -0.6362  0.0000  0.6362  0.1424

 2   0.5417  0.2983  0.1181  0.7255  0.1181  0.2983
     0.0000 -0.8723 -0.8638  0.0000  0.8638  0.8723

 3   0.9172  0.0644  0.6037  0.6430  0.6037  0.0644
     0.0000 -0.4815 -0.0428  0.0000  0.0428  0.4815

PDF version (NAG web site, 64-bit version, 64-bit version)
Chapter Contents
Chapter Introduction
NAG Toolbox

© The Numerical Algorithms Group Ltd, Oxford, UK. 2009–2015