Skip to content

Commit e7958e0

Browse files
author
Ubuntu
committed
rename bioGraph -> bipGraph
1 parent 1eb6b0f commit e7958e0

File tree

2 files changed

+13
-13
lines changed

2 files changed

+13
-13
lines changed

graph/flowGraph.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -254,7 +254,7 @@ func relabelToFront(g flowGraph, s interface{}, t interface{}) {
254254
}
255255
}
256256

257-
func bioGraphMaxMatch(g graph, l []interface{}, flowAlg func(g flowGraph, s interface{}, t interface{})) graph {
257+
func bipGraphMaxMatch(g graph, l []interface{}, flowAlg func(g flowGraph, s interface{}, t interface{})) graph {
258258
//build flow graph
259259
fG := newFlowGraph()
260260
s := struct{ start string }{"s"}

graph/flowGraph_test.go

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ func pushRelabelGolden(g flowGraph) flowGraph {
5555
return flowG
5656
}
5757

58-
func bioGraphMaxMatchSetup() (graph, []interface{}) {
58+
func bipGraphMaxMatchSetup() (graph, []interface{}) {
5959
g := newGraph()
6060
g.AddEdgeBi(edge{"l0", "r0"})
6161
g.AddEdgeBi(edge{"l1", "r0"})
@@ -68,23 +68,23 @@ func bioGraphMaxMatchSetup() (graph, []interface{}) {
6868
return g, []interface{}{"l0", "l1", "l2", "l3", "l4"}
6969
}
7070

71-
func bioGraphMaxMatchGoldenByEdmondesKarp() graph {
71+
func bipGraphMaxMatchGoldenByEdmondesKarp() graph {
7272
g := newGraph()
7373
g.AddEdgeBi(edge{"l0", "r0"})
7474
g.AddEdgeBi(edge{"l1", "r2"})
7575
g.AddEdgeBi(edge{"l2", "r1"})
7676
return g
7777
}
7878

79-
func bioGraphMaxMatchGoldenByPushRelabel() graph {
79+
func bipGraphMaxMatchGoldenByPushRelabel() graph {
8080
g := newGraph()
8181
g.AddEdgeBi(edge{"l1", "r0"})
8282
g.AddEdgeBi(edge{"l4", "r2"})
8383
g.AddEdgeBi(edge{"l2", "r1"})
8484
return g
8585
}
8686

87-
func bioGraphMaxMatchGoldenByRelabelToFront() graph {
87+
func bipGraphMaxMatchGoldenByRelabelToFront() graph {
8888
g := newGraph()
8989
g.AddEdgeBi(edge{"l0", "r0"})
9090
g.AddEdgeBi(edge{"l1", "r2"})
@@ -129,17 +129,17 @@ func TestRelabelToFront(t *testing.T) {
129129
checkFlowGraphOutOfOrder(t, g, gGolden)
130130
}
131131

132-
func TestBioGraphMaxMatch(t *testing.T) {
133-
bioG, l := bioGraphMaxMatchSetup()
134-
gGolden := bioGraphMaxMatchGoldenByEdmondesKarp()
135-
g := bioGraphMaxMatch(bioG, l, edmondesKarp)
132+
func TestBipGraphMaxMatch(t *testing.T) {
133+
bioG, l := bipGraphMaxMatchSetup()
134+
gGolden := bipGraphMaxMatchGoldenByEdmondesKarp()
135+
g := bipGraphMaxMatch(bioG, l, edmondesKarp)
136136
checkGraphOutOfOrderInString(t, g, gGolden, nil)
137137

138-
g = bioGraphMaxMatch(bioG, l, pushRelabel)
139-
gGolden = bioGraphMaxMatchGoldenByPushRelabel()
138+
g = bipGraphMaxMatch(bioG, l, pushRelabel)
139+
gGolden = bipGraphMaxMatchGoldenByPushRelabel()
140140
checkGraphOutOfOrderInString(t, g, gGolden, nil)
141141

142-
g = bioGraphMaxMatch(bioG, l, relabelToFront)
143-
gGolden = bioGraphMaxMatchGoldenByRelabelToFront()
142+
g = bipGraphMaxMatch(bioG, l, relabelToFront)
143+
gGolden = bipGraphMaxMatchGoldenByRelabelToFront()
144144
checkGraphOutOfOrderInString(t, g, gGolden, nil)
145145
}

0 commit comments

Comments
 (0)