added sparse_absolute() utility function