Re: [Wien] hyperfine field question in ORB package for the aluminum

2013-10-07 Thread Peter Blaha
The hyperfine field for a metal is coming mainly from the contact term 
due to the induced spin-polarization by the magnetic field.


You should notice, that a field of 9 T is (for theoretical calculations) 
an extremely small field, causing a very small spin-splitting of the 
states near EF, which causes the HFF.

I suppose all you see is numerical noise.

Since only the states at EF are of interest (the field can only reoccupy 
states within a few mRy (or less) around EF), you need to converge your 
calculation with respect to:


a) the k-mesh   (test MUCH larger meshes (1, 5 10 k or more)
b) the magnetic field (increase it and test fields up to 1000 T), You 
are not interested in the absolute number, but in ppm, i.e. the relative 
induced field.


c) The angular momentum component of the hFF introduced by 
case.vorbup/dn is NOT correct. I would even suggest that you put l=0 to
minimize the effect (or use-orbc  with case.vorbup/dn , where all 
elements are set to zero.)


d) In principle the orbital contribution should be obtainable from the 
NMR-module of wien2k_13. However, also there we observed for metals that 
it is very hard to converge with respect to k-mesh and the final results 
(sum of spin and orbital contribution) does not seem right, while 
spin-only has the correct magnitude (within 10% of the experiment). This 
is an unresolved issue for us so far.



Am 07.10.2013 04:01, schrieb Jing-Han Chen:

Dear WIEN2k users and authors

   We are currently working on the hyperfine field calculation by using
ORB package. In fcc aluminum case, we got 0.154 (KGAUSS) when the
following case.inorb and case.indm are used

case.inorb
3 1 0nmod, natorb, ipr
PRATT, 1.0mixmod, amix
1 1 0  iatom nlorb, lorb
9.Bext in T
0. 0. 1.direction of Bext in terms of lattice vectors

case.indm
-9.  Emin cutoff energy
  1   number of atoms for which density matrix is
calculated
  1  1  0  index of 1st atom, number of L's, L1
  0 0   r-index, (l,s)index

   In order to confirm how the magnetic field is applied for the
multiple sites crystal, we made aluminum as a simple cubic with 4
inequivalent sites and we believe it should be physically identical to
fcc. The following case.inorb and case.indm are used.

case.inorb
3 4 0nmod, natorb, ipr
PRATT, 1.0mixmod, amix
1 1 0  iatom nlorb, lorb
2 1 0  iatom nlorb, lorb
3 1 0  iatom nlorb, lorb
4 1 0  iatom nlorb, lorb
9.Bext in T
0. 0. 1.direction of Bext in terms of lattice vectors

case.indm
-9.  Emin cutoff energy
  4   number of atoms for which density matrix is
calculated
  1  1  0  index of 1st atom, number of L's, L1
  2  1  0  index of 1st atom, number of L's, L1
  3  1  0  index of 1st atom, number of L's, L1
  4  1  0  index of 1st atom, number of L's, L1
  0 0   r-index, (l,s)index

   Both fcc and simple cubic are run by the same way (-orb -cc 0.1).
A complete different HFFs are obtained as the following

:HFF001:0.059   0.000   0.001
0.060 (KGAUSS)
:HFF002:   -1.193   0.000  -0.010
-1.204 (KGAUSS)
:HFF003:1.681   0.000   0.011
1.692 (KGAUSS)
:HFF004:0.046   0.000   0.001
0.047 (KGAUSS)

We got four different HFFs which we thought they are supposed to be the
same. Also all of them are very far from the fcc result (0.154 KGAUSS).
Does anyone know why it happens?

   Any suggestion and comment are appreciated.

--
Jing-Han Chen
Graduate Student
Department of Physics
Texas AM University
4242 TAMU
College Station TX  77843-4242
jhc...@tamu.edu mailto:jhc...@tamu.edu jhc...@tamu.edu
mailto:jhc...@tamu.edu / http://people.physics.tamu.edu/jhchen/



___
Wien mailing list
Wien@zeus.theochem.tuwien.ac.at
http://zeus.theochem.tuwien.ac.at/mailman/listinfo/wien
SEARCH the MAILING-LIST at:  
http://www.mail-archive.com/wien@zeus.theochem.tuwien.ac.at/index.html



--
Peter Blaha
Inst.Materials Chemistry
TU Vienna
Getreidemarkt 9
A-1060 Vienna
Austria
+43-1-5880115671
___
Wien mailing list
Wien@zeus.theochem.tuwien.ac.at
http://zeus.theochem.tuwien.ac.at/mailman/listinfo/wien
SEARCH the MAILING-LIST at:  
http://www.mail-archive.com/wien@zeus.theochem.tuwien.ac.at/index.html


[Wien] Segmentation fault in f7splt (lapw2)

2013-10-07 Thread Pavel Ondračka
Dear WIEN2k mailing list,

