Conjugate transpose: Difference between revisions

Content added Content deleted
(→‎{{header|REXX}}: added the REXX language. -- ~~~~)
Line 100: Line 100:


=={{header|C}}==
=={{header|C}}==
<lang c>
<lang c>/*28th August, 2012
/*28th August, 2012
Abhishek Ghosh
Abhishek Ghosh


Line 125: Line 124:
b.cols = a.rows;
b.cols = a.rows;


b.z = (complex **) malloc (b.rows * sizeof (complex *));
b.z = malloc (b.rows * sizeof (complex *));


for (i = 0; i < b.rows; i++)
for (i = 0; i < b.rows; i++)
{
{
b.z[i] = (complex *) malloc (b.cols * sizeof (complex));
b.z[i] = malloc (b.cols * sizeof (complex));
for (j = 0; j < b.cols; j++)
for (j = 0; j < b.cols; j++)
{
{
Line 284: Line 283:


return 0;
return 0;
}</lang>
}
</lang>
{{out}}
{{out}}
<pre>
<pre>