Wednesday, October 22, 2014

Transient analysis of RLC/RL/RC circuit- PSPICE Simulation

In this post, we will see the transient analysis of RL circuit with the help of an example. Before solving that we should understand the behaviour of Inductor in the steady state condition. To know in detail. See this video--> Prerequisite

Let's take the following example

 PSPICE simulation of RLC circuit
Main diagram


A) Before t=0-

In the above example, before t=0-, i.e in a steady state condition, inductor will act as a short circuit, so the current through the inductor at t=0- will be 0.75A. i(t), in this case will be 0.

B) At t=0+

After the switch S is closed, the inductor will resist the change, so it will not permit this to happen. Even after the switch is closed at t=0. At t=0+(Just after the switch is closed), inductor will still take 0.75A. So the two resistors which are in parallel divide the remaining 0.75A among themselves. i.e i(t)=0.375A at t=0+.


c) t=0+ to infinity

The inductor is a memory element, so it resists the change in current. It takes certain time to reach a steady state. At steady state(t=infinity), the current through il=0.5A(Since L acts a short circuit, the above circuit will be just  a parallel combination of 3 resistors each of 10 ohm. i(t) |t=infinity=0.5A.

General expression of i(t) can be found using the following equation(Refer main diagram to know which is i(t))

i(t)=Final value+(Initial Value-Final value) exp(-t/tc)  ,where tc=time constant of a circuit.

so, 
i(t)=0.5+(0.375-0.5) exp(-1000t) A.

i(t)=0.5-0.125*exp(-1000t) A.

At t=0, i(t)=0.375A
At t=infinity, i(t)=0.5A


                                              PSPICE SIMULATION



i(t)

iL

Red color=i(t). Green color=iL



Note

Because of the presence of inductor, the current i(t) takes certain time(5 time constant) to reach its final value of 0.5A. The current i(t) value varies from 0.375A to 0.5A .
Inductor resists the change in the current.


Simulation video--> Part 1 and Part 2

Saturday, October 11, 2014

Control System Quiz

1) The transfer system of the system which will have more steady error for unit step input is
a) 80/(s+1)(s+2)(s+3)
b)120/s(s+1)(s+15)
c) 60/(s+0.5) (s+3)(s+5.5)
d)120/(s+1)(s+4)(s+15)
Show/hide solution

2)When the gain 'K' of the system is increased, the steady state error of the system
a)Increases
b) Decreases
c) Remains unchanged
d) May Increase or decrease
Show/hide solution

3)A unity feedback system has forward path transfer function G(s)=K/s(s+2). If the design specification is that the steady state error due to ramp input is 0.05,the value of K allowed is
a)20
b)40
c)10
d)80
Show/hide solution

Friday, August 15, 2014

Mason's gain formula example

Control Systems is a fantastic subject and I wanted to write some topics regarding that. The first thing you notice in control system class is to find the gain of a "PRETTY BIG BLOCK" by using various reductions techniques. The steps involved will be :
1) Multiply the gain(G) of the blocks which are in series and add the gains(G) which are in parallel
2) Switch the take-off point to the right side of the block and blah-blah stuff. 

So, in order to avoid all these steps, one brilliant lad, invented a formula, which is named after him(We are accustomed to FORMULA, isn't it? ). That formula makes life easy for us who study control system. That formula is called, MASON'S GAIN FORMULA. Mason's gain formula applies only to LINEAR SYSTEMS.

If you don't know what Linear System is? Google has a quick ans : A general deterministic system can be described by operator, H, that maps an input, x(t), as a function of t to an output, y(t), a type of black box description. Linear systems satisfy the properties of superposition and scaling or homogeneity.


Mason's gain formula Example.

I have solved  a Signal Flow graph using Mason's gain formula. The explanation would be suffice I guess. Kindly go through the snapshots and revert back for any doubts.
Tip:Zoom the pic for better clarity

Mason gain formula example





Monday, August 11, 2014

The Walking man on a LCD using 8051 microcontroller. Trailer








This is a video on "The walking man on a LCD" which has been done using 8051 Microcontroller. We would like to know if anybody is interested in making this project. ? If yes, we will make a tutorial or two on  "How to make a walking man on 16*2 LCD using 8051 Microcontroller"? . 

Wednesday, July 23, 2014

How to print data on second line of 16*2 LCD using Microcontroller (8051)

Let us see how to print on the second line of 16*2 using  8051.

Prerequisite: Knowledge about lcdcmd() and lcddata() functions.

                                              Circuit diagram.



Here is the DDRAM address of 16*2 LCD



                                  For 16*2 LCD

                       ROW1 : 0x80 0x81 0x82 0x83 0x84 ...... 0x8F
                       ROW2 : 0XC0 0XC1 0XC2 0XC3 0xC4......0xCF

The Display data RAM is the set of addresses where the cursor moves. The data will be written on the position where cursor is. The cursor position(address) can be changed by sending various commands to LCD. For ex: lcdcmd(0x80+02) means Cursor points to 1st row, 3rd column.

Suppose the data is "welcome". On executing 0x82 command,the cursor points to the 1st row, 3rd column. If we start sending data to the LCD. 'w' will be printed on the third position. By default, the address will be incremented for new alphabet. Hence 'welcome' will occupy 03 to 09 address in the above figure.

To use second row, first column of the 16*2 LCD. We should point the cursor to that position. This can be done by using lcdcmd(0x80+0x40) .To use second row, second column(0x80+0x41) and so on. After pointing the cursor to that position. We can write the respective data using lcddata() function.

Using these basic commands, we can print the data on second line of 16*2 LCD.



Many animations can be done by playing with  the addresses of DDRAM. Here is a simple demonstration!

Here in the second row, we started printing values from (0x80+0x4D) address and decremented the initial address till the whole array is print. If anyone needs the code and simulation, please use the comment box :).