Talk:Skyline matrix

This was diagonal storage, not skyline
Actually, I got fooled. The examples and description are what is known as storage by diagonals not skyline storage... will have to move it. Here it is stored below for now. Jmath666 04:05, 10 April 2007 (UTC)

For symmetrical matrices (with zero based indexing): $$ A_{skyline}(i,j) = \begin{cases} A_{original}(i,j-i) & \mbox{if } i \le j \le i+bandwidth_{half} \\ 0 & otherwise \end{cases} $$ For unsymmetrical matrices (with zero based indexing): $$ A_{skyline}(i,j) = \begin{cases} A_{original}(i,j-i) & \mbox{if } i-bandwidth_{left} \le j \le i+bandwidth_{right} \\ 0 & otherwise \end{cases} $$

For a symmetric 6 by 6 matrix A with a right bandwidth of 2 turns into the 6 by 3 matrix A_{skyline}. Matrix A in original format: $$ \begin{bmatrix} A_{11} & A_{12} & A_{13} &  0  & \cdots & 0 \\ & A_{22} & A_{23} & A_{24} & \ddots & \vdots \\ &       & A_{33} & A_{34} & A_{35} & 0 \\ &       &        & A_{44} & A_{45} & A_{46} \\ & sym   &        &        & A_{55} & A_{56} \\ &       &        &        &        & A_{66} \end{bmatrix} $$ Matrix A_{skyline} in skyline format: $$ \begin{bmatrix} A_{11} & A_{12} & A_{13} \\ A_{22} & A_{23} & A_{24} \\ A_{33} & A_{34} & A_{35} \\ A_{44} & A_{45} & A_{46} \\ A_{55} & A_{56} & 0 \\ A_{66} & 0 & 0 \end{bmatrix} $$ For an unsymmetrical 6 by 6 tridiagonal matrix B with left and right band widths of 1 turns into the 6 by 3 matrix B_{skyline}. Matrix B in original format: $$ \begin{bmatrix} B_{11} & B_{12} & 0     & \cdots & \cdots & 0 \\ B_{21} & B_{22} & B_{23} & \ddots & \ddots & \vdots \\ 0    & B_{32} & B_{33} & B_{34} & \ddots & \vdots \\ \vdots & \ddots & B_{43} & B_{44} & B_{45} & 0 \\ \vdots & \ddots & \ddots & B_{54} & B_{55} & B_{56} \\ 0     & \cdots & \cdots & 0      & B_{65} & B_{66} \end{bmatrix} $$ Matrix B_{skyline} in skyline format: $$ \begin{bmatrix} 0 & B_{11} & B_{12}\\ B_{21} & B_{22} & B_{23} \\ B_{32} & B_{33} & B_{34} \\ B_{43} & B_{44} & B_{45} \\ B_{54} & B_{55} & B_{56} \\ B_{65} & B_{66} & 0 \end{bmatrix} $$

Details
This article needs some pseudo code. 72.74.211.41 05:06, 4 November 2007 (UTC)

Image
Imaged added and diagram request removed. Rocchini (talk) 11:31, 24 December 2020 (UTC)