Trouble installing cuda 9.1

I have previously had CUDA 10.1(deb, local) installed on my Ubuntu 16.04, but realized I would rather have CUDA 9.1 to gain compatibility with MATLAB (As MATLAB2018b only works with CUDA 9.1)

I had issues trying to install the legacy package parallel to my CUDA 10.1 so I chose to remove cuda 10.1 from the computer.

When I try to install CUDA 9.1, following the instructions at https://developer.nvidia.com/cuda-91-download-archive (either using deb(local) or deb(network)) it installs CUDA 10.1 instead of 9.1.

Does anyone know why this happens - and what can I do to get 9.1?

read the linux install guide

[url]https://docs.nvidia.com/cuda/cuda-installation-guide-linux/index.html#package-manager-additional[/url]

sudo apt-get install cuda

installs the latest version (10.1)

instead use:

sudo apt-get install cuda-9-1