this is a follow up to thread compilation problems on AIX with xlf90.
I've finally managed to compile WIEN2k_13 on AIX 5.3, 
however I'm now getting a segfault when running lapw2.

Segmentation fault in f7splt at line 51 in file  ($t1)
could not read f7splt.f
(dbx) where
f7splt(alm = (...), blm = (...), clm = (...), mult = 2, uenorm =
0.0028448010014590045, num = 1, coord = ' ', dmat = (...)), line 51
in f7splt.f
csplit(0xfd8f50c, 0xfd8f510, 0xfd8a718,
0xfd8976c, 0xfd8f67c, 0x11023fe30, 0x110250590,
0x110260cf0), line 78 in csplit.f
l2main(0xfffe340, 0xfffdb84, 0xfffe518,
0x1101ac4b0, 0x11b88, 0xfffdb80, 0xfffdb90,
0xfffdc48), line 1313 in l2main_tmp_.F
lapw2(), line 605 in lapw2_tmp_.F

The corresponding lines looks like this:
51  dmat(i,j,num)=dmat(i,j,num) + (alm(j)*conjg(alm(i))+ 
52  blm(j)*conjg(blm(i))*uenorm+clm(j)*conjg(clm(i))+ 
53
alm(j)*conjg(clm(i))*pi12lo(ipip,3)+clm(j)*conjg(alm(i))*pi12lo(ipip,3)+

54
blm(j)*conjg(clm(i))*pe12lo(ipip,3)+clm(j)*conjg(blm(i))*pe12lo(ipip,3)
) / mult

Going through all the variables shows suspicious value of ipip =
-2147483648, which is used as array index for pi12lo an pe12lo causing
the segfault.
By grepping through SRC_lapw2 directory I can see, that all other
subroutines which use ipip do something like this:
$grep ipip= *   
csplit.f: ipip=max(ilo(l),1)
d5splt.f: ipip=max(ilo(2),1)
p3splt.f: ipip=max(ilo(1),1)

I'm wondering if there is some similar initialization statement missing
in f7splt.f and what should be ipip set to? 

Also I hope this isn't just some result of my inexperienced efforts to
make WIEN compile on ancient AIX 5.3 or some other bad configuration. 

Best regards
Pavel Ondračka

___
Wien mailing list
Wien@zeus.theochem.tuwien.ac.at
http://zeus.theochem.tuwien.ac.at/mailman/listinfo/wien
SEARCH the MAILING-LIST at:  
http://www.mail-archive.com/wien@zeus.theochem.tuwien.ac.at/index.html


Re: [Wien] Plane average potential for surface

2013-10-07 Thread Oleg Rubel

Dear Salman,

I attached a set of files used to produce a 3D slices of potential (or 
e-density) along Z-axis using LAPW5 and MATLAB.


t-Se.in5c_tmpl is a template input file for LAPW5.

run_lapw5.sh is a script that will generate a set of input files, will 
run LAPW5 using them and store the results as a set of case.rho_.### 
files, where ### is a slice number [1...N]. You will need to edit the 
INPUT PARAMETERS section in order to provide your geometry, case name 
and identify complex calculation.


avrg_potential.m is a MATLAB script that will read case.rho_.### 
files (again the Load data section needs your input) and shape them into 
a 3D array.


After that you can do with this array what you want.

Sorry in advance, if you find the script not very user-friendly and well 
commented. It was never meant for external users. Feel free to modify 
it, if needed.



Best regards
Oleg


On 06/10/2013 1:17 PM, Salman Zarrini wrote:


Dear Oleg,

Thank you for your answer, I know how to get case.vcoul by adjusting
case.in0 and then lapw0 and lapw5, however what I am interested in is
variationof coulomb potential respect to just one dimension where vacuum
and slab are elongated(V-Z). An example of such a plot as well as my
case.vcoul, case.rho and case.struct have been enclosed.

Cheers,

Salman


--
Oleg Rubel, PhD
Scientist, Thunder Bay Regional Research Institute
Adjunct Professor, Dept Physics, Lakehead University
290 Munro St, Thunder Bay, P7A 7T1, Ontario, Canada
Phone: +1-807-7663350
Fax: +1-807-3441948
E-mail: oru...@lakeheadu.ca
Homepage: http://www.tbrri.com/~orubel/
% This programm reads the potential from *.rho_* files and performs
% its averaging
%
% (c) 02.12.2008 by Oleg Rubel

clear all;

%
%   Load data
%

fprefix = 't-Se.rho_.';  % name of the WIEN2k 'case'
nZ = 200; % number of slices alonz Z axis
nX = 17;
nY = 17;
nZstep = 19; % thickness of a pice for averaging

V = zeros( nX , nY , nZ ); % allocate V

%   Read potential from different slices
for j = 0 : nZ-1
  fname = sprintf('%s%s%s', fprefix, num2str(j));
  V(:,:,j+1) = reshape( load(fname) , nX , nY ); % check! can be '...nY,nX)'
