Directory Structure¶
Repository Layout¶
StdFace/
├── CMakeLists.txt # Top-level CMake configuration
├── README.md # Project documentation
├── LICENSE # GPL v3 license
├── src/ # Source code AND headers
│ ├── CMakeLists.txt # Build rules for binaries/libraries
│ ├── dry.c # CLI entry point (main)
│ ├── StdFace_main.c # Core processing logic
│ ├── StdFace_ModelUtil.c/.h # Model utilities
│ ├── StdFace_vals.h # StdIntList parameter structure
│ ├── setmemory.c/.h # Memory allocation utilities
│ ├── version.h # Version macros
│ ├── export_wannier90.c/.h # Wannier90 export (HWAVE)
│ ├── ChainLattice.c # 1D chain lattice
│ ├── Ladder.c # 1D ladder lattice
│ ├── SquareLattice.c # 2D square/tetragonal lattice
│ ├── TriangularLattice.c # 2D triangular lattice
│ ├── HoneycombLattice.c # 2D honeycomb lattice
│ ├── Kagome.c # 2D Kagome lattice
│ ├── Orthorhombic.c # 3D orthorhombic lattice
│ ├── FCOrtho.c # 3D face-centered orthorhombic
│ ├── Pyrochlore.c # 3D pyrochlore lattice
│ └── Wannier90.c # Wannier90 interface
├── samples/ # Example input files
│ └── hubbard/
│ ├── default_model/
│ │ └── stan.in
│ └── wannier/
│ ├── stan.in
│ └── zvo_*.dat
├── test/ # Test suite
└── docs/ # Documentation (Sphinx)
Source reference: Repository root directory listing
Header Files in src/¶
Important
StdFace does not follow the conventional C project layout of placing
public headers in an include/ directory. All headers reside in src/
alongside implementation files.
This design choice means:
Headers and implementations are co-located
No separate include path configuration needed beyond
src/The
src/CMakeLists.txtincludesinclude_directories(include)but this directory does not exist in the repository
Source reference: src/CMakeLists.txt:8
Header Files¶
Header |
Purpose |
|---|---|
|
Core model utilities (37 functions)
|
|
Parameter structure definition
|
|
Memory allocation utilities (24 functions)
|
|
Wannier90 export (HWAVE mode only)
|
|
Version information
|
Source reference: docs/_meta/header_map.yaml
Source Files¶
Core files (compiled into all binary variants):
Source |
Purpose |
|---|---|
|
CLI entry point; argument parsing |
|
Main processing; input parsing; output generation |
|
Implementation of model utility functions |
|
Memory allocation implementation |
|
Wannier90 export implementation |
Lattice-specific files (each implements one lattice type):
Source |
Lattice Type |
|---|---|
|
1D chain |
|
1D ladder (multi-leg) |
|
2D square/tetragonal |
|
2D triangular |
|
2D honeycomb |
|
2D Kagome |
|
3D simple orthorhombic/cubic |
|
3D face-centered orthorhombic/cubic |
|
3D pyrochlore |
|
Wannier90 tight-binding import |
Source reference: src/CMakeLists.txt:13-15
samples/ Directory¶
Contains example input files demonstrating StdFace usage:
samples/
└── hubbard/
├── default_model/
│ └── stan.in # Basic Hubbard model on square lattice
└── wannier/
├── stan.in # Wannier90 mode example
├── zvo_geom.dat # Geometry data
├── zvo_hr.dat # Hopping data
└── zvo_ur.dat # Interaction data
The stan.in files use the standard keyword = value format:
model = "Hubbard"
lattice = square
W = 2
L = 2
t = 1
U = 1
Source reference: samples/hubbard/default_model/stan.in
test/ Directory¶
Contains test cases for validation. Test infrastructure is enabled by the
TestStdFace CMake option (default: ON).
Source reference: CMakeLists.txt:20-24
Build Output¶
After building with CMake, the following artifacts are produced (depending on enabled options):
build/
├── src/
│ ├── hphi_dry.out # HPhi mode binary (if -DHPHI=ON)
│ ├── mvmc_dry.out # mVMC mode binary (if -DMVMC=ON)
│ ├── uhf_dry.out # UHF mode binary (if -DUHF=ON)
│ ├── hwave_dry.out # HWAVE mode binary (if -DHWAVE=ON)
│ ├── libStdFace_hphi.a # HPhi static library
│ ├── libStdFace_mvmc.a # mVMC static library
│ ├── libStdFace_uhf.a # UHF static library
│ └── libStdFace_hwave.a # HWAVE static library
└── ...
Source reference: src/CMakeLists.txt:17-51