Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Banded block banded matrix with different bandwidths for the blocks #101

Open
sethaxen opened this issue Feb 1, 2021 · 3 comments
Open

Comments

@sethaxen
Copy link

sethaxen commented Feb 1, 2021

I have a banded block banded matrix where the blocks themselves can have different bandwidths. Specifically, the bandwidth within the blocks is dependent on which block-diagonal the block is in. e.g., the block at index k ∈ [-l, u] would have a bandwidth of (λ, μ) = (1 - k, 1 + k), so that a block on the subdiagonal k=-1 has a bandwidth of (2, 0), a block on the diagonal k=0 is tridiagonal, and a block on the superdiagonal k=1 has a bandwidth of (0, 2). Can this be represented using this package?

@dlfivefifty
Copy link
Member

Not yet but the current implementation could be modified to take a vector of bandwidths. This sort of thing does come up a lot

@sethaxen
Copy link
Author

sethaxen commented Feb 1, 2021

Do you anticipate doing so would cause any performance regressions? Otherwise, perhaps it would be better to add a new subtype of AbstractBandedBlockBandedMatrix.

@dlfivefifty
Copy link
Member

No I don’t think there are any performance regressions since it doesn’t really use the fact that all the bandwidths are the same. and if there was anywhere that made a difference we could just overload for the case where the bandwidths are <: Fill

Some implementation details will need to be changed though.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants