<｜begin▁of▁sentence｜>### Instruction:
Given a graph displayed using Cairo, how would you instantiate an AlphaVaryingEdgeDrawer to draw the edges with varying transparency, starting from a low alpha value at the source to a high alpha value at the destination?
### Response:
from igraph import Graph
from igraph.drawing import Plot
from igraph.drawing.edge import AlphaVaryingEdgeDrawer
import cairo

# Create a simple graph
g = Graph.Tree(3, 2)

# Initialize a plot with a Cairo context
plot = Plot(surface=cairo.ImageSurface(cairo.FORMAT_ARGB32, 400, 400))
ctx = plot.context

# Set up a palette (using default palette for simplicity)
palette = plot.palette

# Construct the AlphaVaryingEdgeDrawer
edge_drawer = AlphaVaryingEdgeDrawer(ctx, palette, alpha_at_src=0.1, alpha_at_dest=1.0)

# Draw the edges using the custom edge drawer
for edge in g.es:
    edge_drawer.draw(edge, g.vs[edge.source]['coord'], g.vs[edge.target]['coord'])

# Plot to a file
plot.save('example.png')
<|EOT|>
