Parameterized Verification of Ad Hoc Networks