#### StoppTidigare

##### Full Member level 2

- Joined
- Jul 16, 2002

- Messages
- 145

- Helped
- 1

- Reputation
- 2

- Reaction score
- 0

- Trophy points
- 1,296

- Location
- Northern earth

- Activity points
- 1,698

**Matlab help**

Hi all, could somebody explain to what this

z = (r/(r+1) + 1/(r+1)*exp(j*theta));

comes from in the matlab-function below?

I know that constant r-circles are given by the eqn:

(U-r/(r-1))^2 +V^2=(1/(r+1))^2

and the constant x-circles is givne by

(U-1)^2 +(V-1/x)^2=(1/x)^2

Do you remember it from basic Smithchart theory ?

function [h] = smircirc(r)

%SMIRCIRC Draw impedance circle in the Smith chart. This function

%written by Soeren Laursen (slau93@control.auc.dk).

% [H] = SMIRCIRC(R) draws a circle with r = R and returns

% a handle to the circle in H.

global SMITH_CHART_UNDO

theta=linspace(-pi, pi, 63);

z = (r/(r+1) + 1/(r+1)*exp(j*theta));

if nargout > 0

h = plot(z);

SMITH_CHART_UNDO = [SMITH_CHART_UNDO h];

else

SMITH_CHART_UNDO = [SMITH_CHART_UNDO plot(z)];

end

What does he mean with impedance circle ? There's no such!

/StoppTidigare