+/- signs when coding ?

조회 수: 6 (최근 30일)
Jenny Andersen
Jenny Andersen 2019년 11월 16일
답변: Image Analyst 2019년 11월 16일
How to type in v1 = +/- w2/((w3^2)+(w2^2)) and v2 = +/- w3/((w3^2)+(w2^2))?
The problem is that the vectors can be both positive and negative
  댓글 수: 2
Rik
Rik 2019년 11월 16일
Is this in the context of symbolic variables? Otherwise Matlab numeric arrays must have a definite value.
dpb
dpb 2019년 11월 16일
If it is the data itself that is positive or negative, then that is reflected in the values themselves.
If the sign of the terms in the equations themselves are to be different, then you have to code those explicitly and evalute the one of choice. Or, alternatively, code in another coefficient in the location of the sign and set that as data to plus/minus one.

댓글을 달려면 로그인하십시오.

채택된 답변

Image Analyst
Image Analyst 2019년 11월 16일

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 MATLAB에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!

Translated by