Commit f59cb078 authored by Rémi's avatar Rémi
Browse files

Update jMCM for AdderGraphs 0.2

parent eab2bd03
name = "jMCM"
uuid = "1093c137-b6a1-4724-88ca-aaf1fbfbca0a"
version = "0.1.0"
version = "0.1.1"
[deps]
AdderGraphs = "818587fb-0c22-4279-a2b9-8b16b5360b71"
JuMP = "4076af6c-e467-56ae-b986-b466b2749572"
[compat]
AdderGraphs = "~0.1"
AdderGraphs = "~0.2"
......@@ -83,10 +83,8 @@ function mcm(model::Model,
subtraction = [value(model[:cai_right_shsg][i]) < 0, value(model[:cai_left_sg][i]) < 0]
push_node!(addergraph,
AdderNode(round(Int, value(model[:ca][i])),
[abs(round(Int, value(model[:cai_right_shsg][i]))) << -input_shift, abs(round(Int, value(model[:cai_left_sg][i])))],
[input_shift+node_shift, node_shift],
subtraction
[InputEdge(get_addernode_by_value(addergraph, round(Int, value(model[:cai][i,1]))), input_shift+node_shift, subtraction[1]),
InputEdge(get_addernode_by_value(addergraph, round(Int, value(model[:cai][i,2]))), node_shift, subtraction[2])]
)
)
end
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment