A federal judge nullified Wednesday the Trump administration’s orders freezing more than $2.6 billion in grants to Harvard University, ruling that the government violated the First Amendment and federal law in withholding research funding over the school’s handling of campus antisemitism.