How can I solve this: (x-2)*(x+1)^3?
조회 수: 3 (최근 30일)
이전 댓글 표시
Hey there,
I am trying to process this "(x-2)*(x+1)^3" through matlab in way that I can have a result like this:
However every time I try to perform this operation, matlab keeps on telling me that x is set to nothing, how can I solve this?
Thanks in advance!
댓글 수: 0
채택된 답변
Ayaz Siddiqui
2022년 3월 10일
편집: Ayaz Siddiqui
2022년 3월 10일
Try using expand.
syms x;
expand((x-2)*(x+1)^3)
추가 답변 (1개)
Sam Chak
2022년 3월 10일
It's good to hear that you tried working out something by yourself. You need to create a symbolic variable for x.
syms x
For more info, please check:
참고 항목
카테고리
Help Center 및 File Exchange에서 Symbolic Math Toolbox에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!