sisl_toolbox.btd.PermuteBTD
- class sisl_toolbox.btd.PermuteBTD
Bases:
objectPermutation table and block sizes of a block-tridiagonal matrix
- Parameters:
permute (
ndarray) – the permutation table,permute[new] = old. Ifblocksis not passed, this should be a sequence of the permutation indices for each block (e.g.np.split(permute, np.cumsum(blocks)[:-1])), the permutation table is then their concatenation, and the block sizes are their lengths.blocks (
Optional[np.ndarray]) – the block sizes,blocks.sum() == len(permute)
Examples
The two forms are equivalent:
>>> PermuteBTD([2, 0, 1, 3], [1, 3]) >>> PermuteBTD([[2], [0, 1, 3]])
Attributes
- permute: np.ndarray