<!-- Beginvar v=0;var t0=0;var t1=0;var y1=0;var y0=0;var t10=0;var y10=0;var auteur="auteur Arnaud Saint-Martin de www.homeomath.com";function reponse(form){for(var i=0;i<form.length;i++){if(form[i].checked){break}}var repondu=""if(i<form.length){repondu=form[i].value}return repondu;}function affiche(form){var doc="";var phrase="";var fdex="";var fx=form.ft.value;var vit="";t0=eval(form.t0.value);t1=eval(form.t1.value);fdex=traduct(fx);y0=image(fdex,t0);y1=image(fdex,t1);y10=eval(y1-y0);y10=arrondi(y10,100000000);t10=eval(t1-t0);if(Math.abs(t10)<1e-7){alert("Attention l'instant t1 est beaucoup trop proche de t0, je risque de me tromper dans les calculs !!");};t10=arrondi(t10,100000000);v=eval(y10/t10);v=arrondi(v,100000000);vit=v+" m/s";doc=doc+"distance parcourue à l'instant t = "+t0+" s : \nf("+t0+") = "+y0+" m\n";doc=doc+"distance parcourue à l'instant t = "+t1+" s : \nf("+t1+") = "+y1+" m\n";doc=doc+"distance parcourue de t = "+t0+" s à t = "+t1+" s :\n";doc=doc+"f("+t1+") - f("+t0+") = "+y10+" m\n";doc=doc+"temps mis pour parcourir cette distance : \n";doc=doc+t1+" - "+t0+" = "+t10+" s\n";doc=doc+"vitesse moyenne = \n";doc=doc+"[f("+t1+") - f("+t0+")]/("+t1+" - "+t0+") = \n";doc=doc+y10+"/"+t10+" = "+v+" m/s";document.formulaire.cinema.value=doc;document.formulaire.vit.value=vit;}function ind(c){var car="";car="<sub>"+c+"</sub>";return car;}function expo(c){var car="";car="<sup>"+c+"</sup>";return car;}function centre(a,b){var m=eval(eval(a+b)/2);return m;}function image(f,x){var ch=f;ch=ch.replace(/z/g,x);with(Math){v=eval(ch);};v=arrondi(v,100000000);return v;}function ecrit(f){var ch=f;for(var i=1;i<=6;i++){ch=ch.replace("*","");ch=ch.replace("x^3","x"+expo("3"));ch=ch.replace("x^2","x"+expo("2"));ch=ch.replace("x^4","x"+expo("4"));ch=ch.replace("exp(x)","e"+expo("x"));ch=ch.replace("+-","-");ch=ch.replace("--","+");ch=ch.replace("sqrt(x)",racine);ch=ch.replace("abs(x)","|x|");};return ch;}function divise(form){var f=eval(form.h.value);f=eval(f*0.1);document.formulaire.h.value=arrondi(f,100000000);}function traduct(f){var ch=f;ch=ch.replace(/\+\-/g,"-");ch=ch.replace(/\-\+/g,"-");ch=ch.replace(/\-\-/g,"+");ch=ch.replace(/t\^3/g,"z*z*z");ch=ch.replace(/t\^2/g,"z*z");ch=ch.replace(/t\^4/g,"pow(z,4)");ch=ch.replace(/t\^5/g,"pow(z,5)");ch=ch.replace(/t\^6/g,"pow(z,6)");ch=ch.replace(/t\^7/g,"pow(z,7)");ch=ch.replace(/t\^8/g,"pow(z,8)");ch=ch.replace(/t\^9/g,"pow(z,9)");ch=ch.replace(/-t/g,"-1*z");ch=ch.replace(/ln/g,"log");ch=ch.replace(/t/g,"z");ch=ch.replace(/zan/g,"tan");ch=ch.replace(/azan/g,"atan");ch=ch.replace(/sqrz/g,"sqrt");return ch;}function image(f,x){var ch=f;ch=ch.replace(/z/g,x);with(Math){v=eval(ch);};return v;}function init(form){document.formulaire.num.value="";document.formulaire.den.value="";document.formulaire.taux.value="";document.formulaire.h.value=1;}function arrondi(x,choix){var retour=eval(x*choix);var tronc=Math.round(retour);tronc=eval(tronc/choix);return tronc;}function proche(form){t0=eval(form.t0.value);t1=eval(form.t1.value);t10=eval(t1-t0);t1=eval(t0+"+"+eval(t10/10));document.formulaire.t1.value=t1;}//-->
