added inline to distributed_matrix