Love at first sight

I believe love at first sight when i first saw my mother....

Friday, December 23, 2011

Algebraic Formulas

The following formulas will be very useful for the beginners of Algebra as well as those preparing for competitive exams.
  • (a+b)2 = a2 + 2ab + b2

  • (a-b)2 = a2 - 2ab + b2

  • (a+b)3 = a3 + 3ab(a+b) + b3

  • (a-b)3 = a3 - 3ab(a-b) + b3

  • a2-b2 = (a+b)(a-b)

  • a3+b3 = (a+b)(a2-ab+b2)

  • a3-b3 = (a-b)(a2+ab+b2)

  • a4-b4 = (a-b)(a+b)(a2+b2)

  • (a+b)2+(a-b)2 = 2(a2+b2)

  • (a+b)2-(a-b)2 = 4ab
The Algebraic Formulas once learned can be effectively used for solving problems

Saturday, December 10, 2011

RISC

What is RISC

In the mid 1970's advances in semiconductor technology began to reduce the difference in speed between main memory and processor chips.As memory speed increased,and high level languages replaced assembly language,the major reasons for CISC began to disappear,and computer designers began to look at ways computer performance could be optimized beyond just making faster hardware.One of their key realizations was that a sequence of simple instructions produces the same results as a sequence of complex instructions,but can be implemented with a simpler and faster hardware design.Reduced instruction set computer(RISC) is the result.

Characteristics of RISC

  • Simple Instruction Set:In RISC machine,the instruction set contains simple basic instructions,from which more complex instructions can be composed
  • Same length instructions:Each instruction is the same length so that it may be fetched in a single operation.
  • 1 machine-cycle instructions

CISC

Emergence of CISC

CISC,which stands for Complex Instruction Set Computer is a philosophy for designing chips that are easy to program and makes efficient use of memory.Each instruction in CISC instruction set might perform a series of operations inside the processor.This reduces the number of instructions required to implement a given program,and allows the programmer to learn a small but flexible set of instructions

Advantages of CISC

As the time of their initial development,CISC machines used the available technologies to optimize computer performance.

  • Microprogramming is as easy as assembly language to implement,and much less expensive than hardwiring a control unit
  • The ease of microcoding new instructions allowed the designers to make CISC machines upwardly compatible-a new computer could run the same programs as earlier computers because the new computer would contain a superset of instructions of the earlier programming
  • As each instruction became more capable,fewer instructions could be used to implement a given task.This made more efficient use of the relatively slow main menory.
  • Because microprogram instruction sets can be written to match the constructs of high level programming languages,the compiler does not have to be as complicated.

Disadvantages of CISC

  • Earlier generations of a processor family were generally contained as a subset in every new versions.So instruction set and chip hardware become more complex with each generation of computers
  • So that as many instructions as possible could be stored in memory with the least possible wasted space,individual instructions could be of almost any length.This means that different instructions will take different amounts of clock time to execute,slowing down the overall performance of the machine
  • Many specialized instructions aren't used frequently enough to justify their existence-approximately only 20% of the available instructions are used in a typical program
  • CISC instructions typically set the condition codes as a side effect of the instruction.Not only does setting the condition codes take time,but programmers have to remember to examine the condition code bits before a subsequent instructions changes them

Worst passwords

Worst Passwords


Passwords are creating a great buzz today.We want our passwords to be easily remembered and at the same time it should not be hacked.Some people use passwords that are well known and commonly used.

Passwords are highly important in terms of financial transactions.It is always safe to avoid the passwords that are termed as Worst passwords in the computer world

Here is a list of worst passwords.Read carefully and avoid using them

  • password
  • 12345678
  • 123456
  • qwerty
  • abc123
  • monkey
  • 1234567
  • letmein
  • trustno1
  • dragon
  • baseball
  • 111111
  • iloveyou
  • master
  • sunshine
  • ashley
  • bailey
  • passw0rd
  • shadow
  • 123123
  • 654321
  • superman
  • qazwsx
  • michael
  • football

Now i hope your passwords will not fall into the above category and it is too strong to hack.

Graphs in google search

Graphs for Mathematical functions in google search

A new feature is launched by Google for Maths lovers and learners. It is displaying graphical images directly in search pages when mathematical functions are given in Google search box.

Now there is no need to browse for softwares or download and install programs to get graphs for the Mathematical functions

Now let us see how cos(x) is displayed in google search results

cos(x)
Thus Graphs for mathematical functions is made easy.

Wednesday, August 10, 2011

Venn diagrams

Venn diagrams introduced by John venn represents relationship between finite collection of sets.
Consider two sets A,B.
In venn diagrams they are represented as

Logic and Venn diagrams
AUB

A∩B
(AUB)'

(A∩B)'

A'UB

A'∩B

Example
A group of 40 students were surveyed about the languages they have chosen E = English, H = Hindi, T = Tamil.
3 students did not study any of the languages above.
2 students study all three languages
8 study English and Hindi
10 study English and Tamil
6 study Hindi and Tamil
13 students study Hindi
28 students study English
(a) Draw a Venn diagram to illustrate the data given above
(b) How many students study only Tamil?
(c) On your diagram represent the students who do not study English or Hindi.

Solution
A
• There are 3 sets within a universal set.Draw a Venn diagram with 3 intersecting sets.
• The 3 students who do not study any language go inside the box, but outside of the circles.
• 2 students must go in the intersection of all three circles.
• 8 must go in the intersection of E and H, but remember that 2 have already been filled in the intersection of all 3 sets. So only 6 will be put in the intersection.
• Likewise the English and Tamil intersection will have 10 – 2 = 8 and only 4 will go in the Hindi and Tamil intersection.
• In the Hindi set there should be 13, but thus far we have filled in 6+2+4 = 12. So only 1 student is left to go in the Hindi only set.
• Likewise 28 students study English, but we have filled in 16 of these students, so 12 go in the English only section.
• There are 40 students altogether . Counting all the numbers filled in thus far reveals we have put 36 numbers on the diagram. It is important to remember the 3 outside the circles, but in the box. Fill in 4 in the Tamil only section.
• Finally the diagram will be like this,

B
Students reading only Tamil is 4
C

PHP arrays

List of array functions

1.count()
2.sizeof()
2.array_slice()