Implement local brokerage and add tests

Local brokerage is implemented for both undirected and directed networks.

We implement three types of local brokerage for directed networks: in, out and all.The least efficient at the moment is 'all', since it requires us to determine both in- and out-brokerage. There may be a better way :-)