Defender Trotman was put on the transfer list shortly after Cook's arrival as manager towards the end of 2012 but the 26-year-old centre-half responded with some terrific performances during the second half of the season.
Whitaker has primarily featured from the bench since the turn of the year after being a regular pick under former boss John Sheridan.
Fellow midfielders Craig Clay and Jack Waddle, forwards Scott Boden and Jonathan Wafula and goalkeeper Richard O'Donnell are the other players who will be leaving the Proact Stadium.
Meanwhile, the versatile Drew Talbot and forward Jacob Hazel, who are both out of contract in the summer, have been offered new deals but the futures of midfielder Mark Randall and full-back Richard Brindley are yet to be resolved.
Winger Alex Henshall and defender Conor Townsend have returned to Manchester City and Hull respectively at the end of their loan spells.