Network flow, transportation, and scheduling: theory