<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
</head>
<body>
<style type="text/css" style="display:none;"><!-- P {margin-top:0;margin-bottom:0;} --></style>
<div id="divtagdefaultwrapper" style="font-size:12pt;color:#000000;font-family:Calibri,Helvetica,sans-serif;" dir="ltr">
<p><font style="font-family: Calibri, Helvetica, sans-serif, serif, "EmojiFont";" size="3" face="Calibri,Helvetica,sans-serif" color="black"><span style="font-size:12pt;" dir="ltr" id="divtagdefaultwrapper">> Note that by default the second Hubbard channel
 per atom is of the "s character".</span></font><br>
</p>
<p><br>
</p>
<p>Sorry, this is true for most elements. But just for a few elements the second Hubbard channel is not of the s character. One should always check "<span>set_hubbard_l_back</span>".
<br>
</p>
<p><br>
</p>
<p>In the (near) future we would like to make it possible to specify the Hubbard channels (i.e. orbitals to which the Hubbard correction is applied) from the input, and not to have it hard-coded in 
<span>set_hubbard_l</span> and <span>set_hubbard_l_back</span>. <br>
</p>
<p><br>
</p>
<p>Greetings,</p>
<p>Iurii<br>
</p>
<p><br>
</p>
<div id="Signature">
<div id="divtagdefaultwrapper" dir="ltr" style="font-size: 12pt; color: rgb(0, 0, 0); font-family: Calibri, Helvetica, sans-serif, "EmojiFont", "Apple Color Emoji", "Segoe UI Emoji", NotoColorEmoji, "Segoe UI Symbol", "Android Emoji", EmojiSymbols;">
<div name="divtagdefaultwrapper" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:; margin:0">
<div name="divtagdefaultwrapper" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:; margin:0">
<font size="3" face="'Times New Roman', Times, serif" color="808080">--<br>
Dr. Iurii TIMROV<br>
Postdoctoral Researcher<br>
<font color="808080"><font face="'Times New Roman', Times, serif"></font></font></font></div>
<font color="808080"></font>
<div name="divtagdefaultwrapper" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:; margin:0">
<font size="3" face="'Times New Roman', Times, serif" color="808080">STI - IMX <font color="808080">
<font face="'Times New Roman', Times, serif">- THEOS</font></font></font><font size="3" face="'Times New Roman', Times, serif" color="808080"> and NCCR - MARVEL<br>
</font></div>
<div name="divtagdefaultwrapper" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:; margin:0">
<font size="3" face="'Times New Roman', Times, serif" color="808080"><font size="3" face="'Times New Roman', Times, serif" color="808080">Swiss Federal Institute of Technology Lausanne (EPFL<font color="808080"><font face="'Times New Roman', Times, serif">)</font></font></font><br>
</font></div>
<font color="808080"></font>
<div name="divtagdefaultwrapper" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:; margin:0">
<font size="3" face="'Times New Roman', Times, serif" color="808080">CH-1015 Lausanne, Switzerland<br>
+41 21 69 34 881</font></div>
<div name="divtagdefaultwrapper" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:; margin:0">
<a href="http://people.epfl.ch/265334" tabindex="0" id="LPNoLP">http://people.epfl.ch/265334</a><br>
</div>
</div>
</div>
</div>
</div>
<hr style="display:inline-block;width:98%" tabindex="-1">
<div id="divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" style="font-size:11pt" color="#000000"><b>From:</b> users <users-bounces@lists.quantum-espresso.org> on behalf of Timrov Iurii <iurii.timrov@epfl.ch><br>
<b>Sent:</b> Tuesday, August 18, 2020 10:50:28 AM<br>
<b>To:</b> users@lists.quantum-espresso.org<br>
<b>Subject:</b> Re: [QE-users] On-site Hubbard U for background orbitals</font>
<div> </div>
</div>
<div><style type="text/css" style="display:none;"><!-- P {margin-top:0;margin-bottom:0;} --></style>
<div id="divtagdefaultwrapper" style="font-size:12pt;color:#000000;font-family:Calibri,Helvetica,sans-serif;" dir="ltr">
<p>Dear Will,</p>
<p><br>
</p>
<p>The implementation of the multi-channel DFT+U and DFT+U+V codes is in the experimental stage (please use it with
<span>caution</span>), we are still working on it to make it more user-friendly and robust. This is why there is no much documentation about it yet.</p>
<p><br>
</p>
<p>In principle, yes you can use the DFT+U+V <span>machinery</span> to do what you want: to apply two different U values to 4f and 5d states of Gd and set V to zero. But actually there is a multi-channel implementation also in the DFT+U
<span>machinery</span>, but this was not advertised yet for the reasons mentioned above. But you can see some examples in q-e-6.6/<span>test-suite/pw_lda+U</span> (in you case you should check "<span>lda+U_background_one_channel.in"</span>).
<br>
</p>
<p><br>
</p>
<p></p>
<div>> Error in routine init_lda_plus_u (1):<br>
>      lda_plus_u calculation but Hubbard_l not set</div>
<p></p>
<p><br>
</p>
<p>I presume that you get this problem because there is something wrong in your input. If you share your input it would be useful to find what is wrong.</p>
<p><br>
</p>
<p>Note that by default the second Hubbard channel per atom is of the "s character". If you want to change it to something else, then you need to modify the routine "<span>set_hubbard_l_back</span>". The main Hubbard channel is specified in "<span>set_hubbard_l</span>"
 (in your case for Gd it is hard-coded and it is 4f), and the secondary ("background" [1]) Hubbard channel is specified in "<span>set_hubbard_l_back</span>" (in your case for Gd you need to specify that it is the d channel, i.e. <span>hubbard_l_back</span>
 = 2). This modification must be done for both DFT+U and DFT+U+V <span>machineries.</span><br>
