Monday, March 28, 2011

PSpice

The results of the tutorial
After using PSpice for the the tutorial, these are some notes that helped me work through problem 6 on assignment 8:
  • Remember to place a ground; the "floating node" error I had was the result of not defining a ground voltage.
  • I kept having to add libraries and hunt around for the part locations. Resistors are under "ANALOG," voltage sources and current sources are under "SOURCE," and grounds are under "0."
  • I try to keep the wire as clean as possible, i.e., using a single wire to connect elements instead of patching a bunch together.
  • Make sure the wire is not passing through a circuit element. This can mess everything up and is sort of tricky to spot.
  • You can end wire or element placement by pressing Esc (instead of right clicking).
  • Define another target directory to save projects in, as the default one is buried way within the C:/ volume somewhere.
  • Be sure to apply settings once you've edited them in the configuration window.
  • After running the simulation profile, you can click on the I and V buttons to display all voltages and currents in the circuit.
For the homework assignment, I first worked out the solutions by hand for some nodal analysis practice:


After this, I went through and drew up the circuit in PSpice. It was very similar to the tutorial because the parts were mostly identical. The only new element was a voltage source, which was also located in the "SOURCE" library. I created a simulation profile and brought up the currents and voltages. The results verified my answers, because 

12.31 mA * 25 V = 307.75 mW = Pv
and 
3.208 mA * 2 kOhms = 6.416 V = V1

The PSpice model of #8




Friday, March 18, 2011

Nodal Analysis

In this lab, we are modeling a redundant power system that has two voltage sources, in case one fails. This system should have breakers (in order to isolate bad components), which we are modeling with 100 ohm and 220 ohm resistors. Finally, we model two loads, each with 1K ohm resistors. Before we set up the circuit, we were able to calculate the voltage across the loads using nodal analysis, solving for the resulting system of equations. Substituting back into our equations, we could calculate current through each of the power sources and the power they supply.

V2 V3 Ibat.1 Ibat.2 Pbat1 Pbat2
10.26 V 8.67 V 17.4 mA 1.50 mA 0.209 W 0.0135 W

Next, we measured the actual values for the resistors, and set everything up on a breadboard. Here is our circuit:


We measured the actual values for the currents through source 1 and source 2 and voltage across the two loads:



Variable Theroetical    Measured            % Error
I bat 1 17.4 mA     17.9 mA 2.87%
I bat 2 1.50 mA     1.47 mA -2.00%
V2 10.26 V     10.35 V 0.88%
V3 8.67 V     8.75 V 0.92%

Then, we calculated power delivered by the batteries:

P bat 1 = 217 mW
P bat 2 = 13.3 mW

For the last step, we assumed that V2 and V3 were 9V, and used our previous equations to solve for the corresponding source voltages. We calculated that Vbat1 should be 9.9V and Vbat2 should be 10.98V. To achieve this source voltage drop, we hooked up resistor boxes in series with the two sources and tweaked the resistances until the desired 9V was achieved across the loads. These resistances ended up being R1s = 203 ohms and R2s = 103 ohms.

These were the resulting values for this scenario:


V2 V3 Ibat.1 Ibat.2
9.09V 8.99V 9.70 mA 8.61 mA



Monday, March 14, 2011

Voltage Dividers

For "voltage dividers," we are attempting to control the voltage in a circuit such that it hovers between an upper and lower bound. To control this, we can adjust the total resistance in the circuit. We have a constant shunt resistor, and a batch of 3 resistors on a bus which can be put in parallel to lower the equivalent resistance. Through calculations, I determined that Req max (one resistor on) corresponds to the maximum voltage across the bus, and that Req min (all 3 resistors in parallel) corresponds to the minimum voltage. After solving a system of equations, I found that our constant shunt resistor should be 55.47 ohms and that our constant voltage source should run at 5.54 volts. Using Kirchoff's laws, our group could determine that the resulting "max" and "min" bus currents were .00525A and .01425A, respectively.



Next, we actually tested our setup. We had to use slightly different values in practice because our equipment couldn't mimic the ideal calculated values.

Here is the data:

1 load
Req = 1000ohms; Vbus = 5.72V; Ibus = 0.00581A

2 loads
Req = 500ohms; Vbus = 5.43V; Ibus = 0.01096A

3 loads
Req = 332.6ohms; Vbus = 5.18V; Ibus = 0.01559A

Finally, we worked out the actual % variation in voltage, which was very high (14%). Again, this was due to the fact that our resistor box didn't correspond to the calculated shunt resistor value that would yield a perfect 5% variation.

