<｜begin▁of▁sentence｜>### Instruction:
As a textile designer creating patterns and designs for fabrics, imagine you are working on a collection inspired by the flow of water through a network of rivers. In this scenario, you are tasked with determining the maximum flow value from the source river (Vertex 0) to the destination river (Vertex 3). Each river is connected by directional branches with specific flow capacities, mirroring the flow capacities of the directed graph provided. Utilizing this analogy, you can visualize the flow of water through the river network and calculate the maximum flow value while considering the capacity of each river connection.
### Response:
from igraph import Graph

# Define the edges and capacities for the graph
g = Graph(edges=[(0, 1), (1, 2), (2, 3), (3, 0), (1, 3)], directed=True)
g.es['capacity'] = [10, 5, 10, 5, 4]

# Define source and target vertices
source = 0
target = 3

# Calculate the value of the maximum flow from source to target
maxflow_value = g.maxflow_value(source, target, capacity=g.es['capacity'])
print('Maximum flow value:', maxflow_value)
<|EOT|>
