prep_xspec generates all script files necessary at step.1-3 based on the user’s calculation setup. For calculation from scratch, the flag “-i” (i.e. prep_xspec -i) writes template of input files in /Inputs/. For VSC4 users, prep_xspec makes batch files for multi-cores/nodes parallel job submissions.

prep_xspec for standard usage

1. General information

Here, the users provide general information on the target compound, x-ray excitation process. The material name is used only for labeling e.g. bath files, thus can be free chosen. Other names for target compound (atom, valence) and x-ray excitations (core, type, pol) must be consistent with the name of input files (case.ham, case.and, case.cnv, etc) in “/Inputs/“. prep_xspec -i generates the input files with the consistent name with the general information here. Note that the prep_xspec -i overwrites the input files in /Inputs/.

#------  General information
name=NiO     #  material name (this appears only in batch files, thus not strict)
atom=Ni      #  atom to be x-ray excited
valance=2    #  valence (2+) of the target atom 
core=2p      #  core-level to be excited (2p core). For process involving two core levels, name like 1s2p   
type=P       #  P : XPS / A : XAS / RE : RXES
solver=and   #  and: anderson / clu: cluster / dclu: double cluster
pol=N        #  photon polarization (N:no pol. specified / P:sigma/ D:pi)  
flug_ham=""  #  optional flag for hamil (for flag, see below)
flug_and=""  #  optional flag for and

2. Choose initial states for x-ray excitation

As described in step.2 of link  [↪︎], the code computes the initial states on which x-ray excitation acts. For efficient numerical calculation, the computation of the initial states is done on the block Hamiltonian. Thus the users must pick up initial states to be included in the spectral calculation from the eigen states in the blocks. The energies of the low-energy states in the blocks can be found in log_GS file, that is the output file of step.1 [↪︎]. Therefore, if the users don’t know the character of the initial states of the target material (Hamiltonian) in advance, first run the step.1 and then insert the list of initial states to be included here, then rerun “prep_xspec“.

#------  GS-character (list of the eigen states to be included as initial states in the x-ray spectroscopy calculation)
nex=4                      #  number of initial states to be included in the spectroscopy calculation (step2) 
iex=("1" "2" "1" "1")      #  the index of the excited state (1 is the lowest state in the 2mj-block specified below, thus 2 is the first excited state on the 2mj-block)
mjb=("0" "0" "2" "4")      #  the 2mj values of the excited states specified just above   

3. Optional : for generating input files from scratch

For beginners, the prep_xspec with flag -i generates input files from scratch. To specify the configurations to be included in the simulation, the users give the number of the valence electrons (nimp) on the outer shell (e.g. 3d) in the formal valence. From this filling, the bases are generated by the configuration-interaction scheme. “nvhmax” (“ncemax“) defines the maximum number of holes (electrons) in the valence (conduction) bands below (above) the Fermi energy. We recommend first one starts with nvhmax=2 and ncemax=1, then increase the number of holes/electrons depending on the purpose (required accuracy).

#------  optional: for automatic generation of input files (with flag -i)
zatom=28     # atomic number
vshell=3d    # valence shell (3d,4d,5d,4f,5f,etc...)
nimp=8       # no.of electrons (in "valence" shell) at impurity site in the formal valence
sym=1        # symmetry (0:SO3, 1:Oh, 2:D4h, 3:D2h, 4:D3d, 5:Td, -1:No)
nvhmax=2     # max no.of valence holes in CI expansion
ncemax=0     # max no.of conduction electrons in CI expansion

4. path to the executable files in opw2x/lib

Here, the users specify the path to (and name of) the executable files in opw2x/lib. It is recommended to make the path in bash file. Unless you need special implementations, your executable files are ander_VC.dx, hamil.dx, exconv.dx, so do not change this part.

#------  Path to exec file in cluster programs
path_and="ander_VC.dx"
path_ham="hamil.dx"
path_cnv="exconv.dx"

5. For VSC4 users

#============================================ batch files (vsc4 users only!)
job_path=/jobs/spec_jobs       # path to dir of job files
time=24:00:00                  # request time
partition=mem_0096
qos=mem_0096
email=hariki@pe.osakafu-u.ac.jp


#------  multi cpu use for excited states and beamline (only in vsc-4)
mcpu=1         # 0:off / 1:on
njob_node=3    # number of jobs per node (<=16 in VSC-3)
nbeam=50       # number of beamlines (0:off)
noGS=1         # calculation without groundstate (0:with GS / 1:without GS)