|
1 | 1 | @info "running explicit neutral power flow tests with native julia power flow solver" |
2 | 2 |
|
3 | 3 |
|
4 | | -function conductor_correction!(data_eng) |
| 4 | +function conductor_correction!(data_eng::EngineeringModel) |
5 | 5 | nw = data_eng |
6 | 6 | if neutral_idx ∈ nw["conductor_ids"] |
7 | 7 | filter!(e -> e ≠ neutral_idx, nw["conductor_ids"]) |
|
45 | 45 |
|
46 | 46 |
|
47 | 47 |
|
48 | | -function sourcebus_voltage_vector_correction!(data_math::Dict{String,Any}; explicit_neutral=true) |
| 48 | +function sourcebus_voltage_vector_correction!(data_math::MathematicalModel; explicit_neutral=true) |
49 | 49 | if haskey(data_math, "multinetwork") |
50 | 50 | for (n, nw) in data_math["nw"] |
51 | 51 | for (i, bus) in data_math["nw"]["bus"] |
@@ -255,7 +255,7 @@ filter!(e -> e ≠ "case3_balanced_battery_3ph", cases) |
255 | 255 |
|
256 | 256 | # obtain solution from dss |
257 | 257 | sol_dss = open("$solution_dir/$case.json", "r") do f |
258 | | - JSON.parse(f) |
| 258 | + Dict{String, Any}(JSON.parse(f)) |
259 | 259 | end |
260 | 260 |
|
261 | 261 | sol_pmd = transform_solution(res["solution"], data_math, make_si=true) |
@@ -285,7 +285,7 @@ filter!(e -> e ≠ "case3_balanced_battery_3ph", cases) |
285 | 285 | res = compute_mc_pf(pfd) |
286 | 286 |
|
287 | 287 | sol_dss = open("$solution_dir/$case.json", "r") do f |
288 | | - JSON.parse(f) |
| 288 | + Dict{String, Any}(JSON.parse(f)) |
289 | 289 | end |
290 | 290 |
|
291 | 291 | sol_pmd = transform_solution(res["solution"], data_math, make_si=true) |
@@ -323,7 +323,7 @@ cases = ["test_trans_dy_3w", "test_trans_yy_3w", "ut_trans_3w_dyy_1", "ut_trans_ |
323 | 323 |
|
324 | 324 | # obtain solution from dss |
325 | 325 | sol_dss = open("$solution_dir/$case.json", "r") do f |
326 | | - JSON.parse(f) |
| 326 | + Dict{String, Any}(JSON.parse(f)) |
327 | 327 | end |
328 | 328 |
|
329 | 329 | sol_pmd = transform_solution(res["solution"], data_math, make_si=true) |
@@ -388,7 +388,7 @@ solution_dir = "data/opendss_solutions" |
388 | 388 | @test res["termination_status"]["10"] == PF_CONVERGED |
389 | 389 |
|
390 | 390 | sol_dss = open("$solution_dir/$case.json", "r") do f |
391 | | - JSON.parse(f) |
| 391 | + Dict{String, Any}(JSON.parse(f)) |
392 | 392 | end |
393 | 393 |
|
394 | 394 | sol_pmd = transform_solution(res["solution"], data_math, make_si=true) |
|
0 commit comments