Royal Navy security personnel stand guard on HMS Vigilant at Her Majesty's Naval Base, Clyde in Rhu, Scotland Jeff J Mitchell/ Getty Images

Nine British Navy servicemen have tested positive for cocaine use while on duty on board the HMS Vigilant, a submarine armed with up to eight Trident nuclear missiles. The crew members were sent home after failing the drugs tests.

"We do not tolerate drugs misuse by service personnel. Those found to have fallen short of our high standards face being discharged from service," a Royal Navy spokesman said.

A source told the Telegraph the members had tested positive for cocaine and had been discharged. One of the crew members allegedly also had sex with a prostitute in a swimming pool.

Earlier this month, the Ministry of Defence launched an investigation into an "inappropriate relationship" between crew members on board the nuclear submarine, the Daily Mirror reported.

The captain of the vessel was relieved of his duties pending the outcome.

A Royal Navy spokesman said: "We can confirm an investigation is under way, but it would be inappropriate to comment further at this stage. Any allegations of wrongdoing are taken very seriously and will be dealt with appropriately."

There are strict Royal Navy rules about relationships onboard vessels.

In 2014, commander Sarah West was removed from the HMS Portland after claims she had a relationship with another married colleague.