Marius Borg Høiby, the son of Norway’s new queen, has been granted permission to leave his house arrest to attend the funeral of his step-grandfather, the late King Harald V. King Harald passed away on Friday at the age of 89, and his son, Crown Prince Haakon, immediately assumed the throne as King Haakon VIII. His wife, Mette-Marit, recently named queen, has faced public scrutiny in recent years.

Høiby was sentenced in June to four years in prison after being convicted of two rapes. Currently, he is serving his sentence under house arrest with an electronic monitoring device while awaiting a new trial following his appeal. Norwegian police confirmed that Høiby would be allowed to leave confinement to attend King Harald’s funeral on September 9. He had previously been permitted to visit the king in hospital before his death.

Ola Karterud, a police prosecutor, stated that the public prosecutor found sufficient grounds to grant Høiby’s requests to leave custody in connection with the king’s passing. In addition to the two rape convictions, Høiby faces 32 other charges, including violence against a former partner. He was acquitted of two other rape charges.

Høiby, 29, was also allowed to be present during the transfer of the late king’s coffin through the royal palace to the palace chapel. Queen Mette-Marit, making her first public appearance since her accession, joined the procession.

King Haakon is set to take the oath to Norway’s constitution, facing multiple challenges including restoring public confidence in the monarchy. His wife’s past association with the disgraced financier Jeffrey Epstein, who was convicted of sex offenses, has sparked controversy. Earlier this year, as crown princess, Mette-Marit publicly apologized for her connection to Epstein, acknowledging that she had been manipulated and deceived and admitting she did not adequately investigate his background prior to forming a friendship.

The royal family now faces the task of navigating these difficulties as they transition following King Harald’s death.