Skip to content

Commit de8f322

Browse files
committed
adding readme
1 parent 58878f6 commit de8f322

1 file changed

Lines changed: 22 additions & 0 deletions

File tree

README.md

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
# CFMM Optimal Routing
2+
This repository contains the code needed to generate the figures used in the paper
3+
[Optimal Routing for Constant Function Market Makers](https://stanford.edu/~guillean/papers/cfmm-routing.pdf).
4+
5+
## Requirements
6+
The requirements for running these examples are:
7+
- `NumPy`
8+
- `Matplotlib`
9+
- `Cvxpy` (see [here](https://www.cvxpy.org/install/index.html) for installation)
10+
11+
In order to generate the figures as done in the paper you will also need a working TeX distribution.
12+
13+
## How to run
14+
All examples are self-contained and can be run directly, e.g.:
15+
```bash
16+
python arbitrage.py
17+
```
18+
The figures were generated by running
19+
```bash
20+
python two-asset.py
21+
```
22+
but note that this requires a working TeX distribution. (This can be avoided by commenting out any call to `latexify` in `two-asset.py` which requires `ps` as a backend for plotting.)

0 commit comments

Comments
 (0)