How can ı solve this triangle problem at MATLAB?

In the triangle which has edges names:a,b,c; a=9 b=18 c=25 how can ı calculate the alfa(the angles sees a) with the law of cosines? with MATLAB

4 Comments

What have you done so far? What specific problems are you having with your code? Do you know how to code the law of cosines?
yes ı know the basics and of course law of cosines
ı just cant understand how ı can find the angle
ı can find the value of cos(x) but not x
how to do triangle solver

Sign in to comment.

 Accepted Answer

James Tursa
James Tursa on 22 Nov 2021
Edited: James Tursa on 22 Nov 2021
If you can find cos(x), you might look at feeding that into the acos( ) function to recover x.

4 Comments

The program gives me radiant but the question wants angle
If you want an angle in degrees, you can use the acosd( ) function.
Hint: one of the functions listed in the "See Also" section at the end of the documentation page for the acos function will be of use to you.
thanks guys ı solved thanks to you :)

Sign in to comment.

More Answers (0)

Products

Asked:

on 22 Nov 2021

Commented:

on 5 Apr 2025

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!