# Draw the magnitude and phase angle of a voltage in this AC circuit

• Engineering
• Fatima Hasan
In summary, the conversation discusses a code that treats L and C similarly and a solution for a problem involving VDR. The speaker also mentions using [CODE=Matlab] tags to present the code more effectively. They confirm their answer and check for phase difference and V(C) behavior at higher frequencies.
Fatima Hasan
Homework Statement
Consider the simple ac circuit of figure 1(b). The frequency of the AC source varies between 100 Hz to 500 Hz. Draw the magnitude and phase angle of the voltage across the capacitor. Try to increase the frequency by step of 5 Hz.
The circuit is attached below.
Relevant Equations
-
My solution is attached below.
I am not sure if my answer is correct or not , I want to confirm it.

#### Attachments

• Capture.PNG
10.2 KB · Views: 234
• ans1.PNG
25.9 KB · Views: 227
• ans2.PNG
11.6 KB · Views: 237
Fatima Hasan said:
if my answer is correct or not
From the code ?

it seems strange to me that L and C are treated similarly ...

PS: PF has [CODE=Matlab] ... your code here ... [\CODE] tags that present it much mure usefully:

Matlab:
 for i = 1:((500-100)/5 + 1)
w(i) = ...

DaveE and Fatima Hasan
BvU said:
[\CODE] tags that present it much mure usefully:
Thank you !

C should be = 1/(Xc*j*w(i))
I resolve it again and here's what I got :
Matlab:
clc;
clear all;
v=100*(sind(0)*j+cosd(0)); %convert from polar to rectangular form
r=10;
xl=10*10^(-3);
xc=50*10^(-6);
f=100:5:500;
for i=1:((500-100)/5+1)
w(i)=f(i)*2*pi;
l(i)=j*w(i)*xl;
c(i)=1/(xc*j*w(i));
vc(i)=v*c(i)/(c(i)+l(i)+r); %apply VDR
end
figure(1)
subplot (2,1,1) , plot(f,abs(vc))
subplot (2,1,2) , plot(f,rad2deg(angle(vc)))

#### Attachments

11.4 KB · Views: 194
BvU
Looks a lot better now !
Checks are 90 degree phase difference at ##\ 2\pi f = {1\over \sqrt{LC}}\ ##
and V(C) dropping off with ##1/\omega^2\ ## at higher frequencies.

DaveE and Fatima Hasan

## 1. What is an AC circuit?

An AC (alternating current) circuit is a type of electrical circuit in which the current periodically changes direction, usually at a specific frequency. This is in contrast to DC (direct current) circuits, where the current flows in only one direction.

## 2. What is magnitude in relation to voltage in an AC circuit?

The magnitude of a voltage in an AC circuit refers to the maximum value of the voltage, also known as the amplitude. It is typically measured in volts (V) and represents the strength or intensity of the voltage.

## 3. What is phase angle in relation to voltage in an AC circuit?

The phase angle of a voltage in an AC circuit refers to the angular difference between the voltage and a reference point on the circuit. It is measured in degrees or radians and represents the timing or synchronization of the voltage with the reference point.

## 4. How is the magnitude of a voltage represented in a graph of an AC circuit?

In a graph of an AC circuit, the magnitude of the voltage is represented by the height or amplitude of the waveform. The higher the amplitude, the greater the magnitude of the voltage.

## 5. How is the phase angle of a voltage represented in a graph of an AC circuit?

In a graph of an AC circuit, the phase angle of the voltage is represented by the horizontal shift or displacement of the waveform. The greater the displacement, the larger the phase angle of the voltage.

• Engineering and Comp Sci Homework Help
Replies
2
Views
875
• Engineering and Comp Sci Homework Help
Replies
3
Views
1K
• Engineering and Comp Sci Homework Help
Replies
19
Views
2K
• Engineering and Comp Sci Homework Help
Replies
2
Views
1K
• Engineering and Comp Sci Homework Help
Replies
7
Views
2K
• Engineering and Comp Sci Homework Help
Replies
4
Views
2K
• Engineering and Comp Sci Homework Help
Replies
7
Views
1K
• Engineering and Comp Sci Homework Help
Replies
13
Views
1K
• Engineering and Comp Sci Homework Help
Replies
1
Views
1K
• Engineering and Comp Sci Homework Help
Replies
17
Views
2K