</p>
<p><br>
</p>
<p>Greetings,</p>
<p>Iurii<br>
</p>
<p><br>
</p>
<p></p>
<div>[1] Note, the terminology "<span>background</span>" is a bit misleading. It should not be called like that (in general), because this is just a second Hubbard channel per atom. It is called "<span>background</span>" for historical reasons: this secondary
 (background) channel was originally implemented to do something else and hence it has such a name. But we want to change this naming, and only then advertise these features to the QE community.</div>
<br>
<p></p>
<div id="Signature">
<div id="divtagdefaultwrapper" dir="ltr" style="font-size: 12pt; color: rgb(0, 0, 0); font-family: Calibri, Helvetica, sans-serif, "EmojiFont", "Apple Color Emoji", "Segoe UI Emoji", NotoColorEmoji, "Segoe UI Symbol", "Android Emoji", EmojiSymbols;">
<div name="divtagdefaultwrapper" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:; margin:0">
<div name="divtagdefaultwrapper" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:; margin:0">
<font size="3" face="'Times New Roman', Times, serif" color="808080">--<br>
Dr. Iurii TIMROV<br>
Postdoctoral Researcher<br>
<font color="808080"><font face="'Times New Roman', Times, serif"></font></font></font></div>
<font color="808080"></font>
<div name="divtagdefaultwrapper" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:; margin:0">
<font size="3" face="'Times New Roman', Times, serif" color="808080">STI - IMX <font color="808080">
<font face="'Times New Roman', Times, serif">- THEOS</font></font></font><font size="3" face="'Times New Roman', Times, serif" color="808080"> and NCCR - MARVEL<br>
</font></div>
<div name="divtagdefaultwrapper" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:; margin:0">
<font size="3" face="'Times New Roman', Times, serif" color="808080"><font size="3" face="'Times New Roman', Times, serif" color="808080">Swiss Federal Institute of Technology Lausanne (EPFL<font color="808080"><font face="'Times New Roman', Times, serif">)</font></font></font><br>
</font></div>
<font color="808080"></font>
<div name="divtagdefaultwrapper" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:; margin:0">
<font size="3" face="'Times New Roman', Times, serif" color="808080">CH-1015 Lausanne, Switzerland<br>
+41 21 69 34 881</font></div>
<div name="divtagdefaultwrapper" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:; margin:0">
<a href="http://people.epfl.ch/265334" tabindex="0" id="LPNoLP">http://people.epfl.ch/265334</a><br>
</div>
</div>
</div>
</div>
</div>
<hr style="display:inline-block;width:98%" tabindex="-1">
<div id="divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" style="font-size:11pt" color="#000000"><b>From:</b> users <users-bounces@lists.quantum-espresso.org> on behalf of William Hewett <williamholmeshewett1@gmail.com><br>
<b>Sent:</b> Tuesday, August 18, 2020 4:35:59 AM<br>
<b>To:</b> users@lists.quantum-espresso.org<br>
<b>Subject:</b> [QE-users] On-site Hubbard U for background orbitals</font>
<div> </div>
</div>
<div>
<div dir="ltr"><font color="#000000">Hi all,</font>
<div><font color="#000000"><br>
</font></div>
<div><font color="#000000">I'm interested in doing DFT+U calculations on the rare earth mono-nitride GdN. The most successful calculations in the past have used multiple Hubbard U terms (U_f and U_d) on the 4f and 5d electron channels on the Gd ion. This has
 been done before using QE (<font face="arial, sans-serif"><span style="white-space:nowrap">Comput. Mater. Sci 95 (2014) 263-270</span>)</font>. </font></div>
