The BBC has apologised for including scenes of ‘sadistic’ sexual violence in an episode of Silent Witness which broke corporation guidelines.

The BBC Trust ruled that the episode, which included scenes of a prison officer assaulting a victim in a toilet cubicle with a baton, was “too explicit for the series”.

The broadcaster received 632 complaints about the episode which one complainant said he had found “extremely upsetting” and “thoroughly nasty”.

Silent Witness, which stars Emilia Fox, is now in its 15th series. The offending episode was broadcast on 22 April 2012 between 9pm and 10pm.

26 of the complaints were made because scheduling had overrun meaning that viewers tuning into BBC1 at10pm would have seen the programme’s conclusion.

One man said he had turned on his television to watch the BBC News at Ten and had been confronted by “seriously disturbing scenes of utter degradation, extreme violence with sexual overtones”.

Responding to the complaint the programme’s executive producer said “it was not an attempt to gratuitously shock the audience” but was part of a storyline establishing a policewoman’s complicity in the brutality of a male prison officer.

She argued it had been scheduled after the watershed and that after 15 series’ audiences would be familiar with the nature of content included in Silent Witness.

In its ruling the BBC Trust said that “viewers were left in no doubt that an act of sexual violence was being carried out" even though the sexual attack was not shown.

The complaints director said he felt “the programme-makers may have misjudged the feelings of the audience about this sort of material, and the leeway that the audience would permit them based on previous episodes”.

Upholding the complaint the BBC Trust concluded that the programme did not constitute “a serious breach of the editorial standards of the BBC”.

But it said the programme-makers “might have done more to recognise the risk that their viewers would be taken aback by the scene” and acknowledged that the scenes “depicted a sadistic method of inflicting pain, injury and death”.