end;

mean(mean(mean(V)))

%
%   Perform averaging along Z
%

Vavg = zeros( nZ-nZstep , 1 );
z = zeros( nZ-nZstep , 1 );
for j = 1 : nZ-nZstep
  z(j) = j;
  Vsub = V(:,:,j:j+nZstep);
  Vsub2 = Vsub(:);
  Vavg(j) = mean( Vsub2 );
end;
plot(z,Vavg)
stop
#!/bin/sh
#
# This script is intended to build a 3D map of potential (or electron
# density) of a supercell by running 'lapw5' programm of WIEN2k
#
# (c) 21.03.2008 by Oleg Rubel


# INPUT PARAMETERS #


fprefix='t-Se'
fsuffix='c'
dev=1000   # devisor
a=`echo | awk '{print 8.25}'`   # lattice constant along X [Bohr]
b=`echo $a` #Y
c=`echo | awk '{print 94.1584}'`  #Z
meshStep=`echo | awk '{print 0.47}'` # mesh step in Bohr


##
# PRINT INPUT PARAMETERS #
##
echo INPUT PARAMETERS:
echo fprefix = $fprefix
echo fsuffix = $fsuffix
echo dev = $dev
echo a = $a [Bohr]
echo b = $b [Bohr]
echo c = $c [Bohr]
echo meshStep = $meshStep [Bohr]


#
# DETERMINE NUMBER OF DIVISIONS #
#
echo CALCULATED VALUES:
nX=`echo $a $meshStep | awk '{printf %i, $1/$2}'`
nY=`echo $b $meshStep | awk '{printf %i, $1/$2}'`
nZ=`echo $c $meshStep | awk '{printf %i, $1/$2}'`
echo nX = $nX
echo nY = $nY
echo nZ = $nZ


#
# MAIN LOOP #
#

for (( i = 0; i = nZ-1; i++ ))
do
   echo i = $i of `expr $nZ - 1`
   origin1=0
   origin2=0
   origin3=`echo $nZ $dev $i | awk '{printf %i, (1.0/$1)*$2*$3}'`
   echo   origin = $origin1 , $origin2 , $origin3
   xend1=`echo $nX $dev | awk '{printf %i, (1.0-1.0/$1)*$2}'`
   xend2=0
   xend3=$origin3
   echo   xend = $xend1 , $xend2 , $xend3
   yend1=0
   yend2=`echo $nY $dev | awk '{printf %i, (1.0-1.0/$1)*$2}'`
   yend3=$origin3
   echo   yend = $yend1 , $yend2 , $yend3

   sed s/origin1/${origin1}/g;\
  s/origin2/${origin2}/g;\
  s/origin3/${origin3}/g;\
  s/dev/${dev}/g;\
  s/xend1/${xend1}/g;\
  s/xend2/${xend2}/g;\
  s/xend3/${xend3}/g;\
  s/yend1/${yend1}/g;\
  s/yend2/${yend2}/g;\
  s/yend3/${yend3}/g;\
  s/nX/${nX}/g;\
  s/nY/${nY}/g  ${fprefix}.in5${fsuffix}_tmpl  ${fprefix}.in5${fsuffix}
   sleep 1
   # run 'lapw5(c)'
   echo   run lapw5${fsuffix} lapw5.def
   lapw5${fsuffix} lapw5.def
   sleep 3
   echo   cp ${fprefix}.rho ${fprefix}.rho_${i}
   cp ${fprefix}.rho ${fprefix}.rho.${i}
   echo   cp ${fprefix}.in5${fsuffix} ${fprefix}.in5${fsuffix}.${i}
   cp ${fprefix}.in5${fsuffix} ${fprefix}.in5${fsuffix}.${i}
   echo   reformat  ${fprefix}.rho.${i} | sed '/^$/d'  ${fprefix}.rho_.${i}
   reformat  ${fprefix}.rho.${i} | sed '/^$/d'  ${fprefix}.rho_.${i}
done

echo end script
exit
origin1origin2origin3  dev
xend1  xend2  xend3dev
 

Re: [Wien] Plane average potential for surface

2013-10-07 Thread Oleg Rubel

Dear Salman,

I attached a set of files used to produce a 3D slices of potential (or 
e-density) along Z-axis using LAPW5 and MATLAB.


t-Se.in5c_tmpl is a template input file for LAPW5.

run_lapw5.sh is a script that will generate a set of input files, will 
run LAPW5 using them and store the results as a set of case.rho_.### 
files, where ### is a slice number [1...N]. You will need to edit the 
INPUT PARAMETERS section in order to provide your geometry, case name 
and identify complex calculation.


avrg_potential.m is a MATLAB script that will read case.rho_.### 
files (again the Load data section needs your input) and shape them into 
a 3D array.


After that you can do with this array what you want.

Sorry in advance, if you find the script not very user-friendly and well 
commented. It was never meant for external users. Feel free to modify 
it, if needed.



