Gnuplot is one of the most useful tool for plotting all kinds of figures in Linux system. Here, we give an simple example to plot distribution function with gnuplot. We will plot the function of two kind of molecules A and B in a liquid, along the normal direction (z-axis),ie., as a function of z coordinate. The distribution file are dist_A.dat and dist_B.dat. The value is too different to each other, we plot them with different scale. The details can be found in the script scr_doubleaxis.gnuplot.
To plot, just run
The script is as follows.
继续阅读“Gnuplot Examples (1): Plotting With Double-yaxis”
Suppose we have a file theta.dat which has 1000 lines and each line has a angle value. Its first 10 lines are as follows.
How to plot a histogram figure in python with matplotlib with the file theta.dat?
We put this file in the home directory, thus the position is ~/theta.dat.
Then , we plot in Enthought Canopy Graphical Environment! One can download and install it in Software Manager. If we open it, the window looks like this.
继续阅读“Plot histograms in python with matplotlib”
On the Raspbian system, when I created a new user with the commands
There is no directory named “gang” under the home directory. When I login as a user (gang) and want to use the
sudo command to create a main directory for myself, I saw the error “gang is not in the sudoers file. This incident will be reported. ” This error implies that I have to edit the sudoers file to give myself the privilege to use
sudo. To have the root privilege, I need to do as follows.
继续阅读“Solution for the Error “*** is not in the sudoers file. This incident will be reported. “”
One solution of “Package pdftex.def Error: File ‘eps-converted-to.pdf’ not found
In Textstudio, when I compile a tex file including a .eps file, I meet a error like this:
Error: ! Package pdftex.def Error: File `P_ba_at_t-eps-converted-to.pdf’ not found.
Here is one solution I found from web. MichaelChirico answered this question. The answer is as follows.
利用自生系统中的PPA(Personal Package Archive)(Boot-Repair）来恢复（重装）Ubuntu系统中的引导程序GRUB
如果你的电脑上同时安装了两个系统，当你的Ubuntu 升级后，windows或Fedora就将不再在你的grub列表中了。当你安装了windows或Fedora时，先安装的Ubuntu却不能启动，因为其grub已经被清除了。可以利用自生系统（live CD或live USB）中的Boot-Repair来恢复或重装Ubuntu中的Grub。Boot Repair是一个用来恢复或重装Ubuntu上的Grub引导程序的简单的图形界面工具。为了恢复grub，你需要有一个Ubuntu自生系统（live CD 或者live USB）。可以按如下步骤来做：