From: Farshid bahrami on
Hi.

I want to solve a complex equation (F(x)) and I don't know the initial guess to use fzero. Can anybody guide me?

syms x; % the only unknown variable

% Constants
eps1=-16.3-.522*1i;
eps2=1.44^2;
eps3=1.615^2;
eps4=1.5125^2;

% Constants
N=0;

lambda0=.6326e-6;
k0=(2*pi/lambda0)^2;

% Constants

k12=eps1*k0^2;
k22=eps2*k0^2;
k32=eps3*k0^2;
k42=eps4*k0^2;

K31=eps3/eps1;
K32=eps3/eps2;
K21=eps2/eps1;
K34=eps3/eps4;

% Definitions dependent on x

kx1^2=k12-x^2;
kx2^2=k22-x^2;
kx3^2=k32-x^2;
kx4^2=k42-x^2;

% Constants
t2=.1e-6;
t3=1e-6;


% Two sides of the equation are A and B

A=kx3*t3;
B=atan((K31*1i.*kx1./kx3)-K32.*(kx2./kx3)*tan(kx2.*t2))/(1+K21*(1i.*kx1./kx2).*tan(kx2.*t2))+atan(K34*1i.*kx4./kx3)+N*pi;

% the final equation to be solved

F(x) =A-B;