Two smaller triangles are inside a bigger one, and to calculate the desired properties of them.

t3.png

The class is modeled as:
class T3 extends triangle
{
triangle t1, t2;

t1.A = A;
t1.c = b;

t2.A = B;
t2.c = a;

c = t1.b + t2.b;
t1.a = t2.a;
}

Example 1: Two right triangles inside
rt3.png

The class is modeled as:
class RT3 extends T3
{
t1.C = asin(1);
t2.C = asin(1);
}

RT3 is a derivative of class T3, where asin(1) denotes both the angles are right angles.

Given:
B = 1.3122
a = 3
c = 6

Results:
a = 3:<input>
A = 0.506093590467355:<3.1415926-B-C>
area = 8.70074894754062:<(s(s-a)(s-b)*(s-c))'2>
b = 5.98280394791186:<(a^2+c^2-2ac*cos(B))'2>
B = 1.3122:<input>
c = 6:<input>
C = 1.32329900953265:<acos((((b^2)-((c^2)-(a^2)))/((2a)b)))>
s = 7.49140197395593:<(abc)/2>
t1.a = 2.900249368754:<t1.c*sin(t1.A)/sin(t1.C)>
t1.A = 0.506093590467355:<A>
t1.area = 7.58825390736993:<(t1.s(t1.s-t1.a)(t1.s-t1.b)*(t1.s-t1.c))'2>
t1.b = 5.23282858992915:<t1.c*sin(t1.B)/sin(t1.C)>
t1.B = 1.06470268273775:<(3.1415926-(t1.A+t1.C))>
t1.c = 5.98280394791186:<b>
t1.C = 1.5707963267949:<asin(1)>
t1.s = 7.05794095329751:<(t1.at1.bt1.c)/2>
t2.a = 2.90024964918021:<t2.c*sin(t2.A)/sin(t2.C)>
t2.A = 1.3122:<B>
t2.area = 1.11249408107565:<(t2.s(t2.s-t2.a)(t2.s-t2.b)*(t2.s-t2.c))'2>
t2.b = 0.767171254647072:<t2.c*sin(t2.B)/sin(t2.C)>
t2.B = 0.258596273205104:<(3.1415926-(t2.A+t2.C))>
t2.c = 3:<a>
t2.C = 1.5707963267949:<t1.C>
t2.s = 3.33371045191364:<(t2.at2.bt2.c)/2>

Example 2: D is the middle of BC
et3.png

Given:
the same initial values as the above example

Results:
a = 3:<input>
A = 0.506093590467355:<3.1415926-B-C>
area = 8.70074894754062:<(s(s-a)(s-b)*(s-c))'2>
b = 5.98280394791186:<(a^2+c^2-2ac*cos(B))'2>
B = 1.3122:<input>
c = 6:<input>
C = 1.32329900953265:<acos((((b^2)-((c^2)-(a^2)))/((2a)b)))>
s = 7.49140197395593:<(abc)/2>
t1.a = 3.66018736399858:<t2.a>
t1.A = 0.506093590467355:<A>
t1.area = 4.3503744737703:<(t1.s(t1.s-t1.a)(t1.s-t1.b)*(t1.s-t1.c))'2>
t1.b = 3:<c/2>
t1.B = 0.40860264087363:<asin((sin(t1.A)/(t1.a/t1.b)))>
t1.c = 5.98280394791186:<b>
t1.C = 0.91469620120255:<asin((sin(t1.A)/(t1.a/t1.c)))>
t1.s = 6.32149565595522:<(t1.at1.bt1.c)/2>
t2.a = 3.66018736399858:<(t2.b^2+t2.c^2-2t2.bt2.c*cos(t2.A))'2>
t2.A = 1.3122:<B>
t2.area = 4.35037447377031:<(t2.s(t2.s-t2.a)(t2.s-t2.b)*(t2.s-t2.c))'2>
t2.b = 3:<t1.b>
t2.B = 0.914696326794897:<acos((((t2.c^2)-((t2.b^2)-(t2.a^2)))/((2t2.a)t2.c)))>
t2.c = 3:<a>
t2.C = 0.914696326794897:<acos((((t2.b^2)-((t2.c^2)-(t2.a^2)))/((2t2.a)t2.b)))>
t2.s = 4.83009368199929:<(t2.at2.bt2.c)/2>

Last edited Feb 2, 2009 at 4:15 AM by samhuang, version 3

Comments

No comments yet.