Network Coding for Wireless and Wired Networks: Design, Performance and Achievable Rates