what is pigeon principal?Explainthe applications of pigeonhole principle with example?
401338
If m pigeons are put into m pigeonholes, there is an empty hole iff there's a hole with more than one pigeon.\n\nIf there are 6 people at a party, then either 3 of them knew each other before the party or 3 of them were complete strangers before the party.\n\nAlmost trivial....
1136350
Good Question, Mandelbrot's book and Barnsley's book will provide you with many examples.
267038
You might try reading Whitehead and Russell's Principia Mathematica.  I can't promise it will help, as I haven't read it, but I've been told that this issue is addressed.
195789
PigeonRank's success relies primarily on the superior trainability of the domestic pigeon (Columba livia) and its unique capacity to recognize objects regardless of spatial orientation. The common gray pigeon can easily distinguish among items displaying only the minutest differences, an ability that enables it to select relevant web sites from among thousands of similar pages.\n\nBy collecting flocks of pigeons in dense clusters, Google is able to process search queries at speeds superior to traditional search engines, which typically rely on birds of prey, brooding hens or slow-moving waterfowl to do their relevance rankings.\n\nWhen a search query is submitted to Google, it is routed to a data coop where monitors flash result pages at blazing speeds. When a relevant result is observed by one of the pigeons in the cluster, it strikes a rubber-coated steel bar with its beak, which assigns the page a PigeonRank value of one. For each peck, the PigeonRank increases. Those pages receiving the most pecks, are returned at the top of the user's results page with the other results displayed in pecking order.
939187
First, evaluate these functions to understand what they mean. Here is a listing of n and f(n)\n\n0 1 2 3 4 5 6 ...\n0 2 4 6 8 10 12 ...\n\nHere is a listing of n and g(n):\n\n0 1 2 3 4 5 6 ...\n0 0 1 1 2 2 3 ...\n\nEvaluate g • f using g • f (n) = g(f(n)) to get its listing:\n\n0 1 2 3 4 5 6 ...\n0 1 2 3 4 5 6 ...\n\nwhich provides evidence for question (a). g(f(n)) = g(2n) = n, because 2n is even.\n\nThe listing of f • g is\n\n0 1 2 3 4 5 6...\n0 0 2 2 4 4 3 ...\n\nAnalyze f(g(n)) = 2 [n/2]. What happens when n is even, and when n is odd?\n\nA function, F, is injective if different values never map to the same value. Or, the listing does not have duplicates. To prove that F is not injective is easy: just find a counterexample, that is a and b such that F(a) = F(b), but a ≠ b. To prove that F is injective you must show that in general if F(x) = F(y) then x = y. \n\nLook at the listings. If a listing has duplicates then the function is not injective. A proof is just providing a counterexample. Example: f • g has duplicates; the simplest are 0 and 1: f • g(0) = f • g(1), and 0 ≠ 1.The listing of f has no duplicates. To prove that f is injective, prove that if 2x = 2y then x = y. That should be easy!\n\nA function is surjective if the listing contains every number in the domain, that is all the numbers: 0, 1, 2, 3,...\n\nThe listing of f does not contain 1. So f is not surjective. A proof is to show that there is no n such that f(n) = 1. That's easy because f(n) is even!\n\nThe listing of g appears to contain all the numbers. Does it contain 2006? Can you find n such that g(n) = 2006? Such that n/2 = 2006? Yes, n = 4012. Similarly, for any number (instead of 2006).\n\nSo, I have provided some strategies and examples to let you now make your own proofs.
918264
IF you mean like an ordered pair it is a point on a graph.  An example is:  (x,y)  so you can have (3,5)  or (-7,-88)  Otherwise I'm not sure what you're talking about.
900433
Discounting rotations and mirror images, there is only one way to make a magic square using the digits 1 through 9.  \n\nFirst, we can prove the 5 has to go in the middle:\n\nLet the numbers in the top row from left to right be a, b, and c.  Let the numbers in the middle row from left to right be d, e, and f.  (Note e is the middle box.)  Let the numbers in the bottom row from left to right be g, h, and i.     \n\nWe know a + b + c = 15 and g + h + i = 15\n\nWe also know a + e + i = 15, b + e + h = 15, and c + e + g =15.  Therefore, (a + e + i) + (b + e + h) + (c + e + g) = 15 * 3 = 45.  We can rearrange this to (a + b + c) + (g + h + i) + 3e = 45.  Since a + b + c = 15 and g + h + i = 15, that reduces to 15 + 15 + 3e = 45, or 3e = 15.  Therefore e (the middle box) must equal 5.   \n\nKnowing the middle box is 5, try 9 in a corner and you'll notice a problem - the 6, 7 and 8 can't all be placed in the square without the row or column with the 9 exceeding 15.  So, the 9 has to occupy a side box.  Since we are discounting rotations and mirror images, we can arbitrarily select box b for the 9.  This forces the placement of the 1 in box h.   \n\nWith the 9 and 1 now placed, the 8 and 6 have to go in the row with the 1.  So, we'll put the 8 in box g and the 6 in box i.  (We still haven't done anything to create a second square if rotations and mirror images are discounted.)  That forces the placement of the final four numbers.
455504
I will explain a method that is the most easy on this planet, and a unique one.\n\nI will illustrate with the help of a simple example.\n\nEg. 4-2.\n\nDraw no. line as follows:\n\n<-6--5--4--3--2--1--0--1--2--3--4--5--6--7-->\n\nNumbers left to zero are negative integers\nand to the right are the positive ones.\n\nLocate 4 on this line. Now move 2 steps behind 4 as the operation to be carried out is subtraction.\n\nThis will give answer as 2. \n\nSimilarly for addition move the steps ahead.
471450
weezy is on the right track, that glow1989 is on the right track.  For everyone who thinks that writing 1+1=2 is so obvious that it constitutes a self-contained proof of itself(!)... if you undertake a serious study of mathematical proof, you might find that 357 pages is a good length for a quick introduction to the ideas that are involved in considering questions in this area.  Of course, I am talking about actually UNDERSTANDING something - very different to simply passing an exam, regardless of the 'level' of maths you are enrolled in.\n\nYes, as you mentioned, this is a hard question.  'Proving' that 1+1=2 is not as simple as it sounds, because of the inherent question of what we mean by 'prove'.  You might have noticed that some proofs you have used depend on other proofs, which in turn depend on other proofs, ... which ultimately rest on a handful of axioms.  It is the nature of operations that are allowed by any axiomatic system, that determine the characteristics of mathematical problems that can be said to be SOLVABLE.  It is no small task to understand the axioms that underlie our systems of mathematics.  For example, maths students learn: that division by zero is undefined; that any object raised to a null power is equal to unity; some differences between rational and irrational numbers; what we mean when we consider objects to exist in 'sets'; and so on.  Those who consider themselves to be excellent students are usually able to list these rules in rapid-fire style.  But if we are asked to 'prove' why those rules are the way they are, the questions start to seem fuzzy, and you typically run out of convenient formulas to rely on.  You could easily write 357 pages just to explain what you actually MEAN by the numbers 1 or 2, without worrying about the definition of the addition operation!  As usual, people might do better to stop and consider what the question is asking before booting in a smug answer.\n\nLook into Hilbert's Problem (David Hilbert - German mathematician), which was a more workable and compact form of a proposal by Russell and Whitehead to formalise mathematics on a general basis, according to well-established axioms and procedures.\n\nOther notable mathematicians to work in this area were Alan Turing, Alonzo Church (look for Church's Lambda Calculus), Emil Post, and the brilliant Kurt Gödel.  In more recent decades, look for Gandy (1988) and of course many others.\n\nLol, molawby is spot-on.  I wish he'd posted b4 me... would've saved me a bit of typing.  If all you need to do is learn to sing the right song, to pass your exams and get the job that stipulates that you need to have completed such-and-such a course, then you don't have to worry about any of this.  Of course, that doesn't mean you have to dismiss it either.  But if you are chasing a deeper understanding, it probably does take the 20 yrs, and you won't necessarily get paid for it, heheheh.\n\nFor bedside reading, I suggest Roger Penrose etc...
55122
Better way is to creat an instance of Random class.\nIt has methods, nextInteger(), nextdouble(), and others.
270029
There are of course good ways and bad ways of doing this.  The best way involves using a search tree like DFS and then pruning.  Instead of showing you something this complex (since I am unsure of your level of understanding) I will show you a common simple algorithm.  I will leave the code up to you, here is the psuedo-code:\n\n----------------------------------------------------\nALGORITHM JohnsonTrotter(n)\n//input: positive integer n\n//output: a list of all permutations of (1...n)\n\ninitialize the first permutation with (1,2...n) and with a second correspoing list ('L','L',...,'L').\n\n//Definition: mobile integer = if the corresponding letter is L \n//and the left adjacent number is smaller or vise versa.\n \nwhile there exists a mobile integer k do\n     find the largest integer K\n     swap K and the adjacent integer (left one if L) right otherwise\n     reverse the direction of all integers that are larger than k\nend do while\n----------------------------------------------------\nthis is really a simple algorithm to follow and to code, I am working off memmory here so it may not be the exact terms used but the algorithm is 100% I assure you.  Hope this helps and have fun.
593080
*** pseudocode ****\n\n\n$max = $array[0];\n$min = $array[0];\n\nfor( $x=1; $x <= $size_of_array; $x++ )\n {\n     if($array[$x] < $min)\n       {\n          $min = $array[$x];\n       }\n\n     if($array[$x] > $max)\n       {\n          $max = $array[$x];\n       }\n\n}\n\n\n\n\nhave fun\n\n\nt
174124
This geometric trick is very involving:\nYou can use it as a starting point for geometric construction of square roots, equivalence of areas and isometric transforms\nhttp://answers.yahoo.com/question/?qid=1006030501625\n\nThis other about divisibility and prime factoring of integers has deep mathematical concepts beyond it: starting from it you can speak about prime factoring, bynary count, combinatory calculus and mathematical induction\nhttp://answers.yahoo.com/question/?qid=1006022300298&r=w\n\nI'm going to use them in my school classes
1155862
to many to post.....they are all on this site \n\nhttp://www.geom.uiuc.edu/docs/reference/CRC-formulas/
947782
If A is a subset of C and A has the same cardinality as C, then the sets A and C are the same.\n\nI guess as a proof, you could assume that there is an element in C that is not in A...in which case the cardinality of C would be greater than the cardinality of A, which is a contradiction.\n\nThen B gets trapped in the middle.  A = B = C.
1170415
(she never SAID it was math)\n\nAt the 'end' of each example, the values in your variables 'a' and 'b'...\n\nEx 1: a = 2, b = 2\nEx 2: a = 3, b = 3\nEx 3: a = 2, b = 3\n\nYour examples 2 & 3 use pre and postincrementation, which is common not only in Java but most programming languages.\n\nExample 2 uses a 'preincrement' operator, so 'b' is incremented to 3 before its value is assigned to 'a'.\nExample 3 uses 'postincrement', so the original value of 'b' (2) is assigned to 'a' before 'b' is incremented to 3.
1047890
class C\n{\npublic:\nenum { NUM_VALUES = 10 };\n\nprivate:\ndouble m_values[NUM_VALUES];\n\npublic:\n// Sets the number stored at index i in m_values to v\nvoid SetValue(int i, double v) throw( std::exception )\n{\nif ( i < 0 || i >= NUM_VALUES ) throw std::exception("Index out of range");\nm_values[i] = v;\n}\n\n// Gets the number stored at index i in m_values\ndouble GetValue(int i) const throw( std::exception )\n{\nif ( i < 0 || i >= NUM_VALUES ) throw std::exception("Index out of range");\nreturn m_values[i];\n}\n\n    // Returns the mean of the numbers stored in m_values\n    double GetMean(void) const \n    {\n        double sum = 0;\n        for ( int i = 0; i < NUM_VALUES; i ++ ) sum += m_values[i];\n        return sum / NUM_VALUES;\n    }\n\n    // Returns the sample standard deviation of the numbers stored in m_values\n    double GetStandardDeviation(void) const \n    {\n        double mean = GetMean();\n        double sum = 0;\n        for ( int i = 0; i < NUM_VALUES; i ++ ) sum += (m_values[i]-mean)*(m_values[i]-mean);\n        return sqrt(sum/(NUM_VALUES-1));\n    }\n};