Monday, May 30, 2016

Day 19 2nd Order Circuits Contb

We started with talking about the Qi wireless charger which had two modes of charging, Resonant and Inductive. There is a trade off between each mode, loosely coupled system trade off larger distance at the cost of lower power transfer efficiency and higher EMF. Tightly coupled system produce less heat which is favorable for heat budgeted devices like cell phones.

We then move onto the real gritty stuff of continued the work on Series and Parallel RLC. We started with the step respond of a series RLC circuit. It is a second order differential, with i = Cdv/dt. Vt = Vn + Vf. In natural response Vs = 0. Vn can be OD,CD,UD, Vf = Vinf = Vs.
 OD = A1e^s1t+A2e^s2t
 CD = (A1+A2t)e^-alpha*t
 UD = (A1coswdt + A2sinwdt)e^-alpha*t
The complete version then is:
 OD = Vs + A1e^s1t+A2e^s2t
 CD = Vs + (A1+A2t)e^-alpha*t
 UD = Vs + (A1coswdt + A2sinwdt)e^-alpha*t

A1 and A2 are from V(0) and dV(0)/dt. V is Cap, I is current of inductor.

Knowing this we try an example.


White board work: Using above information and numbers given.
More white board work continued.
White board work: more white board work we found di/dt in terms of A2 = -10. S = j8
More white board work continued.
White board work continued, found A1 = 20V used wd since it was a O
We then move onto the step response of a parallel RLC circuit. We use current for parallel.
I(t) = In + If. . In can be OD,CD,UD, If = Is.
 OD =Is +  A1e^s1t+A2e^s2t
 CD = Is + (A1+A2t)e^-alpha*t
 UD = Is + (A1coswdt + A2sinwdt)e^-alpha*t
We tried an example of our own with the knowledge attain above.
White board work: S1 = -1+j S2 = -1-j, UD. If = Is  = 5A
More white board work continued.
White board worked continued: A2 = -5
We then move onto the lab of the day: RLC circuit response.
Prelab: We first did the lab in every-circuit. Then we wrote the second order diff on the white board. Then estimated damp ratio. And lastly rise time and frequency on white board.

Picture of the everycircuit schematic and working, min -20 mV max 62.3 mV and freq 1khz
White board work of prelab it has the second order diff, (kind of cut off but is there).

White board work of the second order.
More white board prelab work.
White board work: Has alot of information has Vo at 42mV. A1 = 42. alpha = 500, w0 = 10,000, UD. Damping ratio = .05.

Picture of the time respond in the every-circuit app.
Picture of the time respond of every-circuit, 10 ms.
Picture of real circuit.
Picture of the real circuit, none of that fake stuff.
Picture of the real stuff data.
Picture of the step respond.
More picture data.
Picture of data of step respond freq 200 hz, Vin = 40 mV Vout = 2 volts. Matches every-circuit and our white board work very closely with Vin 42 mV. As percent diff  it is = 4.7 % error.
More pictures of real, cleaner version!
Picture of the real but prettier thanks to Edgar. We will not name the original maker.
White board work for POST lab:
We found wd to be 9987, r1 real to be 47.4 ohms. A1 - 42, A2 = 6.3

White board work showing the used second order diff and the steps needed to find A1 and A2.
More white board work, found di/dt and t of rise time = 10us. Which matched was close to every-circuit but was off by a factor of 10 to get percent error of = 1000%. We think we lost a exponent somewhere in our math but think we got it correctly.

In conclusion of the lab: We found our numbers to match every-circuit and the data from diligent. We are off by a factor 100 since picture data says 1us and we got 10us and every-circuit says 10ms. We are close but far away. Our percent error for A1 and A2 are good with Vin being 42 mV and recorded at 40 mV our percent error is 4.7%. The damping ratio is .05 and we got .5 again out numbers are off by a factor so somewhere in the math we lost an exponent but our percent error would be 0 but in this case it is over 1000%. We also think we may be off because real has non-ideal components while every-circuit had ideal components.

The text file for this contiues on with talking general second order circuts like op amps and smoothing digital signals but I dont have pictures for that.

In summary of the day we learned more about step response circuit and did a lab on it and briefly talked about second order op amps. We learned that series use V for step response and parallel use I for step response but the equations of OD,CD, UD are the same for both just need to swamp out V for I. Vf = Vinf, If = Iinf.

Day 18 2nd Order Circuitsb

