*
* Automatically uses lowest entropy to avoid issues such as interpretting 0101
* as hexadecimal which would be 16 bits when really it's only 4 bits of binary
*
* Automatically uses lowest entropy to avoid issues such as interpretting 0101
* as hexadecimal which would be 16 bits when really it's only 4 bits of binary
// eg the second last card can be only one of two, not one of fifty two
// so the added entropy for that card is only one bit at most
if (base.asInt == 52) {
// eg the second last card can be only one of two, not one of fifty two
// so the added entropy for that card is only one bit at most
if (base.asInt == 52) {
var totalDecks = Math.ceil(base.parts.length / 52);
var totalCards = totalDecks * 52;
var totalCombos = factorial(52).pow(totalDecks);
var totalDecks = Math.ceil(base.parts.length / 52);
var totalCards = totalDecks * 52;
var totalCombos = factorial(52).pow(totalDecks);
var maxWithReplace = BigInteger.pow(52, base.parts.length);
// Calculate the new value by scaling the original value down
var withoutReplace = entropyInt.multiply(maxWithoutReplace).divide(maxWithReplace);
var maxWithReplace = BigInteger.pow(52, base.parts.length);
// Calculate the new value by scaling the original value down
var withoutReplace = entropyInt.multiply(maxWithoutReplace).divide(maxWithReplace);
entropyHtml = entropyHtml.replace(/H/g, "<span class='card-suit heart'>\u2665</span>");
entropyHtml = entropyHtml.replace(/S/g, "<span class='card-suit spade'>\u2660</span>");
}
entropyHtml = entropyHtml.replace(/H/g, "<span class='card-suit heart'>\u2665</span>");
entropyHtml = entropyHtml.replace(/S/g, "<span class='card-suit spade'>\u2660</span>");
}