have now got the generic more generic function _decode_fountain, working like a dream