<html>
<head>
<style><!--
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 10pt;
font-family:Tahoma
}
--></style></head>
<body class='hmmessage'><div dir='ltr'>
Dear Giuseppe,<br>Deepest thanks for your advice.<br>Your suggestion is really helpful and inspiring.<br>If you are in Singapore, I would like to buy you a cup of coffee,<img style="border-style: none; vertical-align: text-bottom;" title="Open-mouth smile" alt="Open-mouth smile" src="http://gfx1.hotmail.com/mail/w4/pr04/ltr/emo/open_mouthed_smile.gif" height="19" width="19"><br>Cheers~,<br><font style="font-size: 10pt;" size="2"><br></font><font style="font-size: 12pt;" size="3"><font style="" color="#4f81bd"><font face="Franklin Gothic Medium"><br></font>Franklin<br></font></font><font style="" face="Franklin Gothic Medium"><font color="#4f81bd" size="3">
<hr id="ecxEC_EC_EC_EC_EC_EC_[object]">
Franklin Zhan<br> <br>Ph.D student<br>School of Mechanical and Aerospace Engineering,<br>Nanyang Technological University, Singapore.<br></font></font><font style="" face="Comic Sans MS"><br><br></font><br><br><br><div><div id="SkyDrivePlaceholder"></div>> From: giuseppe.mattioli@ism.cnr.it<br>> To: pw_forum@pwscf.org<br>> Date: Wed, 25 Jul 2012 09:16:43 +0200<br>> Subject: Re: [Pw_forum] how to calculate and plot HOMO or LUMO isosurface<br>> <br>> <br>> Dear Felipe<br>> You seem not to be a chemist...:-)<br>> The ground state of an O2 molecule is a triplet one, with 7 up valence electrons and 5 down.<br>> <br>> Dear Zhan<br>> This morning (morning in Italy, at least) you are lucky. I've done (almost) the same thing <br>> yesterday...<br>> <br>> Once the above is settled, first you should perform a relax calculation with K_POINTS (gamma). You do <br>> not need a nscf calculation if you use a bit of smearing. Something like<br>> <br>> &control<br>> calculation = 'relax'<br>> prefix='$FILE',<br>> pseudo_dir = '$PSEUDO_DIR/',<br>> outdir='$TMP_DIR/',<br>> /<br>> &system<br>> ibrav=1, celldm(1)=30.000000,<br>> nat=2, ntyp=1,<br>> ecutwfc =35.0,<br>> ecutrho =280.0,<br>> occupations='smearing', degauss=0.01,<br>> nspin=2,<br>> starting_magnetization(1)=0.3,<br>> /<br>> &electrons<br>> mixing_mode='plain'<br>> mixing_beta=0.3<br>> conv_thr=1.0d-7<br>> electron_maxstep=200<br>> /<br>> &ions<br>> ion_dynamics='bfgs'<br>> /<br>> ATOMIC_SPECIES<br>> O 15.999 O_pbe.van.UPF<br>> ATOMIC_POSITIONS {angstrom}<br>> O 5.000576334 5.029093041 5.029093041<br>> O 5.009423666 5.870906959 5.870906959<br>> K_POINTS {gamma}<br>> <br>> will provide a sufficient number of unoccupied orbitals for your purpose.<br>> <br>> Then, remember that when you use nspin=2 and K_POINTS {gamma} you are formally using two k points <br>> (gamma up and gamma down) which are labelled as kpoint=1 and kpoint=2, respectively. In your pw.x <br>> output you should acknowledge (but you should already know it by molecular orbital theory of <br>> homonuclear diatomic molecules...) that both the HOMO in the up channel (-9.1985 -9.1983) and the <br>> LUMO in the down channel (-4.9925 -4.9924) are doubly degenerate. Thus, you must plot the single-<br>> electron orbitals and sum them.<br>> <br>> ------ SPIN UP ------------<br>> <br>> <br>> k = 0.0000 0.0000 0.0000 ( 47171 PWs) bands (ev):<br>> <br>> -34.3196 -21.0375 -17.4698 -17.4697 -14.7359 -9.1985 -9.1983 -0.6483<br>> -0.1403 -0.0924<br>> <br>> ------ SPIN DOWN ----------<br>> <br>> <br>> k = 0.0000 0.0000 0.0000 ( 47171 PWs) bands (ev):<br>> <br>> -33.1724 -19.2543 -13.7742 -12.6937 -12.6937 -4.9925 -4.9924 -0.5833<br>> -0.0519 -0.0089<br>> <br>> the Fermi energy is -8.4505 ev<br>> <br>> This is quite easy, supposing that you read carefully the pp.x input guide... But, as I said, you <br>> won a free ride today...<br>> <br>> &inputpp<br>> prefix = '$FILEA'<br>> outdir = '$TMP_DIR/'<br>> filplot = '$FILEA-HOMOa.dat'<br>> plot_num= 7<br>> kpoint=1<br>> kband=6<br>> /<br>> <br>> $PARA_PREFIX $ESPRESSO/pp.x $PARA_POSTFIX < $INPFILE >> $OUTFILE<br>> <br>> &inputpp<br>> prefix = '$FILEA'<br>> outdir = '$TMP_DIR/'<br>> filplot = '$FILEA-HOMOb.dat'<br>> plot_num= 7<br>> kpoint=1<br>> kband=7<br>> /<br>> <br>> $PARA_PREFIX $ESPRESSO/pp.x $PARA_POSTFIX < $INPFILE >> $OUTFILE<br>> <br>> <br>> &inputpp<br>> /<br>> &plot<br>> nfile = 2<br>> filepp(1) = '$FILEA-HOMOa.dat'<br>> weight(1) = 1.0<br>> filepp(2) = '$FILEA-HOMOb.dat'<br>> weight(2) = 1.0<br>> iflag = 3<br>> output_format = 5<br>> fileout = '$FILEA-HOMO.plot'<br>> e1(1) =1.0, e1(2)=1.0, e1(3) = 0.0,<br>> e2(1) =0.0, e2(2)=0.0, e2(3) = 1.0,<br>> nx=56, ny=40<br>> /<br>> <br>> $PARA_PREFIX $ESPRESSO/pp.x $PARA_POSTFIX < $INPFILE >> $OUTFILE<br>> <br>> This will produce a nice .xsf file containing your HOMO orbital, which you can plot with xcrysden. <br>> You may also obtain a cube file, but I cannot remember the output format.<br>> <br>> As for the LUMO, use kpoint=2, and the correct kband numbers and do the same thing.<br>> <br>> I hope this really help... (in Italy I would have said: you owe me a cup of coffee...)<br>> <br>> Giuseppe<br>> <br>> <br>> On Wednesday 25 July 2012 08:43:30 Filipe Camargo Dalmatti Alves Lima wrote:<br>> > Dear Zhan,<br>> > <br>> > The number of electrons on your system determines the occupied bands and<br>> > consequently the HOMO level.<br>> > <br>> > So, What you need to do?<br>> > <br>> > First, check the number of electron that you are using. (If you are using<br>> > the O default pseudopotencials it should be 6 valence electrons)<br>> > Then, you'll have 12 electrons and 6 bands (each bands is occupied by 2<br>> > electrons).<br>> > <br>> > Now check your output file, which is generated using the pw.x code.<br>> > The band number 6 represents your HOMO level and the band number 7 is the<br>> > LUMO one.<br>> > <br>> > So, now you know your bands. Then you can obtain the wavefunction.<br>> > <br>> > You will need to run the pp.x twice: one for HOMO and another for LUMO.<br>> > kband=6 (to plot HOMO)<br>> > and<br>> > kdand=7 (to plot LUMO)<br>> > <br>> > I hope it will solve your problem,<br>> > <br>> > Best regards,<br>> > <br>> > > Dear PWSCF users,<br>> > > <br>> > > I am trying to calculate HOMO and LUMO levels and plot these isosurfaces<br>> > > for O2 molecule.<br>> > > I first relaxed the O2 and then did nscf calculation. then I used pp.x to<br>> > > calculate the HOMO and LUMO levels. but I can not find the HOMO or LUMO<br>> > > level in output files.<br>> > > the code for pp.x is pasted as following:<br>> > > <br>> > > &inputpp<br>> > > <br>> > > prefix= 'O2'<br>> > > outdir= '/scratch/zhan0273/PWSCF/O2/tmp'<br>> > > <br>> > > filplot = 'O2'<br>> > > plot_num= 7<br>> > > spin_component=0<br>> > > ! kpoint=40<br>> > > kband=8<br>> > > /<br>> > > &plot<br>> > > nfile = 1<br>> > > filepp(1) = 'O2'<br>> > > weight(1) = 1.0<br>> > > iflag = 3<br>> > > output_format = 5<br>> > > fileout = 'O2.orb.xsf'<br>> > > /<br>> > > <br>> > > So please give advice. Thank you all in advance!<br>> > > <br>> > > Best regards,<br>> > > <br>> > > ------------------------------<br>> > > Franklin Zhan<br>> > > Ph.D student<br>> > > School of Mechanical and Aerospace Engineering,<br>> > > Nanyang Technological University, Singapore.<br>> > > <br>> > > <br>> > > <br>> > > <br>> > > _______________________________________________<br>> > > Pw_forum mailing list<br>> > > Pw_forum@pwscf.org<br>> > > http://www.democritos.it/mailman/listinfo/pw_forum<br>> <br>> -- <br>> ********************************************************<br>> - Article premier - Les hommes naissent et demeurent<br>> libres et ¨¨gaux en droits. Les distinctions sociales<br>> ne peuvent ¨ºtre fond¨¨es que sur l'utilit¨¨ commune<br>> - Article 2 - Le but de toute association politique<br>> est la conservation des droits naturels et <br>> imprescriptibles de l'homme. Ces droits sont la libert¨¨,<br>> la propri¨¨t¨¨, la s¨´ret¨¨ et la r¨¨sistance ¨¤ l'oppression.<br>> ********************************************************<br>> <br>> Giuseppe Mattioli <br>> CNR - ISTITUTO DI STRUTTURA DELLA MATERIA <br>> v. Salaria Km 29,300 - C.P. 10 <br>> I 00015 - Monterotondo Stazione (RM) <br>> Tel + 39 06 90672836 - Fax +39 06 90672316 <br>> E-mail: <giuseppe.mattioli@ism.cnr.it><br>> _______________________________________________<br>> Pw_forum mailing list<br>> Pw_forum@pwscf.org<br>> http://www.democritos.it/mailman/listinfo/pw_forum<br></div>                                            </div></body>
</html>