A small C# library for working with complex numbers and simple quantum wave functions. The library is designed to be lightweight and easy to use. It can be used for simulations, numerical experiments, or as a tool for visualization.
ComplexF- a float based complex number type.MathC- provides mathematical operations on complex numbers- Wave function abstractions (1D)
- Built-in solutions such as:
- infinite potential well,
- harmonic oscillator,
- Gaussian wave packet
Clone the repository:
git clone https://github.com/Tim355Code/QuantumWavesCSharp.gitThen include the project in your C# solution.
usingQuantumWaves;usingCMath;ComplexFz=2f+ComplexF.I*3f;floatmagnitude=MathC.Abs(z);ComplexFconjugate=z.Conjugate;// Example wave functionvarpsi=newSimpleWaveFunction1D((x,t)=>{returnMathC.Exp(ComplexF.I*x);},FloatRange.Infinite,ComplexF.One);// defined over (-∞, ∞)floatprobability=psi.ProbabilityDensity(1.0f,0.0f);See the rest here
cd src
dotnet test- Three dimensional wave function abstractions
- Unity visualization examples