7
$\begingroup$

I want to label a duplicate edge I have with different labels in an adjacency graph.

So far I have this:

AdjacencyGraph[({
   {1, 1},
   {1, 2}
  }), VertexLabels -> {1 -> "v", 2 -> "u"}, DirectedEdges -> True, 
 EdgeLabels -> {(1 -> 1) -> "δ", (1 -> 2) -> "γ", (2 -> 1) -> "β", (2 -> 2) -> "α"}]

Which gives me this:

enter image description here

Is there a way to label one as α_1 and α_2?

$\endgroup$
2
$\begingroup$
ag = AdjacencyGraph[{{1, 1}, {1, 2}}, 
 VertexLabels -> {1 -> "v", 2 -> "u"}, DirectedEdges -> True, 
 EdgeLabels -> {(1 -> 1) -> "δ", (1 -> 2) -> "γ", (2 -> 1) -> "β", (2 -> 2) -> "α"}];

Module[{i=1}, Show[ag] /. "α" :>Subscript["α", i++]]

enter image description here

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.