<div><font color="#000000"><br>
</font></div>
<div><font color="#000000">I suspect that in v6.6 this may now be possible in the stable branch via an onsite Hubbard V term on both the standard and background orbitals?</font></div>
<div><font color="#000000"><br>
</font></div>
<div><font color="#000000">The pw.x input guide gives that Hubbard_V(na,na,k) will be the onsite Hubbard interaction. After setting the appropriate values for the background n, l and occupations of Gd in:</font></div>
<div><font color="#000000"><br>
</font></div>
<div><font color="#000000">Modules/set_hubbard_l.f90</font></div>
<div><font color="#000000">Modules/set_hubbard_n.f90</font></div>
<div><font color="#000000">PW/src/tabd.f90</font></div>
<div><font color="#000000"><br>
</font></div>
<div><font color="#000000">and increasing sc_size = 3 in Modules/parameters.f90</font></div>
<div><font color="#000000"><br>
</font></div>
<div><font color="#000000">and compiling the code, I've used the following in the &SYSTEM block:</font></div>
<div><font color="#000000"><br>
</font></div>
<div><font color="#000000">lda_plus_u=.true.</font></div>
<div><font color="#000000">lda_plus_u_kind=2</font></div>
<div><font color="#000000">Hubbard_V(1,1,1)=a</font></div>
<div><font color="#000000">Hubbard_V(1,1,3)=b<br>
</font></div>
<div><font color="#000000"><br>
</font></div>
<div><font color="#000000">I guess there will now be two Hubbard terms on that atom at side na, on the standard and background orbitals.</font></div>
<div><font color="#000000"><br>
</font></div>
<div><font color="#000000">However, I find the following error:</font></div>
<div><font color="#000000"><br>
</font></div>
<div>Error in routine init_lda_plus_u (1):<br>
     lda_plus_u calculation but Hubbard_l not set</div>
<div><font color="#000000"><br>
</font></div>
<div><font color="#000000">Any help is appreciated, </font><span style="color:rgb(0,0,0)">I'm running QE 6.6 on Ubuntu 20.04.</span></div>
<div><font color="#000000"><br>
</font></div>
<div><font color="#000000">Thanks</font></div>
<div><br>
</div>
<div><font color="#000000">Will Hewett</font></div>
<div><font color="#000000">Postdoctoral Researcher</font></div>
<div><font color="#000000">Victoria University of Wellington</font></div>
<div><font color="#000000">New Zealand</font></div>
</div>
</div>
</div>
</body>
</html>