move codes related to Detector, like antenna pattern functions