Best regards
Oleg


P.S. I realized that email systems block shell scripts. You need to 
rename run_lapw5.hs - run_lapw5.sh



On 06/10/2013 1:17 PM, Salman Zarrini wrote:


Dear Oleg,

Thank you for your answer, I know how to get case.vcoul by adjusting
case.in0 and then lapw0 and lapw5, however what I am interested in is
variationof coulomb potential respect to just one dimension where vacuum
and slab are elongated(V-Z). An example of such a plot as well as my
case.vcoul, case.rho and case.struct have been enclosed.

Cheers,

Salman


--
Oleg Rubel, PhD
Scientist, Thunder Bay Regional Research Institute
Adjunct Professor, Dept Physics, Lakehead University
290 Munro St, Thunder Bay, P7A 7T1, Ontario, Canada
Phone: +1-807-7663350
Fax: +1-807-3441948
E-mail: oru...@lakeheadu.ca
Homepage: http://www.tbrri.com/~orubel/

% This programm reads the potential from *.rho_* files and performs
% its averaging
%
% (c) 02.12.2008 by Oleg Rubel

clear all;

%
%   Load data
%

fprefix = 't-Se.rho_.';  % name of the WIEN2k 'case'
nZ = 200; % number of slices alonz Z axis
nX = 17;
nY = 17;
nZstep = 19; % thickness of a pice for averaging

V = zeros( nX , nY , nZ ); % allocate V

%   Read potential from different slices
for j = 0 : nZ-1
  fname = sprintf('%s%s%s', fprefix, num2str(j));
  V(:,:,j+1) = reshape( load(fname) , nX , nY ); % check! can be '...nY,nX)'
end;

mean(mean(mean(V)))

%
%   Perform averaging along Z
%

Vavg = zeros( nZ-nZstep , 1 );
z = zeros( nZ-nZstep , 1 );
for j = 1 : nZ-nZstep
  z(j) = j;
  Vsub = V(:,:,j:j+nZstep);
  Vsub2 = Vsub(:);
  Vavg(j) = mean( Vsub2 );
end;
plot(z,Vavg)
stop

#!/bin/sh
#
# This script is intended to build a 3D map of potential (or electron
# density) of a supercell by running 'lapw5' programm of WIEN2k
#
# (c) 21.03.2008 by Oleg Rubel


# INPUT PARAMETERS #


fprefix='t-Se'
fsuffix='c'
dev=1000   # devisor
a=`echo | awk '{print 8.25}'`   # lattice constant along X [Bohr]
b=`echo $a` #Y
c=`echo | awk '{print 94.1584}'`  #Z
meshStep=`echo | awk '{print 0.47}'` # mesh step in Bohr


##
# PRINT INPUT PARAMETERS #
##
echo INPUT PARAMETERS:
echo fprefix = $fprefix
echo fsuffix = $fsuffix
echo dev = $dev
echo a = $a [Bohr]
echo b = $b [Bohr]
echo c = $c [Bohr]
echo meshStep = $meshStep [Bohr]


#
# DETERMINE NUMBER OF DIVISIONS #
#
echo CALCULATED VALUES:
nX=`echo $a $meshStep | awk '{printf %i, $1/$2}'`
nY=`echo $b $meshStep | awk '{printf %i, $1/$2}'`
nZ=`echo $c $meshStep | awk '{printf %i, $1/$2}'`
echo nX = $nX
echo nY = $nY
echo nZ = $nZ


#
# MAIN LOOP #
#

for (( i = 0; i = nZ-1; i++ ))
do
   echo i = $i of `expr $nZ - 1`
   origin1=0
   origin2=0
   origin3=`echo $nZ $dev $i | awk '{printf %i, (1.0/$1)*$2*$3}'`
   echo   origin = $origin1 , $origin2 , $origin3
   xend1=`echo $nX $dev | awk '{printf %i, (1.0-1.0/$1)*$2}'`
   xend2=0
   xend3=$origin3
   echo   xend = $xend1 , $xend2 , $xend3
   yend1=0
   yend2=`echo $nY $dev | awk '{printf %i, (1.0-1.0/$1)*$2}'`
   yend3=$origin3
   echo   yend = $yend1 , $yend2 , $yend3

   sed s/origin1/${origin1}/g;\
  s/origin2/${origin2}/g;\
  s/origin3/${origin3}/g;\
  s/dev/${dev}/g;\
  s/xend1/${xend1}/g;\
  s/xend2/${xend2}/g;\
  s/xend3/${xend3}/g;\
  s/yend1/${yend1}/g;\
  s/yend2/${yend2}/g;\
  s/yend3/${yend3}/g;\
  s/nX/${nX}/g;\
  s/nY/${nY}/g  ${fprefix}.in5${fsuffix}_tmpl  ${fprefix}.in5${fsuffix}
   sleep 1
   # run 'lapw5(c)'
   echo   run lapw5${fsuffix} lapw5.def
   lapw5${fsuffix} lapw5.def
   sleep 3
   echo   cp ${fprefix}.rho ${fprefix}.rho_${i}
   cp ${fprefix}.rho ${fprefix}.rho.${i}
   echo   cp ${fprefix}.in5${fsuffix} ${fprefix}.in5${fsuffix}.${i}
   cp ${fprefix}.in5${fsuffix} ${fprefix}.in5${fsuffix}.${i}
   echo   reformat  ${fprefix}.rho.${i} | sed '/^$/d'  ${fprefix}.rho_.${i}
   reformat  ${fprefix}.rho.${i} | sed '/^$/d'  ${fprefix}.rho_.${i}
