<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<body text="#000000" bgcolor="#FFFFFF">
<p>Dear Gui Wei,</p>
<p>why do you need to use sumpdos.x? You can also use other tools.
In fact, you only want to sum the same column<br>
of many different files, right? Google helps. Something like this
should work:<br>
<br>
<a class="moz-txt-link-freetext" href="https://unix.stackexchange.com/questions/182758/sum-two-columns-from-different-files">https://unix.stackexchange.com/questions/182758/sum-two-columns-from-different-files</a><br>
<br>
So, you can use:<br>
<br>
paste file1 file2 | awk '{ print $3 + $13; }'<br>
<br>
but doing this for 64 files might be hard. What about:<br>
<br>
<a class="moz-txt-link-freetext" href="https://askubuntu.com/questions/963011/adding-columns-from-multiple-files-with-numbered-names">https://askubuntu.com/questions/963011/adding-columns-from-multiple-files-with-numbered-names</a><br>
<br>
Thus, something like this:<br>
<br>
awk '{a[FNR]=$1;b[FNR]+=$2;c[FNR]+=$3;d[FNR]+=$4;e[FNR]+=$5}
END{for (i=1;i<=FNR;i++) print a[i], b[i], c[i], d[i], e[i]}'
C.pdos_atm#{1..64}(\C\)_wfc#2\(p\) >> total_C_pdos.dat<br>
<br>
Now you have in the 3rd column of total_C_pdos.dat the total pz
pDOS.</p>
<p>Regards</p>
<p>Thomas<br>
</p>
<br>
<div class="moz-cite-prefix">On 12/12/18 14:40, IORI, Federico
wrote:<br>
</div>
<blockquote type="cite"
cite="mid:CACE-OVUev-aWJV1e0g8wRm=PrveB0igdHvi+E4FExu9OuYcwJQ@mail.gmail.com">
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<div dir="ltr">
<div dir="ltr">
<div dir="ltr">To me this information is not directly given in
QE.
<div>Or you change your basis set for a localised basis set
(not QE code) or you try a wannier expansion in case </div>
<div><br>
</div>
<div><a
href="https://www.quantum-espresso.org/Doc/pp_user_guide/node8.html"
moz-do-not-send="true">https://www.quantum-espresso.org/Doc/pp_user_guide/node8.html</a><br>
</div>
<div><br>
</div>
<div><a href="http://ermes.unt.edu/Tutorial_Proj.pdf"
moz-do-not-send="true">http://ermes.unt.edu/Tutorial_Proj.pdf</a><br>
</div>
<div><br>
</div>
<div><br>
</div>
</div>
</div>
</div>
<br>
<div class="gmail_quote">
<div dir="ltr">On Wed, Dec 12, 2018 at 2:23 PM Gui Wei <<a
href="mailto:201707021019@cqu.edu.cn" moz-do-not-send="true">201707021019@cqu.edu.cn</a>>
wrote:<br>
</div>
<blockquote class="gmail_quote" style="margin:0px 0px 0px
0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><font
face="Times New Roman" size="4">Hi,</font>
<div>
<div style="text-indent:0px"><font face="Times New Roman"
size="4"><span style="text-indent:6pt" lang="EN-US"><span style="white-space:pre-wrap"> </span>Thanks
for your reply.</span><span style="text-indent:6pt"
lang="EN-US"> When I use your
method,</span><span style="text-indent:6pt"
lang="EN-US">I got the same result as before.That is
two columns
of data:</span><span style="text-indent:6pt"
lang="EN-US"> </span><span style="text-indent:6pt"
lang="EN-US">E (eV) pdos(E),</span><span
style="text-indent:6pt" lang="EN-US"> </span><span
style="text-indent:6pt" lang="EN-US">Where pdos(E)</span><span
style="text-indent:6pt" lang="EN-US"> </span><span
style="text-indent:6pt" lang="EN-US">contains the sum
of three items:Pz,Px,Py.</span><span
style="text-indent:6pt" lang="EN-US"> </span><span
style="text-indent:6pt" lang="EN-US">But my purpose is
to only sum the Pz orbital's
states of each atom.</span></font></div>
<div style="text-indent:0px"><font face="Times New Roman"
size="4"><span style="text-indent:6pt" lang="EN-US"><br>
</span></font></div>
<div style="text-indent:0px">
<div><font face="Times New Roman" size="4">Gui Wei</font></div>
<div><font face="Times New Roman" size="4">School of
Mechanical Engineering,Chongqing University, China</font></div>
</div>
<div style="text-indent:0px"><font face="Times New Roman"
size="4"><span style="text-indent:6pt" lang="EN-US"><br>
</span></font></div>
<div><br>
<blockquote name="replyContent"
class="gmail-m_585969441599762682ReferenceQuote"
style="padding-left:5px;margin-left:5px;border-left:2px
solid rgb(182,182,182);margin-right:0px">-----原始邮件-----<br>
<b>发件人:</b><span id="gmail-m_585969441599762682rc_from">"IORI,
Federico" <<a
href="mailto:federico.iori@airliquide.com"
target="_blank" moz-do-not-send="true">federico.iori@airliquide.com</a>></span><br>
<b>发送时间:</b><span
id="gmail-m_585969441599762682rc_senttime">2018-12-12
18:18:06 (星期三)</span><br>
<b>收件人:</b> <a
href="mailto:users@lists.quantum-espresso.org"
target="_blank" moz-do-not-send="true">users@lists.quantum-espresso.org</a><br>
<b>抄送:</b> <br>
<b>主题:</b> Re: [QE-users] Superposition of 2Pz orbital's
states<br>
<br>
<div dir="ltr">Hi.
<div><br>
</div>
<div>My quick and dirty homemade way</div>
<div><br>
</div>
<div><span style="font-family:monospace,monospace">ls
-1 pdos_atm* > list.dat</span><br>
</div>
<div><font face="monospace, monospace">grep "(p"
list.dat > list_2p.dat<br>
sumpdos.x -f list_2p.dat > pdos_2p.dat </font><br>
</div>
<div><font face="monospace, monospace"><br>
</font></div>
<div><font face="monospace, monospace">HTH</font></div>
<div><font face="monospace, monospace"><br>
</font></div>
<div><font face="monospace, monospace">ff</font></div>
</div>
<br>
<div class="gmail_quote">
<div dir="ltr">On Wed, Dec 12, 2018 at 10:39 AM Gui
Wei <<a href="mailto:201707021019@cqu.edu.cn"
target="_blank" moz-do-not-send="true">201707021019@cqu.edu.cn</a>>
wrote:<br>
</div>
<blockquote class="gmail_quote" style="margin:0px 0px
0px 0.8ex;border-left:1px solid
rgb(204,204,204);padding-left:1ex">
<div><span style="text-indent:7pt" lang="EN-US"><font
face="Times New Roman" size="4">Hi,</font></span></div>
<div><font face="Times New Roman" size="4"><span
style="text-indent:7pt" lang="EN-US">When I
sum the pdos for 2p orbitals of 64 carbon
atoms with sumpdos.x : ./sumpdos.x
C.pdos_atm#1(\C\)_wfc#2\(p\)
C.pdos_atm#2(\C\)_wfc#2\(p\)……C.pdos_atm#64(\C\)_wfc#2\(p\).I
obtain the result that contains only <a
name="m_585969441599762682_m_5434891892472965177_OLE_LINK1"
moz-do-not-send="true">two columns</a> of
data:E(eV)and pdos(E) rather than four
columns:E(eV) pdos(E) pdos(E) pdos(E).</span><span
style="text-indent:7pt" lang="EN-US"> </span><span
style="text-indent:7pt" lang="EN-US">But what
I care about is the result of superposition of
2Pz </span><span style="text-indent:7pt"
lang="EN-US">orbital's states.</span><span
style="text-indent:7pt" lang="EN-US"> </span><span
style="text-indent:7pt" lang="EN-US">Is there
any easy way to quickly count the data I
want?</span></font></div>
<div><span style="text-indent:7pt" lang="EN-US"><font
face="Times New Roman" size="4"><br>
</font></span></div>
<div><span style="text-indent:7pt" lang="EN-US"><font
face="Times New Roman" size="4"><br>
</font></span></div>
<div><span style="text-indent:7pt" lang="EN-US"><font
face="Times New Roman" size="4">
<div style="text-indent:0px">Gui Wei</div>
<div style="text-indent:0px">School of
Mechanical Engineering,Chongqing University,
China</div>
</font></span></div>
_______________________________________________<br>
users mailing list<br>
<a href="mailto:users@lists.quantum-espresso.org"
target="_blank" moz-do-not-send="true">users@lists.quantum-espresso.org</a><br>
<a
href="https://lists.quantum-espresso.org/mailman/listinfo/users"
rel="noreferrer" target="_blank"
moz-do-not-send="true">https://lists.quantum-espresso.org/mailman/listinfo/users</a></blockquote>
</div>
<br clear="all">
<div><br>
</div>
-- <br>
<div dir="ltr"
class="gmail-m_585969441599762682gmail_signature">
<div dir="ltr">
<div>
<div dir="ltr">
<div>
<div dir="ltr">
<div>
<div dir="ltr">
<div>
<div dir="ltr">
<div>
<div dir="ltr">
<div><span style="background-color:transparent;font-family:Arial;font-size:10pt;font-weight:700;white-space:pre-wrap">Federico IORI</span><br>
</div>
<div><span>
<p dir="ltr"
style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:10pt;font-family:Arial;background-color:transparent;font-style:italic;vertical-align:baseline;white-space:pre-wrap">Computational material scientist</span></p>
<p
style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="background-color:transparent;color:rgb(61,133,198);font-family:Arial;font-size:11pt;font-style:italic;font-weight:700;white-space:pre-wrap">Paris-Saclay Research Center</span></p>
<p dir="ltr"
style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:9pt;font-family:Arial;background-color:transparent;vertical-align:baseline;white-space:pre-wrap"><a href="https://www.google.com/maps/place/Air+Liquide/@48.8297381,2.2016685,11.75z/data=%214m5%213m4%211s0x47e67e61a4fbbdc7:0xca3bea9e80059880%218m2%213d48.7630415%214d2.1333045" style="color:rgb(17,85,204);font-family:arial,sans-serif;font-size:12.8px;white-space:normal" target="_blank" moz-do-not-send="true">1 chemin de la Porte des Loges</a>
<span style="font-family:arial,sans-serif;font-size:12.8px;white-space:normal">Les Loges en Josas – 78354 Jouy en Josas cedex</span>
<span style="font-family:arial,sans-serif;font-size:12.8px;white-space:normal">Mail</span><span style="font-family:arial,sans-serif;font-size:12.8px;white-space:normal">: <a href="mailto:federico.iori@airliquide.com" target="_blank" moz-do-not-send="true">federico.iori@airliquide.com</a></span>
</span></p>
<p dir="ltr"
style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:9pt;font-family:Arial;background-color:transparent;vertical-align:baseline;white-space:pre-wrap">Phone: +33 7 621 605 15</span></p>
<p dir="ltr"
style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:9pt;font-family:Arial;background-color:transparent;vertical-align:baseline;white-space:pre-wrap"><img src="https://lh5.googleusercontent.com/jWge08q7BtEKOlxuBF_cj804ywzhJmkjw9rEb5dBZLKyUL_HQkVwhcwNi9vtzVTj-EiY-wQhE18VPSACNFaAFCAWvxp6bEwkTDR6-IjGBqp-Y3Afzx-OxN8OHxXYPLS0Dz9tP8fr" style="border: none;" moz-do-not-send="true" width="165" height="40"></span></p>
<p dir="ltr"
style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><br>
</p>
</span></div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</blockquote>
</div>
</div>
_______________________________________________<br>
users mailing list<br>
<a href="mailto:users@lists.quantum-espresso.org"
target="_blank" moz-do-not-send="true">users@lists.quantum-espresso.org</a><br>
<a
href="https://lists.quantum-espresso.org/mailman/listinfo/users"
rel="noreferrer" target="_blank" moz-do-not-send="true">https://lists.quantum-espresso.org/mailman/listinfo/users</a></blockquote>
</div>
<br clear="all">
<div><br>
</div>
-- <br>
<div dir="ltr" class="gmail_signature">
<div dir="ltr">
<div>
<div dir="ltr">
<div>
<div dir="ltr">
<div>
<div dir="ltr">
<div>
<div dir="ltr">
<div>
<div dir="ltr">
<div><span style="background-color:transparent;font-family:Arial;font-size:10pt;font-weight:700;white-space:pre-wrap">Federico IORI</span><br>
</div>
<div><span>
<p dir="ltr"
style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:10pt;font-family:Arial;background-color:transparent;font-style:italic;vertical-align:baseline;white-space:pre-wrap">Computational material scientist</span></p>
<p
style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="background-color:transparent;color:rgb(61,133,198);font-family:Arial;font-size:11pt;font-style:italic;font-weight:700;white-space:pre-wrap">Paris-Saclay Research Center</span></p>
<p dir="ltr"
style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:9pt;font-family:Arial;background-color:transparent;vertical-align:baseline;white-space:pre-wrap"><a href="https://www.google.com/maps/place/Air+Liquide/@48.8297381,2.2016685,11.75z/data=%214m5%213m4%211s0x47e67e61a4fbbdc7:0xca3bea9e80059880%218m2%213d48.7630415%214d2.1333045" style="color:rgb(17,85,204);font-family:arial,sans-serif;font-size:12.8px;white-space:normal" target="_blank" moz-do-not-send="true">1 chemin de la Porte des Loges</a>
<span style="font-family:arial,sans-serif;font-size:12.8px;white-space:normal">Les Loges en Josas – 78354 Jouy en Josas cedex</span>
<span style="font-family:arial,sans-serif;font-size:12.8px;white-space:normal">Mail</span><span style="font-family:arial,sans-serif;font-size:12.8px;white-space:normal">: <a href="mailto:federico.iori@airliquide.com" target="_blank" moz-do-not-send="true">federico.iori@airliquide.com</a></span>
</span></p>
<p dir="ltr"
style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:9pt;font-family:Arial;background-color:transparent;vertical-align:baseline;white-space:pre-wrap">Phone: +33 7 621 605 15</span></p>
<p dir="ltr"
style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:9pt;font-family:Arial;background-color:transparent;vertical-align:baseline;white-space:pre-wrap"><img src="https://lh5.googleusercontent.com/jWge08q7BtEKOlxuBF_cj804ywzhJmkjw9rEb5dBZLKyUL_HQkVwhcwNi9vtzVTj-EiY-wQhE18VPSACNFaAFCAWvxp6bEwkTDR6-IjGBqp-Y3Afzx-OxN8OHxXYPLS0Dz9tP8fr" style="border: none;" moz-do-not-send="true" width="165" height="40"></span></p>
<p dir="ltr"
style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><br>
</p>
</span></div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<br>
<pre wrap="">_______________________________________________
users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:users@lists.quantum-espresso.org">users@lists.quantum-espresso.org</a>
<a class="moz-txt-link-freetext" href="https://lists.quantum-espresso.org/mailman/listinfo/users">https://lists.quantum-espresso.org/mailman/listinfo/users</a></pre>
</blockquote>
<br>
<pre class="moz-signature" cols="72">--
Dr. rer. nat. Thomas Brumme
Wilhelm-Ostwald-Institute for Physical and Theoretical Chemistry
Leipzig University
Phillipp-Rosenthal-Strasse 31
04103 Leipzig
Tel: +49 (0)341 97 36456
email: <a class="moz-txt-link-abbreviated" href="mailto:thomas.brumme@uni-leipzig.de">thomas.brumme@uni-leipzig.de</a>
</pre>
</body>
</html>