This site is version 0.0.1. Most of the code on this site is drafted by an agent and needs review. I apologize for the AI-speak, we are working on rewriting it!
viv-lang.org

Engines

Programs you feed an input file

An engine is a Viv program that declares which file formats it reads, what it produces, and how large an input a browser tab can handle. Drop a file on its page and, before anything runs, the page shows what it read, an estimate of the run time, and anything in the input it cannot handle. Then the program runs in your browser. If your input is one of the cases the engine was validated on, it also prints how far its result is from the reference value.

Band structure of a crystal, from a POSCAR, a CIF or a pw.x input

#! engine dft-bands

Reads crystal (poscar | cif | qe-pw | xyz+cell); settings (ecut, kmesh, smearing, bands (defaults from dft/ref/materials.py)). Produces bands, total-energy.

Checked on si and gaas. Runs compiled to WebAssembly or interpreted.

Hartree-Fock energy of a molecule, from an XYZ file and a basis name

#! engine hf-energy

Reads molecule (xyz); settings (basis (sto-3g | 6-31g | 6-31g* | cc-pvdz | def2-svp), charge, spin, method (rhf | uhf | rohf), spherical or cartesian). Produces total-energy, orbital-energies.

Checked on water 6-31g and water cc-pvdz. Runs in the Viv interpreter (viv.wasm).

The header

An engine declares itself in #! lines at the top of its program, like the ones a post carries. The site builds these pages from them and refuses an engine whose validated line names a file that does not exist:

#! engine dft-bands
#! title Band structure of a crystal, from a POSCAR, a CIF or a pw.x input
#! program dft/pwdft_it
#! input crystal: poscar | cif | qe-pw | xyz+cell
#! input settings: ecut, kmesh, smearing, bands (defaults from dft/ref/materials.py)
#! output bands, total-energy
#! limit tab: fcc lattices, up to 8 atoms, an estimated 90 s of compiled wasm; larger runs natively with dft/run.sh
#! validated si: dft/si_it_check.viv
#! validated gaas: dft/gaas_it_check.viv

The input block, the lines between # ---- input: and # ---- end of input, is the part the page replaces with your file's contents. Everything after it is the program that runs.

Credits

The Hartree–Fock engine's basis sets come from the Basis Set Exchange, and its energies are compared with PySCF 2.5.0 (Apache-2.0); no PySCF code is copied. The DFT engine's GTH pseudopotential parameters are CP2K's GTH_POTENTIALS table as PySCF ships it (Goedecker, Teter and Hutter 1996; Hartwigsen, Goedecker and Hutter 1998); only the numbers are used.