Solve nonlinear complex equations
이전 댓글 표시
Hello,
I am trying to numerically solve a nonlinear complex equation and I would like to find all the complex roots. The equation is of the type:
cot(z)*z = 1-z^2*(1+i*z)
Does a specific function exist to find all the complex roots or do I need to separate z in the real and imaginary parts?
Thanks in advance for your help!
채택된 답변
추가 답변 (1개)
Azzi Abdelmalek
2013년 2월 10일
Use fzero function
doc fzero
f=@(z)cot(z)*z -(1-z^2*(1+i*z))
z0=i;
sol=fzero(f,z0); % the solution is near z0
댓글 수: 2
It's interesting that this worked for z0=i, but it appears to be just a fluke. FZERO can't really handle complex-valued functions. Note,
>> sol=fzero(f,1+i)
Error using fzero (line 309)
Function value at starting guess must be finite and real.
Ed
2013년 2월 10일
카테고리
도움말 센터 및 File Exchange에서 Solver-Based Nonlinear Optimization에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!