function calculAlcool() {
	if(document.form1.genre.value == 1) { // Chargement des données suivant le sexe de la personne
		var sexe1 = 17.45;
		var sexe2 = 0.4786;
	}else{
		var sexe1 = 18.075;
		var sexe2 = 0.3186;
	}
	var pils = 12;
	if (document.form1.pils.value == "") {
		var qPils = 0
	}else{
		var qPils = parseInt(document.form1.pils.value);
	}
	var wijn = 12;
	if (document.form1.wijn.value == "") {
		var qWijn = 0
	}else{
		var qWijn = parseInt(document.form1.wijn.value);
	}
	var champagne = 12;
	if (document.form1.champagne.value == "") {
		var qChampagne = 0
	}else{
		var qChampagne = parseInt(document.form1.champagne.value);
	}
	var streekbieren = 25;
	if (document.form1.streekbieren.value == "") {
		var qstreekbieren = 0
	}else{
		var qstreekbieren = parseInt(document.form1.streekbieren.value);
	}
	var breezer = 12.5;
	if (document.form1.breezer.value == "") {
		var qbreezer = 0
	}else{
		var qbreezer = parseInt(document.form1.breezer.value);
	}
	var cocktail = 12.5;
	if (document.form1.cocktail.value == "") {
		var qcocktail = 0
	}else{
		var qcocktail = parseInt(document.form1.cocktail.value);
	}
	var sterkedrank = 12;
	if (document.form1.sterkedrank.value == "") {
		var qsterkedrank = 0
	}else{
		var qsterkedrank = parseInt(document.form1.sterkedrank.value);
	}
	var sherry = 12;
	if (document.form1.sherry.value == "") {
		var qsherry = 0
	}else{
		var qsherry = parseInt(document.form1.sherry.value);
	}
	if (document.form1.genre.value == "") {
		alert("Verplicht invullen: man of vrouw");
		return false;
	}else{
		var poids = parseInt(document.form1.poids.value);
	}
	if (document.form1.poids.value == "") {
		alert("Verplicht invullen: gewicht");
		return false;
	}else{
		var poids = parseInt(document.form1.poids.value);
	}
	// calcul du temps
	var t = parseInt(document.form1.debut.value);
	var D = ((qPils*pils)+(qWijn*wijn)+(qChampagne*champagne)+(qstreekbieren*streekbieren)+(qbreezer*breezer)+(qcocktail*cocktail)+(qsterkedrank*sterkedrank)+(qsherry*sherry))/(sexe1 + (sexe2 * poids));
	var AlcoholTotal = Math.round((D - 0.15 * (t - 0.5))*100)/100; // on obtient le degré d'alcolémie total (on arrondi 2 chiffres après la virgule)
	
	if (D > 0) {
	if (AlcoholTotal > 0) {
		//alert("Taux d'alcolémie : "+AlcoholTotal);
		// maintenant on calcul combien de temps il faudra pour descendre en dessous de 0,49
		if (AlcoholTotal > 0.49) {
			var t2 = (D - 0.325)/0.15; // temps total avant de reprendre le volant (sans compter les heures déjà passées)
			//alert("temps total avant d'atteindre 0.5 = "+ t2);
			var total = Math.round((t2-t)*100)/100; // temps qu'il reste pour reprendre le volant
			var longueurTotal = String(total).length;
			var positionVirgule = String(total).indexOf(".");
			if(positionVirgule==-1) {
				alert("Au total, il faut "+total+"h pour désaouler");
			}else{
				var total2 = String(total).substring(positionVirgule+1, longueurTotal);
				var total3 = (parseInt(total2)/100)*60;
				var heures = String(total).substring(0, positionVirgule);
				var minutes = Math.round(total3);
				if(String(minutes).length < 2) {
					if(minutes < 10) {
						minutes2_ok = "0" + String(minutes);
					}else{
						minutes2_ok = String(minutes) + "0";
					}
				}else{
					minutes2_ok = minutes;
				}
				$('#resultBox .normalText div#displayPromille').html(AlcoholTotal = String(AlcoholTotal).replace(/\./g,","));
				$('#resultBox .normalText div#displayPromilleTxt').html('Is het pro mille alcohol in je bloed.');
				$('#resultBox .normalText div#displayUuren').html(heures+'.'+minutes2_ok);
				$('#resultBox .normalText div#displayUurenTxt').html('Is het aantal uren dat je geen voertuig mag besturen (ook geen fiets)!');
				$('#resultBox').css({visibility: "visible"}).fadeIn(300, function() {
				$('#zebg').animate({top: 0}, 'slow');
				});
				//alert("Total = " + total);
				//alert("Au total, il faut "+heures+"h"+minutes2_ok+" pour désaouler");
			}
		}else{ // sous le seuil de 0.49
			//$('#resultBox .normalText div#displayPromille').html(AlcoholTotal+' Is het pro mille alcohol in je bloed.');
			$('#resultBox .normalText div#displayPromille').html(AlcoholTotal = String(AlcoholTotal).replace(/\./g,","));
			$('#resultBox .normalText div#displayPromilleTxt').html('Is het pro mille alcohol in je bloed.');
			$('#resultBox .normalText div#displayUuren').html('0');
			$('#resultBox .normalText div#displayUurenTxt').html('Is het aantal uren dat je geen voertuig mag besturen (ook geen fiets)!');
			$('#resultBox').css({visibility: "visible"}).fadeIn(300, function() {
			$('#zebg').animate({top: 51}, 'slow');
			});
		};
	}else{ // pas un gramme d'alcohol dans le sang
		//alert("Plus d'alcohol dans le sang");
		$('#resultBox .normalText div#displayPromille').html('ok');
		$('#resultBox').css({visibility: "visible"}).fadeIn(300, function() {
		$('#zebg').animate({top: 103}, 'slow');
		});
	};
	}else{
		$('#resultBox .normalText div#displayPromille').html('0');
		$('#resultBox .normalText div#displayPromilleTxt').html('Is het pro mille alcohol in je bloed.');
		$('#resultBox .normalText div#displayUuren').html('0');
		$('#resultBox .normalText div#displayUurenTxt').html('Is het aantal uren dat je geen voertuig mag besturen (ook geen fiets)!');
		$('#resultBox').css({visibility: "visible"}).fadeIn(300, function() {
				$('#zebg').animate({top: 103}, 'slow');
			});
	}
}
