randRange( 100, 999 ) randRange( 100, 999 ) SMALL_FACTOR * BIG_FACTOR randRange( 1, 3 ) randRange( 1, 3 ) padDigitsToNum( digits( SMALL_FACTOR ), SMALL_FACTOR_DECIMAL + 1 ) padDigitsToNum( digits( BIG_FACTOR ), BIG_FACTOR_DECIMAL + 1 ) []
graph.multiplier = new Multiplier( BIG_FACTOR, SMALL_FACTOR, BIG_FACTOR_DIGITS, SMALL_FACTOR_DIGITS, BIG_FACTOR_DECIMAL, SMALL_FACTOR_DECIMAL ); graph.multiplier.show(); graph.multiplier.showDecimals(); DUMMY = Array( graph.multiplier.getNumHints() );
( PRODUCT * pow( 10, -(BIG_FACTOR_DECIMAL + SMALL_FACTOR_DECIMAL) ) ).toFixed(BIG_FACTOR_DECIMAL + SMALL_FACTOR_DECIMAL)
<<<<<<< HEAD
doMultiplicationStep( bigIndex, BIG_FACTOR_DIGITS, smallIndex, SMALL_FACTOR_DIGITS );
while( graph.highlights.length ) { graph.highlights.pop().remove(); } path( [ [ -1 - MAX_NUM_DIGITS, 0.5 - SMALL_FACTOR_DIGITS.length ], [ 1, 0.5 - SMALL_FACTOR_DIGITS.length ] ] ); label( [ -1 - MAX_NUM_DIGITS, 1 - SMALL_FACTOR_DIGITS.length ] ,"\\huge{+\\vphantom{0}}" );
while( PRODUCT_DIGITS.length < SMALL_FACTOR_DECIMAL + BIG_FACTOR_DECIMAL + 1 ) { PRODUCT_DIGITS.unshift( 0 ); } drawDigits( PRODUCT_DIGITS, 1 - PRODUCT_DIGITS.length, -SMALL_FACTOR_DIGITS.length );
label( [ - MAX_NUM_DIGITS, -SMALL_FACTOR_DIGITS.length * BIG_FACTOR_DIGITS.length + 2 ], "\\text{The top number has " + plural( BIG_FACTOR_DECIMAL, "digit" ) + " to the right of the decimal.}", "right" ); label( [ - MAX_NUM_DIGITS, -SMALL_FACTOR_DIGITS.length * BIG_FACTOR_DIGITS.length + 1 ], "\\text{The bottom number has " + plural( SMALL_FACTOR_DECIMAL, "digit" ) + " to the right of the decimal.}", "right" ); label( [ - MAX_NUM_DIGITS, -SMALL_FACTOR_DIGITS.length * BIG_FACTOR_DIGITS.length ], "\\text{The product has " + BIG_FACTOR_DECIMAL + " + " + SMALL_FACTOR_DECIMAL + " = " + ( SMALL_FACTOR_DECIMAL + BIG_FACTOR_DECIMAL ) + " digits to the right of the decimal.}", "right" ); style({ fill: "black" }, function() { ellipse( [ -SMALL_FACTOR_DECIMAL - BIG_FACTOR_DECIMAL + 0.5, -0.2 - SMALL_FACTOR_DIGITS.length ], [ 0.09, 0.06 ] ); });
=======
graph.multiplier.showHint(); >>>>>>> 67037a196910ca0f4c461094a83eb6e761fd7218
graph.multiplier.showDecimalsInProduct();