done

Re: [Wien] Segmentation fault in f7splt (lapw2)

2013-10-07 Thread Oliver Albertini
I had the same problem when I used the wrong -qarch. I had to specify pwr7
and the default from siteconfig is pwr5. If you want to find out the system
architecture issue the prtconf command.
On Oct 7, 2013 3:00 AM, Pavel Ondračka pavel.ondra...@email.cz wrote:

 Dear WIEN2k mailing list,

 this is a follow up to thread compilation problems on AIX with xlf90.
 I've finally managed to compile WIEN2k_13 on AIX 5.3,
 however I'm now getting a segfault when running lapw2.

 Segmentation fault in f7splt at line 51 in file  ($t1)
 could not read f7splt.f
 (dbx) where
 f7splt(alm = (...), blm = (...), clm = (...), mult = 2, uenorm =
 0.0028448010014590045, num = 1, coord = ' ', dmat = (...)), line 51
 in f7splt.f
 csplit(0xfd8f50c, 0xfd8f510, 0xfd8a718,
 0xfd8976c, 0xfd8f67c, 0x11023fe30, 0x110250590,
 0x110260cf0), line 78 in csplit.f
 l2main(0xfffe340, 0xfffdb84, 0xfffe518,
 0x1101ac4b0, 0x11b88, 0xfffdb80, 0xfffdb90,
 0xfffdc48), line 1313 in l2main_tmp_.F
 lapw2(), line 605 in lapw2_tmp_.F

 The corresponding lines looks like this:
 51  dmat(i,j,num)=dmat(i,j,num) + (alm(j)*conjg(alm(i))+ 
 52  blm(j)*conjg(blm(i))*uenorm+clm(j)*conjg(clm(i))+ 
 53
 alm(j)*conjg(clm(i))*pi12lo(ipip,3)+clm(j)*conjg(alm(i))*pi12lo(ipip,3)+
 
 54
 blm(j)*conjg(clm(i))*pe12lo(ipip,3)+clm(j)*conjg(blm(i))*pe12lo(ipip,3)
 ) / mult

 Going through all the variables shows suspicious value of ipip =
 -2147483648, which is used as array index for pi12lo an pe12lo causing
 the segfault.
 By grepping through SRC_lapw2 directory I can see, that all other
 subroutines which use ipip do something like this:
 $grep ipip= *
 csplit.f: ipip=max(ilo(l),1)
 d5splt.f: ipip=max(ilo(2),1)
 p3splt.f: ipip=max(ilo(1),1)

 I'm wondering if there is some similar initialization statement missing
 in f7splt.f and what should be ipip set to?

 Also I hope this isn't just some result of my inexperienced efforts to
 make WIEN compile on ancient AIX 5.3 or some other bad configuration.

 Best regards
 Pavel Ondračka

 ___
 Wien mailing list
 Wien@zeus.theochem.tuwien.ac.at
 http://zeus.theochem.tuwien.ac.at/mailman/listinfo/wien
 SEARCH the MAILING-LIST at:
 http://www.mail-archive.com/wien@zeus.theochem.tuwien.ac.at/index.html

___
Wien mailing list
Wien@zeus.theochem.tuwien.ac.at
http://zeus.theochem.tuwien.ac.at/mailman/listinfo/wien
SEARCH the MAILING-LIST at:  
http://www.mail-archive.com/wien@zeus.theochem.tuwien.ac.at/index.html


Re: [Wien] Segmentation fault in f7splt (lapw2)

2013-10-07 Thread Pavel Ondračka
Oliver Albertini píše v Po 07. 10. 2013 v 07:56 -0700:
 I had the same problem when I used the wrong -qarch. I had to specify
 pwr7 and the default from siteconfig is pwr5. If you want to find out
 the system architecture issue the prtconf command.
 
Dear Oliver,

thank for advice, however prtconf reports: Processor Type:
PowerPC_POWER5 so I should be probably fine with -qarch=pwr5, also it's
kinda strange that you fixed this by setting pwr7. I thought that those
optimization flags were forward compatible... 

For example: IBM docs I've just googled states that -qarch=pwr3
Produces object code containing instructions that will run on the
POWER5, POWER5+, POWER6, or POWER7 hardware platforms

