Answered step by step
Verified Expert Solution
Question
1 Approved Answer
please solve the error in matlab For the triangle shown below, which has side lengths a, b and c and interior angle between the sides
please solve the error in matlab
For the triangle shown below, which has side lengths a, b and c and interior angle between the sides with lengths a and b, the cosine law says: b (I c? = a + b2 2ab cos Write a MATLAB function called angles that takes the lengths of three sides of a triangle as arguments and returns the three interior angles of the triangle. For example; >>angles (1, 2, V3) should return (approximately) 30, 60 and 90 degree. Note: The outputs should be in degrees. The order of the outputs does not matter. 1 function (alfa, beta, theta]=angle(a,b,c) 2 3 angalfa acos((a^2+b^2-c^2)/(2*a*b)); 4 angbeta acosd((b^2+c^2-a^2)/(2*b*c)); 5 angtheta acosd((c^2+a^2-b^2)/(2*c*a)); 6 7 end Code to call your function C Reset 1 [alfa, beta, theta)=angle(1,2,sqrt(3)) Output Output argument "alfa" (and maybe others) not assigned during call to "angleStep by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started