How Do You Correctly Plot a Bode Diagram for a High-Pass Filter in MATLAB?

AI Thread Summary
To correctly plot a Bode diagram for a high-pass filter in MATLAB, the transfer function should be defined as G = RC*s / (RC*s + 1), where RC is the product of resistance and capacitance. In this case, with a capacitance of 220 nF and resistance of 10 kΩ, RC calculates to 220e-12 * 1e4. The user should ensure that the transfer function is properly set up in MATLAB using the 'tf' command. The Bode plot can then be generated using the 'bode' function. Proper manipulation of the transfer function in MATLAB will yield the correct magnitude and phase response for the high-pass filter.
gimini75
Messages
50
Reaction score
0
Hi

I have a transfer function< I want to draw a bode diagram in MATLAB, the transfer function is for a simple HPF when I use MATLAB to find the magnitude and phase shift it giving a wrong diagram, the transfer function is:

=RCs / (RCs + 1)
I want to know how shoud I have to manipulate this function in MATLAB to find the correct answer?
Capacitance = 220 nF
R = 10 kilo ohm
Thanks
 
Physics news on Phys.org
s=tf('s');
RC=220e-12*1e4;
G=RC*s/(RC*s+1);
bode(G)
 
Thread 'Have I solved this structural engineering equation correctly?'
Hi all, I have a structural engineering book from 1979. I am trying to follow it as best as I can. I have come to a formula that calculates the rotations in radians at the rigid joint that requires an iterative procedure. This equation comes in the form of: $$ x_i = \frac {Q_ih_i + Q_{i+1}h_{i+1}}{4K} + \frac {C}{K}x_{i-1} + \frac {C}{K}x_{i+1} $$ Where: ## Q ## is the horizontal storey shear ## h ## is the storey height ## K = (6G_i + C_i + C_{i+1}) ## ## G = \frac {I_g}{h} ## ## C...

Similar threads

Back
Top