Skip to content

Commit 4c991de

Browse files
committed
Update
1 parent d2eace0 commit 4c991de

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

src/Bridges/Variable/set_map.jl

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ function MOI.get(
8585
if value === nothing
8686
return
8787
end
88-
return MOI.Bridges.inverse_map_function(bridge, value)
88+
return MOI.Bridges.map_function(bridge, value)
8989
end
9090

9191
function MOI.set(
@@ -98,7 +98,7 @@ function MOI.set(
9898
MOI.set(model, attr, bridge.constraint, nothing)
9999
return
100100
end
101-
bridged_value = MOI.Bridges.map_function(bridge, value)
101+
bridged_value = MOI.Bridges.inverse_map_function(bridge, value)
102102
MOI.set(model, attr, bridge.constraint, bridged_value)
103103
return
104104
end
@@ -132,7 +132,7 @@ function MOI.get(
132132
if value === nothing
133133
return
134134
end
135-
return MOI.Bridges.inverse_adjoint_map_function(bridge, value)
135+
return MOI.Bridges.adjoint_map_function(bridge, value)
136136
end
137137

138138
function MOI.set(
@@ -145,7 +145,7 @@ function MOI.set(
145145
MOI.set(model, attr, bridge.constraint, nothing)
146146
return
147147
end
148-
bridged_value = MOI.Bridges.adjoint_map_function(bridge, value)
148+
bridged_value = MOI.Bridges.inverse_adjoint_map_function(bridge, value)
149149
MOI.set(model, attr, bridge.constraint, bridged_value)
150150
return
151151
end

test/Bridges/Variable/SOCtoRSOCBridge.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,7 @@ function test_adjoint_map_function()
155155
inner = MOI.Utilities.UniversalFallback(MOI.Utilities.Model{Float64}())
156156
model = MOI.Bridges.Variable.SOCtoRSOC{Float64}(inner)
157157
x, _ = MOI.add_constrained_variables(model, MOI.SecondOrderCone(3))
158-
@test MOI.Bridges.adjoint_map_function(model.map[first(x)])
158+
@test MOI.Bridges.adjoint_map_function(model.map[first(x)], [2, 0.5, 1])
159159
[2.5 / sqrt(2), +1.5 / sqrt(2), 1.0]
160160
return
161161
end

0 commit comments

Comments
 (0)