We started the day with talking about boundary values. A couple of simple things to know is that v(0+) = v(0-) and i(0+) = i(0-). So it is important to start with how the circuit behaves initially and how it behaves in the end. Inductors act like shorts, Capacitors act like open in DC setting after a long time. In order to understand this we did an example. White Board work below.
White board work: We took out the .25H inductor, and .1F capacitors, and drew the equivalent circuit of t approach infinity. V = IR, V = 4.
We then did the KVL.
White board work: Using KVL. di/dt = 0.
We then did some algebra with the properties of inductors. We end up with a second order.
White board work: algebra work to end up with i = Ae^st. and we try to find S.
More white board work continued.
White board work: Continued to find S.
More White board work continued.
White board work: Found S used square root to find s in terms on alpha and omeganot.
More white board work continued. Depending on alpha or omega bigger the circuit damps differently. OverDamp = alpha>omega C > 4L/R^2, Critically Damp alpha = omega, UnderDamp alpha<omega, used omegad = sqrt(omega^2-alpha^2), time constan is 1/alpha and T = 2pi/omegad
We then moved onto source free RLC circuit. Alpha = R/2L, Omega = 1/sqrt(LC)
White board work: circuit drawn with numbers.
More white board continued.
White board work: S = -alpha +- sqrt(alpha^2-omega^2). Alpha >omega this OD.
We then move on the lab of the day: Series RLC Circuit Step Response
Prelab: Part1 White board work and circuit and equations.

White board work: drew circuit, and second order equation
White board work: Found alpha and omega, alpha = 500, omgea = 4.61e3, alpha<omega UD. Damping ratio .108.
White board continued for part 2.
White boar work: finding R, R = 9.22 ohms.
White board work: Inductor resistance is 2.4 ohms, R = 1 (4.5)real, C = .47uf, L = 1mH
Picture of Part 1 circuit.

Picture of the Vin and Vout of part 1 circuit.

Picture of data of Vin and Vout. Vin = 15.9 mV, and Vout = 16.1 mV, rise times of 2.6us. and 2.2us, Freq = 124khz.

Picture of part 1 of the lab. Delta X = 120us.

Picture of data for part2 lab. Vout = 5.3 mV, Vin = 1V. Risetime 1.9us and 0s.

Picture of part 2 of the lab, the new R is 9.22 ohms, or closes to it. to make it CD.

Picture of part 2 of the lab. We noticed that Vin and Vout are 180 out of phase.

Picutre of the delta X = 40 us.

Picture of more data for part 2, clearer.

Picture of data for part 2 lab, Vin 7.8 mV, Vout = 18.8 mV, ristime = 15 ns. Freq = 4.3 Mhz
In conclusion of the lab:
The lab showed the oscillation between the inductor and capacitor. It made sense of the OD portion that the Vout was dying out. For part 2 Vin and Vout were 180 out of phase. There were some difficulty find the right R for the second part of the lab sense the inductor had resistance and the 1 ohm resistor has great uncertainty which made it 4.5 ohms. The gain was 1 for part 2 as shown in the pictures. Finally there was unexpected overshoot and the DC gain since we did not have ideal parts.

We then move onto to talk about source free parallel RLC circuits.
They also have a second order equation. Alpha and omega are different. We tired an example on the white board.
White board work: S1 and S2 the same as before however alpha = 1/2RC and omega = 1/Sqrt(LC)
White board work continued.
White board work: continued we found S in terms of A1 and A2, did some plug ins and found A1 and then found A2. A1 = -.208, A2 = 5.2

In summary we learned about boundary values and the rules associated with them. Did an example of it with making inductors short and capacitors open. Vinital = V after and same with current. Then found values of S with alpha and omega. There is three types OD,CD,UD, with alpha>omega, alpha = omega, alpha<omega. CD has omegad = sqrt(omega^2-alpha^2). There are two types of RLC series and parallel. We did a lab on Series RLC circuit. Found the CD resistance for part 2, 9.22 ohms. We concluded that the pictured taken made sense for the OD circuit and CD circuit, however there was unexpected overshoot with the non ideal parts used. Lastly we talked about spark plugs and how they useful.

Thursday, May 12, 2016

Day 17 1st Order Circuits contc

We started the day with talking about first order op amp circuits. Capacitors and inductors apply three useful properties in  electric circuits. Caps store energy, Caps oppose abrupt changes in voltage, Inductors oppose abrupt changes on current, this is useful for spark and arc suppression and for changing pulsing dc voltage into a smooth dc voltage. Lastly they both are frequency dependent, which in turns make them frequency discrimination for ac applications.

We were asked to show the algebra of an Integrator Op-amp. White board work below.

White Board work of an Integrator Op-amp. use Ir = Ic and Ic = -CdVo/dt. Gain is -1/RC and integration of Vin which is -Vin/Tao.
Next we were asked to another example with values and show the signal going in of the Op-amp.
White Board work: We take an input signal and take the derivative and negative 1.
White board work of the Differentiator. Not the same integrator, since output is -RC(derivative) and not -1/RC(integrate)
White board work: showing the output real. It is the gain(-1) times the derivative of input signal.
Afterwards we move onto the lab of the day: Inverting Differnetiator.
Prelab: Is done on the white board. C1 = .1uF, R = 1M ohm, RC = -1
Vout = -1/RC dVin/dt Vin = Acos(wt) w = 2f,  Vout = 1/(1.04)(w)sin(wt)

