major first commit, full working version

stil may be buggy, need to check outputs
it runs and produces output, but we'll see!
initial commit

working piece for computing source quality. still need to write the
feedback bit (import from the other code)