Friday, October 19, 2012

Install Lyx in my local account

These 4 steps will compile, test and install LyX:

    0) Linux users beware: You need qt4 and qt4-devel packages
       of the same version to compile LyX.

    1) ./configure
         if you want to install LyX at your own local account, you should then use
       ./configure --prefix=$HOME

    2) make
       compiles the program.

    3) src/lyx
       runs the program so you can check it out.

    4) make install
       will install it. You can use "make install-strip" instead
           if you want a smaller binary.


Last point, when you first start LyX, you do the '/Tools/Reconfigure'  in order to make many template available.

Wednesday, September 5, 2012

Bandstructure and DoS calculation

Some basic understanding that deserved to be mentioned here:

1. Bandstructure calculation requires the system has translational invariance, which means the system should be a infinite system with certain lattice symmetry, otherwise there is now meaning for the definition of momentum .  So basically, we should calculate the bandstructure of the studied system in a 'lead' or at least should treat it as a lead.

2 DoS is by the same argument should be calculate inside a lead. And the system should not be 'finalize()' before your calculation of DoS or bandstructure.

Tuesday, September 4, 2012

Collection of Questions for Poster section for the windsor summer

Q1: Why gap closing does not observed in your dI/dV curve as those observed in the LDOS?

A1: As the paper"T. Stanescu et al, arXiv:1206.0013v1(2012)", the LDOS cannot fully represent the whole information of the system. And as you see the joining of the peak in the LDOS in the paper mentioned about is parameters dependent. So if we can find the good parameter, we believe we can also see the process of joining of the peaks.


Q2: Disorder open SC gap, and make SC proximity effect large, why?

A2: According to the paper "P. G. de Gennes and D. Saint-James, Phys. Letter 4, 151(1963)" and "C. W. J. Bennakker, Lect. Notes. Phys. 667, 131(2005)", the formula showed in the poster. When there are disorder impurities in the system, they will make the scattering more intense and thus the long rang scattering which has large parallel momentum is suppressed. Only left the scattering that are nearly perpendicular to the SC-NW interfaces. Thus leading to the small T(p||), and thus large E_gap.


 Q3: What could it be if we add a SC term directly in H_1D instead of writing a BdG Hamiltonian?
A3: For the SC Hamiltonian, it is always has the form of BdG.


Q4: What makes the Rashba double parabolic band splited?
A4: The Zeemam terms


Q5: Change chemical potential will bring what change?
A5: Chemical potential is always in the gap. However, you can always change chemical potential in your numerical calculation and those change gate voltage in the experiment. If the system has multi-subband, you can tune your chemical potential within each subband (which is formed due to the confinement).


Q6: What are the many other peaks? Why they form? And what does disorder do with them?

A6: The other peaks are due to multi-band, or modes, or channels which will essentially bring to different Andreev-reflections. We conclude that weak disorder will kill the other modes(peaks), and open the gap.

Q7: What is the difference between V_bias, and V_gate?
A7: V_bias are the voltage difference between Normal lead and SC lead. However, V_gate is the applied electric field control the chemical potential in the NW system. They are quiet different concepts.


Thursday, July 26, 2012

《幽兰操》 韩愈

一个君子是能处于不利的环境而保持他的志向和德行操守的
韩愈《幽兰操》:


兰之猗猗,扬扬其香。
不采而佩,于兰何伤。
今天之旋,其曷为然。
我行四方,以日以年。
雪霜贸贸,荠麦之茂。
子如不伤,我不尔觏。
荠麦之茂,荠麦之有。
君子之伤,君子之守。

Wednesday, July 25, 2012

Python print in the same line successively

The question is like in python code:
for i inrange(1,100):
    print i

And the output is like:
1
2
3
.
.
99

I want it to print in the same line like: 1 2 3 . . . 99
Solution: use ',' to prevent starting from a new line:
for i in range(1,100):
    print i,
Another thing is that if you want to start something from a new line, you should use '\n' in either 'print '\n' ' or '.write('\n')'

git basic

Normally, there is a classification of bare (empty) repository and non-bare repository. The bare repository is serving as a central media to connect any information to the other repositories. And there is always your working repository where you make change and improvment to your files inside.  Whenever you have made some change in your working repository, you should push it to the bare repository. And from your other computers other where or your account on cluster, you should 'git fectch' or 'git reset --hard' to the bare repository on your server.

Here is some basic procedures that one can build your repositories:
  • Making a local "non-bare" working repository, add a folder and files inside under git version control:
    1. We start from mkdir an empty folder
    2. mkdir wire
      cd wire
      git init
    3. And then copy the files to wire
    4. Add all the files inside folder 'wire', and git commit them all

    5. git add *
      git commit -a
      # Note, it is very important not to include .pyc, .py~ files otherwise your will get much unnecessary and unexpected trouble in the future
    6. Edit git comment to provide some information about the version and descripiton comment. And also you can add user name and email information about it:
      git config --global user.name "Voornaam Achternaam"
      git config --global user.email "aaa@bbb.com"
      git config --global core.editor "my favorate editor" #e.g. vim, nano, less
  • Make a bare repository, a remote copy of your local working reposiotry:
    1. making a remote bare repository using ssh to our server: ssh name@ssh.lorentz.leidenuniv.nl
      mkdir repo/wire.git
      cd repo/wire.git
      git init --bare
      exit
    2. Go back to your local working repository, and make remote add, and push your local repository to the remote bare repository wire.git at the server:

    3. git remote add origin name@ssh.lorentz.leidenuniv.nl:repo/wire.git
      git push origin master
    4. Note here "origin" is a name you can choose for the remote bare repository, you can name it for whatever you want, and you can check the all the remote repositories name or choose to delete them by using the command below
    5. git remote # check all the name of remote repository
      git remote rm aaa # remove the remote repository whose name is aaa
    6. After your git push from you local non-bare repository to the bare repository, you can go to your server and using "gitk --all" (if you have that) to check out the status, or using "git status". You can always use these command to check the status and branch.
  • Get a copy of a remote bare repository:
    1. If it is from your own computer or server account

    2. git clone /repo/wire.git
      git clone name:ssh.lorent.leidenuniv.nl:repo/wire.git
    3. If it is from other computer or server account

    4. git clone ~/otheruser/repo/hie_or_her_project.git
      git clone name:ssh.lorent.leidenuniv.nl:~otheruser/repo/his_or_her_project.git

      Note, unless you want to make some change in this repository (but usually people do not make change here), do not first make this folder 'git init'. Here you just copy or fetch it from a remote repository. You will always working and make file changes in you local non-bare working repository, i.e. wire here, and then push the changed files to ~repo/wire.git. You will always keep up changes from wire.git by using 'git fetch'. Make sure you understand this information flow direction once you made some change.
  • Keep up with changes from remote repositories:

    1. Once you make some change in your local non-bare working repository, you git push it to the bare repository, and to keep up the change at other places from this non-repository you need to:
    2. git fetch origin (or --all)
      git reset --hard origin
      Or you can delete the folder and make git clone, see above section
    3. In order to make sure you have the same version, you go to your copied repository and check

    4. git describe --always

      This will return a series number which identify the version of your repository, which is made after each time you made change in your working repository and git commit them. Each version has a unique version series number. So this number here should be coincides with the same number you using 'git describe --always' at your local non-bare working repository.