I don't know how to prove sin^2(x)+cos^2(x)=1

63 vues (au cours des 30 derniers jours)
Moun Hyeon Song
Moun Hyeon Song le 17 Nov 2020
Modifié(e) : Bruno Luong le 17 Nov 2020
I want to prove this thing by Matlab
sin^2 (x) + cos^2 (x) = 1
Somebody help me.
Please.....
  1 commentaire
Bruno Luong
Bruno Luong le 17 Nov 2020
Nothing can be prove by MATLAB or any software

Connectez-vous pour commenter.

Réponse acceptée

KSSV
KSSV le 17 Nov 2020
Modifié(e) : KSSV le 17 Nov 2020
There are multiple ways to prove this:
Option 1:
x = rand ;
sin(x)^2+cos(x)^2
Option 2:
syms a b c
sinx = a/c ;
cosx = b/c ;
LHS = sinx^2+cosx^2 ;
In the above we have
Thus LHS = 1

Plus de réponses (3)

Ameer Hamza
Ameer Hamza le 17 Nov 2020
Modifié(e) : Ameer Hamza le 17 Nov 2020
If you have symbolic toolbox, you can use isAlways()
syms x
eq = sin(x)^2 + cos(x)^2 == 1;
tf = isAlways(eq)
value of 1 means that it is correct for all values of 'x'.

James Tursa
James Tursa le 17 Nov 2020
Modifié(e) : James Tursa le 17 Nov 2020
[cos(x),sin(x)] is defined to be a point on the unit circle, so by definition we have sin^2(x) + cos^2(x) = 1 always. This isn't something to be proved since it is a definition. If you want to demonstrate it with values, you can always just plug stuff in and see that you always get about 1 within numerical floating point errors, or make x symbolic and evaluate the expression. But, this will just be a "feel good" demonstration ... it doesn't prove anything since the result follows directly from the definition.

Bruno Luong
Bruno Luong le 17 Nov 2020
Modifié(e) : Bruno Luong le 17 Nov 2020
Definition
exp(x) = sum x^k/factorial(k).
Property (provable here)
exp(x+y) = exp(x)*exp(y)
Definitions
sin(x) = 1/(2i) (exp(ix) - exp(-ix))
cos(x) = 1/2 (exp(ix) + exp(-ix))
Thus using exp(0) = 1, i^2=-1
sin(x)^2 = -1/4 (exp(2ix) + exp(-2ix) -2)
cos(x)^2 = +1/4 (exp(2ix) + exp(-2ix) +2)
When sum it all the exp terms go away and we get
sin(x)^2 + cos(x)^2 = 1
(then one can deduce (sin(x),cos(x)) is point on circle, NOT the opposite definition of sin(x) is abcissa coordinate of point on circle bla bla bla).

Catégories

En savoir plus sur Resizing and Reshaping Matrices dans Help Center et File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by