Clean up.m

From Spinach Documentation Wiki
Jump to: navigation, search

Array clean-up utility. Drops non-zero elements with magnitude below the user-specified tolerance and converts between sparse and dense represen- tations depending on the density of non-zeros in the array. Syntax:

                  A=clean_up(spin_system,A,nonzero_tol)