Quantum Inspired Algorithm