Using a Directional Antenna to Achieve Quality Transmission on a Wireless Ad hoc Network under Jamming Attacks