FRANKFURT, July 13 (Reuters) - German generic drugmaker Stada Arzneimittel (STAGn.DE: Quote, Profile, Research) has agreed to sell its unprofitable U.S. unit to New Jersey-based DAVA Pharmaceuticals for around $40 million, it said in a statement on Thursday.