Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revisionBoth sides next revision
documentation:language_reference:functions:determinantstring [2018/06/21 16:22] – Filled with content Simon Heinzedocumentation:language_reference:functions:determinantstring [2018/09/12 14:37] – Changed order of input Simon Heinze
Line 2: Line 2:
  
 ### ###
-DeterminantString(//Inds//,//NF//) creates a string of length //NF// and sets all characters to '0', except for those indices included in //Inds//, which it sets to '1'. This automatizes the input of functions like NewWavefunction or Eigensystem.+DeterminantString(//NF//,//Inds//) creates a string of length //NF// and sets all characters to '0', except for those indices included in //Inds//, which it sets to '1'. This automatizes the input of functions like NewWavefunction or Eigensystem.
 ### ###
  
 ===== Input ===== ===== Input =====
  
-  * //Inds// : A list of indices. 
   * //NF// : The number of fermionic states (and hence the length of the resulting string).   * //NF// : The number of fermionic states (and hence the length of the resulting string).
 +  * //Inds// : A list of indices.
  
 ===== Output ===== ===== Output =====
Line 26: Line 26:
 Ind, NF = CreateAtomicIndicesDict(orbitals,groupings) Ind, NF = CreateAtomicIndicesDict(orbitals,groupings)
  
-print("\nDeterminantString({0,1,2,3},NF):" ) +print("\nDeterminantString(NF,{0,1,2,3}):"
-print(DeterminantString({0,1,2,3},NF) ) +print(DeterminantString(NF,{0,1,2,3}) ) 
-print("\nDeterminantString(Ind[\"Fe_2p\"],NF):") +print("\nDeterminantString(NF,Ind[\"Fe_2p\"]):"
-print(DeterminantString(Ind["Fe_2p"],NF) ) +print(DeterminantString(NF,Ind["Fe_2p"]) ) 
-print("\nDeterminantString(Ind[\"H_states\"],NF):") +print("\nDeterminantString(NF,Ind[\"H_states\"]):"
-print(DeterminantString(Ind["H_states"],NF) ) +print(DeterminantString(NF,Ind["H_states"]) ) 
-print("\nDeterminantString(Ind[\"Fe_states\"],NF):") +print("\nDeterminantString(NF,Ind[\"Fe_states\"]):"
-print(DeterminantString(Ind["Fe_states"],NF) )+print(DeterminantString(NF,Ind["Fe_states"]) )
  
-psi = NewWavefunction(NF,0,{{DeterminantString(Ind["Fe_3d"],NF) , 1}})+psi = NewWavefunction(NF,0,{{DeterminantString(NF,Ind["Fe_3d"]) , 1}})
 print(psi) print(psi)
 </code> </code>
Print/export