how to write cos*cos*sin

Antworten (2)

Azzi Abdelmalek
Azzi Abdelmalek am 14 Jul. 2016

0 Stimmen

f=@(x) cos(x)*cos(x)*sin(x)

2 Kommentare

Jose Louis
Jose Louis am 15 Jul. 2016
Matlab does not accept that, for example, if I have three angles (Alpha, Beta, Gama) and I need to solve X= cos(Alpha)*Sin(Beta)* sin(Gama) Matlab does not accept that
Azzi Abdelmalek
Azzi Abdelmalek am 15 Jul. 2016
There is nothing about solving in your question, please edit your question and make it clear, explain what are you data and what are your unknown variables

Melden Sie sich an, um zu kommentieren.

Star Strider
Star Strider am 15 Jul. 2016

0 Stimmen

You have to use element-wise operations:
ccs = @(x) cos(x).*cos(x).*sin(x);
See Array vs. Matrix Operations for a full explanation of the difference.

Kategorien

Mehr zu Operators and Elementary Operations finden Sie in Hilfe-Center und File Exchange

Gefragt:

am 14 Jul. 2016

Kommentiert:

am 15 Jul. 2016

Community Treasure Hunt

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

Start Hunting!

Translated by