The easiest way to set an environment variable in Ubuntu is to set it in the /etc/environment file.
Setting it in your bash_profile or bashrc file doesn’t work for me. There’s a Debian historical reason behind it, and no doubt more details. But if you want a quick way to set your LD_LIBRARY_PATH for the intel fortran compiler, that’s it.
My environment file looks like this:
note: this is an old post and I don’t find myself using Ubuntu a lot now, especially as an computer administrator. If it turns out this is wrong or out of date let me know.