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

Negating SymTridiagonal yields dense matrix #36680

Closed
jagot opened this issue Jul 15, 2020 · 1 comment
Closed

Negating SymTridiagonal yields dense matrix #36680

jagot opened this issue Jul 15, 2020 · 1 comment
Labels
good first issue Indicates a good issue for first-time contributors to Julia help wanted Indicates that a maintainer wants help on an issue or pull request linear algebra Linear algebra

Comments

@jagot
Copy link
Contributor

jagot commented Jul 15, 2020

               _
   _       _ _(_)_     |  Documentation: https://docs.julialang.org
  (_)     | (_) (_)    |
   _ _   _| |_  __ _   |  Type "?" for help, "]?" for Pkg help.
  | | | | | | |/ _` |  |
  | | |_| | | | (_| |  |  Version 1.6.0-DEV.388 (2020-07-07)
 _/ |\__'_|_|_|\__'_|  |  Commit ff174120aa (8 days old master)
|__/                   |
julia> using LinearAlgebra
julia> -Tridiagonal(1:10, 1:11, 1:10)
11×11 Tridiagonal{Int64,Vector{Int64}}:
 -1  -1   ⋅   ⋅   ⋅   ⋅   ⋅   ⋅   ⋅    ⋅    ⋅
 -1  -2  -2   ⋅   ⋅   ⋅   ⋅   ⋅   ⋅    ⋅    ⋅
  ⋅  -2  -3  -3   ⋅   ⋅   ⋅   ⋅   ⋅    ⋅    ⋅
  ⋅   ⋅  -3  -4  -4   ⋅   ⋅   ⋅   ⋅    ⋅    ⋅
  ⋅   ⋅   ⋅  -4  -5  -5   ⋅   ⋅   ⋅    ⋅    ⋅
  ⋅   ⋅   ⋅   ⋅  -5  -6  -6   ⋅   ⋅    ⋅    
  ⋅   ⋅   ⋅   ⋅   ⋅  -6  -7  -7   ⋅    ⋅    ⋅
  ⋅   ⋅   ⋅   ⋅   ⋅   ⋅  -7  -8  -8    ⋅    ⋅
  ⋅   ⋅   ⋅   ⋅   ⋅   ⋅   ⋅  -8  -9   -9    ⋅
  ⋅   ⋅   ⋅   ⋅   ⋅   ⋅   ⋅   ⋅  -9  -10  -10
  ⋅   ⋅   ⋅   ⋅   ⋅   ⋅   ⋅   ⋅   ⋅  -10  -11
julia> -SymTridiagonal(1:11, 1:10)
11×11 Matrix{Int64}:
 -1  -1   0   0   0   0   0   0   0    0    0
 -1  -2  -2   0   0   0   0   0   0    0    0
  0  -2  -3  -3   0   0   0   0   0    0    0
  0   0  -3  -4  -4   0   0   0   0    0    0
  0   0   0  -4  -5  -5   0   0   0    0    0
  0   0   0   0  -5  -6  -6   0   0    0    0
  0   0   0   0   0  -6  -7  -7   0    0    0
  0   0   0   0   0   0  -7  -8  -8    0    0
  0   0   0   0   0   0   0  -8  -9   -9    0
  0   0   0   0   0   0   0   0  -9  -10  -10
  0   0   0   0   0   0   0   0   0  -10  -11
@StefanKarpinski StefanKarpinski added linear algebra Linear algebra good first issue Indicates a good issue for first-time contributors to Julia help wanted Indicates that a maintainer wants help on an issue or pull request labels Jul 15, 2020
@StefanKarpinski
Copy link
Sponsor Member

Seems like a simple missing method. Would be a good first issue!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Indicates a good issue for first-time contributors to Julia help wanted Indicates that a maintainer wants help on an issue or pull request linear algebra Linear algebra
Projects
None yet
Development

No branches or pull requests

2 participants