So IMHO compiling with -qarch=pwr5 for pwr7 shouldn't break anything
unless some other weird stuff is going on.

Best regards
Pavel Ondračka

 On Oct 7, 2013 3:00 AM, Pavel Ondračka pavel.ondra...@email.cz
 wrote:
 Dear WIEN2k mailing list,
 
 this is a follow up to thread compilation problems on AIX
 with xlf90.
 I've finally managed to compile WIEN2k_13 on AIX 5.3,
 however I'm now getting a segfault when running lapw2.
 
 Segmentation fault in f7splt at line 51 in file  ($t1)
 could not read f7splt.f
 (dbx) where
 f7splt(alm = (...), blm = (...), clm = (...), mult = 2, uenorm
 =
 0.0028448010014590045, num = 1, coord = ' ', dmat =
 (...)), line 51
 in f7splt.f
 csplit(0xfd8f50c, 0xfd8f510,
 0xfd8a718,
 0xfd8976c, 0xfd8f67c, 0x11023fe30,
 0x110250590,
 0x110260cf0), line 78 in csplit.f
 l2main(0xfffe340, 0xfffdb84,
 0xfffe518,
 0x1101ac4b0, 0x11b88, 0xfffdb80,
 0xfffdb90,
 0xfffdc48), line 1313 in l2main_tmp_.F
 lapw2(), line 605 in lapw2_tmp_.F
 
 The corresponding lines looks like this:
 51  dmat(i,j,num)=dmat(i,j,num) + (alm(j)*conjg(alm(i))+ 
 52  blm(j)*conjg(blm(i))*uenorm+clm(j)*conjg(clm(i))+ 
 53
 
 alm(j)*conjg(clm(i))*pi12lo(ipip,3)+clm(j)*conjg(alm(i))*pi12lo(ipip,3)+
 
 54
 
 blm(j)*conjg(clm(i))*pe12lo(ipip,3)+clm(j)*conjg(blm(i))*pe12lo(ipip,3)
 ) / mult
 
 Going through all the variables shows suspicious value of ipip
 =
 -2147483648, which is used as array index for pi12lo an pe12lo
 causing
 the segfault.
 By grepping through SRC_lapw2 directory I can see, that all
 other
 subroutines which use ipip do something like this:
 $grep ipip= *
 csplit.f: ipip=max(ilo(l),1)
 d5splt.f: ipip=max(ilo(2),1)
 p3splt.f: ipip=max(ilo(1),1)
 
 I'm wondering if there is some similar initialization
 statement missing
 in f7splt.f and what should be ipip set to?
 
 Also I hope this isn't just some result of my inexperienced
 efforts to
 make WIEN compile on ancient AIX 5.3 or some other bad
 configuration.
 
 Best regards
 Pavel Ondračka
 
 ___
 Wien mailing list
 Wien@zeus.theochem.tuwien.ac.at
 http://zeus.theochem.tuwien.ac.at/mailman/listinfo/wien
 SEARCH the MAILING-LIST at:
  
 http://www.mail-archive.com/wien@zeus.theochem.tuwien.ac.at/index.html
 ___
 Wien mailing list
 Wien@zeus.theochem.tuwien.ac.at
 http://zeus.theochem.tuwien.ac.at/mailman/listinfo/wien
 SEARCH the MAILING-LIST at:  
 http://www.mail-archive.com/wien@zeus.theochem.tuwien.ac.at/index.html


___
Wien mailing list
Wien@zeus.theochem.tuwien.ac.at
http://zeus.theochem.tuwien.ac.at/mailman/listinfo/wien
SEARCH the MAILING-LIST at:  
http://www.mail-archive.com/wien@zeus.theochem.tuwien.ac.at/index.html


Re: [Wien] Segmentation fault in f7splt (lapw2)

2013-10-07 Thread Oliver Albertini
Optimization level may also be a factor. It's hard to say what the
difference in compilation is for instance -O0 - -O3 - -O5. It is
interesting to note that the seg fault occurs for both of us in f7splt
which (I believe) is a part of the code that calculates the relative
occupation of the f orbitals. I was calculating TiC when I saw that error,
a system where I would not expect that code to be used. I think there are
many 'unnoticed' bugs with these optimizations. For instance, compiling
lapack: -O0 complies with IEEE NaN specs, while -O3 does not. But then
again, it may just be a pwr5 issue.

Maybe try pwr3 -O5, pwr3 -O3, pwr5 -O3, or pwr5 -O0.


