Nie możesz wybrać więcej, niż 25 tematów Tematy muszą się zaczynać od litery lub cyfry, mogą zawierać myślniki ('-') i mogą mieć do 35 znaków.

39 wiersze
950B

  1. %% Transfer function of a RC-network
  2. % This script will run automated measurements for you. Note that all frequencies
  3. % are given in Hertz.
  4. %% Component Values
  5. % Fill in the measured values in the following code box.
  6. %%
  7. R = 3.2942e3; %Ohm
  8. C = 315.82e-9;%Farad
  9. %%
  10. % Give the desired begin and end frequency as well as number of steps:
  11. f_start = 10; %Hz
  12. f_stop = 1e3; %Hz
  13. %%
  14. % Do not edit the following code box.
  15. f = 10.^linspace(log10(f_start),log10(f_stop),500);
  16. %% Theoratical Curves
  17. % Give the equations for the magnitude:
  18. %%
  19. A = -10*log10(1+(2*pi*f*R*C).^2);
  20. %%
  21. % For the phase:
  22. P = -atan(2*pi*f*R*C);
  23. %%
  24. % For the cut-off frequency:
  25. Fc = 1/(2*pi*R*C);
  26. %%
  27. % And both asymptotes where $f >> f_c$ and $f << f_c$:
  28. S_smaller = 0*f; %smaller than cut-off frequency
  29. S_larger = -20*log10(2*pi*f*R*C); %larger than cut-off frequency
  30. %% Running the Measurement
  31. %%
  32. n_steps = 5;
  33. amplitude = 10;
  34. RC_TransferFunction_script;