White Board work: Showing our circuit with values on the Op amp. Note R of 10M is 9.6M
White board work of voltages in at the different freq. 2khz,1khz and 500 hz.
White board work: The lab asked for 1V offset but we used 5mV,5mV and 2mV instead, don't remember why. The order is 2khz, 1khz, and 500 hz.
We then took the amplitude reading of the values. Channel 2 is Vin, Channel 1 is Vout.
White Board work: 500hz amp in 2.7mV, 2khz amp in 2.68mV, and 1khz amp in 2.69mV. Their respected Amplitude out are: 3.3V,2.56V and 3.48V. This is the tablet for post lab. Percent error is further down. There are difference between expected and measured, the differences believe are because of using the wrong formula and/or not the right input voltage/different RC.
Lastly our comments on the lab, Vout is Pi/2 out of phase of Vin and if frequency goes up Amplitude goes down.
White board work: Our conclusion of the lab, Vout is pi/2 out of phase and frequency goes up Amplitude goes down.

Here are the pictures required of the post lab: Pics of different frequency 2khz,1khz, and 500hz

Picture of the 1khz signal, yellow is output signal, cosine, blue is input signal cosine plus phase shift.

Picture of the data from the 1khz signal: Vout =3.2 V, Vin = 2.68 mV
Picture of 2khz signal, Yellow is Vout, Blue is Vin. Ch1, Ch2.
Picture of the 2khz signal, Yellow is cosine, blue is cosine +phaseshift. Vin, Vout.

Picture of the 2khz data: Vout = 1.6V, Vin= 2.68 mV
Picture of 500hz signal. blue is Vin, Yellow is Vin.
Picture of the 500 hz signal: Yellow is Vout, Blue is Vin.

Picture of Data for 500hz: Vout = 3.3V, Vin = 2.68 mV.
Here is a picture of the circuit used.
Picture of the circuit used: Op amp, .1uF and 10M (9.6 M real) resistor.
For the conclusion of the lab: POST LAB
5*cos(2*pi*f) w1 = 12566,w2 = 6283, w3 = 3141 1/RC = .96 Vin 2.68mV
-1/RC *Vin*w1*sin(w1) = 2.68 V, real is 2.56 %diff = 3.7%
-1/RC*Vin*w2*sin(w2) = 4.7 V, real is 3.48 %dif = 25%
-1/RC*Vin*w3*sin(w3) =4.5 V, real is 3.3 %dif = 26.6%

I do not feel confident is these percent error's,  I tried using different input voltages and the numbers calculated do not add up, I do believe we recorded the right numbers. I think I must be using the wrong formula :(

 We then moved onto switching functions! We started with the delta and what it represents. An area of 1.

White board work of delta, delta = 1!
We then tried an example of using switching formula.
White board work of the switching example. Ic = CdVct/dt. The derivative of u is delta the derivative of rt is u. Vc at 5 at0.
More white board work shown.
White board work: Ic, the impulse is .6 at .5.
Next we move onto the step response of RC circuit.White board work below.
White Board work of the step respond. V/R times e of -t/tao times the step respond.
We then tried another example by using what we learned and did on the white board.
White board work: Vs = 5u, Vintial = 0, Tao = 5. Tao is Req times C.
More white board work shown. The final formula needed. Vinf + [Vnot - Vinf]e to the -t/tao.
White board work with the equation in standard form.
White board work with numbers plugged in.
White board work: Cdv/dt - .5(-5/4)(-1/5)e^-t/Tao.
We then move onto the Step Respond of a RL circuit. i = in+if. In = Ae^-t/Tao, Tao =  L/R. We tried an example shown on the white board.
White Board work. We needed to find Inot, then Req for Tao. Then we used node voltage to find Iinf.
We came to the conclusion formula of i(t) = 5/6(1+e^-t)A
In summary we started with op amps. One being the integrator and the other being the Differentor. The integrator integrated Vin, and the differenetor differentiated Vin by the op amp. We then moved onto the lab of the which was the differentor. We found our numbers to not match the expected values with percent different errors up to 26% but we believe that is due to not following the instruction in the lab with the right input voltages are the right resistors. We do think we got resonalbe data. It seemed from the pictured that the Vout was 90degress out of phase from the input which makes sense and the higher the frequency the lower the amplitude was recorded. Lastingly for the day we talked and derived step response logic for both the RC and RL circuit. For RC the initial capacitor voltage is 0, final is Vinf and then find Tao. For RL the initial inductor current is 0, final current if Iinf and then find Tao. last thing we talked about was delay circuits and relays.