Thanks for your question!
Following a double dissolution election, such as the one held in July 2016, all 76 senators are re-elected. The Senate must then agree on a method to decide which senators will serve a six-year term and which will serve a three-year term.
Normally, because state senators are elected on a rotating basis and for a six-year term, half these senators are elected in a federal election with the House every 3 years. The terms of the 4 territory senators are the same as the members of the House of Representatives.
Section 13 of the Australian Constitution requires that the rotation of the Senate must be re-established following a double dissolution election. Under a motion agreed to by the Senate when it first met after the election, senators who received the largest quota of votes or, in other words, won the first 6 spots in each state, will serve six-year terms. Those elected in the 7th to 12th spots will serve three-year terms.