The last problem involved the sort-of inverse of our original situation: if the equivalent resistance was kept constant, how would we have to vary the shunt resistor in order to create a 1% variation in bus voltage? Using a similar system of equations, I found that Rs = 32.24 ohms yielded the upper bound and Rs = 39.73 ohms yielded the lower. 

Wednesday, March 9, 2011

Introduction to Biasing

We have two LEDs in parallel, each with unique voltage ceilings. Since we have only one power supply (also in parallel), we have to find out how to differ the voltage through each of the LEDs. This is called biasing. We can limit voltage across the LEDs by adding resistors to the circuit. These resistors "soak up" some of the parallel voltage so that not all of it is going through our sensitive LEDs.

Given a 9V source and two parallel LEDs with voltage limits of 5V and 2V, respectively, we could calculate that a 220 ohm resistor is needed in series with the 5V LED, and a 100 ohm resistor with the 2V LED. So we set up our circuit as such, and connected a voltmeter in parallel + ammeter in series with the LEDs to take some measurements. We also set up configurations with the individual LEDs.

The model
Here are our measurements:


Config 1
LED1 Current = 14.5mA
LED1 Voltage = 6.86V
LED2 Current = 21.0mA
LED2 Voltage = 1.65V
Supply Current = 35.4mA


Config 2
LED1 Current = 14.6mA
LED1 Voltage = 6.81V
Supply Current = 14.4mA


Config 3
LED2 Current = 20.7mA
LED2 Voltage = 1.65V
Supply Current = 20.7mA

Based on these results and a hypothetical 9V, 0.2 amp-hour battery, we calculated that the LEDs could be powered for 4.68 hours.

We then calculated the actual vs. theoretical LED current. Our actual current was lower due to the fact that we were using a non-ideal voltmeter in parallel.

Finally, we calculated the efficiency of our setup, which was quite low due to the resistors stealing a lot of our power.

Power out: 0.13412 W
Power in:    0.3186 W
Power lost: 0.18448 W

Efficiency: 42.1%

We were asked about what would happen to the efficiency if a 6V power source had been used instead of a 9V. I reasoned that it would increase, because less power is now going to the resistors (which aren't doing any work). 5V would actually correspond to the most efficient setup, since we're now using a value that allows us to eliminate the most resistance possible (one of our LEDs has a 5V max) and run a resistor only alongside the 2V max LED.

Friday, March 4, 2011

Introduction to DC Circuits

In this lab, we used the relationship between voltage, resistance, and current (V=IR) to solve a hypothetical problem involving a battery, load, and unknown length of wire.

The problem

We have a battery that supplies a constant voltage to the circuit for a limited amount of time, and a load in the circuit with a constant resistance. In any real situation, the wires necessary to make the circuit also add resistance to the circuit.  As the total resistance in the series circuit increases, voltage across the load decreases in order to maintain a constant current (current is constant across series elements and our battery voltage is constant). There is a minimum voltage for which this load will operate, and we're trying to find the maximum added cable resistance that corresponds to this minimum voltage.

The model

Our setup


We modeled the battery with a constant-voltage power supply, the load with a resistor whose value was known, and the unknown length of cable with a variable-resistance box. These three things, along with an ammeter, were set up in series; a voltmeter was set up in parallel with the load to catch the operating voltage corresponding to any given resistor box value.

What we found

Values:
Actual load resistance: 975 ohm
Resistor box power rating: 0.3 W
Max supply voltage (Vbatt): 12.09 V
Max supply current: 2 A
V across the load: 10.96 V
I through battery: 11.45 mA
R of cable: 88 ohms

We tweaked the variable-resistance box until the voltage across the load dropped to exactly 11v (our minimum). The added resistance that caused this was 88 ohms, and the resulting current was 11.45 mA.

Using the capacity of the battery (0.8 Amp-hours) and the current flowing through it, we were able to calculate that the battery should sufficiently power the load for 69.87 hours.

Using P=IV and its other forms, P=(V^2)/R and P=(I^2)R we calculated the power going into the load and the "wire" (resistor box), respectively.

P to load: 0.123 W
P to cable: 0.0115

We could then calculate the efficiency of this setup, which was 91.4%. This means that 91.4% of the power goes into the load, and the remaining power goes into the wire.

Based on the resistance per unit length of AWG #30 wire, we were able to calculate the length that corresponds to the 88 ohms, and thus the maximum distance the load can be placed from the source while still maintaining a functional voltage.

Max distance: 128 meters