On Mon, Oct 7, 2013 at 9:55 AM, Pavel Ondračka pavel.ondra...@email.czwrote:

 Oliver Albertini píše v Po 07. 10. 2013 v 07:56 -0700:
  I had the same problem when I used the wrong -qarch. I had to specify
  pwr7 and the default from siteconfig is pwr5. If you want to find out
  the system architecture issue the prtconf command.
 
 Dear Oliver,

 thank for advice, however prtconf reports: Processor Type:
 PowerPC_POWER5 so I should be probably fine with -qarch=pwr5, also it's
 kinda strange that you fixed this by setting pwr7. I thought that those
 optimization flags were forward compatible...

 For example: IBM docs I've just googled states that -qarch=pwr3
 Produces object code containing instructions that will run on the
 POWER5, POWER5+, POWER6, or POWER7 hardware platforms

 So IMHO compiling with -qarch=pwr5 for pwr7 shouldn't break anything
 unless some other weird stuff is going on.

 Best regards
 Pavel Ondračka

  On Oct 7, 2013 3:00 AM, Pavel Ondračka pavel.ondra...@email.cz
  wrote:
  Dear WIEN2k mailing list,
 
  this is a follow up to thread compilation problems on AIX
  with xlf90.
  I've finally managed to compile WIEN2k_13 on AIX 5.3,
  however I'm now getting a segfault when running lapw2.
 
  Segmentation fault in f7splt at line 51 in file  ($t1)
  could not read f7splt.f
  (dbx) where
  f7splt(alm = (...), blm = (...), clm = (...), mult = 2, uenorm
  =
  0.0028448010014590045, num = 1, coord = ' ', dmat =
  (...)), line 51
  in f7splt.f
  csplit(0xfd8f50c, 0xfd8f510,
  0xfd8a718,
  0xfd8976c, 0xfd8f67c, 0x11023fe30,
  0x110250590,
  0x110260cf0), line 78 in csplit.f
  l2main(0xfffe340, 0xfffdb84,
  0xfffe518,
  0x1101ac4b0, 0x11b88, 0xfffdb80,
  0xfffdb90,
  0xfffdc48), line 1313 in l2main_tmp_.F
  lapw2(), line 605 in lapw2_tmp_.F
 
  The corresponding lines looks like this:
  51  dmat(i,j,num)=dmat(i,j,num) + (alm(j)*conjg(alm(i))+ 
  52  blm(j)*conjg(blm(i))*uenorm+clm(j)*conjg(clm(i))+ 
  53
 
 alm(j)*conjg(clm(i))*pi12lo(ipip,3)+clm(j)*conjg(alm(i))*pi12lo(ipip,3)+
  
  54
 
 blm(j)*conjg(clm(i))*pe12lo(ipip,3)+clm(j)*conjg(blm(i))*pe12lo(ipip,3)
  ) / mult
 
  Going through all the variables shows suspicious value of ipip
  =
  -2147483648, which is used as array index for pi12lo an pe12lo
  causing
  the segfault.
  By grepping through SRC_lapw2 directory I can see, that all
  other
  subroutines which use ipip do something like this:
  $grep ipip= *
  csplit.f: ipip=max(ilo(l),1)
  d5splt.f: ipip=max(ilo(2),1)
  p3splt.f: ipip=max(ilo(1),1)
 
  I'm wondering if there is some similar initialization
  statement missing
  in f7splt.f and what should be ipip set to?
 
  Also I hope this isn't just some result of my inexperienced
  efforts to
  make WIEN compile on ancient AIX 5.3 or some other bad
  configuration.
 
  Best regards
  Pavel Ondračka
 
  ___
  Wien mailing list
  Wien@zeus.theochem.tuwien.ac.at
  http://zeus.theochem.tuwien.ac.at/mailman/listinfo/wien
  SEARCH the MAILING-LIST at:
 
 http://www.mail-archive.com/wien@zeus.theochem.tuwien.ac.at/index.html
  ___
  Wien mailing list
  Wien@zeus.theochem.tuwien.ac.at
  http://zeus.theochem.tuwien.ac.at/mailman/listinfo/wien
  SEARCH the MAILING-LIST at:
 http://www.mail-archive.com/wien@zeus.theochem.tuwien.ac.at/index.html


 ___
 Wien mailing list
 Wien@zeus.theochem.tuwien.ac.at
 http://zeus.theochem.tuwien.ac.at/mailman/listinfo/wien
 SEARCH the MAILING-LIST at:
 http://www.mail-archive.com/wien@zeus.theochem.tuwien.ac.at/index.html

___
Wien mailing list
Wien@zeus.theochem.tuwien.ac.at
http://zeus.theochem.tuwien.ac.at/mailman/listinfo/wien
SEARCH the 

Re: [Wien] Segmentation fault in f7splt (lapw2)

2013-10-07 Thread Peter Blaha
I can confirm that this is a real problem, which was undetected for 
two reasons:
a) It is active ONLY when ISPLIT=15 in case.struct. Thus you must have 
set this manually. However, I doubt that this kind of splitting 
(according to +/-m) is very informative.  Instead, use the qtl program !


b) In ifort uninitial variables are set to zero, so it does not seem to 
harm (maybe it would if you have f-LOs), but in principle it is a bug.


