Simplified serial algorithm