Skip to content

Commit

Permalink
v0.5.1 mv remove_bus!, reduce_tree! and SinglePhase rij, xij
Browse files Browse the repository at this point in the history
…to CommonOPF
  • Loading branch information
NLaws committed Aug 1, 2023
1 parent cd9bfa8 commit b2c1b0d
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 19 deletions.
3 changes: 2 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
# LinDistFlow Changelog

## dev
## v0.5.1
- add `get_line_amps`, `get_peak_line_amps_percent`, and `define_line_amps_pu`
- mv SinglePhase `rij` and `xij` to CommonOPF

## v0.5.0
- deprecate `get_edge_values` and `get_bus_values` in favor of `CommonOPF.get_variable_values`
Expand Down
2 changes: 1 addition & 1 deletion Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,6 @@ LinearAlgebra = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e"
SparseArrays = "2f01184e-e22b-5df5-ae63-d93ebab69eaf"

[compat]
CommonOPF = "0.3.5"
CommonOPF = "0.3.6"
JuMP = "^0.21, 1.0"
julia = "1"
1 change: 1 addition & 0 deletions src/LinDistFlow.jl
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
module LinDistFlow

using CommonOPF
import CommonOPF: rij, xij # extending to MultiPhase, need to consolidate into CommonOPF
using JuMP
using LinearAlgebra
import SparseArrays: sparse
Expand Down
18 changes: 1 addition & 17 deletions src/utils.jl
Original file line number Diff line number Diff line change
@@ -1,12 +1,4 @@

function rij(i::String, j::String, p::Inputs{SinglePhase})
linecode = get_ijlinecode(i, j, p)
linelength = get_ijlinelength(i, j, p)
rmatrix = p.Zdict[linecode]["rmatrix"] * linelength / p.Zbase
return rmatrix[1]
end


# TODO mv MultiPhase rij xij to CommonOPF (requires something new to handle BFM vs. LDF)
function rij(i::String, j::String, p::Inputs{MultiPhase})
linecode = get_ijlinecode(i, j, p)
linelength = get_ijlinelength(i, j, p)
Expand All @@ -30,14 +22,6 @@ function rij(i::String, j::String, p::Inputs{MultiPhase})
end


function xij(i::String, j::String, p::Inputs{SinglePhase})
linecode = get_ijlinecode(i, j, p)
linelength = get_ijlinelength(i, j, p)
xmatrix = p.Zdict[linecode]["xmatrix"] * linelength / p.Zbase
return xmatrix[1]
end


function xij(i::String, j::String, p::Inputs{MultiPhase})
linecode = get_ijlinecode(i, j, p)
linelength = get_ijlinelength(i, j, p)
Expand Down

2 comments on commit b2c1b0d

@NLaws
Copy link
Owner Author

@NLaws NLaws commented on b2c1b0d Aug 1, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@JuliaRegistrator
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Error while trying to register: Version 0.5.0 already exists

Please sign in to comment.