void FastTransposeSMatrix(TSMatrix M
{
//采用三元組順序表存儲表示
T
T
T
if (T
for (col=
num[col] =
for (t=
++num[M
rpos[
for (col=
rpos[col] = rpos[col
//求T中每一行的第一個非零元在T
for (p=
col = M
T
T
T
++rpos[col];
}//for
}//if
}//FastTransposeSMatrix
上述算法的時間復雜度為O (M
From:http://tw.wingwit.com/Article/program/sjjg/201311/23282.html