I'm abroad and the internet connection is not stable enough to make 
tests, but I'll try to look into it soon.



Am 07.10.2013 18:55, schrieb Pavel Ondračka:

Oliver Albertini píše v Po 07. 10. 2013 v 07:56 -0700:

I had the same problem when I used the wrong -qarch. I had to specify
pwr7 and the default from siteconfig is pwr5. If you want to find out
the system architecture issue the prtconf command.


Dear Oliver,

thank for advice, however prtconf reports: Processor Type:
PowerPC_POWER5 so I should be probably fine with -qarch=pwr5, also it's
kinda strange that you fixed this by setting pwr7. I thought that those
optimization flags were forward compatible...

For example: IBM docs I've just googled states that -qarch=pwr3
Produces object code containing instructions that will run on the
POWER5, POWER5+, POWER6, or POWER7 hardware platforms

So IMHO compiling with -qarch=pwr5 for pwr7 shouldn't break anything
unless some other weird stuff is going on.

Best regards
Pavel Ondračka


On Oct 7, 2013 3:00 AM, Pavel Ondračka pavel.ondra...@email.cz
wrote:
 Dear WIEN2k mailing list,

 this is a follow up to thread compilation problems on AIX
 with xlf90.
 I've finally managed to compile WIEN2k_13 on AIX 5.3,
 however I'm now getting a segfault when running lapw2.

 Segmentation fault in f7splt at line 51 in file  ($t1)
 could not read f7splt.f
 (dbx) where
 f7splt(alm = (...), blm = (...), clm = (...), mult = 2, uenorm
 =
 0.0028448010014590045, num = 1, coord = ' ', dmat =
 (...)), line 51
 in f7splt.f
 csplit(0xfd8f50c, 0xfd8f510,
 0xfd8a718,
 0xfd8976c, 0xfd8f67c, 0x11023fe30,
 0x110250590,
 0x110260cf0), line 78 in csplit.f
 l2main(0xfffe340, 0xfffdb84,
 0xfffe518,
 0x1101ac4b0, 0x11b88, 0xfffdb80,
 0xfffdb90,
 0xfffdc48), line 1313 in l2main_tmp_.F
 lapw2(), line 605 in lapw2_tmp_.F

 The corresponding lines looks like this:
 51  dmat(i,j,num)=dmat(i,j,num) + (alm(j)*conjg(alm(i))+ 
 52  blm(j)*conjg(blm(i))*uenorm+clm(j)*conjg(clm(i))+ 
 53
 
alm(j)*conjg(clm(i))*pi12lo(ipip,3)+clm(j)*conjg(alm(i))*pi12lo(ipip,3)+
 
 54
 blm(j)*conjg(clm(i))*pe12lo(ipip,3)+clm(j)*conjg(blm(i))*pe12lo(ipip,3)
 ) / mult

 Going through all the variables shows suspicious value of ipip
 =
 -2147483648, which is used as array index for pi12lo an pe12lo
 causing
 the segfault.
 By grepping through SRC_lapw2 directory I can see, that all
 other
 subroutines which use ipip do something like this:
 $grep ipip= *
 csplit.f: ipip=max(ilo(l),1)
 d5splt.f: ipip=max(ilo(2),1)
 p3splt.f: ipip=max(ilo(1),1)

 I'm wondering if there is some similar initialization
 statement missing
 in f7splt.f and what should be ipip set to?

 Also I hope this isn't just some result of my inexperienced
 efforts to
 make WIEN compile on ancient AIX 5.3 or some other bad
 configuration.

 Best regards
 Pavel Ondračka

 ___
 Wien mailing list
 Wien@zeus.theochem.tuwien.ac.at
 http://zeus.theochem.tuwien.ac.at/mailman/listinfo/wien
 SEARCH the MAILING-LIST at:
  http://www.mail-archive.com/wien@zeus.theochem.tuwien.ac.at/index.html
___
Wien mailing list
Wien@zeus.theochem.tuwien.ac.at
http://zeus.theochem.tuwien.ac.at/mailman/listinfo/wien
SEARCH the MAILING-LIST at:  
http://www.mail-archive.com/wien@zeus.theochem.tuwien.ac.at/index.html



___
Wien mailing list
Wien@zeus.theochem.tuwien.ac.at
http://zeus.theochem.tuwien.ac.at/mailman/listinfo/wien
SEARCH the MAILING-LIST at:  
http://www.mail-archive.com/wien@zeus.theochem.tuwien.ac.at/index.html



--
Peter Blaha
Inst.Materials Chemistry
TU Vienna
Getreidemarkt 9
A-1060 Vienna
Austria
+43-1-5880115671
___
Wien mailing list
Wien@zeus.theochem.tuwien.ac.at
http://zeus.theochem.tuwien.ac.at/mailman/listinfo/wien
SEARCH the MAILING-LIST at:  
http://www.mail-archive.com/wien@zeus.theochem.tuwien.ac.at/index.html