# Solving linear equations in Laplacians and SDD matrices

**URL:** <https://discourse.julialang.org/t/solving-linear-equations-in-laplacians-and-sdd-matrices/93911>\
**Category:** General Usage\
**Created:** [February 2, 2023, 9:13am UTC](https://discourse.julialang.org/t/solving-linear-equations-in-laplacians-and-sdd-matrices/93911 "2023-02-02T09:13:31Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![ahmad88](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ahmad88/32/32437_2.png) [@ahmad88](https://discourse.julialang.org/u/ahmad88)\
**Post date:** [February 2, 2023, 9:13am UTC](https://discourse.julialang.org/t/solving-linear-equations-in-laplacians-and-sdd-matrices/93911/1 "2023-02-02T09:13:31Z")

</div>

I am trying to solve linear equations for SDD matrix as follows

```julia
a= ring_graph(5)
la=lap(a)
b = randn(size(la,1))
sddm = copy(la); # doing it with a SDDM matrix
sddm[1,1] += 1;
sol = approxchol_sddm(sddm,verbose=true)
x = sol(b)

```

In this way the code is working without any problems but if I change the graph to be graph I read it as follows:

`a=loadgraph("ieeebus.graphml", "G" , GraphIO.GraphML.GraphMLFormat())`  
it gives an error messeage  
`LoadError: MethodError: no method matching extendMatrix(::SparseMatrixCSC{Int64, Int64}, ::Vector{Float64})`
