diff -r 082c23b26055 -r d4246abee34e www/rec_print.php --- a/www/rec_print.php Mon Nov 12 16:34:43 2018 +0100 +++ b/www/rec_print.php Mon Nov 12 22:47:49 2018 +0100 @@ -204,34 +204,11 @@ $cost_hops += $cost; $total_hops += $amount; - $fmoment = 1.0; $moment = hop_useat_names($useat); - if (($useat == "Dry Hop") || ($useat == "Dry hop")) { - $fmoment = 0.0; - } else if ($useat == "Whirlpool") { - $fmoment = 0.0; - } else if ($useat == "Mash") { - $fmoment = 0.7; // Brouwhulp - } else if (($useat == "First Wort") || ($useat == "First wort")) { - $fmoment = 1.1; // Brouwhulp, Louis, Ozzie - } else if ($useat == "Aroma") { - $fmoment = 0.0; // Brouwhulp 1.0 redeneert vlamuit. - } else if ($useat == "Boil") { - $fmoment = 1.0; + if ($useat == "Boil") { $moment = "Kook@".$time; } - - $pfactor = 1.0; - if ($form == "Pellet") { - $pfactor = 1.1; - } - - /* Tinseth only for now */ - $AddedAlphaAcids = (($alpha / 100) * $mass * 1000) / floatval($row['batch_size']); - $Bigness_factor = 1.65 * pow( 0.000125, floatval($row['est_og']) - 1); - $BoilTime_factor = ((1 - exp(-0.04 * $time)) / 4.15); - $utiisation = $Bigness_factor * $BoilTime_factor; - $ibu = (round($utiisation * $AddedAlphaAcids * $fmoment * $pfactor * 10) / 10.0); + $ibu = calc_IBU($useat, $form, floatval($row['est_og']), floatval($row['batch_size']), $mass, $time, $alpha, $row['ibu_method']); $this->Cell($vul,5,$name,0,0,'L',true); $this->Cell(35,5,$origin,0,0,'L',true);