Warnock's algorithm