Cody

Problem 43601. Find the sines of an isosceles triangle when given its area and height

Solution 2071085

Submitted on 27 Dec 2019
This solution is locked. To view this solution, you need to provide a solution of the same size or smaller.

Test Suite

Test Status Code Input and Output
1   Fail
A = 60; h = 5; y_correct = [0.3752 0.3752 0.6927]; tolerance = 1e-4; y = theSineOfAnglesOfATriangle(A,h); assert(abs(y(1)-y_correct(1))<tolerance) assert(abs(y(2)-y_correct(2))<tolerance) assert(abs(y(3)-y_correct(3))<tolerance)

[Warning: Function assert has the same name as a MATLAB builtin. We suggest you rename the function to avoid a potential name conflict.] [> In theSineOfAnglesOfATriangle (line 2) In ScoringEngineTestPoint1 (line 5) In solutionTest (line 3)]

Output argument "ans" (and maybe others) not assigned during call to "theSineOfAnglesOfATriangle". Error in Test1 (line 5) y = theSineOfAnglesOfATriangle(A,h);

2   Fail
A = 12; h = 4; y_correct = [0.7174 0.7174 0.8608]; tolerance = 1e-4; y = theSineOfAnglesOfATriangle(A,h); assert(abs(y(1)-y_correct(1))<tolerance) assert(abs(y(2)-y_correct(2))<tolerance) assert(abs(y(3)-y_correct(3))<tolerance)

[Warning: Function assert has the same name as a MATLAB builtin. We suggest you rename the function to avoid a potential name conflict.] [> In theSineOfAnglesOfATriangle (line 2) In ScoringEngineTestPoint2 (line 5) In solutionTest (line 5)]

Output argument "ans" (and maybe others) not assigned during call to "theSineOfAnglesOfATriangle". Error in Test2 (line 5) y = theSineOfAnglesOfATriangle(A,h);

3   Fail
A = 120; h = 8; y_correct = [0.4534 0.4534 0.8001]; tolerance = 1e-4; y = theSineOfAnglesOfATriangle(A,h); assert(abs(y(1)-y_correct(1))<tolerance) assert(abs(y(2)-y_correct(2))<tolerance) assert(abs(y(3)-y_correct(3))<tolerance)

[Warning: Function assert has the same name as a MATLAB builtin. We suggest you rename the function to avoid a potential name conflict.] [> In theSineOfAnglesOfATriangle (line 2) In ScoringEngineTestPoint3 (line 5) In solutionTest (line 7)]

Output argument "ans" (and maybe others) not assigned during call to "theSineOfAnglesOfATriangle". Error in Test3 (line 5) y = theSineOfAnglesOfATriangle(A,h);

4   Fail
A = 11; h = 7; y_correct = [0.8281 0.8281 0.3628]; tolerance = 1e-4; y = theSineOfAnglesOfATriangle(A,h); assert(abs(y(1)-y_correct(1))<tolerance) assert(abs(y(2)-y_correct(2))<tolerance) assert(abs(y(3)-y_correct(3))<tolerance)

[Warning: Function assert has the same name as a MATLAB builtin. We suggest you rename the function to avoid a potential name conflict.] [> In theSineOfAnglesOfATriangle (line 2) In ScoringEngineTestPoint4 (line 5) In solutionTest (line 9)]

Output argument "ans" (and maybe others) not assigned during call to "theSineOfAnglesOfATriangle". Error in Test4 (line 5) y = theSineOfAnglesOfATriangle(A,h);

5   Fail
A = 10; h = pi; y_correct = [0.6461 0.6461 0.9197]; tolerance = 1e-4; y = theSineOfAnglesOfATriangle(A,h); assert(abs(y(1)-y_correct(1))<tolerance) assert(abs(y(2)-y_correct(2))<tolerance) assert(abs(y(3)-y_correct(3))<tolerance)

[Warning: Function assert has the same name as a MATLAB builtin. We suggest you rename the function to avoid a potential name conflict.] [> In theSineOfAnglesOfATriangle (line 2) In ScoringEngineTestPoint5 (line 5) In solutionTest (line 11)]

Output argument "ans" (and maybe others) not assigned during call to "theSineOfAnglesOfATriangle". Error in Test5 (line 5) y = theSineOfAnglesOfATriangle(A,h);

6   Fail
A = 100; h = 90; y_correct = [0.8414 0.8414 0.0208]; tolerance = 1e-4; y = theSineOfAnglesOfATriangle(A,h); assert(abs(y(1)-y_correct(1))<tolerance) assert(abs(y(2)-y_correct(2))<tolerance) assert(abs(y(3)-y_correct(3))<tolerance)

[Warning: Function assert has the same name as a MATLAB builtin. We suggest you rename the function to avoid a potential name conflict.] [> In theSineOfAnglesOfATriangle (line 2) In ScoringEngineTestPoint6 (line 5) In solutionTest (line 13)]

Output argument "ans" (and maybe others) not assigned during call to "theSineOfAnglesOfATriangle". Error in Test6 (line 5) y = theSineOfAnglesOfATriangle(A,h);