필터 지우기
필터 지우기

got Root( ) function as an answer to solve function

조회 수: 1 (최근 30일)
Harsha vardhan naidu
Harsha vardhan naidu 2020년 4월 20일
답변: Star Strider 2020년 4월 20일
alpha = [ 0.0011 , 0.0003 , 0.0014 ; 0.0005 , 0.0012 , 0.0003 ; 0.0015 , 0.0006 , 0.0018]
func = det (alpha - (1/x^2)*eye(3)); i have to solve for the x. so I ave used solve function
solution = solve(func,x); I am getting answer as Root(function in z) z is not a defined variable. like this
-root(z^3 - (4678547572322683*z^2)/23058430092136939520 + (32298961955171129226741589070309*z)/4253529586511730793292182592897102643200 + 636247053454892806674580934243698396657569963/392318858461667547739736838950479151006397215279002157056000, z, 1)^(1/2)
In next step i have to extract positive solutions out off all the solutions so I used solution(real(solution)>0) but I am getting an error because the solution is not numerical.
  댓글 수: 2
KSSV
KSSV 2020년 4월 20일
Where is x in your code?
Harsha vardhan naidu
Harsha vardhan naidu 2020년 4월 20일
편집: Harsha vardhan naidu 2020년 4월 20일
In the second line
func = det(alpha - (1 / x^2)*eye(3) )

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

채택된 답변

Star Strider
Star Strider 2020년 4월 20일
Use:
solution = vpasolve(func,x);
although it may be necessary to use:
solution = solve(func,x);
solution = vpa(solution);
.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Solver Outputs and Iterative Display에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by