Scientific Calculator

(public) Giordano/dode

By Giordano Giordano Cignani

dode=function(){
var global:a2=atan(2);
var global:a=a2/2;
var global:sigma=(tan(a));
var global:t=36;t2=72;
var global:f=[1.;0.;0.];
var global:s=[1.;tan(a);0.];
var global:s=s/sqrt(s'*s);
var global:v=[1.;tan(a);tan(a)*tan(t)];
var global:v=v/sqrt(v'*v);
var global:F=[1.,0.,0.;0.,cos(t),-sin(t);0.,sin(t),cos(t)];
var global:F2=F*F;
var global:F_2=1/F2;
var global:S=[cos(a2),sin(a2),0;sin(a2),-cos(a2),0;0,0,-1];
var global:V2=S*(1/F2);
var global:V_2=1/V2;
var global:fi0=V_2*f;
var global:fi1=F2*fi0;
var global:fi_1=F_2*fi0;
var global:fi2=F2*fi1;
var global:fi_2=F_2*fi_1;
var global:pa=RP1(s,s+fi1,f,fi0,[0;0;0]);
var global:pb=RP1(s,s+fi1,f,v,[0;0;0]);
var global:pc=s;
var global:lung=2*MOD(pa-s);
var global:posa=1;
var global:posb=MOD(pb-s)/MOD(pa-s);
var global:posc=0;
var global:acosa=acos(COS(fi1,fi_1));
var global:acosb=acos(COS(fi1,fi_2));
var global:acosc=acos(COS(fi1,fi2));
var global:torsa=tors(fi_1,fi2,fi1);
var global:torsb=tors(fi_2,fi2,fi1);
var global:torsc= 0;
var global:dist=CHOP(DMin(F_2*s,fi0,s,fi1)[0]);
CHOP([["lung.",lung,1;"spess.",dist,dist/lung;"diametro",(2-dist),(2-dist)/lung],
["","A","B","C";"pos.",posa,posb,posc;"ang.",acosa,acosb,acosc;"tors.",torsa,torsb,torsc]])};

dode1=function(){
M=F2*V2*F_2;
aaa=CHOP(M*(pa-s));
kk=1/aaa(1,1);
aa=CHOP(M*(pa-s))*kk;
bb=CHOP(M*(pb-s))*kk;
pi2=CHOP(M*fi2);
pi_2=CHOP(M*fi_2);
pi_1=CHOP(M*fi_1);
["A=",aa,"B=",bb,"DA=",pi_1,"DB=",pi_2,"DC=",pi2]};

spam? | offensive?

0 Comments

Sign in to leave a comment