How To Install python-periodictable on Ubuntu 18.04

In this tutorial we learn how to install python-periodictable on Ubuntu 18.04. python-periodictable is Extensible periodic table of the elements (Python 2)

Introduction

In this tutorial we learn how to install python-periodictable on Ubuntu 18.04.

What is python-periodictable

python-periodictable is:

This package provides a periodic table of the elements with support for mass, density and xray/neutron scattering information.

Masses, densities and natural abundances come from the NIST Physics Laboratory, but do not represent a critical evaluation by NIST scientists.

Neutron scattering calculations use values collected by the Atomic Institute of the Austrian Universities. These values do corresponding to those from other packages, though there are some differences depending to the tables used. Bound coherent neutron scattering for gold in particular is significantly different from older value: 7.63(6) as measured in 1974 compared to 7.90(7) as measured in 1990.

X-ray scattering calculations use a combination of empirical and theoretical values from the LBL Center for X-ray Optics. These values differ from those given in other sources such as the International Tables for Crystallography, Volume C, and so may give different results from other packages.

This package installs the library for Python 2.

There are three methods to install python-periodictable on Ubuntu 18.04. We can use apt-get, apt and aptitude. In the following sections we will describe each method. You can choose one of them.

Install python-periodictable Using apt-get

Update apt database with apt-get using the following command.

sudo apt-get update

After updating apt database, We can install python-periodictable using apt-get by running the following command:

sudo apt-get -y install python-periodictable

Install python-periodictable Using apt

Update apt database with apt using the following command.

sudo apt update

After updating apt database, We can install python-periodictable using apt by running the following command:

sudo apt -y install python-periodictable

Install python-periodictable Using aptitude

If you want to follow this method, you might need to install aptitude first since aptitude is usually not installed by default on Ubuntu. Update apt database with aptitude using the following command.

sudo aptitude update

After updating apt database, We can install python-periodictable using aptitude by running the following command:

sudo aptitude -y install python-periodictable

How To Uninstall python-periodictable on Ubuntu 18.04

To uninstall only the python-periodictable package we can use the following command:

sudo apt-get remove python-periodictable

Uninstall python-periodictable And Its Dependencies

To uninstall python-periodictable and its dependencies that are no longer needed by Ubuntu 18.04, we can use the command below:

sudo apt-get -y autoremove python-periodictable

Remove python-periodictable Configurations and Data

To remove python-periodictable configuration and data from Ubuntu 18.04 we can use the following command:

sudo apt-get -y purge python-periodictable

Remove python-periodictable configuration, data, and all of its dependencies

We can use the following command to remove python-periodictable configurations, data and all of its dependencies, we can use the following command:

sudo apt-get -y autoremove --purge python-periodictable

References

Summary

In this tutorial we learn how to install python-periodictable package on Ubuntu 18.04 using different package management tools: apt, apt-get and aptitude.