How To Install liblip2 on Ubuntu 18.04

In this tutorial we learn how to install liblip2 on Ubuntu 18.04. liblip2 is reliable interpolation of multivariate scattered data

Introduction

In this tutorial we learn how to install liblip2 on Ubuntu 18.04.

What is liblip2

liblip2 is:

Lip interpolates scattered multivariate data with a Lipschitz function.

Methods of interpolation of multivariate scattered data are scarce. The programming library Lip implements a new method by G. Beliakov, which relies on building reliable lower and upper approximations of Lipschitz functions. If we assume that the function that we want to interpolate is Lipschitz-continuous, we can provide tight bounds on its values at any point, in the worse case scenario. Thus we obtain the interpolant, which approximates the unknown Lipschitz function f best in the worst case scenario. This translates into reliable learning of f, something that other methods cannot do (the error of approximation of most other methods can be infinitely large, depending on what f generated the data).

Lipschitz condition implies that the rate of change of the function is bounded:

|f(x)-f(y)|<M||x-y||.

It is easily interpreted as the largest slope of the function f. f needs not be differentiable.

The interpolant based on the Lipschitz properties of the function is piecewise linear, it possesses many useful properties, and it is shown that it is the best possible approximation to f in the worst case scenario. The value of the interpolant depends on the data points in the immediate neigbourhood of the point in question, and in this sense, the method is similar to the natural neighbour interpolation.

There are two methods of construction and evaluation of the interpolant. The explicit method processes all data points to find the neighbours of the point in question. It does not require any preprocessing, but the evaluation of the interpolant has linear complexity O(K) in terms of the number of data.

“Fast” method requires substantial preprocessing in the case of more than 3-4 variables, but then it provides O(log K) evaluation time, and thus is suitable for very large data sets (K of order of 500000) and modest dimension (n=1-4). For larger dimension, explicit method becomes practically more efficient. The class library Lip implements both fast and explicit methods.

There are three methods to install liblip2 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 liblip2 Using apt-get

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

sudo apt-get update

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

sudo apt-get -y install liblip2

Install liblip2 Using apt

Update apt database with apt using the following command.

sudo apt update

After updating apt database, We can install liblip2 using apt by running the following command:

sudo apt -y install liblip2

Install liblip2 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 liblip2 using aptitude by running the following command:

sudo aptitude -y install liblip2

How To Uninstall liblip2 on Ubuntu 18.04

To uninstall only the liblip2 package we can use the following command:

sudo apt-get remove liblip2

Uninstall liblip2 And Its Dependencies

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

sudo apt-get -y autoremove liblip2

Remove liblip2 Configurations and Data

To remove liblip2 configuration and data from Ubuntu 18.04 we can use the following command:

sudo apt-get -y purge liblip2

Remove liblip2 configuration, data, and all of its dependencies

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

sudo apt-get -y autoremove --purge liblip2

References

Summary

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