text
stringlengths
8
1.28M
token_count
int64
3
432k
Electrodynamics. This book is going to cover the topic of electrodynamics using vector calculus. We will provide a brief refresher to the topics of vector calculus, but this book does not intend to teach that topic to students who do not have any background in it. For more information about calculus and vector calculus topics, see Calculus and Linear Algebra. Because this book is part of a series of books on Modern Physics, the reader is assumed to have a background in relativity theory, or to be able to concurrently read the Special Relativity book. This book is going to discuss the electric and magnetic fields and forces, and related subjects. It is intended to be read by advanced undergraduates in the field of physics or engineering. This book is new and needs a lot of work. This is a wiki, so "you" can contribute.
187
Chinese (Mandarin)/Numbers. Number System (數字系統). 基本用字. The parenthesized entries are the complex and formal forms, which are used mainly in notarized, official documents, and when writing checks. An exception is zero; the complex form is much more widely used than a casual circle. The complex forms are known in English as banker's anti-fraud numerals, in Chinese as 大寫 (simplified Chinese: 大写; Hanyu Pinyin: "dàxiě;" which is the same term for "capital letter"). They are necessary because, since normal Chinese characters are so simple, a forger could easily change 三十 to 五千 with just three strokes. See Standard numbers for more information. Some Chinese characters used as complex and formal numerals have other uses as well, possible as heteronyms. For example: 個十百千萬 Larger Numbers. 等(děng) etc. 等 etc. 等 etc. 等 etc. 等 etc. 更大的數字(億兆) Even Larger Numbers. 等 etc. 中文中零的用法 The Use of Zero in Chinese. If a number ends in zero, there is no need to include the Chinese character for zero. For example, However, if the zero character does not end the number (i.e., it is followed by a non-zero character), it is necessary to include the zero character, while the "tens-place" characters are dropped. For example, Note that the "十" in the first example and the "百" in the second example are dropped. If a zero digit is followed by one or more zero digits, only one zero character is need. For example, 數字手勢 Chinese Gestures for Numbers. Note:hand signs are the same as Western hand signs. Except for six, hold out your thumb and pinky. For seven, make a "peacock head" by putting all of your fingers on your thumb. For eight, hold your thumb and second finger facing up. For nine, make your second finger look like a hook and then hold it out facing up. Source:
493
Scouting/BSA/Insect Study Merit Badge. Requirement 2. Insects Centipedes Spiders Requirement 4. Describe the characteristics that distinguish the principal families and orders of insects. Requirement 5. a.Observe 20 different live species of insects in their habitat. In your observations, include at least four orders of insects. b.Make a scrapbook of the 20 insects you observe in 5a. Include photographs, sketches, illustrations, and articles. Label each insect with its common and scientific names, where possible. Share your scrapbook with your merit badge counselor.
152
Probability/Probability Spaces. Terminologies. The name of this chapter, , is a mathematical construct that models a random experiment. To be more precise: Let us first give the definitions related to sample space. For the definitions of event space and probability, we will discuss it in later sections. Probability interpretations. In this chapter, we will discuss probability mathematically, and we will give an axiomatic and abstract definition to probability (function). By axiomatic definition, we mean defining probability to be a function that satisfying some axioms, called probability axioms. But such axiomatic definition does not tell us how should we interpret the term "probability", so the definition is said to be from the interpretation of probability. Such independence make the formal definition always applicable, no matter how you interpret probability. However, the axiomatic definition does not suggest a way to construct a probability measure (i.e., assigning probabilities to events): it just states that probability is a function satisfying certain axioms, but how can we construct such function in the first place? In this section, we will discuss two main types of probability interpretations: subjectivism and frequentism, where the method of assigning probabilities to events is mentioned in each of them. Subjectivism. Intuitively and naturally, of an event is often regarded as a numerical measure of the "chance" of the occurrence of the event (that is, how likely the event will occur). So, it is natural for us to assign probability to an event based on our own assessment on the "chance". (In order for the probability to be valid according to the axiomatic definition, the assignment needs to satisfy the .) But different people may have different assessment on the "chance", depending on their personal opinions. So, we can see that such interpretation of probability is somewhat , since different people may assign different probabilities to the same event. Hence, we call such probability interpretation as (also known as ). The main issue of the subjectivism is the lack of objectivity, since different probabilities can be assigned to the same event based on personal opinion. Then, we may have difficulties in choosing which of the probabilities should be used for that event. To mitigate the issue of the lack of objectivity, we may adjust our degrees of belief on an event from time to time when there are more observed data through , which will be discussed in later chapter, so that the value is assigned in a more objective way. However, even after the adjustment, the assignment of value is still not in an objective way, since the adjusted value (known as ) still depends on the initial value (known as ), which is assigned subjectively. Frequentism. Another probability interpretation, which is objective, is called . We denote by formula_1 the number of occurrences of an event formula_2 in formula_3 repetitions of experiment. Then, we call formula_4 as the of the event formula_2. Intuitively, we will that the relative frequency fluctuates less and less as formula_3 gets larger and larger, and approach to a constant limiting value (we call this as ) as formula_3 tends to infinity, i.e., the limiting relative frequency is formula_8. It is thus natural to take the limiting relative frequency as the probability of the event formula_2. This is exactly what the definition of probability in the frequentism. In particular, the of such limiting relative frequency is an assumption or in frequentism. However, an issue of frequentism is that it may be infeasible to conduct experiments many times for some events. Hence, for those events, no probability can be assigned to them, and this is clearly a limitation for frequentism. Because of these issues, we will instead use a modern axiomatic and abstract approach to define probability, which is suggested by a Russian mathematician named Andrey Nikolaevich Kolmogorov in 1933. By , we mean defining probability quite broadly and abstractly as something that satisfy certain axioms (called ). Such probability axioms are the mathematical foundation and the basis of modern probability theory. Probability axioms. Since we want use the probability measure formula_13 to assign probability formula_14 to every event formula_2 in the sample space, it seems natural for us to set of the probability measure formula_13 to be the set containing subsets of formula_17, i.e., the power set of formula_17, formula_19. Unfortunately, this situation is not that simple, and there are some technical difficulties if we set the domain like this, when the sample space formula_17 is . This is because the power set of such uncountable sample space includes some "badly behaved" sets, which causes problems when assigning probabilities to them. (Here, we will not discuss those sets and these technical difficulties in details.) Thus, instead of setting the domain of the probability measure to be formula_19, we set the domain to be a (sigma-algebra) containing some "sufficiently well-behaved" events: We have seen two examples of formula_22-algebra in the example above. Often, the "smallest" formula_22-algebra is not chosen to be the domain of the probability measure, since we usually are interested in events formula_24 and formula_17. For the "largest" formula_22-algebra, on the other hand, it contains every event, but we may not be interested in some of them. Particularly, we are usually interested in events that are "well-behaved", instead of those "badly behaved" events (indeed, it may be even impossible to assign probabilities to them properly (those events are called )). Fortunately, when the sample space formula_17 is , every set in formula_19 is "well-behaved", so we can take this power set to be a formula_22-algebra for the domain of probability measure. However, when the sample space formula_17 is , even if the power set formula_19 is a formula_22-algebra, it contains "too many" events, particularly, it even includes some "badly behaved" events. Therefore, we will not choose such power set to the domain of the probability measure. Instead, we just choose a formula_22-algebra that includes the "well-behaved" events to be the domain, so that we are able to assign probability properly to every event in the formula_22-algebra of the domain. Particularly, those "well-behaved" events are often the events of interest, so all events of interest are contained in that formula_22-algebra, that is, the domain of the probability measure. To motivate the probability axioms, we consider some properties that the "probability" in frequentism (as a limiting relative frequency) possess: formula_46 It is thus very natural to set the probability axioms to be the three properties mentioned above: Using the probability axioms alone, we can prove many well-known properties of probability. Basic properties of probability. Let us start the discussion with some simple properties of probability. Using this result, we can obtain from the countable additivity of probability: Finite additivity makes the proofs of some of the following results simpler. Thus, we have the desired result. Property 2: By property 1, we have formula_48. We then have the desired numeric bound on formula_49 since formula_50 also by the nonnegativity of probability. Property 3: formula_51 Property 4: By property 3, we have formula_52 Property 5: Assume that formula_53. Then, formula_54. Hence, by property 3, formula_55 Constructing a probability measure. As we have said, the axiomatic definition does not suggest us a way to construct a probability measure. Actually, even for the same experiment, there can be many ways to construct a probability measure that satisfies the above probability axioms if there are not sufficient information provided: Also, by the numeric bound of probability, the two probabilities assigned has to be between zero and one. So, without further information, we can set formula_56 where formula_57 (and thus formula_58). Hence, we can see that there are infinitely many ways to construct a probability measure for this random experiment! However, we have previously mentioned that we may assign probabilities to events subjectively (as in subjectivism), or according to its limiting relative frequency (as in frequentism). Through these two probability interpretations, we may provide some background information for a random experiment, by assigning probabilities to some of the events before constructing the probability measure, to the extent that there is way to construct a probability measure. Consider the coin tossing example again: In general, it is not necessary to assign probability to event in the event space in the background information for us to able to construct the probability measure in exactly one way. Consider the following example. We can see from this example that to provide sufficient background information to the extent that the probability measure can be constructed in exactly one way, we just need the probability of each of the singleton events (which should be nonnegative and sum to one to satisfy the probability axioms). After that, we can calculate the probability for each of the other events in the event space, and hence construct the only possible probability measure. This is true when the sample space is countable, in general: The following is an important special case for the above theorem. _.</math> \times \underbrace{6}_{\text{blue}}=36</math>. Since the outcomes should be equally likely, the desired probability is formula_59 (there is only one sample point for this event). assuming that the outcomes in the sample space are equally likely. \times\underbrace{\binom 43}_{\text{green}}\times \underbrace{2}_{\text{blue}}=24</math> sample points. It follows that the probability is formula_60. \times \underbrace{5}_{\text{blue/orange}}=60</math> sample points. Thus, the probability is formula_61. \times \underbrace{6}_{\text{Bob's roll}}=36</math> outcomes in total. There are 6 outcomes where Amy and Bob draw (both get 1,2,3,4,5, or 6). It follows that the probability is formula_62. (b) To calculate the probability, clearly one can count the number of outcomes where Amy wins. But here we offer an alternative and more convenient approach, which makes use the of the game. Notice that the situation for Amy and Bob is basically the same in the game (for each of them, there is another player doing the same thing as him/her, and the winning conditions are the same). So, the game is kind of . Thus, by the natural symmetry of the game, the probability that Amy wins and the probability that Bob wins are equal. But we can notice that the events that Amy wins, Bob wins, and they draw are disjoint. Also, their union is the whole sample space. It follows that the sum of their probabilities is 1. Hence, letting formula_63 be the probability that Amy wins, we have formula_64 (b) The probability is formula_65. (c) The probability is formula_66. More advanced properties of probability. Recall the in combinatorics. We have similar results for probability: ^{}\mathbb P(E_{i_1}\cap E_{i_2}\cap E_{i_3}\cap\dotsb\cap E_{i_{k-1}}\cap E_{k+1})}\\ &\quad{\color{blue}+(-1)^{k+2}\sum_{i_1<i_2<\dotsb<i_k}^{}\mathbb P(E_{i_1}\cap E_{i_2}\cap \dotsb\cap E_{i_k}\cap E_{k+1})}\quad(\text{using inductive hypothesis twice}) -\dotsb{+\color{deeppink}(-1)^{k+1}\sum_{i_1<i_2<\dotsb<i_k}^{}\mathbb P(E_{i_1}\cap E_{i_2}\cap \dotsb\cap E_{i_k})}\\ &\quad{\color{purple}+\mathbb P(E_{k+1})}{\color{brown}-\sum_{i_1}^{}\mathbb P(E_{i_1}\cap E_{k+1})}{\color{darkgreen}+\sum_{i_1<i_2}^{}\mathbb P(E_{i_1}\cap E_{i_2}\cap E_{k+1})}-\dotsb +{\color{deeppink}(-1)^{k+1}\sum_{i_1<i_2<\dotsb<i_{k-1}}^{}\mathbb P(E_{i_1}\cap E_{i_2}\cap E_{i_3}\cap\dotsb\cap E_{i_{k-1}}\cap E_{k+1})}\\ \quad(\text{just changing colors})\\ -\dotsb+{\color{deeppink}(-1)^{k+1}\sum_{i_1<i_2<\dotsb<i_k}^{}\mathbb P(E_{i_1}\cap E_{i_2}\cap\dotsb\cap E_{i_k})}\\ &\quad{\color{blue}+(-1)^{k+2}\sum_{i_1<i_2<\dotsb<i_k<i_{k+1}}^{}\mathbb P(E_{i_1}\cap E_{i_2}\cap \dotsb\cap E_{i_k}\cap E_{i_{k+1}})}\quad(\text{sum is wrt }k+1\text{ case, which involves }E_1,E_2,\dotsc,E_{k+1})\\ </math> So, formula_67 is true. Hence, by the principle of mathematical induction, formula_68 is true for every positive integer formula_3. =0.25</math>. (b) From Venn digram, the probability is formula_70. The following is a classical example for demonstrating the application of inclusion-exclusion principle. -\dotsb +(-1)^{n+1}\frac{\cancel{n!}}{n!\cancel{(n-n)!}}\cdot\frac{\cancel{(n-n)!}}{\cancel{n!}}\\ &=\frac{1}{1!}-\frac{1}{2!}+\frac{1}{3!}-\dotsb+(-1)^{n+1}\frac{1}{n!}. </math> It follows that the desired probability is formula_71 (b) Notice that "exactly formula_72 letters are placed into the correct envelopes" is equivalent to "(at least) formula_72 letters are placed into the correct envelopes none of the other formula_74 letters are placed into the correct envelopes". Thus, to get the probability, it suffices to calculate the number of sample points in the latter event, and it by the number of sample points in the sample space (which is formula_75 by (a)). We can get the number of sample points in the latter event by considering it as a three-step process: It follows that the number of sample points in the event is formula_84 Hence, the desired probability is formula_85
3,671
Russian/Prepositions. Prepositions are small words that precede a phrase and connect it to the rest of the sentence. Example of prepositions in English include 'He went in the shop', 'She spoke about him, 'They went by the shops', etc. Russian prepositions work just like their English counterparts, with one important difference: they all place the next phrase in one of the six grammatical cases. As such, a good understanding of the Russian case system is needed to use prepositions. Some cases are used primarily or even entirely with prepositions, while others are used more in their main function than with prepositions- this page assumes familiarity of Russian cases and pronunciation. Prepositions with 2 cases. Like in German, some prepositions can have 2 cases. The accusative (again, like in German) and the genitive cases are used to express movement: accusative pertains to destination, while genitive indicates the source of movement. The instrumental and the Prepositional are used to express staticness. Examples. Nominative: Accusative: Genitive: Dative: Instrumental: Prepositional: Note: using the preposition "в/во" when saying you're in a place, or going to a place, works in the majority of cases; however, some places require you to use "на" instead of "в/во". For example: but: Similarly: but: And more. There is a limited number of those, but the use of "на" over that of "в/во" is mandatory in these cases.
357
Russian/Personal Pronouns. The personal pronouns in Russian are arguably the easiest to learn. As they do not modify nouns (unlike their possessive counterparts), they conjugate only by case. They are: There are two important nuances to these pronouns. First, notice that the masculine and neuter third-person singular pronouns are the same in all cases but the nominative, and in the genitive and accusative are pronounced '"ye-vo"', not '"ye-go"'. Second, if the pronoun's case is called by a preposition, third-person pronouns gain the prefix н- (e.g., compare 'his' in 'It's his house', Это его дом, and 'He has a house', У него есть дом).
181
Russian/Interrogative Pronouns. Like all pronouns, the interrogative pronouns are words that replace nouns in a sentence. Interrogative pronouns are those that ask questions, or "interrogate". Compare "Peter is doing it" with "Who is doing it" - replacing the noun with an interrogative pronoun turns it into a question, though the rest of the sentence is left intact. Like the nouns they replace, interrogative pronouns must conjugate to suit the appropriate grammatical case. While some words discussed here are used more as adverbs than pronouns, they are still pronouns and are included here for the sake of completeness. The pronouns. The twelve interrogative pronouns are as follows: Russian pronoun quiz. Russian/Pronouns/Quiz There are a few nuances to how you conjugate these pronouns, before we discuss how to use them. Какой, который, чей. You may notice that какой ('what kind'), который ('what/which'), and чей ('whose'), are adjectives. They are therefore called "adjectival" pronouns. As such, when they are used in a sentence, they take on the ending appropriate for the gender and number of the noun it refers to, and the case appropriate for where it is in the sentence. This can mean that it takes on a different case to its noun. Чей is an irregular adjective with unpredictable endings, and conjugates as follows: Кто, что, сколько. In contrast to the three adjectival pronouns, there are three nominal pronouns, so called because they more closely resemble nouns. These pronouns do not conjugate by gender and number like their adjectival counterparts, but still change according to case: If you are familiar with the case system, you may notice that these endings are roughly similar to the adjectival endings, with a few alterations. As ever, кого is pronounced 'ko-vo', not 'ko-go', and similarly for чего. The remaining six pronouns are indeclinable and do not conjugate. Asking questions. Кто? Что? To ask a question, use the pronoun as the subject of the verb. If you need to give it a gender, such as when forming the past tense, treat кто as a masculine singular noun (e.g., "Who was working? Кто работал?), что as a neuter singular noun (e.g., "What was rolling?" Что катилось?), and сколько as a plural noun (e.g., "How many people are walking?" Сколько человек идут? ). These can also be used as conjunctions (i.e., words that join sentences together), and are sometimes translated differently than when used as interrogative pronouns: Как? Когда? Почему? Как ('how'), когда ('when'), and почему ('why'), don't conjugate, and are used just like in English: There are a number of common colloquialisms that are standard beginner's phrases: Сколько? Какой? Чей? This pronoun simply means 'how much' or 'how many': Like other quantity words, it also commands the genitive case. It often calls the plural form of a noun: The two adjectival pronouns, какой and чей, are also simple in use. Какой asks what category something belongs to, or which item of a set, while чей asks for the owner of something: /Сколько Какой Чей quiz/ Где? Куда? Откуда? The penultimate set of pronouns relate to motion and location. The English 'Where?' can translate in two ways: 'Where are you?' and 'Where are you going?'. Где? asks the first, locative question, while куда asks the second, directional question. To ask specifically where someone has come "from", use откуда. Который? The primary meaning is simply 'which one?', though который is also used to ask about one particular thing in a sequence of similar things. It can also be used as an adjective meaning 'who' or 'whom':
978
XML - Managing Data Exchange/The one-to-one relationship. Introduction. In the previous chapter, some new features of XML schemas, documents, and stylesheets were introduced as well as how to model a one-to-many relationship. In this chapter, we will introduce the modeling of a one-to-one relationship in XML. We will also introduce more features of an XML schema. A one-to-one (1:1) relationship. The following diagram shows a one-to-one and a one-to-many relationship. The one-to-one relationship records each country as a single top destination. Exhibit 4-1: Data model for a 1:1 relationship XML schema. A one-to-one (1:1) relationship is represented in the data model in Exhibit 4-1. The addition of country and destination to the data model allows the 1:1 relationship named topDestination. A country has many different destinations, but only one top destination. The XML schema in Exhibit 4-2 shows how to represent a 1:1 relationship in an XML schema. XML schema example. <?xml version="1.0" encoding="UTF-8"?> <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" elementFormDefault="unqualified"> Tour Guide <xsd:element name="tourGuide"> <xsd:complexType> <xsd:sequence> <xsd:element name="country" type="countryDetails" minOccurs="1" maxOccurs="unbounded" /> </xsd:sequence> </xsd:complexType> </xsd:element> Country <xsd:complexType name="countryDetails"> <xsd:sequence> <xsd:element name="countryName" type="xsd:string" minOccurs="1" maxOccurs="1"/> <xsd:element name="population" type="xsd:integer" minOccurs="0" maxOccurs="1" default="0"/> <xsd:element name="continent" minOccurs="0" maxOccurs="1"> <xsd:simpleType> <xsd:restriction base="xsd:string"> <xsd:enumeration value="Asia"/> <xsd:enumeration value="Africa"/> <xsd:enumeration value="Australasia"/> <xsd:enumeration value="Europe"/> <xsd:enumeration value="North America"/> <xsd:enumeration value="South America"/> <xsd:enumeration value="Antarctica"/> </xsd:restriction> </xsd:simpleType> </xsd:element> <xsd:element name="topDestination" type="destinationDetails" minOccurs="0" maxOccurs="1"/> <xsd:element name="destination" type="destinationDetails" minOccurs="0" maxOccurs="unbounded"/> </xsd:sequence> </xsd:complexType> Destination <xsd:complexType name="destinationDetails"> <xsd:all> <xsd:element name="destinationName" type="xsd:string"/> <xsd:element name="description" type="xsd:string"/> <xsd:element name="streetAddress" type="xsd:string" minOccurs="0"/> <xsd:element name="telephoneNumber" type="xsd:string" minOccurs="0"/> <xsd:element name="websiteURL" type="xsd:anyURI" minOccurs="0"/> </xsd:all> </xsd:complexType> </xsd:schema> <br> New elements in schema. <br> Let’s examine the new elements and attributes in the schema in Exhibit 4-2. Restrictions in schema. <br> Placing restrictions on elements was introduced in the previous chapter; however, there are more potentially useful restrictions that can be placed on an element. Restrictions can be placed on elements and attributes that affect how the processor handles whitespace characters: <xsd:element name="streetAddress"> <xsd:simpleType> <xsd:restriction base="xsd:string"> <xsd:whiteSpace value="preserve"/> </xsd:restriction> </xsd:simpleType> </xsd:element> White space & length constraints. The whiteSpace constraint is set to "preserve", which means that the XML processor will not remove any white space characters. Other useful restrictions include the following: Order indicators. In addition to placing restrictions on elements, order indicators can be used to define in what order elements should occur. All indicator. The <all> indicator specifies by default that the child elements can appear in any order and that each child element must occur once and only once: <xsd:element name="person"> <xsd:complexType> <xsd:all> <xsd:element name="firstname" type="xsd:string"/> <xsd:element name="lastname" type="xsd:string"/> </xsd:all> </xsd:complexType> </xsd:element> Choice indicator. The <choice> indicator specifies that either one child element or another can occur: <xsd:element name="person"> <xsd:complexType> <xsd:choice> <xsd:element name="employee" type="employee"/> <xsd:element name="visitor" type="visitor"/> </xsd:choice> </xsd:complexType> </xsd:element> Sequence indicator. The <sequence> indicator specifies that the child elements must appear in a specific order: <xsd:element name="person"> <xsd:complexType> <xsd:sequence> <xsd:element name="firstname" type="xsd:string"/> <xsd:element name="lastname" type="xsd:string"/> </xsd:sequence> </xsd:complexType> </xsd:element> XML document. <br> The XML document in Exhibit 4-3 shows how the new elements (country and destination) defined in the XML schema found in Exhibit 4-2 are used in an XML document. Note that the child elements of <topDestination> can appear in any order because of the <xsd:all> order indicator used in the schema. <?xml version="1.0" encoding="UTF-8"?> <?xml-stylesheet type="text/xsl" href="newXMLSchema.xsl" media="screen"?> <tourGuide xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="XMLSchema.xsd"> Malaysia <country> <countryName>Malaysia</countryName> <population>22229040</population> <continent>Asia</continent> <topDestination> <description>A popular duty-free island north of Penang.</description> <destinationName>Pulau Langkawi</destinationName> </topDestination> <destination> <destinationName>Muzium Di-Raja</destinationName> <description>The original palace of the Sultan</description> <streetAddress>122 Muzium Road</streetAddress> <telephoneNumber>48494030</telephoneNumber> <websiteURL>www.muziumdiraja.com</websiteURL> </destination> <destination> <destinationName>Kinabalu National Park</destinationName> <description>A national park</description> <streetAddress>54 Ocean View Drive</streetAddress> <telephoneNumber>4847101</telephoneNumber> <websiteURL>www.kinabalu.com</websiteURL> </destination> </country> Belize <country> <countryName>Belize</countryName> <population>249183</population> <continent>South America</continent> <topDestination> <destinationName>San Pedro</destinationName> <description>San Pedro is an island off the coast of Belize</description> </topDestination> <destination> <destinationName>Belize City</destinationName> <description>Belize City is the former capital of Belize</description> <websiteURL>www.belizecity.com</websiteURL> </destination> <destination> <destinationName>Xunantunich</destinationName> <description>Mayan ruins</description> <streetAddress>4 High Street</streetAddress> <telephoneNumber>011770801</telephoneNumber> </destination> </country> </tourGuide> Exercises. <br>
2,847
Mass Media/Newspapers. Newspapers are print media and/or the newsgathering organizations that produce them. Most conventional newspapers are published on a daily or weekly basis, and are meant to inform the general public about recent events, especially public affairs. Besides local, national or international news, papers often carry sports and entertainment features, opinion columns and advertising. Newspapers may address a general audience, focus on a geographical area, or cover a specialized subject, such as newspapers for a specific profession, industry or interest. Newspapers traditionally are supported by selling advertising space as well as subscription or single-copy sales of the newspapers themselves. Through history, newspapers have sometimes been subsidized by organizations or interest groups, including political parties. Mass-circulation newspapers, such as those evolving in 19th century New York, attempt to appeal to a wider audience (and wider advertising market) than overtly partisan papers. As the Internet's World Wide Web spread in the 1990s, newspaper companies established Web editions carrying stories from the print edition and, increasing in the next decade, original material. By 2009 this had blurred the distinction between the printed newspaper and the online newspaper. By 2009, some newspapers were shifting from daily print production to daily Web production with weekly printed editions. Some new Web-only publications adopted reporting and writing styles commonly associated with printed newspapers. Newspaper advertising categories include: Newspapers are the largest employers of print media. About 40% of ad revenue for a newspaper comes from classifieds. National events. National papers include "USA Today" and the "Christian Science Monitor." Local events. Newspapers are a populace's main source of local news. Editorials. Editorial pages exist solely to display opinions, usually on political matters. They're kept separate from other areas of the newspaper because the opinions aren't meant to represent the newspaper so much as they are meant as a public forum. An editorial page may consist of political cartoons, letters sent by readers, or a persuasive article. Examples. UK: "Daily Mail", "The Times", "The Guardian" Italy: "Reppublica", "Corriere della Sera" France: "L'Équipe" There are hundreds of national and regional newspaper but most of them you can only find in it's country or region(state).
532
Dichotomous Key. This e-book can help with the identification of unknown organisms or species. The method adopted uses mostly a "dichotomous key" based on two choices, which is either in written format or pictographic, or both. For convenience, there may be polytomous sections within the book. A written dichotomous key presents the reader with two statements that describe certain characteristics. The statements should be mutually exclusive for the key to work efficiently. For example, 'it is either red or it isn't'. On selecting one, the reader is presented with the next couplet choice in the key and so on - to eventually arrive at an identification. This key uses "hyperlinks" to navigate. Classification with keys. Taxonomic systems are based on similar characteristics or increasingly on DNA analysis. The systems attempt to model the natural order, thus helping research by classifying different organisms. Taxonomic systems vary, but the following system has been found useful: There are many sub units in use. Keys usually start with a first selection from the following: How the key works. If the description at each level does not appear accurate then back up to some earlier couplet and start over, questioning each decision more carefully. Finally, a verification step is important by comparing the specimen with any further details available including description,photographs and other reference. The habitat and location where the sample was collected is useful for plants. If the description and other information satisfactorily confer, then a correct identification is possible. Start Here. Which Kingdom does it belong to? Animalia. Does it live underwater or mostly underwater? Plantae. What kind of plant is it? Aquatic Animal. What kind of animal is it? Fish. What kind of fish is it? (Osteichthyes): Actinopterygii & Sarcopterygii, but also lampreys (Myxini) and hagfish (Petromyzontida) Bird. What kind of bird is it? Insect. What kind of insect is it? Lizard. What kind of lizard is it? Shark. The keys in Wikibooks are still under development. A raw list is given below:
500
Slovene. Slovene is a South Slavic language spoken by roughly 2 million people in Slovenia (long considered to be the northernmost province of Yugoslavia) and in the border regions with northeastern Italy and southern Austria. It is closely related to Serbo-Croatian, Macedonian and Bulgarian, to which it is mutually intelligible to a wide extent in manner similar between Spanish, Catalan, and Galician and Portuguese in the Iberian Peninsula. Slovene, like almost every Slavic language, is a very tricky language to learn for speakers of Germanic languages (like English and German). It is highly inflected, that is, nouns, numbers, and adjectives decline according to gender (masculine, feminine and neutral) and number. Unlike the closely-related Serbo-Croatian, which is the only Slavic language that uses both Latin and Cyrillic alphabets and to which it's often compared to, Slovene only uses the Latin script with the same characters and diagraphs used by the aforementioned language. What makes Slovene stand out from others is that, not only it uses singular and plural, but it also uses the dual number system. In other words, there are verb conjugations, noun declinations and adjectives meant for two people or two groups, while the plural is meant for three and above. Of all the Balto-Slavic Languages, only Sorbian (found in what's popularly called East Germany, near the border with Poland) and Lithuanian retain the dual system inherited from old Slavonic. Slovene is often described as the true "Romantic" language because in Slovene it is possible to distinguish between "we" (plural) meaning a group of people including yourself and "we" (dual) meaning one other person and yourself. There are a total six noun cases in Slovene, like most Slavic languages. Slovene uses both Latin and Slavic names for case, both correct and interchangeably used: nominative (imenovalnik), accusative (akuzativ-tožilnik), genitive (genitiv-rodilnik), dative (dative-dajalnik), locative (lokativ-mestnik), and instrumental (instrumental-orodnik). This textbook will made under the assumption that the reader has, at least, some basic knowledge of Russian, Polish, Serbo-Croatian or any other Slavic language. If you do have some familiarity with these languages, you'll be surprised how closely related they are how their grammar structures are almost identical. A knowledge of some Old Church Slavonic (old Bulgarian) will help understand the dual number system. External links. Until this section is fleshed out, English speakers can visit: http://www.ff.uni-lj.si/sft/
640
Dichotomous Key/Animalia. 1. incomplete Single cell protists 9. incomplete Orthonectida, Rhombozoa, Acoelomorpha, Chaetognatha, Hemichordata, Xenoturbellida, Platyzoa, Lophotrochozoa
77
Modern Greek/Contents. Welcome to the Wikibook course on Greek. Please read the before beginning. Table of Contents. There will be two ways of using this wikibook. You may wish to learn in a lesson-style way, with knowledge organised from the easier- to the harder-to-learn material, or you may want to look for a specific topic using the table of contents, which is organised by topics rather to difficulty. Either way, we recommend the reading of the introduction. Introduction / Εισαγωγή. About Greek / Για τα Ελληνικά. The Greek Language (Η Ελληνική γλώσσα) is an Indo-European language with a documented history of some 3,000 years. "Ancient Greek" in its various forms was the language both of classical Greek civilisation and of the origins of Christianity, and was a first or second language over a large part of the Roman Empire. It has been studied in schools and universities in many countries from the Renaissance onwards. "Modern Greek", which differs in many ways from Ancient Greek but is still recognisably the same language, is spoken by approximately 12 million speakers worldwide, most of whom live in Greece and Cyprus. Greek is traditionally written in the . This wikibook pretends to discuss and expose Modern Greek. See also Ancient Greek, Koine Greek. Alphabet / Αλφάβητο. The Greek Language was one of the first written languages in all world. The script used had some peculiarities not observed today: for instance, the vowels were not written, and one needed to guess or to know their specific place inside the word. This alphabet has been evolving, through contact with other cultures and through the simple action of the time, until it became what it is today. Amongst the Greek alphabet, we can spot some (or even many) similarities with the Latin (or Roman) one. The alphabet used nowadays has 24 letters: 7 vowels and 17 consonants. Besides the alphabet, there is also an accent ( ´ ) and a diaresis( ¨ ). The use of these two diacritics is discussed in the . Pronunciation of the Alphabet. Greek sounds are, in general, soft. As a major rule, each letter carries a single sound (this is not universal, but almost, as we'll see later in this page). As in the , we see here a table with the various letters. This time, the columns represent not the name, but the "approximate" sound of the letters. Note: The letter Γγ is the most difficult to pronounce for an English speaker: it is like a stronger h, simultaneous with the vibration of the vocal cords; in other words, it is the voiced counterpart of the χ. Before e and i vowels, it is pronounced as a y like in the word yes. Diphthongs. "Diphthongs" are combinations of two vowels that function as a unique sound. Note that in Modern Greek, the word "Diphthong" (δίφθογγος) is also used for combination of vowels that sound like a simple vowel (digraphs). There are eight diphthongs in Modern Greek. There are also some similar combinations of consonants: Accent and Dieresis. Most Greek words have a "stressed syllable" which is the syllable said with more strength: for instance, in the english words "comfort" and "peculiarity", the stressed syllables are "com" and "ar", respectively. In all other words (those with two or more syllables), an accent ( ΄ ) is used above the syllable to mark the stress. In most one-syllable words, the accent is omitted. When the stress falls on a syllable that has a diphthong, the accent is used above the last letter of this diphthong. Thus, the accents are as shown on these words: Παύλος ("Paul") ou γυναίκα ("woman"). If the accent is put on the first vowel of a diphthong, it is pronounced as two separate vowels rather than as a diphthong, as in the word ρολόι ("watch" or "clock"), which has three syllables, not two. On the other hand, if the diphthong is pronounced as two vowels but the accent falls on second vowel, the dieresis ( ¨ ) is used, as in the word Εβραϊκός ("Hebrew"). There are, however, some words that aren't stressed (usually monosyllabic gramatical words), and these don't have an accent. Words like these are read as affixes added to the main word. Examples: Every stressed word with more than one syllable carries an accent. However, there are monosyllabic words that also have accent, like ή ("or") and πού ("where"). This accent has a double function:
1,181
General Biology/Getting Started. <br> <br> <br>
32
General Biology/Cells. <br> <br>
22
General Biology/Genetics. <br> <br>
22
General Biology/Classification of Living Things. <br> <br> <br>
33
General Biology/Tissues and Systems. <br> <br>
24
General Biology/Additional Material. <br> This page is links to modules that were not included in the original notes donated by Drs. Doerder and Gibson and need to be organized into the rest of the material in a logical way. External links. <br>
70
Dichotomous Key/Aves. 13. unfinished 16: Cassowaries. unfinished 17. unfinished 18: Kiwis. unfinished 21. unfinished 22. unfinished Tasmanian Nativehen, Gough Island Moorhen, Makira Wood Rail, Samoan Wood Rail, Takahe (bright blue/green plumage), New Guinea Flightless Rail, invisible rail, Red-eyed Crake, Inaccessible Rail, Calayan Rail, Lord Howe Woodhen, New Caledonian Rail, Weka, Woodford's Rail, Giant Coot
145
General Biology/Evolution of Life. Key Terms. Evolution: Any change in allele frequency in a population, often the result of natural selection. Natural selection: differential reproduction of genotype within a population; one genotype reproduces more successfully than another and donates more copies of itself to the next generation. This means that allele frequencies change within a population. Natural selection is the only mechanism known to produce complex adaptations in nature. Natural selection can occur in any population that has heritable fitness differences. Fitness: the ability of an individual to contribute its genes to the next generation. Differences in fitness are central to natural selection. Relative fitness: fitness of an individual compared to others in its species. Hardy–Weinberg principle states that both allele and genotype frequencies in a population remain constant or are in equilibrium from generation to generation unless specific disturbing influences are introduced. Natural Selection. Both Charles Darwin and Alfred Russell Wallace proposed natural selection. Wallace went to Darwin for help getting published and the result was that the two presented their papers together. Natural selection is the result of violation of Hardy-Weinberg equilibrium, a state of stability in a population where allele frequencies do not change. A population stays in Hardy-Weinberg equilibrium when five assumptions (or prerequisites) are maintained: Results of Hardy-Weinberg equilibrium: Q: What happens when we violate one of the five assumptions of Hardy-Weinberg equilibrium? A: Allele frequencies change. The Hardy-Weinberg principle is named after English mathematician G. H. Hardy and German physician G. Weinberg, who independently came to similar conclusions in 1908. Note: In our lab computer simulation lab experiment, we relax the H-W restriction against natural selection, resulting in simulated evolution. When not all phenotype fitnesses are equal, selection occurs, allele frequencies change, and evolution results. Q: Will a dominant allele take over a recessive allele in frequency? A: No. The Hardy-Weinberg principal shows that any allele that confers greater fitness will become more frequent in the population than an allele that confers lesser fitness, and disproves the easy assumption that a dominant allele would overtake a population over time. Allele frequency is based on fitness, not whether it is dominant or recessive. Hardy-Weinberg equation: formula_1 Examples of adaptation due to natural selection Skin color of the Australian Death adder: brilliant orange skin very unusual in an animal but quite similar to the local soil color. Likely that the snake moved towards this color over time as snakes with brownish and then orange coloring experienced higher survivorship than other-colored snakes. Pesticide resistance in insects: Pesticide DDT (developed in ‘30s to combat malaria by knocking out its vector, malaria-carrying mosquitoes) had an initially high kill rate that diminished over time until it became essentially ineffective against insects. Hundreds of similar pesticide resistances have been developed in other insect species. Antibiotic resistance in bacteria: disease-causing bacteria have followed a similar adaptive path to the insects. This is caused by incorrect use of antibiot-ics for disease treatment. An incomplete application of antibiotics kills most of the disease-carrying microbes in a patient’s body. The most antibiotic-resistant germs have then been selected. These multiply and can become increasingly uncontrollable by further antibiotic treatment. Public health officials fear that this process when repeated over time will create super-germs that will be re-sistant to all drugs. Tuberculosis (TB) is a disease currently following this path of increasing antibiotic resistance. There are various mechanisms of acquired chemical resistance: Industrial melanism in English pepper moth (Biston betularia). The moth has two naturally occurring morphs, or varieties: typical (light-colored) and carbonized (dark-colored). The more common morph has historically been the typical, but a change in its habitat led to an increase in frequency of the carbonized. (Air pollution killed off light-colored lichen on tree trunks, leaving moths exposed on dark bark instead of lighter lichen. Predatory birds acted as an agent against the more visible morph of the moth, which responded to the natural selection by increasing the frequency of the less visible morph. Monkeys who kill others’ young: Observed by Sarah Hrdy. Langur monkeys live in social troops with one male presiding over several females and their young. Female young stay within the troop but male young are kicked out to roam the fringes of the troop and try to take over other troops. Incoming male leaders kill suckling young, as well as the babies of females with whom he hasn’t mated. Q: Why? A: Because lactating females are in irregular estrus cycle and unavailable to become pregnant. Killing their young frees them up to become pregnant sooner with his babies. The counter adaptation in females: they mate with the new male even if already pregnant, as the new leader will not then not later kill their baby. (Similar situations have since been observed in other species, such as mice). Selfless turkey problem: 1st generation male descendants of one female turkey set up a brotherhood, a tiny social hierarchy headed by the alpha male. The brotherhood courts females as a group. A female selects one brotherhood for mating, usually a larger one, then mates with the alpha male only. Q: Did natural selection shape the behavior of these brother turkeys? A: No answer given, but an implied “yes”. Q: Has natural selection tuned all characteristics of every organism? A: No. Example: The Indian rhino has 1 horn, and the African rhino has 2 horns. This difference is likely a historical accident, not an adaptation, as two horns don’t seem to give an advantage over one. Five constraints on evolution: Historical constraints: “present variation biases future possibilities”. Variation comes on top of past history. Formal constraints: Variation can’t defy laws of physics. Ex: pigs don’t fly, and insects are limited in size by their exoskeletons. You-can’t-get-there-from-here constraints: An advantageous end result must follow many tiny advantageous steps. Ex: There are no live-bearing birds, possibly because the thin eggshell necessary for gas transfer if incubated inside the bird is so disadvantageous for a egg development outside the bird. However, flight feathers evolved from reptilian scales because each tiny change to the scales over time was advantageous, and afterwards allowed the evolution of flight. Time/variation constraints: new alleles formed thru random mutation, which needs time and is ultimately pushed by mathematic probabilities rather than pulled to a specific end. In limited time, limited results. Ex: Human heart disease the possible result of recent changes in human diet (last 100s of years as opposed to last 100,000s of years of human evolution). Pleiotropic constraints: (pleiotropy: when one gene has multiple phenotypic expressions) one allele may have several effects, some good & some bad. If the sum of parts is positive, the allele is favored (even if it carries along some unfavorable baggage). Ex: Cystic fibrosis allele may have been advantageous against cholera in pre-industrial Europe. Mutation: a random process that is the “ultimate” source for natural selection. Little mutation results in advantageous change, and so is very inefficient. Q: Why does it work at all? A: Because: Sampling error: the difference between a sample and the actual population. Greater for smaller sample sizes. Unrelated to population size, based on abso-lute size of sample. Q: What happens when the population size is limited, restricting Hardy-Weinberg equilibrium? A: In small populations, chance events can dramatically change allele frequencies. Example: “A” and “a” alleles are in equal frequencies in a population: formula_6 formula_7 In a sample size of four organisms from this population we would expect to find: formula_8 formula_9 However, 30% of the time we would have the following result, with a shift favoring one allele: formula_10 formula_11 And about 8/1000 of the time (1%): formula_12 formula_13 One allele is completely eliminated! (If the population size is 40, the chances of this are 1/500,000). In this way, alleles can be eliminated from a real population. Q: How can small sample sizes occur in real populations? Virtual small population size: a small proportion of individuals in population cover reproductive resposibilites. Usually occurs with males, sometimes females. Ex: Mammals such as seals, where one giant male guards over and mates with harem of many females. This is because the females go to an isolated spot to birth to avoid predators, then go into heat just days after giving birth. A large male fights other males for the privilege of guarding these females and their offspring as “beach master”. The females intermittently go off to feed, coming back to feed their calves. Result in males is that they are much larger than the females; they store lots of body fat so they can stay on the beach a long time (as soon as they leave another male will come take their spot). Effective breeding population for one generation is therefore much smaller than actual number of living members. Another example: in wolves, only the alpha male and alpha female breed, and the others just help raise their young. So a wolf population of sixty may have a breeding population of just six. Immigration / emigration: “gene flow” – individual moves in from a different area & brings new allele frequencies. “A little bit can do a lot”. Ex: interracial marriage. Mutation: produces variation in gene pool. Rates are low and work very slowly: just 1/100,000 to 1/1,000,000 mutations occur per locus per gamete per generation. Mutation alone is not enough to drive an allele to a higher frequency. A general rule: any allele with a frequency of 1% or more of the total population was not driven there by mutation. Non-random mating: individuals choose mates based on genotype. (Positive) assortative mating: choosing a mate with a genotype similar to your own, leading to homozygotic offspring. Dissortative mating: choosing for dissimilar genotype, leading to heterozygotes. Inbreeding: mating with close relatives: a way to mate with your own genotype (and produce homozygotic offspring) Note: the average human has about thirty lethal recessive allele loci in his total chromatin. Mating with close kin increases the possibility of an offspring with double recessive lethal alleles. Many species have outbreeding behaviors to discourage inbreeding. Ex: langur society: females born in a troop remain in their troop but males are booted out, discouraging brothers mating with sisters. Non-random mating can change genotype frequencies but NOT allele frequencies by itself, therefore not responsible for evolution. But it can expose certain alleles to selection by making them homo or heterozygous in the genotype. Aging senescence: decline in performance in the general body of an organism with increasing age. This is a selectable trait and is not present in all organisms. Tissue does not “need” to be senescent. Some protists basically “live forever”; fruit flies can be bred for longevity. Q: Why is this? A: Gibson does not say why, but suggests that it is a selectively favored trait. After class the professors seem to say that senescence is not necessarily an evolutionarily favored trait as much as a byproduct of the processes that led to higher development. In order to achieve delayed reproduction, more resources were put towards early survivorship at the expense of later survivorship. A related example is the difference between salmon in the Atlantic and Pacific oceans. Atlantic salmon live through multiple spawning seasons but Pacific salmon have been selected to put all their energy into one, difficult spawning cycle, where they die right after. Types of selection: Stabilizing selection: Selection that moves organisms toward the center of their range of possible traits. Ex: human birth weight; especially large and small babies suffer greater infant mortality, favoring babies of intermediate weight. A stabilizing environment results in fossil records that are unchanged for millions of years, such as for the body plans of sharks and horseshoe crabs. Directional selection: Selection that acts to eliminate an extreme from an array of phenotypes. Ex: Metals such as copper are usually almost lethal to some plants. A strain of copper-resistant grass has developed over many generations of growing in contaminated high-Cu soil. Disruptive selection: Selection that tends to eliminate intermediate type. Ex: African seedcracker: has two bill sizes, one large and one small, each one best suited for a different kind of locally-abundant seed. Intermediate bill types are unfavored by selection because they are poorly suited for either kind of seed. Here, the homozygote that results in one bill type or the other is favored over the heterozygote, which produces the intermediate bill type. Consider a population that has the following genotypic frequencies for a given locus having two alleles, “A” and “a”: Q: What is the allele frequency for “A”? (i.e., what is p?) Q: Does the population appear to be in Hardy-Weinberg equilibrium? Steps to solve: We see that the genotype frequencies change from their initial values to their final vales. Therefore the population was not in Hardy-Weinberg equilibrium. Q: If the numbers are only somewhat dissimilar how do we tell if they should be considered similar or dissimilar? A: This is determined with statistical and mathematical analyses beyond the scope of this class. Tests have been done on breeding many organisms for a certain trait by divid-ing successive generations into groups based on phenotype. Ex: Fruit flies (Drosophila) artificially selected into two groups: one with many abdominal bristles, one with few bristles. We find that neither of the two resulting groups even overlaps the bristle range found in the starting generation. This mimics the results of natural selection on a wild population under certain circumstances. This is similar to the process used for thousands of years by plant and animal breeders. Heterozygote advantage: when heterozygote genotype confers greater fitness than a homozygote. A classic example of this is sickle-cell anemia. This human disease occurs when a person is homozygotic for the recessive allele. The recessive allele increases survivorship against malaria in the herozygotic carrier. Natural selection works in high malaria areas to increase the frequency of this allele in humans. The allele frequency is highest in central Africa, where malaria has been a big killer. Speciation: Q: How do we get a new species? Q: What is a species? A: There are different definitions, but only one that we will go over in depth. Biological species concept (BSC): of Ernst Mayer. A species defined as a reproductively isolated population. If two organisms can interbreed, they are one species; if they cannot, they are not of the same species. Not a perfect definition as lions and tigers can interbreed in captivity, and this works only with sexually reproducing organisms (dandelions reproduce asexually). Phenotypic definition: species defined by phenotypic gaps in a population. Cladistic definition: populations or population groups which are members a single clade Clade: a branch of the evolutionary tree. Two ways to name a new species: Cladogenesis has three splitting models / hypotheses based on patra, “homeland” Parapatric speciation: perhaps the only example we have of this is found in the copper-resistant mine grass previously discussed. Selection strongly favors the genotype homozygous for the Cu-resistant allele. This has resulted in an adaptation in the pollination time to make it different than the pollination time for the surrounding grasses, avoiding cross-fertilization. Here is speciation without geographic isolation caused by the intense selection. Sympatric speciation: (is this info right? Book seems to conflict with lecture) a common source of new species in plants but uncommon in animals, this occurs when gametes from two different species cross and create a viable new species. This believed to be the source of ½ of the flowering plants. Polyploidization: the most important model of sympatric speciation. Or, the doubling of chromosomes that can lead to sympatric speciation. Allopolyploid: polyploidization triggered by an interspecific hybridization event. The resulting zygote may be unviable or infertile. If viable, it may later develop fertility. This is due to the differences between cell divisions in mitosis and meiosis (and we thought that we had escaped). In mitosis, chromatids self-replicate. In meiosis, each chromatid has to “find” its homologue. If no homologue is present, the result is viable but infertile. However, with an abnormal mitotic event, cytokinesis (division of the cytoplasm after nuclear division) does not occur, resulting in a cell with double the normal number of chromosomes. If this cell enters meiosis, it can be fertile. (Many examples of this). Ex: Bread wheat is the result of two successive grass hybridization events. Grass went from having 14 > 28 > 42 chromosomes. Geographic speciation Geographic variation: Differences in a species based on geographic location, usually genetically based. Found in humans, where genotypes from one place are different than those from another. More common in less mobile populations as it is opposed by gene flow. Ex: yarrow, a plant which is found to be shorter at higher altitudes. Q: Is this variation due to genes or to environment? A: a “common garden experiment” finds the answer. Seeds of different origins are grown in the same environment. Result is that seeds from higher altitudes grow into shorter yarrow plants, revealing an underlying genetic factor. Ex: common garter snake, Thamnophis surtalis, common throughout the US and Canada, is divided into various local sub species with local colorations. As garter snakes are not highly mobile, the populations can become locally adapted. In mallard ducks this geographic variation does not occur as each generation a male hooks up with a female in the southern “win-tering grounds”, then follows her up to her northern home, which may be very distant from his other home. This results in a genetic shuffle each generation independent of location. One population can be broken into different, isolated populations for a time, al-lowing two distinct evolutionary pathways. Ex: a glacier advances over North America and splits a population into SW and SE groups. When the barrier is removed (the glacier retreats) the populations can come into contact again, called secondary contact. Q: Then what happens? A: If inbreeding results in fertile offspring, they are still of the same species. If not, they are now new species. Isolating mechanisms: anything that acts to prevent the production of viable zygotes between two organisms. Classified into two groups: The prezygotic mechanisms prevent the fertilization of an egg by the sperm, and hence the production of a zygote, commonly when male courtship is unrecognized by the female. Postzygotic isolating mechanisms result in a zygote which Ex: A cross between a donkey and a horse produces a mule, which is sterile. Geographic separation can result in two quite morphologically different popula-tions that interbreed on secondary contact and are therefore one biological species. Like, they can look all different and stuff but still breed with each other. And sometimes, a seemingly slight difference prevents interbreeding. The point: the “amount” of differences that arise during the isolation of two populations doesn’t necessarily determine whether they will successfully interbreed upon secondary contact and therefore be considered one or two species. Ex: Eastern and western meadow larks are almost identical in appearance (morphologically similar) but are distinct biological species. This is possibly the result changes which occurred during isolation caused by glacial separation. On secondary contact these two populations apparently did not respond to each other for mating, becoming two biological (reproductive) species. (There are various examples like this one). Peripheral isolates: a relatively common version of geographic isolation. At the edge of a species range an organism lives at the limit of its survivability. When these areas become separated from each other, allopatric speciation can occur, high rates of selection can push allele frequencies. Habitat islands: areas where a habitat favorable to a species is surrounded by an area where the species does not survive. Ex: a volcanic island in an ocean. In this case, founder populations arrive and find ecological vacuums, or different conditions, that influence adaptation. Adaptive radiation, a series of adaptation events, occurs as various species interact and adjust through evolution. Ex: the variation found in Darwin’s finches was caused when a founder population of finches adapted to the unique conditions of each island). Note: even greater variation is found amongst the finches of the Hawaiian Islands. Hawaii is also the home to countless species of Drosophila (fruit flies). Binomial nomenclature: “two-named naming” (bi: two, nomin: name) originated by Carolus Linnaeus (Carl von Linné) of Sweden. Each species of organism has its own unique two-part name, made up of Homo sapiens is the binomial name for the modern human. Homo is a genus of related primates (all but mankind are now extinct) and sapiens is a descrip-tor, “wise”. When typed, this two-part name is customarily italicized, and when handwritten, underlined. The naming system is hierarchical, with succeeding levels dividing organisms into more specific taxonomic groups. The broadest division is that of kingdom (or domain, a more basic designation now accepted by many biologists. Here is the full list from most general to most specific. (Domain) » Kingdom » Phylum » Class » Order » Family » Genus » Species. There are subdivisions that are sometimes used between these levels (for example, subphylum) but we are not responsible for knowing them. The higher the level, the greater the difference between groups, reflecting pro-gressively earlier speciation events. Q: Why does Linnaus’ naming system neatly fit the evolutionary tree, as he invented it outside an evolutionary context? A: The organisms are related in a genealogical way with inherently hierarchical relationships. Taxon: a given group of organisms at some given rank. Ex: the taxon “Canis”, a group of dogs at level genus, vs. the taxon “canidae”, at level family. (Taxonomy: orderly classification of plants and animals according to their presumed natural relationships.) Monophyletic taxon: a species set, or grouping of species, made up of Ex: great apes Paraphyletic taxon: a grouping of species just like the monophyletic taxon except that it excludes species that have diverged farthest from the common ancestor. Ex: Great apes, minus humans. Polyophyletic taxon: grouping of species that excludes the most recent common ancestor. Ex: A grouping of whales and sharks, without their common primitive ancestor (whatever that might be). There are two taxonomic schools of thought: Both schools agree on how to draw the evolutionary tree, as well as that: However they disagree in the treatment of the middle ground, paraphyletic taxonomic groups. The traditionalists say: These groups are OK, as they reflect important evolutionary change. The cladists say, paraphyletic groups are NOT OK, as the identification of “important” changes is based on people’s opinions. Cladism prefers greater objectivity. Q: How do we estimate evolutionary sequences? A: Derived homology, or transition from [ a -> a’ ], ex: a species’ loss of a digit thru time. Synapomorphy: Gibson says that synapomorphy gives the only real idea of branching sequence symplesiomorphy: Evolutionary branching Q: How can we generate hypotheses about evolutionary branching? (How can we figure out which branching sequence is most likely the historical one?) A: There are various ways to do this. Generally, we start by considering certain characters, then arrange them into possible trees. Characters are found in either a more ancestral or more derived state, and sometimes the trait can disappear completely or even reappear. When a species goes from having one version of a trait to another version, it is called a trait change. One way to determine the most likely branching sequences is by creating examples of all the possible sequences. Although this is a simple process, it is not feasible in many cases because the number of possible branching sequences is so great. For example, a group of just 10 species has over 34 million possible evolutionary trees. (Certain methods are used to eliminate many of these options and make the process simpler). The simplest sequence is the one that has the smallest number of trait changes, and is preferred. They are then used as a basis for further refinement that comes with more data. Punctuated equilibrium: a hypothesis about the tempo and mode of evolution, presented by Stephen Gould and Niles Eldridge as a challenge to the traditional view known as phyletic gradualism. Current thought sees evolutionary change as neither of these two extremes but rather somewhere in between, or sometimes more like the one and other times more like the other. Evolutionary “novelties” Q: How can we explain macroevolution? Can the incremental changes of microevolution lead to the big changes of macroevolution, such as flight in birds? What other processes can lead to major changes in species? Preaptation (co-opting) Allometric growth Paedomorhosis (paidos: child) Isometric growth: all parts grow at the same rate and stay in proportion, as in a growing salamander and in most organisms Algometric growth: different parts grow at different rates, resulting in changing proportions thru growth cycle, as in human, and in the godwit, a bird whose beak grows exponentially faster than its head does Analogous structures: two structures that serve a similar function but have different origins. Examples: wings of a butterfly and a bird, leglessness in snakes and in certain lizards, white eggs in various diverse bird species Antennapedia: mutant fruitfly has small legs on head in place of normal antennae, caused by inappropriate development of cells into homologous part Bithorax: ancestors to modern insects had two full pairs of wings but today some of these have evolved the second pair into small balancing structures called halteres. (Some extant insects, such as the dragonfly, retain all four wings, one pair on the second and third segments of the thorax). Insects with only two wings are called dipthera, meaning “two wings”. In the bithorax mutant, halteres develop into a second full set of wings. Homeodomain: series of 60 amino acids (180 nucleotides) which encodes development and has remained similar throughout the evolution of very different organisms, spanning the animals and apparently extending into parts of the plant kingdom as well. Reveals the strong conservation of genes thru evolution.
6,490
Dichotomous Key/Plantae. Plants are mainly multicellular, predominantly photosynthetic eukaryotes of the kingdom Plantae. The term is today generally limited to the green plants, which form an unranked clade Viridiplantae (Latin for "green plants"). This includes the flowering plants, conifers and other gymnosperms, ferns, clubmosses, hornworts, liverworts, mosses and the green algae, and excludes the red and brown algae. Historically, plants formed one of two kingdoms covering all living things that were not animals, and both algae and fungi were treated as plants; however all current definitions of "plant" exclude the fungi and some algae, as well as the prokaryotes (the archaea and bacteria). Green plants have cell walls containing cellulose and obtain most of their energy from sunlight via photosynthesis by primary chloroplasts, derived from endosymbiosis with cyanobacteria. Their chloroplasts contain chlorophyll a and b, which gives them their green color. Some plants are parasitic and have lost the ability to produce normal amounts of chlorophyll or to photosynthesize. Plants are characterized by sexual reproduction and alternation of generations, although asexual reproduction is also common. There are about 300–315 thousand species of plants, of which the great majority, some 260–290 thousand, are seed plants. Green plants are the basis of most of Earth's ecologies, especially on land. Plants that produce grains, fruits and vegetables form humankind's basic foodstuffs, and have been domesticated for millennia. Plants play many roles in culture. They are used as ornaments and, until recently and in great variety, they have served as the source of most medicines and drugs. The scientific study of plants is known as botany, a branch of biology. 1. Green algae; mostly aquatic. Chlorophyta and Charales. 2. Not Green algae; aquatic or terrestrial. Streptophyta / Embryophyta. 3. Non-vascular land plants. Bryophyta. 4. Vascular plants. Tracheophyta. 5. Spore producing plant. 6. Seed producing and flowering plants. 7. Trunk absent or branches extend from trunk. 8. Flowering plant. Angiosperm. 9. Non-flowering plant. Gnetophyte. 10. Leaves thin, needle-like.
607
Applicable Mathematics/Probability. Probability is a way of expressing an expectation about the likelihood of an "event" occurring in an "experiment", based on whatever information is available either about the mechanism which lies behind the experiment (theoretical probability) or knowledge of previous events (experimental probability). An example of a random experiment and often used in Maths puzzles is the birth of a child, in which the gender of the child cannot be known beforehand and is usually deemed to be 50/50 boy versus girl. In this case, the experiment is the birth, the possible "outcomes" are "girl" and "boy". The word "event" usually refers to the particular outcome we consider a "success" (which simply means the type of outcome whose probability we wish to calculate). Often, the "outcomes" are expressed as the result of a SERIES of experiments ("What are the chances of throwing heads twice in two tosses of the same coin"). The Measure of Probability. The normal measure of probability is a number between 0 and 1, where 0 means "impossible" (not quite true, see below), .5 means "as likely as not" and 1 means "certain to happen". For example, the probability of tossing a head" is usually taken to be 0.5. In everyday language, the number is more likely to be expressed as a fraction (1/2 or "one in two") or a percentage ("50% chance"). When throwing a die, the probability of getting a 1 is 1/6 (i.e. we expect that in a large number of throws, the frequency of "1s" will be close to 1/6 of the number of throws). Two kinds of Probability. In Maths classes, the first type of probability is more common, in science, the second. Meaning of Probability. Repeated Events. Where an event can be repeated in the same way as often as desired, then not only is it clear what the calculated probability means ("I expect that if I toss this coin 500 times, I will see about 250 heads"), but also it will be possible to check whether the estimate was correct (toss the coin and see how many times you get a head). One-offs. Where a trial (or event) is a one-off (neither this trial, nor a very similar one can be done again) then not only must the calculation be a theoretical one, but also it is less clear what the calculated figure MEANS. "There is a 50% chance of the Earth being destroyed by collision with a comet during this year". Either the Earth will or will not be destroyed, neither outcome will show you whether your calculated probability was correct. Actually, you CAN run the trial as many times as you like (treat each year as one trial), but there will be a maximum of ONE "successful" outcome, so it is not easy to see what light 1 or 2 or 3 or 4 destruction-free years sheds on your calculation. If, however, you have the opportunity to gamble on many different one-off events, and experience gives you good reason to trust your probability estimates, then probability does have some meaning: you would be wise in future wagers to bet on events to which you ascribe high probability and better to avoid improbable ones (except at very favorable odds). This is actually similar to horse-racing - you are encouraged to believe you can calculate the odds of a horse winning, but most races are really one-offs run in very different circumstances to all the other races. If you only bet on one race in your life, then you are unlikely to back a real outsider at whatever odds - but if you spend a lot of time at racecourses, you may probably back quite a lot of outsiders, but only in the cases where you believe that the high odds against them are more generous then necessary - expecting (perhaps unwisely, since it is the bookies, not you, who set the odds) that the few that win will pay enough to outweigh your many small losses on the ones that did not. Outcomes and sample spaces. When doing experiments, the answer is not known prior to the actual experiment. However, we should know what we "can" get. The possible results of an experiment are called outcomes. A certain group of outcomes is called a sample space. When you throw a die, you can get 1, 2, 3, 4, 5 or 6 eyes. These are the possible outcomes in a throw. the sample space is U = {1, 2, 3, 4, 5, 6}. Model of probability. A model of probability gives the probability of every outcome a number between 1 and 0. The sum of the probability of all possible outcomes is 1 (if you cannot make them add up to 1, then you have missed or double-counted some possibilities). Let's for instance take a die-throw as an example. The model of probability for that would be: P(1) = P(2) = P(3) = P(4) = P(5) = P(6) = 1/6 However, when we're looking at whether a birth results in a boy or a girl, the model of probability results in: P(B) = 0.514 and P(G) = 0.486 In the first example, all the outcomes have the same probability - the model is uniform. In the second example, the outcomes have different probabilities - the model is "not" uniform.
1,229
Dichotomous Key/Coleoptera. 9. Could be Buprestidae, Cantharidae, Cerambycidae, Chrysomelidae, Scolytidae
43
Introduction to Philosophy/Authors. /MK/ has loved philosophy ever since she realised that it is a matter of 'thinking things over carefully', and has been around it in one form or another since. She is especially interested in the Existentialists, and has contributed to that part of the book. She also knows something about Utilitarianism and Pragmatism. might make some contributions to the logic part, and maybe to the philosophy of mind part as well. But I don't think I'll achieve much without your help and encouragement. is currently a student of philosophy, has made contributions to the Metaphysics section (particularly the section on person hood), and intends to continue contributing.
154
Diplomatic History. __NOEDITSECTION__
12
Dichotomous Key/Petromyzonidae. This is a Dichotomous Key for the Family Petromyzonidae.
31
Diplomatic History/Authors. is an undergraduate student of Diplomatic History and International Relations at the University of Pennsylvania. He began the Diplomatic History textbook at 3:00 AM on a school night. He plans to make his major contributions to the chapters on Germany, the Cold War, World War II, and the EU. He invites others to contribute at will. is an undergraduate student of Linguistics and Political Science at the University of Florida. He hopes to assist Bigrabid by making major contributions for all time periods of China, Eastern and Central Europe, and Africa. is an undergraduate student of International Relations at the Technical University of Lisbon, ISCSP. He hopes to assist the other authors by making contributions to the chapters on Russia and the USSR and Germany.
174
GCSE ICT. This book will cover the major components of all the courses. It should not be based around any specific board and it is hoped that it will become a resource for those studying ICT at any level. It looks at visible applications of computers in the world around us and covers the topics in context. Anyone of these case studies should be looked at as a resource to help you produce coursework. You might like to: If you found something difficult to understand please alter it to help those who follow you or contact some one who can! This resource will also need a content mapping / index - so that it is possible for teachers and pupils to find example of particular usage. Revision Guides. /GCP Revision Guide/
156
GCSE ICT/ICT in Schools. Schools use ICT for: Administration. Schools have to keep information about all the pupils and staff. The Schooltool project is developing an open source solution for this problem and has a detailed analysis of what is needed in all sorts of schools. Proprietary solutions include CCM's product CMIS and Capita's SIMS. Schools need to store information on: A subject and a teaching tool. Schools also teach ICT and/or computing as a subject and often have networks for pupils to store their work on and to access eductional resources. The types of applications that the pupils will use will include: These would include both specific and general resources.
158
GCSE ICT/ICT and Banks. Banks have been heavy users of ICT for a long time. From the introduction of MICR in the 1950's through to the current push for 'Chip and PIN'. The reason for this enthusiasm for new technology is to keep costs down. A simple estimate of the number of transactions that occur daily in the UK will explain why automation is essential! How many people have bank accounts? - estimate 1/3 of the population... some 20 million people. How often do they use their accounts? this is a for bill payments, holes in the wall transactions, debit cards, etc. - estimate every other day... so 10 million transactions per day. How long does it take to handle a transaction? guess 30 seconds of human work... so 5 million minutes of work per day. How many transactions could a worker handle in a day? based on an 8 hour day... 8 hours = 480 minutes (roughly 500 minutes...) So how many workers would be needed to keep up with these transactions? formula_1 formula_2 So around an additional 10,000 workers would be required - and these figures are underestimates.
283
General Chemistry/Matter is measured. Measurement is the determination of the size or magnitude of something. Measurement is not limited to physical quantities, but can extend to quantifying almost any imaginable thing such as degree of uncertainty, Index of Consumer Confidence|consumer confidence, or the rate of increase in the fall in the price of beanie baby|beanie babies. In physics and engineering, measurement is the process of comparing physical quantity|physical quantities of real-world object (philosophy)|objects and event|events. Established standard objects and events are used as unit|units, and the measurement results in at least two numbers for the relationship between the item under study and the referenced unit of measurement, where at least one number estimates the "statistics|statistical uncertainty" in the measurement, also referred to as "measurement error" (in a philosophical distinction). Measuring instruments are the means by which this translation is made. Metrology is the study of measurement. A metric is a standard for measurement. The quantification of phenomena through the process of measurement relies on the existence of an explicit or implicit metric, which is the standard to which the measure is referenced. If I say I am '5', I am indicating a measurement without conveying an applicable standard. I may mean I am 5 years old, 5 feet high, or 5-time world raquetball champion. Measuring physical quantities accurately is important in science, engineering and commerce. For example, the unit for length might be a well-known person's foot, and the length of a boat can be given as the number of times that person's foot would fit the length of the boat. Laws to regulate measurement were originally developed to prevent fraud. However, units of measurement are now generally defined on a scientific basis, and are established by international treaties. The history of measurements is a topic within the History of Science and Technology. The meter was standardized as the unit for length after the French revolution, and has since been adopted throughout most of the world. The United States and the UK are in the process of converting to the SI system. This process is known as metrication. Systems of measurement: Measuring the ratios between physical quantities is an important sub-field of physics. Some important physical quantities include:
503
General Chemistry/Properties of elements are periodic. The periodic table of the chemical elements is a display of known chemical elements, arranged by electron structure so that many chemical property|chemical properties vary regularly across the table. The original table was created without a knowledge of the inner structure of atom|atoms: if one orders the elements by atomic mass, and then plots certain other properties against atomic mass, one sees an undulation or "periodicity" to these properties as a function of atomic mass. The first to recognize these regularities was the German chemist Johann Wolfgang Döbereiner who, in 1829, noticed a number of "triads" of similar elements: This was followed by the English chemist John Alexander Reina Newlands, who in 1865 noticed that the elements of similar type recurred at intervals of eight, which he likened to the octave|octaves of music, though his "law of octaves" was ridiculed by his contemporaries. Finally, in 1869, the German Lothar Meyer and the Russian chemist Dmitry Ivanovich Mendeleev almost simultaneously developed the first periodic table, arranging the elements by mass. However, Mendeleev plotted a few elements out of strict mass sequence in order to make a better match to the properties of their neighbours in the table, corrected mistakes in the values of several atomic masses, and predicted the existence and properties of a few new elements in the empty cells of his table. Mendeleev was later vindicated by the discovery of the electronic structure of the elements in the late 19th century|19th and early 20th century. Lists of the elements List of elements by name|by name, List of elements by symbol|by symbol, and List of elements by number|by atomic number are available. The following figure shows the currently known periodic table of the elements. Each element is listed by its atomic number and chemical symbol. Elements in the same column ("periodic table group|group") are chemically similar. Colour coding for atomic numbers: The number of electron shell|electron shells an atom has determines what period it belongs to. Each shell is divided into different subshells, which as atomic number increases are filled in roughly this order: 1s 2s 2p 3s 3p 4s 3d 4p 5s 4d 5p 6s 4f 5d 6p 7s 5f 6d 7p 8s 5g 6f 7d 8p Hence the structure of the table. Since the outermost electrons determine chemical properties, those tend to be similar within groups. Elements adjacent to one another within a group have similar physical properties, despite their significant differences in mass. Elements adjacent to one another within a period have similar mass but different properties. For example, very near to nitrogen (N) in the second period of the chart are carbon (C) and oxygen (O). Despite their similarities in mass (they differ by only a few atomic mass units), they have extremely different properties, as can be seen by looking at their allotrope|allotropes: diatomic oxygen is a gas that supports burning, diatomic nitrogen is a gas that does not support burning, and carbon is a solid which can be burnt (yes, diamond|diamonds can be burnt!). In contrast, very near to chlorine (Cl) in the next-to-last group in the chart (the halogen|halogens) are fluorine (F) and bromine (Br). Despite their dramatic differences in mass within the group, their allotropes have very similar properties: They are all highly corrosion|corrosive (meaning they combine readily with metal|metals to form metal halide salt|salts); chlorine and fluorine are gases, while bromine is a very low-boiling liquid; chlorine and bromine at least are highly colored.
895
General Chemistry/Chemical formulas describe chemical compounds. A chemical formula " is a concise way of expressing information about the atoms that constitute a particular chemical compound. It identifies each type of chemical element|element by its chemical symbol and identifies the number of atoms of such element to be found in each discrete molecule of that compound. The number of atoms (if greater than one) is indicated as a subscript." For example methane, a simple molecule consisting of one carbon atom bonded to four hydrogen atoms has the chemical formula: and glucose with six carbon atoms, twelve hydrogen atoms and six oxygen atoms has the chemical formula: A chemical formula may also supply information about the types and spatial arrangement of bonds in the chemical, though it does not necessarily specify the exact isomer. For example ethane consists of two carbon atoms single-bonded to each other, each having three hydrogen atoms bonded to it. Its chemical formula can be rendered as CH3CH3. If there were a double bond between the carbon atoms (and thus each carbon only had two hydrogens), the chemical formula may be written: CH2CH2, and the fact that there is a double bond between the carbons is assumed. However, a more explicit and correct method is to write H2C:CH2 or H2C=CH2. The two dots or lines indicate that a double bond connects the atoms on either side of them. A triple bond may be expressed with three dots or lines, and if there may be ambiguity, a single dot or line may be used to indicate a single bond. Molecules with multiple functional groups that are the same may be expressed in the following way: (CH3)3CH. However. this implies a different structure from other molecules that can be formed using the same atoms (isomers). The formula (CH3)3CH implies a chain of three carbon atoms, with the middle carbon atom bonded to another carbon:<br> C-C-C<br>     |<br>    C<br> and the remaining bonds on the carbons all leading to hydrogen atoms. However, the same number of atoms (10 hydrogens and 4 carbons, or C4H10) may be used to make a straight chain: CH3CH2CH2CH3. The alkene 2-butene has two isomers which the chemical formula CH3CH=CHCH3 does not identify. The relative position of the two methyl groups must be indicated by additional notation denoting whether the methyl groups are on the same side of the double bond ("cis" or "Z") or on the opposite size from each other ("trans" or "E"). Polymers. For polymers, parentheses are placed around the repeating unit. For example, a hydrocarbon molecule that is described as: CH3(CH2)50CH3, is a molecule with 50 repeating units. If the number of repeating units is unknown or variable, the letter "n" may be used to indicate this: CH3(CH2)"n"CH3.<br> Ions<br> For ions, the charge on a particular atom may be denoted with a right-hand superscript. For example Na+, or Cu2+. The total charge on a molecule may also be shown in this way. For example H3O+ Isotopes. Although isotopes are more relevant to nuclear chemistry than to conventional chemistry, different isotopes may also be indicated as a left-hand superscript in a chemical formula. For example, the radioactive phosphate ion is 32PO4-.
836
General Chemistry/Gases, liquids and solids each have specific physical characteristics. In the physical sciences, a phase is a set of states of a macroscopic physical system that have relatively uniform chemical composition and physical properties (i.e. density, crystal structure, index of refraction, and so forth.) The most familiar examples of phases are solids, liquids, and gases. Less familiar phases include plasmas, Bose-Einstein condensates and fermionic condensates and the paramagnetic and ferromagnetic phases of magnetic materials. Phases are sometimes called states of matter, but this term can lead to confusion with thermodynamic states. For example, two gases maintained at different pressures are in different thermodynamic states, but the same "state of matter". Definitions. Although phases are conceptually simple, they are hard to define precisely. A good definition of a phase of a system is a region in the parameter space of the system's thermodynamic variables in which the free energy is analytic. Equivalently, two states of a system are in the same phase if they can be transformed into each other without abrupt changes in any of their thermodynamic properties. All the thermodynamic properties of a system—the entropy, heat capacity, magnetization, compressibility, and so forth—may be expressed in terms of the free energy and its derivatives. For example, the entropy is simply the first derivative of the free energy with temperature. As long as the free energy remains analytic, all the thermodynamic properties will be well-behaved. When a system goes from one phase to another, there will generally be a stage where the free energy is non-analytic. This is known as a phase transition. Familiar examples of phase transitions are melting (solid to liquid), freezing (liquid to solid), boiling (liquid to gas), and condensation (gas to liquid). Due to this non-analyticity, the free energies on either side of the transition are two different functions, so one or more thermodynamic properties will behave very differently after the transition. The property most commonly examined in this context is the heat capacity. During a transition, the heat capacity may become infinite, jump abruptly to a different value, or exhibit a "kink" or discontinuity in its derivative. <br> "Possible graphs of heat capacity (C) against temperature (T) at a phase transition." In practice, each type of phase is distinguished by a handful of relevant thermodynamic properties. For example, the distinguishing feature of a solid is its rigidity; unlike a liquid or a gas, a solid does not easily change its shape. Liquids are distinct from gases because they have much lower compressibility: a gas placed in a large container expands to fill the container, whereas a liquid forms a puddle in the bottom of the container. Not all the properties of solids, liquids, and gases are distinct; for example, it is not useful to compare their magnetic properties. On the other hand, the ferromagnetic phase of a magnetic material is distinguished from the paramagnetic phase by the presence of bulk magnetization without an applied magnetic field. Emergence and universality. Phases are emergent phenomena produced by the self-organization of a macroscopic number of particles. Typical samples of matter, for example, contain around 1023 particles (Avogadro's number). In systems that are too small—even, say, a thousand atoms—the distinction between phases disappears, since the appearance of non-analyticity in the free energy requires a huge, formally infinite, number of particles to be present. One might ask why real systems exhibit phases, since they are not actually infinite. The reason is that real systems contain thermodynamic fluctuations. When a system is far from a phase transition, these fluctuations are unimportant, but as it approaches a phase transition, the fluctuations begin to grow in size (i.e. spatial extent). At the ideal transition point, their size would be infinite, but before that can happen the fluctuations will have become as large as the system itself. In this regime, "finite-size" effects come into play, and we are unable to accurately predict the behavior of the system. Thus, phases in a real system are only well-defined away from phase transitions, and how far away it needs to be is dependent on the size of the system. There is a corollary to the emergent nature of phase phenomena, known as the principle of universality. The properties of phases are largely independent of the underlying microscopic physics, so that the same types of phases arise in a wide variety of systems. This is a familiar fact of life. We know, for example, that the property that defines a solid—resistance to deformation—is exhibited by materials as diverse as iron, ice, and Silly Putty. The only differences are matters of scale. Iron may resist deformation more strongly than Silly Putty, but both maintain their shape if the applied forces are not too strong. Phase diagrams. The different phases of a system may be represented using a phase diagram. The axes of the diagrams are the relevant thermodynamic variables. For simple mechanical systems, we generally use the pressure and temperature. The following figure shows a phase diagram for a typical material exhibiting solid, liquid and gaseous phases. <br> "A typical phase diagram." The markings on the phase diagram show the points where the free energy is non-analytic. The open spaces, where the free energy is analytic, correspond to the phases. The phases are separated by lines of non-analyticity, where phase transitions occur, which are called phase boundaries. In the above diagram, the phase boundary between liquid and gas does not continue indefinitely. Instead, it terminates at a point on the phase diagram called the critical point. This reflects the fact that, at extremely high temperatures and pressures, the liquid and gaseous phases become indistinguishable. In water, the critical point occurs at around 647 K (374 °C or 705 °F) and 22.064 MPa. The existence of the liquid-gas critical point reveals a slight ambiguity in our above definitions. When going from the liquid to the gaseous phase, one usually crosses the phase boundary, but it is possible to choose a path that never crosses the boundary by going to the right of the critical point. Thus, phases can sometimes blend continuously into each other. We should note, however, that this does not always happen. For example, it is impossible for the solid-liquid phase boundary to end in a critical point in the same way as the liquid-gas boundary, because the solid and liquid phases have different symmetry. An interesting thing to note is that the solid-liquid phase boundary in the phase diagram of most substances, such as the one shown above, has a positive slope. This is due to the solid phase having a higher density than the liquid, so that increasing the pressure increases the melting temperature. However, in the phase diagram for water the solid-liquid phase boundary has a negative slope. This reflects the fact that ice has a lower density than water, which is an unusual property for a material. Polymorphism. Many substances can exist in a variety of solid phases each corresponding to a unique crystal structure. These varying crystal phases of the same substance are called polymorphs. Diamond and graphite are examples of polymorphs of carbon. Graphite is composed of layers of hexagonally arranged carbon atoms, in which each carbon atom is strongly bound to three neighboring atoms in the same layer and is weakly bound to atoms in the neighboring layers. By contrast in diamond each carbon atom is strongly bound to four neighboring carbon atoms in a cubic array. The unique crystal structures of graphite and diamond are responsible for the vastly different properties of these two materials. Each polymorph of a given substance is usually only stable over a specific range of conditions. For example, diamond is only stable at extremely high pressures. Graphite is the stable form of carbon at normal atmospheric pressures. Although diamond is not stable at atmospheric pressures and should transform to graphite, we know that diamonds exist at these pressures. This is because at normal temperatures the transformation from diamond to graphite is extremely slow. If we were to heat the diamond, the rate of transformation would increase and the diamond would become graphite. However, at normal temperatures the diamond can persist for a very long time. Non-equilibrium phases like diamond that exist for long periods of time are said to be metastable. Another important example of metastable polymorphs occurs during the processing of steel. Steels are often subjected to a variety of thermal treatments designed to produce various combinations of stable and metastable iron phases. In this way the steel properties, such as hardness and strength can be adjusted by controlling the relative amounts and crystal sizes of the various phases that form. Phase separation. Different parts of a system may exist in different phases, in which case the phases are usually separated by boundary surfaces. Gibbs' phase rule describes the number of phases that can be present at equilibrium for a given system at various conditions. The phase rule indicates that for a single component system at most three phases (usually gas, liquid and solid) can co-exist in equilibrium. The three phases can all co-exist only at a single specific temperature and pressure, characteristic of the material, called the triple point. The conditions where two phases become indistinguishable is called a critical point. The phase rule also indicates that two phases can only co-exist at equilibrium for specific combinations of temperature and pressure. For example for a liquid-gas system if the vapor pressure is lower than that corresponding to the temperature, the system will not be at equilibrium, rather the liquid will tend to evaporate until the vapor pressure reaches the appropriate level or all of the liquid is consumed. Likewise, if the vapor pressure is too great for the given temperature condensation will occur. For the case of multi-component systems the phase rule indicates that additional phases are possible. A common example of this occurs in mixtures of mutually insoluble substances such as water and oil. If a few drops of oil are poured into pure water, there will be a small amount of intermixing, but there will be two distinct phases: one primarily oil and the other primarily water. The exact composition of the phases will be a function of the temperature and pressure but not a function of the amount of oil. It may be possible to change the temperature such that one of the phases disappears: for example, if the mixture is heated, it is possible that at some temperature, all of the oil is dissolved in the water. Above this temperature there is only one phase, and the composition of the phase "does" depend on how much oil was put in. Phase separation can also exist in two dimensions. The boundaries between phases, the surfaces of materials, and the grain boundaries between different crystallographic orientations of a single material can also show distinct phases. For example, surface reconstructions on metal and semiconductor surfaces are two dimensional phases. Gas. A gas is one of the phases of matter. Gases are, like liquids, fluids: they have the ability to flow and do not resist deformation. Unlike liquids, however, unconstrained gases do not occupy a fixed volume, but instead expand to fill whatever space they occupy. The kinetic energy in a gas is the greatest of the states of matter. Because of this increased kinetic energy, gas atoms and molecules tend to bounce off of one another, more so as the kinetic energy is increased. Liquid. One of the four phases of matter, a liquid is a fluid whose volume is fixed under conditions of constant temperature and pressure; and, whose shape is usually determined by the container it fills. Liquids tend to pull themselves together into droplets due to surface tension. The kinetic energy in a liquid is greater than that of a solid, but less than that of a gas. A liquids atoms/molecules are "slippery"; that is, they slide over one another, allowing the liquid to flow. If a liquid is at rest in a uniform gravitational field, the pressure formula_1 at any point is given by where formula_3 is the density of the liquid (assumed constant) and formula_4 is the depth of the point below the surface. Note that this formula assumes that the pressure at the free surface is zero. It should be noted that glass at normal temperatures is "not" a "supercooled liquid", but a solid. See the article on glass for more details. Solid. A solid is a state of matter, characterized by a definite volume and a definite shape (i.e. it resists deformation). Within a solid, atoms/molecules are relatively close together, or "rigid"; however, this does not prevent the solid from becoming deformed or compressed. In the solid phase of matter, atoms have a spatial ordering; because all matter has some kinetic energy, the atoms in even the most rigid solid move slightly, but this movement is "invisible". Physicists call the study of solids solid state physics. This includes semiconductors and superconductivity. Solid state physics is a type of condensed matter physics. Materials science is primarily concerned with properties of solids such as strength and phase transformations. It overlaps strongly with solid state physics. Solid state chemistry overlaps both of these fields, but is especially concerned with the synthesis of novel materials.
2,976
Statistics/Different Types of Data/PS. Statistical data can be obtained from two sources primary or secondary. Primary Data. Primary data means original data that has been collected specially for the purpose in mind. It means someone collected the data from the original source first hand. Data collected this way is called primary data. The people who gather primary data may be an authorized organization, investigator, enumerator or they may be just someone with a clipboard. Those who gather primary data may have knowledge of the study and may be motivated to make the study a success. These people are acting as a witness so primary data is only considered as reliable as the people who gathered it. "Research where one gathers this kind of data is referred to as field research". For example: your own questionnaire. Secondary Data. Secondary data is data that has been collected for another purpose. When we use Statistical Method with Primary Data from another purpose for our purpose we refer to it as Secondary Data. It means that one purpose's Primary Data is another purpose's Secondary Data. Secondary data is data that is being reused. Usually in a different context. "Research where one gathers this kind of data is referred to as desk research". For example: data from a book. Why Classify Data This Way? Knowing how the data was collected allows critics of a study to search for bias in how it was conducted. A good study will welcome such scrutiny. Each type has its own weaknesses and strengths. Primary Data is gathered by people who can focus directly on the purpose in mind. This helps ensure that questions are meaningful to the purpose but can introduce bias in those same questions. Secondary Data doesn't have the privilege of this focus but is only susceptible to bias introduced in the choice of what data to reuse. Stated another way, those who gather Secondary Data get to pick the questions. Those who gather Primary Data get to write the questions. « Sources of Data | Statistics | » Qualitative and Quantitative
436
Statistics/Different Types of Data/Quantitative and Qualitative Data. Qualitative data. Qualitative data is a categorical measurement expressed not in terms of numbers, but rather by means of a natural language description. In statistics, it is often used interchangeably with "categorical" data. For example: favorite color = "blue" height = "tall" i hated the most = "zen" Although we may have categories, the categories may have a structure to them. When there is not a natural ordering of the categories, we call these nominal categories. Examples might be gender, race, religion, or sport. When the categories may be ordered, these are called ordinal variables. Categorical variables that judge size (small, medium, large, etc.) are ordinal variables. Attitudes (strongly disagree, disagree, neutral, agree, strongly agree) are also ordinal variables, however we may not know which value is the best or worst of these issues. Note that the distance between these categories is not something we can measure. Quantitative data. Quantitative data is a numerical measurement expressed not by means of a natural language description, but rather in terms of numbers. However, not all numbers are continuous and measurable. For example, the social security number is a number, but not something that one can add or subtract. For example: molecule length = "450 nm" height = "1.8 m" Quantitative data always are associated with a scale measure. Probably the most common scale type is the ratio-scale. Observations of this type are on a scale that has a meaningful zero value but also have an equidistant measure (i.e., the difference between 10 and 20 is the same as the difference between 100 and 110). For example, a 10 year-old girl is twice as old as a 5 year-old girl. Since you can measure zero years, time is a ratio-scale variable. Money is another common ratio-scale quantitative measure. Observations that you count are usually ratio-scale (e.g., number of widgets).
466
Invertebrate Zoology/Arthropods. Introduction to the Arthropods. Arthropods (Phylum Arthropoda) constitute the largest phylum of animals, and include the insects, arachnids (e.g., mites, ticks, spiders), crustaceans (crabs, lobsters, shrimp), and other similar creatures. Between 75 and 80% of all organisms on planet Earth are arthropods—over a million modern species are known, and the fossil record reaches back to the early . However, species in the world's tropical forests remain largely undiscovered; Thomas (1990) estimated that perhaps 6 to 9 million species are yet to be discovered in this environment alone. Arthropods are common in all environments, and include symbiotic and parasitic forms. They range in size from microscopic plankton (~0.25 mm) up to forms several metres long.its class insecta bear almost 1.4-1.5 million species. Because this group is so large, we will devote the next several chapters to the various subgroups: the subphyla and classes of arthropods. The Trilobites. Because of the hard exoskeleton, arthropods tend to make excellent fossils. A particularly large group of arthropods known as trilobites are known only from the fossil record: flourishing in Cambrian seas and into the lower Palaeozoic. The last of the triliobites disappeared at the end of the Permian.
366
Wikimedia/The History of Wikibooks/Growing Wikibooks. Until this page is expanded, see Wikipedia's treatment of the subject. Here's a problem: it's one thing to write encyclopedia articles collaboratively. They are usually on specific, narrowly-focused topics, and it is clear what they require. Books, and even textbooks, by contrast, are very personal. There are thousands of ways to write an English composition textbook, or a textbook on C programming, or on physics. (That's why there "are" thousands of such textbooks.) What reason is there to think that any sufficiently knowledgeable person will want to put in the many, many hours required to write a textbook when he or she has to collaborate with others who do not share his or her understanding of what the book should look like? What would motivate anyone capable of developing a good textbook to do so with random strangers instead of either by him- or herself, or with trusted colleagues? An answer: A Wikibook probably shouldn't expect to follow the traditional model of motivating a single author or two to write an entire book. It seems more practical for multiple authors to supply various modules while one or two editors massage the overall book into a consistent style. That way there's not too much load on any one person's shoulders. "3 October 2005:" A missing concept: I've been perusing the various Wikimedia projects looking for a suitable forum to collaborate on the creation of new knowledge. The Wikipedia clearly is inappropriate - it addresses that which is history or known to be true. Wikisource explicitly excludes original works of authorship. Wikibooks seems to confine itself to the narrow concept of a textbook, and the answer to the objection raised above implies the persona of the creator of a body of knowledge or work of authorship, or at least the explication of a body of knowledge, is unimportant. Wikisource, in contrast acknowledges this importance, and embraces the concept of "completion" by locking pages once typography and formatting are correct. "Creation of new knowledge is happening at , the Metaweb, the original wiki, and many other wiki." I submit that the concept of a book embraces more than the greater depth and breadth of content when compared to an encyclopedia. A book is an expression of a personal perception of truth or the union of a limited number of such personal perceptions, and the persona(e) of the author(s) is part and parcel of that expression. You can not anonymize Shakespeare, or Einstein, or Hemingway, or Dylan Thomas, or Buckminster Fuller, or any of the other well known and seminal historical contributors to human knowledge and culture. Why then should future contributors be clothed in gray uniforms and anonymous faces? Is such anonymity even possible in an original work? With books, there is such a thing as saying "there, now it is done, complete". Some single individual must have the authority to say it. "I was under the impression that some very significant contributions were made anonymously -- such as the . I think that wiki allows people to contribute anonymously, if they should so choose, and also allows people to put their name on the book as one of its editors." "I would like to point out that the books of the Bible, the Iliad and the Odyssey, Gilgamesh, the Vedas, and many other works far superior to Shakespeare or Hemingway are anonymous." Wikibooks clearly does not provide such a tool, so I will suggest here what might be done to improve Wikibooks, or perhaps establish a new wiki project to address the needs. To begin with I give a simple list of requirements for me to participate: 1) Copy left is essential - I have no interest in conventional publishers, or proprietary exclusion of readers. "Wikibooks has this -- check." 2) A project format, where the initiator of a book is the principal Author/Editor/Administrator of that book. "I think there are already several Wikibooks that each have one person who declares himself the principle editor of that book." 3) A tiered editing environment: a) the first tier is a traditional wiki - this facilitates contributions by geographically scattered authors - a meeting place. b) the second tier is by invitation of the principal author - this allows the principal author to "edit" the contributors - excluding cranks and people with an incompatible approach. No harm is done - they can become principal author of another book derived from the first tier as a starting point. Tier 2 is not locked, but is protected by the principal author and his or her selected cadre of collaborators. c) the third tier is a complete book - locked against modification, but subject to peer review, which may include those who had been excluded from contributing by the principal author. Peer review provides a markup mechanism for the benefit of the principal author. The principal author may incorporate or disregard markups at his or her discretion. d) the fourth tier is release of the complete book combined with a wikireview mechanism, permitting readers to evaluate and rank what they read, so future readers may easily cull their selections. The released book, like Wikisource, is locked. "While we all agree that this intellectually sounds like it should work, Wikipedia already tried a tiered editing environment () -- and it didn't work. While I certainly am in favor of improving Wikibooks, "it sounds like it would work better" is irrelevant in the face of experimental evidence that it actually works worse. -- 20:28, 25 October 2005 (UTC)" 4) I like to read in comfortable quiet places. To facilitate this, I download PDFs and read offline. A true wiki book would have considerable length, and would be available for download for the convenience of the reader. This, together with the originality of the works, makes the medium akin to a bookstore - an amalgam of a copy left publisher and a bookseller, where the price is always zero. "Wikibooks already support this point 4. For example, all the various modules of the "Computer_Science:Algorithms" book: moved to the "Algorithms" book are all gathered together (using transclusion) into one long book at http://en.wikibooks.org/wiki/Computer_Science:Algorithms:Full_Text : moved to "Algorithms/Print version" ." (That page is broken.) What I am proposing is not radical - it is the essential environment of an academic collaboration. It differs in that it is unencumbered by the necessity of signing away ones ownership rights, and, more significantly, in that it provides a means for people with common interests, who have never met, and who might never be able to meet, to productively collaborate, while excluding unwanted interference. "4 October 2005:" In addition to making some minor clarifications and correcting some typographical errors in the above text, I wish to address a few additional issues which occurred to me overnight (the URL of this contribution is different, because I am on a different machine - I am, however, the author of the 3 October text). Wikiversity: While I am aware that the formation of Wikiversity is nascent, and necessarily incompletely formed, it is interesting to me to note that the defining characteristics of Wikiversity are at present a caricature of the essential purpose of a university, namely the pursuit of truth. This necessarily begins with the study of what is already known, which may be accomplished in a rudimentary fashion merely by reading in an encyclopedia, for example the Wikipedia. It does not take long for this approach to become inadequate, and so we have textbooks, which serve as more focussed guides to those seeking understanding. Wikibooks was apparently created to address this need. But anyone serious about learning soon discovers textbooks are at best so much more wastepaper - glib, incomplete, and often misleading if not downright wrong. So it is that the scholar inevitably takes his mission to a library, seeking a diversity of perspectives from a diversity of authors, in order to form his or her own perception of the truth. Wikisource does not qualify as a library because it excludes new works, and has no mechanism for including access to copyrighted material. An eventuality that happens sooner for some than others, is that even the library is inadequate, and so the scholar strikes out on his or her own, expressing new ideas in scholarly journals (all of which are encumbered by onerous copyright restrictions), or book length original works of authorship. Much of the current activity in developing Wikiversity seems to be concerned with testing, grading, and certification. All of these activities are irrelevant to the pursuit of truth, designed primarily to serve as barriers to encumber those who merely seek power. History has show us that these barriers have mixed effectiveness. To emulate such nonsense in the comparatively level playing field of the web strikes me as misguided at best. Neutral POV: While neutral POV is admirable for an encyclopedia entry, it is inappropriate for a book. A book is a focussed and elaborate expression of a point of view. In areas such as mathematics or science, that point of view is not necessarily an opinion. More often, it is a logical edifice, founded upon a small set of axioms or empirical data, which may be arbitrarily chosen. It is an elaboration of an abstraction of the author's experience and understanding. Requiring such an expression to be neutral undermines the purpose of pedagogy (the apparent purpose of a textbook), and utterly defeats the purpose of original authorship. Free Access: The historical case of Oliver Heaviside serves as a good example of how an improved wikibooks might shine. Heaviside was an uneducated outsider, whose original works were only able to find publication in serial form in a commercial magazine called "The Electrician". Heaviside's contributions to electrical engineering and mathematics were seminal and are now universally accepted. Is it not one of the fundamental purposes of Wikimedia to provide every human being with access to information, without exclusion? Isn't part of the philosophy of the wiki to enable every human to participate, without undue barriers, and to allow the readership to determine what endures? How many Oliver Heavisides have been crushed into obscurity by exclusionary policies? Do not the uniform policies of Wikimedia excluding original works in all of its venues constitute an exclusionary policy? Vanity, Personal Autonomy, and Personal Responsibility: An immediate objection to the ideas I am proposing will no doubt be the policy against vanity. It is agreed that vanity is an offensive human quality, but the issue of authorship is deeper than that. At the root of it are the founding concepts of a wiki: personal autonomy and personal responsibility. It is personal autonomy that gives the wiki its power - everyone is equally accepted without undue suppression of contributions. But it is personal responsibility that holds autonomy in check - the perpetration of vandalism for example is limited to those few individuals who do not yet understand they are responsible for what they do. Were it not so, the problem of vandalism would be intractable. Authorship, and its formal acknowledgment is nothing more than an abstraction of responsibility. If you write a book length tract of text, you are, for better or worse, responsible for it. It is authorship which holds you accountable, and such accountability is not vanity, for it is a sword which can cut both ways.
2,608
Myers-Briggs Type Indicator/Traditionalist. The Guardians is another name for ../Sensing/ Judgers. There are four personality types that fall into this category: ../ESTJ/, ../ESFJ/, ../ISTJ/, and ../ISFJ/. Personality. This type is conservative and hardworking, values responsibility and service to others, is serious, trustworthy, and diligent, focused on duty and getting the job done, adheres to traditional values and dress, and is slow to accept new ideas. The SJ has a strict idea of how things should be done and frowns on deviation from it. Profession. SJs make up the greatest part of the management of business organizations. Their attention to detail and preference to make decisions quickly lend well to the structure of larger organizations. Communication. Guardians are polite and straightforward, respectful and more formal than the other temperaments. They talk in an unadorned way and include facts and precise details rather than generalizations. Appearance. SJs dress neatly and conservatively but don't focus on current trends. They tend to have good posture and walk briskly. Hobbies. Handcrafts, collecting things (especially antiques), volunteerism, sports, jogging, and participation in service organizations.
292
Myers-Briggs Type Indicator/Experiencer. The "Artisan" is another name for the ../Sensing/ Perceiver. This includes the four types ../ESTP/, ../ESFP/, ../ISTP/, ../ISFP/. About 30% of people are classified as Artisans. Barbra Streisand, Elvis Presley, Franklin Roosevelt, and Clint Eastwood are all examples of Artisans. Personality. The Artisan is typically quite playful, tends to live in the moment, have fun, get along easily with people, and be carefree and easy-going. He/She is impulsive and seeks the next experience or adventure. This person does not spend much time planning or philosophizing, preferring to take spontaneous action. He/She can gravitate toward risky activities. They love keeping their friends happy and will often challenge them to contests of skill such as video games or physical challenges, "Race you to the playground!". Profession. They are the artists of the society, the performers. Artisans tend to dislike too many rules and gravitate towards hands-on professions and hobbies involving tools or crafts. Communication. Their speaking style is simple and concrete. They don't use many methaphors and like to gesticulate. Body language expresses more. Appearance. SPs tend to dress casually and in sporty apparel. As sensors, SPs are aware of the colors and textures of their clothes but sometimes may appear messy. Some SPs love to feel good-looking and stylish, but still comfortable. Hobbies. Working on cars, extreme sports, woodworking and gardening are common SP hobbies. SPs may also like painting, music and the fine arts if they have an artistic streak.
405
Myers-Briggs Type Indicator/Idealist. The Idealist is the same as the ../Intuitive Feeler and includes the following four personality types: ../ENFJ/, ../ENFP/, ../INFJ/, and ../INFP/. Idealists are one of the rarest types of personality, the other being the Rationals. Famous Idealists include Princess Diana, Eleanor Roosevelt, Mohandas Gandhi, and Mikhael Gorbachev. Personality. Idealists are the Diplomats. They spend their whole lives searching for their unique identity. The idealist prefers to think abstractly about the future and how issues will affect the people around them. They are more focused on the intangibles than the nitty-gritty of daily life, so they may appear detached or in another world. Unfortunately for the idealist, gracefulness and body awareness are not their natural gift and they are more likely than not to be less adept at sports or other activities that require high body awareness. If an idealist is skilled at sports it is most likely to be from training rather than natural ability. They are often dreamers and crave for a better world, which can also make them quite invested in philosophical or political questions. They often possess social grace and charisma, as well as the ability to inspire those around them, but also can appear overly sensitive and dreamy to others. They generally possess a talent for verbal expression and are also often artistically inclined, even though they focus more on the abstracts forms of art than tangible ones. They have often passions for writing, poetry, music or humanitarian sciences like social studies and philosophy. They often have a strong, idealistic sense of values which at times clashes with those around them and tend to be advocates for social justice and care for those less well off than themselves. At their worst they can be manipulative and self righteous, believing themselves to know better than those around them. If healthy they also can be quite self aware and are good at determining the motives of themselves and those around them. Profession. NFs flee from corporate management and gravitate towards helping professions where they can contribute to society and humanity, such as teaching, counseling, politics, and the clergy. Their individualism could lead to careers that focus on personal growth and development, and journalistic work that appeals to their idealism and truth-seeking. Communication. NFs are generally good communicators. Idealists can be indirect in speech and use metaphors or analogies to make points. Rather than talking about things in an objective way, they key in more to the reactions that people have to what they are saying and how the topics relate to their own feelings and values. They talk about relationships, values, and intangibles. Appearance. The iNtuitive in the idealist makes him less fixed on personal appearance. NFs are unconventional and at times even artsy, and wear clothing that communicates their values, which may lead them to appear more like hippies than court-ready lawyers. If a Judger, the NF will take more care of his appearance than if a Perceiver. Hobbies. Travel, reading, music, cinema, poetry, History, Philosophy, Literature, Art History, art appreciation, photography, television and Internet surfing.
734
Myers-Briggs Type Indicator/Conceptualizer. The Rational is another name for the ../Intuitive/ ../Thinking/. This includes four personality types: the ../ENTJ/, ../ENTP/, ../INTJ/, and ../INTP/. About 15% of the population are Rationals. Some of the most famous Rationals were Marie Curie, Albert Einstein, and Dwight D. Eisenhower. Personality. The Rational is more comfortable thinking in the abstract, doing so in an analytical, objective way. As an iNtuitive, the NT is not particularly given to sports. Profession. This temperament is the quintessential professor, living in academia and in his or her own deep thoughts about something or other. Communication. The Rational tends to be roundabout in explanations and may not be very aware of how others feel. Appearance. This temperament often ignores rules of fashion, having more important things to concern themselves with, preferring function over all else. It is not uncommon for a Perceiving NT to neglect personal hygiene. Many Perceivers will not hesitate to walk around naked. If a Judger, the NT will take more care of his or her appearance. A number of Judgers tend to have an asexual look. Hobbies. Studying self-improvement, learning about new things or languages...
318
German/Answers 1. Lektion 1 Antworten. < Return to "Lektion 1" Lektion 2 Antworten. < Return to "Lektion 2" Lektion 3 Antworten. < Return to "Lektion 3" Lektion 4 Antworten. < Return to "Lektion4" Wiederholung Antworten. < Return to "Wiederholung"
119
Portuguese. Ir à página principal(Go to the main page)
15
Portuguese/Contents. Portuguese Wikibook. Welcome to the Portuguese language Wikibook. Here you can learn the different parts to the Portuguese language through our grammar references and our course. Why not start with the feature word? Previous knowledge on a closely-related languages (Romance languages—occasionally called the Latin languages or, less often, the Romanic or Neo-Latin languages) like Catalan, French, Italian and Spanish might make studying Portuguese much easier. There are several differences among the three main dialects of Portuguese: as it is spoken in Portugal (European Portuguese), as it is spoken in Brazil (Brazilian Portuguese), and as it is spoken in Africa (African Portuguese). While their written forms are very similar, there are some differences in the spoken language (both in phonology and syntax) that are specific to each of them. Galician, which is a language spoken in Galicia, is not a Portuguese dialect, as sometimes it is stated, but Galician and Portuguese can be seen as two dialects of the same language - Galician-Portuguese). Brazilian and African Portuguese show a great influence in their vocabulary from aboriginal languages and Bantu languages which are not present in European Portuguese. Their phonology is more similar to older European Portuguese variants. Brazilian Portuguese also has several unique Americanisms. Courses for Portuguese spoken in Portugal. Level One - Beginners <br> Eight lessons for the absolute beginner. <br> Level Two - Intermediate <br> Continuation from the beginner course. A guide to Portuguese pronunciation Courses for Portuguese spoken in Brazil. See also an alternative course in Brazilian Portuguese. Planning Introduction <br>Introduction to the language. <br> Level One - Beginners <br>Ten lessons for the absolute beginner. <br> Level Two - Intermediate <br>Continuation from the beginner course. A guide to Portuguese pronunciation
460
Portuguese/Contents/Personal Pronouns of Subject. « Portuguese:Contents The Portuguese language contains pronouns for I, you (formerly thou), he, she, we, you and they. There is no "it" because Portuguese has no neuter gender, and instead an ungendered thing will be considered either masculine or feminine, depending on the gender of the word (keep in mind that gender in this case doesn't actually mean "men" or "women", it's just the name used for the noun classes of Portuguese. For example, the word for table: "mesa", is feminine, but it's not actually seen as a female or as "girly", it's just a naming convention). The pronouns. Official forms: Pronouns of "treatment": Always conjugated in the third person singular, these are employed to refer to someone in a more formal fashion, or to speak to someone with a specific title (can also be used as honorifics). A list of common ones: 'Colloquial forms:' As you can see, there is sometimes more than one pronoun in Portuguese for the equivalent English word. The reason for this is to show both the "gender" and the "level of formality" that you wish to use to address the other person. I & we. To say "I", you simply say "eu". To say "we", you say "nós" (in Brazil you might say "a gente" or "nois" in an informal setting). These words don't reflect gender alone but the words that accompany them (such as adjectives) still take into account the gender of the speaker/group. You. When you say "you" in Portuguese to an individual, you must show the level of formality that is appropriate to that person. By saying "tu", you are addressing that person informally, in the way you'd talk with a friend. When you use "você", you are speaking in a more formal way. Again, these words don't carry any gender themselves but those that follow them agree with the gender of whoever is being spoken to. When talking to a group of people, "vocês" is commonly used. At one point, "vós" was used as a formal plural "you", but it is now obsolete, although still heard in the north of Portugal. Only people who use an extremely erudite way of speaking use this pronoun. In some dialects, mainly in Brazil, "tu" is considered too odd for general use and "você" is almost always used instead for informal situations. He, she, & they. As in the English language, Portuguese has individual words for "he" ("ele") and "she" ("ela"). But unlike in English, Portuguese also has male and female words for "they". "Eles" is used for males, but can also be used when dealing with both a male and a female (or a large group involving both genders). However, "elas" is used only for female groups. Other forms of he, she, & they. When dealing with a formal situation or to an unknown person, "he", "she", and "they" can take on formal states. "O senhor" would replace "ele", and "a senhora" would replace "ela". For "they", "os senhores" replaces "eles" and "as senhoras" replaces "elas". These forms would usually be used with older people, parents and teachers.
785
German/Level III/Answers. "Markus Studiert" Antworten. < Return to ../Markus Studiert/ "Gespräche Unter Geschäftsmännern" Antworten. < Return to ../Gespräche Unter Geschäftsmännern/ "Mach Dir Keine Sorgen!" Antworten. < Return to ../Mach Dir Keine Sorgen!/
105
German/Level I/Wie heißt du. <br clear="all"> This lesson deals with basic conversation topics such as saying hello and goodbye and asking people how they are feeling. This lesson features audio recordings by native speakers to help you with the pronunciation. Dialogue. Read and listen to the following dialogue between two students: Franz and Greta. You don't have to understand anything! You should rather try to find out how each word is pronounced. Now try to understand the dialogue with the help of the following list of vocabulary. (A complete translation is given in the answers to the next problems.) Hellos and Goodbyes. There are many ways of saying hello and goodbye in German; some of them are: The more formal phrases are "guten Morgen", "guten Tag", and "auf Wiedersehen". The less formal ones are "tschüss", "Tag", "servus", and "ciao". The others are somewhat inbetween formal and informal. Mr. and Mrs.. In German, "Herr" and "Frau" are used instead of "Mr." and "Mrs." before a last name; e.g., "Mr. Schwarz" – "Herr Schwarz". "Frau" is used for married and unmarried women. Some people still use "Miss" – "Fräulein" in spoken German but it is no longer used in written German since it is considered an inappropriate discrimination of unmarried women. Literally, "der Herr" means "the gentleman" and "die Frau" means "the woman". If you use these words without a last name after them, you have to use an article before them; e.g., "der Herr" or "die Frau". This is actually just like in English. For example: Note also that the German translation of "the man" is "der Mann" and "the lady" should be translated to "die Dame". Thus, without last names you would rather use these pairs: Replies to "Wie geht's?". There are many ways to reply to the question "Wie geht's?" Here are some of them: After replying to the question, you could continue with: Or shorter: Test. The test consists of three parts: pronunciation, vocabulary, and translation. As always, you should write down your answers before you check them. (Writing the German words is in fact a great way to practice the spelling of German words.) The vocabulary and translation problems are all from English to German because this is what you have to learn if you want to communicate in German. Once you are able to translate an English word to the corresponding German word, it won't be any problem to translate the German word back to English.
622
Do-It-Yourself/Soap. Make soap from lard. Safety. Gloves, labcoat and appropriate eyeware should be worn when handling the 6M NaOH. It should be used in a well-ventilated area, preferably in a fume hood. DO NOT BREATHE THE FUMES. Wash with vinegar should you get some on your skin (have some vinegar handy before starting the experiment) -DO NOT wash with water!. Mixing lye with water results in a chemical reaction that creates extreme heat - hence, washing lye off your hands (for example) with water will only initiate that reaction on your hand, resulting in chemical burn.
155
Myers-Briggs Type Indicator/Introverting-Extroverting Feeling pattern. A way to quickly narrow down the possibilities of what a person's personality type is the method of Introverting / Extraverting Feeling analysis. Some types tend to Extravert emotion and the others tend to Introvert emotion. All of the types that end in FJ or TP tend to Extravert Feeling, while all of the types that end in FP or TJ tend to Introvert Feeling. Extraverted Feeling (and Introverted Thinking) Introverted Feeling (and Extraverted Thinking)
139
Russian/Possessive Pronouns. The 3rd person possessive pronouns (его́ his, её her, его́ its, их their) take the gender and the quantity of the possessing person/object: The above rule is common to both English and Russian languages and is opposite to the one in French. The reflexive pronouns (свой his/her/its own m., своя his/her/its own f., своё his/her/its own n., свои his/her/its own pl.), as well as all possessive nouns except the 3rd person ones take the gender and the quantity of the object in possession: This rule doesn't apply to English, but agrees with the use of 1st and 2nd person possessive pronouns in French.
180
Learning the vi Editor/Making your work easier. By now you should know the rudiments of using vi. However, to really make vi work for you, it may be helpful to know the following to make your work easier for you. More on commands. Say you are editing a document, and you wish to delete ten lines - as of now, the only way to do this is to enter dd ten times. Or if you want to delete seven characters exactly - you would have to enter x seven times. There must be a better way! Repetition. Fortunately, vi lets you augment most of the commands in case you want to repeat that command a certain number of times. This is done by typing in the number of times you want that command repeated, followed by the command. So, if you want to delete ten lines, you would type 10dd. Or if you want to delete seven characters, you would type 7x. You can also repeat the last action done by typing . (this is a single period keystroke), the single-repeat operation over the location you want to repeat the previous operation. So if you wanted to repeat the deletion of ten lines as in the previous example, you could repeatedly press . to perform this operation over and over again. Exercise. 1. Type the sentence Good morning Doctor, how are you today?. Delete "Good morning". 2. Now using the single-repeat operation, delete "how are". Motion. vi allows you greater flexibility over motion as well. There are a few commands to allow you to quickly jump around your document, such as : ^ acts in the following way, if the line was hello how are you and your cursor is on the u, if you would enter ^, the cursor would be upon the h. Furthermore, the / command allows you to jump directly to some pattern in the file. For example, if you're looking for the next occurrence of the word "pomegranate" in your text, if you hit /, then type in pomegranate (you need not enter insert mode) and hit enter, the cursor will jump to the next occurrence of the word, if it exists. If you want to search backwards, you would perform the same procedure, but use the ? command. To repeat either search, enter //, ??, or alternatively, type / or ? and hit Enter. You can also press n to jump to the next occurrence, and N to jump to the previous occurrence. Commands and motion. We know now that vi lets you enter a number to specify how many times to do something. Consider this example now: you want to delete everything after a certain point on a line - you could enter dw for each word from the cursor position to the end of the line, or hold down x, but these are cumbersome examples. vi thankfully lets you do something much faster. With certain commands, vi allows you to specify a position, using the methods in the previous sections. The position is specified after the command. For example, to delete up to the end of the line, you would enter d$. Other examples:
680
Internet Technologies/Telnet. Telnet is a protocol designed to remotely access computers in a client-server fashion. Telnet is inherently insecure, as the data passed from the client to the server or vice-versa is not encrypted. For connections through insecure networks (such as the Internet), SSH (Secured SHell), should be used so all communications between the client and server are encrypted. Examples. Test if the HTTP port is open and its service listening. telnet localhost 80 Send an email. telnet localhost 25 Trying 127.0.0.1... Connected to localhost.localdomain. Escape character is '^]'. 220 smtp.mydomain.com mail from:<[email protected]> 250 2.1.0 <[email protected]>... Sender ok rcpt to:<[email protected]> 250 2.1.5 <[email protected]>... Recipient ok data 354 Enter mail, end with "." on a line by itself Let's meet 250 2.0.0 n514OvkN019941 Message accepted for delivery quit 221 2.0.0 smtp.mydomain.com closing connection Connection closed by foreign host.
344
German/Lesson 11. Lektion 11 = Ein Treffen in Hannover (WIP)= Katja hat sich mit einem Freund, Markus, verabredet, den sie im Chat kennengelernt hat. Sie hat ein Foto von ihm gesehen, und vielleicht gefällt er ihr ja. Am "Kröpcke", der größten U-Bahnstation in Hannover, steigt sie aus der U-Bahn. Täglich betreten Hunderte von Menschen diese Station, Schüler, Studenten, Angestellte und Rentner. Sie ist 22, studiert seit 2 Jahren Tiermedizin in Hannover, und ist im Moment ledig. Sie geht auf die Rolltreppe, betritt die Stufen, und fährt zwei Stockwerke nach oben. Währenddessen schaut sie nach unten. Ihre U-Bahn hat die Station verlassen. Eine andere U-Bahn hat bereits gehalten, und die Fahrgäste sind aufgestanden und ausgestiegen. Sie kommt auf der zweiten Ebene an und geht weiter, Richtung Sonnenlicht, in die Pasarelle. Die Pasarelle führt Richtung Hauptbahnhof, und links und rechts locken die Schaufenster der Geschäfte. Nach einer Weile hat sie die Rolltreppe erreicht, die zum Hauptbahnhof führt. Nun sieht sie in voller Breite den Hauptbahnhof von Hannover, und davor einen Sockel mit einer Statue von einem Pferd mit Reiter. Dort hat Markus schon fünf Minuten gewartet und begrüßt sie, bevor sie sich ins Eiscafe nebenan setzen. Vokabeln. Katja Female first name Markus Male first name sich verabreden to make a date Chat Internet Chat kennenlernen to get to know someone kennengelernt Partizip Perfekt von kennenlernen das Foto Photographic Picture sehen to see gesehen Partizip Perfekt von "sehen" vielleicht perhaps gefallen to please someone (with dative) er gefällt ihr She likes him (he pleases her, literally) Kröpcke The name of Hanover's biggest subway station U-Bahn subway die größte greatest (feminine here) die Station the station aussteigen getting off (a train, investment etc.) täglich daily betreten to enter Hunderte hundreds diese female form of "this" der Schüler, die Schüler(pl) "pupil" (British engl.) der Student student der Angestellte Clerk der Rentner, die Rentner(pl) pensioner studieren to study im Moment currently ledig a person not having a partner gehen to go Rolltreppe escalator die Stufe stair fahren to drive (often specializing from engl. to travel towards) währenddessen "during this" schauen look ihre her (form for female possessions of a female person) verlassen to leave verlassen Partizip Perfekt von "verlassen" eine andere another (feminine object) bereits already der Fahrgast passenger die Fahrgäste passengers (pl) aufstehen to stand up aufgestanden Partizip Perfekt von "aufstehen" ausgestiegen Partizip Perfekt von "aussteigen" die Ebene level/plateau weitergehen to go on sie geht weiter she goes on das Sonnenlicht sunlight die Richtung direction Richtung Sonnenlicht towards sunlight die Passarelle passage way führen lead Hauptbahnhof central station (in most German cities this is in the city centre) Richtung Hauptbahnhof in direction of the central station links left rechts right locken tempt (not to confuse with "die Locken" = locks, curls!!) das Schaufenster display window die Schaufenster plural of "das Schaufenster" das Geschäft the shop die Geschäfte the shops der Geschäfte of the shops nach einer Weile After a while erreichen reach erreicht Partizip Perfekt von erreichen die zum Hauptbahnhof führt that leads to the central station Word Order. Inverted word order occurs under several circumstances, among which are: For interrogatives, a simple statement, "Du hast das Buch." becomes "Hast du das Buch?" when converting it to a question. The method is simply switching the verb and subject of the sentence. Time expressions, such as "Nach der Schule" prefacing a sentence cause inverted word order. The formula is "Time Expression", "Verb", "Subject" and "Rest of sentence." Practically applied, "Every day, I go to school" becomes "Jeden Tag gehe ich zur Schule." Subordinating conjunctions connect a dependent clause to an independent clause. Some subordinating conjunctions are: "dass" (that), "obwohl" (although), "seit" (since), "weil" (because), and "wenn" (if, when). The formula for a dependent clause is "subordinating conjunction" "subject" "rest of clause" "verb" and is offset from the independent clause by a comma. Here are some examples (the dependent clause is underlined): Ich kann das Buch nicht kaufen, weil ich kein Geld habe. Ich kaufe das Buch für dich, da du kein Geld hast. Wenn unsere Eltern uns besuchen, schenken sie uns Geschenke. "I can't buy the book because I have no money." "I am buying the book for you, as you have no money." "When our parents visit us, they give us presents."
1,382
Lucid Dreaming/Reality Checks/Hands. Presentation. With the hands reality check, you check if your hands are normal. Look at your hand or both hands and focus on them. Count the fingers in your head or out loud. They may have the wrong number of fingers, the number may change while you try to count them, the fingers can be deformed and keep on changing when you look at them. Your hands can be the wrong colour, or have other abnormalities. As well as doing this regularly, you could also do it every time you notice somebody using their hands. You could also mark your own hands to remind you to do this reality check (or another), for example by writing something in your palm, the back of your hand, or wrist (see also Reading).
167
Dichotomous Key/Arthropoda. 1. incomplete Branchiopoda<br> Remipedia<br> Cephalocarida<br> Maxillopoda<br> Ostracoda<br> Malacostraca 5. incomplete Chilopoda<br> Diplopoda<br> Pauropoda<br> Symphyla 6. incomplete Crustacea Chelicerata
145
Dichotomous Key/Carnivora. 7. Could be ../Mustelidae/, ../Ursidae/, ../Procyonidae/, or ../Canidae/. 8. Could be ../Felidae/, ../Herpestidae/, ../Viverridae/, or ../Nandiniidae/.
77
Portuguese/Contents/Irregular verbs. « Portuguese:Contents Irregular verbs are verbs that don't follow the normal pattern used in giving tense to verbs (as is the case with regular verbs). Instead, they have their own individual ways of adding tense. For instance, in English we would end most past tense verb usages with the letters ED ("work", "clean", and "thank" become "worked", "cleaned", and "thanked"). But with irregular verbs, we make much different changes to them ("see", "think", and "do", become "saw", "thought", and "did"). The Portuguese language has instances such as these, and we will explore them in this section. There are several levels of irregularity in Portuguese verbs. Most irregular of all are the so-called "anomalous" verbs, which are only two: ser and ir. These two verbs present "stem change" within the Present Indicative tense, which means that not all persons begin the same way: ser ir eu sou vou tu és vais você é vai ele/ela é vai nós somos vamos vós* sois ides vocês são vão eles/elas são vão Furthermore, curiously, in several tenses (the Perfect and Plus-quam-perfect Preterites Indicative, the Imperfect and Future Subjunctive) the conjugation is "exactly the same" for these two verbs: indicative subjunctive perfect plusquamperfect imperfect future eu fui fora fosse for tu foste foras fosses fores ele/ela foi fora fosse for nós fomos fôramos fôssemos formos vós fostes fôreis fôsseis fordes eles/elas foram foram fossem forem There is also stem change in the Present Subjunctive, but the stems remain the same for all persons and numbers and they differ in each verb: ser ir eu seja vá tu sejas vás ele/ela seja vá nós sejamos vamos vós sejais vades eles/elas sejam vão Tenses. The following are sections dedicated to the different tenses used for irregular verbs: Irregular verbs. Here is a list of the most common irregular verbs, along with their meanings (the links refer to the wiktionary project):
573
Portuguese/Contents/Regular verbs. « Portuguese:Contents Regular verbs are verbs that have a normal pattern used in giving tense to the verbs. This is as apposed to irregular verbs, which have their own individual ways of adding tense. Verb endings. Verbs in Portuguese end in 3 different suffixes. These suffixes are -ar, -er, and -ir. These suffixes determine how the verb's tenses are handled. Tenses. The following are sections dedicated to the different tenses used for regular verbs: Regular verbs. Here is a list of some common regular verbs, along with their meanings:
148
Puzzles/Riddles. Puzzles - Riddles<br> Generally, a riddle is a sort of puzzle in which one is asked a question and makes attempts to come to an answer. A riddle can be a puzzling question, a hypothetical problem to be solved, or what is often also referred to as a thought experiment. Often, posing riddles can be used for other purposes than puzzlement, like the famous hangman's riddles, as well as for argumentative or political ends, where the answer is not so much a mystery but is presented as though it were. There are many types of riddles depending on their structure, their format, and what methods of thinking they require to solve. Many riddles are tricky, in that they manipulate language or common thought processes to make the answer seem less clear, like garden path riddles. The largest category of riddles are identity riddles, in which a common object or other phenomenon is described, and the solution is to correctly identify what that common object is by naming it. This is often used in educational settings as well as children's learning rhymes.<br> Below are the some of the more commonly known puzzles in existence. The Riddle of the Sphinx. Perhaps one of the most famous or perhaps the most well known riddles are The Riddle of the Sphinx.<br> As humankind’s earliest puzzle, it is among the ten greatest of all time. This is the first known recorded puzzle in the human history that are coming out of from that very legend. <br> Legend has it that a similarly enormous sphinx guarded the entrance to the ancient city of Thebes. According to legend, when mythical Greek king Oedipus approached the city of Thebes, he encountered a gigantic sphinx ( a mythology beast with human face with the body of lion) guarding the entrance to the city. The menacing beast confronted the mythic king and posed the following riddle to him, warning that if he failed to answer it correctly, he would die instantly at the sphinx’s hands. <br> The Sphinx ask Oedipus: <br> codice_1 Oedipus , after thinking for the moments answered, <br> codice_2 <br> Upon hearing the correct answer, the astonished sphinx killed itself, and Oedipus entered Thebes as the hero for ridding the city of the terrible monster that had kept it captive for so long. The Riddle of the Sphinx is considered to be the prototype for all riddles. It is intentionally constructed to harbor a non-obvious answer:namely, that life’s three phases of infancy, adulthood,and old age are comparable, respectively, to the three phases of a day (morning, noon, and night). Its function in the Oedipus story, moreover, suggests that puzzles may have originated as tests of intelligence and thus as probes of human mentality. The Samson’s Marriage Riddle. The another examples are from the biblical story of Samson's Marriage Riddle. At his wedding feast, Samson, obviously wanting to impress the relatives of his wife-to-be, posed the following riddle to his Philistine guests. If they could given him answer to the riddles, he will gives them thirty linen garments and thirty sets of clothes and vice versa will happened if they couldn't answer. Judges 14:14<br> codice_3 Samson contrived his riddle to describe something that he once witnessed: A swarm of bees that made honey in a lion’s carcass. <br> Hence, the wording of the riddle: the “eater” =“swarm of bees”; “the strong” = the “lion”; and “came forth sweetness” =“made honey.” <br> The deceitful guests, however, took advantage of the seven days to coerce the answer from Samson’s wife. When they gave Samson the correct response, <br> Judge 14:18<br> codice_4 <br> The mighty biblical hero became enraged, returned his newly wed wives to her family members and declared war against all Philistines which will led to his eventual downfall. From this examples, yet again, we can see that the usage of riddles since the ancient time to test of one's intellect. The riddle of King Solomon and Queen Sheba. In this story of The riddle of King Solomon and Queen Sheba, the biblical Queen Sheba upon hearing the wisdom of King Solomon,pay a visit to the King himself and organize riddle contests simply for the pleasure of outwitting each other. <br> The Queen Sheba asked King Solomon the first riddle: <br> codice_5 <br> King Solomon answered: <br> codice_6 <br> Stunned by his answer, Queen Sheba asked him the second riddles: <br> codice_7 <br> Again King Solomon answered: <br> codice_8 (In the Hebrew literature story, Lot is daughter who became pregnant by their father,Haran and bore sons). <br> For the third riddle, Queen Sheba brought up 2 children who are of same facial feature, same height, same attire. She asked <br> codice_9 <br> King Solomon made a sign to his eunuchs, who brought him nuts and roasted ears of corn, which they scattered before the children. The males, who were not bashful, collected them and tied them within the hems of their garments. The girls, however, were bashful (since their bodies would be revealed if they were to tie their undergarments) and therefore tied them within their outer garments. Therefore, King Solomon commented: "These are the males, and these are the females" <br> Again dumbfounded by King Solomon wisdom, for the final riddles, she bought out a group of people circumcised and uncircumcised . Again, she riddled King Solomon codice_10 <br> King Solomon immediately made a sign to the High Priest to open the Ark of the Covenant.<br> Within moments of opening of the Ark, whose who were circumcised stood or bowed their bodies to half their height, while their countenances were filled with the radiance of the Shekhinah. The uncircumcised, however, fell on their faces. In this story, we could see that riddles is sometimes presented as a practical problem to be solved as seen in the last two of the riddles posed by Queen Sheba. Nursery Rhyme's: Old Mother Twitchett. In other cultures, such as in Western countries, we can find riddles in unexpected places such as children nursery rhymes. Here are one of the more popular ones: These are particular riddle disguised as nursery rhyme that sound like this: codice_11 <br> codice_12 <br> codice_13 <br> codice_14 <br> The answer is of course needle and thread
1,801
Myers-Briggs Type Indicator/QuickTyping. You can use the tools of the Myers-Briggs Type Indicator to quickly determine a person's personality type though a method called Speedreading. This process, developed by Paul D. Tieger and Barbara Barron-Tieger in The Art of Speedreading People, lets you use three basic tools to decipher clues in anyone's demeanor, whether your contact is in person, over the phone, or even on a chat line. The three tools are as follows:
120
Inorganic Chemistry/Transition metals. In the extended form of periodic table, the elements have been grouped into four blocks, the s, p, d, and f-blocks. The elements in groups 3-12 are called d-block or transition elements. The properties of these elements are unlike those of s-block and p-block elements. D-block elements represent a change or transition between the s- and p-block elements, hence why they are called transition elements. Previously transition elements were regarded as those which possessed partially filled penultimate d-subshell in their ground state or in one of their commonly occurring oxidation states. However the above definition doesn't cover the elements of group 12 i.e. Zinc metals(Zn,Cd and Hg) as these elements do not have partially filled (n-1)d-subshells in their ground state and neither too in their ionic state. However Zinc metals showing similarity with other transition metals were included in the transition metals. So forty elements belong to the transition metals family, 10 each in 3rd, 4th, 5th and 6th period. The transition elements include the most common elements used. These include iron, aluminium, titanium , which form the base of the construction and manufacturing industry, metals that are valued for their beauty i.e. gold, silver, and platinum and metals such as palladium, ruthenium and osmium which have catalytic properties. These contain the densest metals like osmium(d=22.49 gm cm-3), the metals with the highest and lowest melting points, tungsten(mpt. 3683K) and mercury(mpt. 234K). Certain transition metals are also important in living organisms. Iron, Fe, is present in the protein hemoglobin which is responsible for the transport of the oxygen in the living organisms. Cobalt, Co, present in vitamin B12 help in the metabolism of carbohydrates and fats in the human body. Copper and Zinc are important in biological catalysis. Cobalt, nickel, manganese, and molybednum are essential components of certain enzymes. Transition metals all share some general characteristics, they: Complexes. When ligands form co-ordinate bonds with transition metals ions a complex is formed. Common ligands are H2O and NH3. The transition metal ion acts as a Lewis Acid and the ligand acts as a Lewis base. The number of co-ordinate bonds in the complex is the co-ordination number of that complex. Example of complexes are the tetrachlorocobaltate(II) ion, [CoCl4]2- and the hexaqaua-iron(III) ion, [Fe(H2O)6]3+ Ligands. Ligands can be divided into three categories: unidentate, bidentate and multidentate. Unidentate ligands can form one co-ordinate bond with a central metal ion. Bidentate ligands can form two co-ordinate bonds with a central metal ion and so on. Another type of ligand is an ambidentate ligand. An ambidentate ligand contains two sites which can form a co-ordinate bond with a central metal ion, though they cannot both form a bond with the same metal ion at the same time. They can however simultaneously bond to separate ions creating a bridge between two complexes. Uses of Complexes & Ligands. EDTA. <br>Antidote<br> EDTA reacts with metal ions to produce stable EDTA complexes. It can therefore be used to remove poisonous metal ions such as lead and mercury from the bloodstream. The complexes are then excreted.<br> <br>Surgery<br> EDTA can remove calcium ions from bloodstream. The removal of these ions prevents the blood from clotting which is necessary during surgical procedures. <br><br>Water softener<br> EDTA can remove calcium ions from hard water, thereby softening it. This helps to prevent the formation of limescale. <br> Cisplatin. <br> Cisplatin [Pt(NH3)2Cl2] is a cytotoxic complex used during cancer treatment. It is usually used to treat ovarian, testicular, lung, bladder, gullet and stomach cancers. <br> Silver. <br> Tollen's reagent<br> When silver nitrate is dissolved in aqueous ammonia [Ag(NH3)2]+ is formed. More commonly known as Tollen's reagent this complex is used in the test to distinguish ketones from aldehydes. <br><br> Electroplating<br> When a silver salt is dissolved in aqueous Potassium (or sodium) cyanide the [Ag(CN)2] - is formed. The complex is used as the electrolyte in the silver-plating process.
1,240
Electronics. Others. Resources: Resources that are not yet covered by the Permission Form
21
Dichotomous Key/Passeriformes. 9 - Corvida. Could be Atrichornithidae, Climacteridae, Maluridae, Pardalotidae, Petroicidae, Pomatostomidae, Cinclosomatidae, Neosittidae, Pachycephalidae, Dicruridae, Campephagidae, Oriolidae, Artamidae, Paradisaeidae, Corvidae, Corcorachidae, Irenidae, Laniidae, Vireonidae, Ptilonorhynchidae
131
Q3Map2. Q3Map2 has now been integrated with the GtkRadiant Project. Windows, Mac and Linux binaries for both 32-bit and 64-bit systems can be download from the project page. The Q3Map2 source code is now available through the GtkRadiant GitHub Repository. Official Support Forum @Splashdamage Current stable version is 2.5.17 Q3Map2 is a BSP compiler for games based on the id Tech 3 engine. It compiles .map files, which are editable with an editor, into .bsp files, which are binary files for the game and are not editable. It currently supports the following platforms: Q3Map2 was designed to replace the Q3Map.exe that comes with QERadiant, GtkRadiant and GMAX Tempest. However, there are significant enhancements that require a little twiddling to use, such as faster lighting and enhanced surface production. Fun Facts: Usage. Q3Map2 is a command-line utility. In general, users make use of Q3Map2 in one of three ways: It should be noted that the default command lines given in the GtkRadiant bsp menu are by no means a complete showcase of the available Q3Map2 options and switches. You may edit the bsp menu command lines from the GtkRadiant preferences, but for total control of your Q3Map2 compile writing a batch file or using one of the front ends is probably a better idea. Q3Map2 command lines generally follow the format: "C:\path\to\Q3Map2.exe" [<general option>] [<major switch> [<minor switch> <minor switch>...]] "C:\path\to\maps\mapname.map" Switches. General options. -connect <hostname/ip address> -info -game <quake3|wolf|et|etut|ef|jk2|ja|sof2|tenebrae|qfusion> -fs_game <mod name> -fs_basepath <"C:\path\to\game\directory"> -convert [-format <ase|map|quake3|wolf|et|etut|ef|jk2|ja|sof2|tenebrae|qfusion>] -scale <N.N> -export -import -exportents -onlyents -threads <number of threads Q3Map2 should use> -v -rename Major switches. -bsp -vis -light Minor switches. The three major switches (-bsp, -vis, and -light) all have many options that can be accessed via their respective minor switches. There are quite a few minor switches, so in the interest of readability the lists of minor switches have been organized on separate pages of the Q3Map2 wiki. BSP phase minor switches. Q3Map2 BSP phase minor switches have their own page at Q3Map2/BSP VIS phase minor switches. Q3Map2 VIS phase minor switches have their own page at Q3Map2/VIS Light phase minor switches. Q3Map2 Light phase minor switches have their own page at Q3Map2/Light Q3Map2-specific entity keys. Q3Map2-specific entity keys have their own page at Q3Map2/Entity keys. Specialized tutorials. A Good "Final" Compile. This command line is a good compile to start building off of when you want to produce a "final" compile of your map. It is by no means perfect for every map, but a good place to start tweaking based on your own maps particulars. "C:\path\to\q3map2.exe" -meta -v "C:\path\to\mapname.map" "C:\path\to\q3map2.exe" -vis -v "C:\path\to\mapname.map" "C:\path\to\q3map2.exe" -light -fast -patchshadows -samples 3 -bounce 8 -gamma 2 -compensate 4 -dirty -v "C:\path\to\mapname.map" Games with the r_overbrightbits value enabled by default (i.e. Quake III Arena) may want to use the -gamma and -compensate switches. Otherwise, remove from the compile settings above. Creating an .ase model out of brushwork. Here is an example of a batchfile that does both, bsp and convert compile: "C:\path\to\q3map2.exe" -bsp -meta -patchmeta -game [game abbreviation] "C:\path\to\model.map" "C:\path\to\q3map2.exe" -convert ase -game [game abbreviation] "C:\path\to\model.bsp" Et voila! You've now got a misc_model created out of brushwork. Play with the "modelscale" and "angles" entity keys, and see why Q3Map2 .ase conversion is completely and totally great. -subdivisions # For extra moxie, import model.map as a prefab to your new map. Select the "model" brushwork, and texture it with clip. Rotate these new clip brushes into place over your misc_model; the brush vertexes of these clip brushes will get screwed up a bit, but since the player can't see clip, you really can't tell in-game. It's lovely, and doesn't have any of the ill effects of Q3Map2 autoclipping. _skybox tutorial. The _skybox entity "grabs" all the map geometry it can "see" via the normal entity flooding algorithm and assimilates it into the portal sky heap. This is an important concept to understand; if there is any leak between your "main" map and the separate area designated for the _skybox, your compile will take forever, only to produce a very borked .bsp. With that out of the way... Notes: Authors: see page history Decompiling into a .map. Q3Map2 can decompile a .bsp into a .map. This procedure is by no means perfect, and you should never take anything from others maps when license forbids it, but decompiling a map is good to "see how it's done". q3map2 -game [game abbreviation] -convert -format map [name of the bsp file].bsp So if the .bsp is called testmap.bsp and you use Jedi Academy, you use this: q3map2 -game ja -convert -format map testmap.bsp You should then find a .map in the same folder as q3map2.exe and the .bsp.
1,633
Q3Map2/BSP. BSP phase minor switches:. -custinfoparms. // Contentflags surfaceparmName 0x0000 //whatever bitflag is used by your mod for said surfaceparm // Surfaceflags surfaceparmName 0x0000 //whatever bitflag is used by your mod for said surfaceparm -skyfix. Sidenote: ATI's behavior is correct. The bug was with *NVIDIA* drivers not distinguishing between GL_CLAMP and GL_CLAMP_TO_EDGE, and Q3 using the wrong one: since Q3 development was done predominantly on nVidia hardware, nobody noticed it until too late.
164
Inorganic Chemistry/Cover. Welcome to the wikibooks open content<br>Inorganic Chemistry Textbook Contributing. This is a wiki textbook -- feel free to edit it, update it, correct it, and otherwise increase its teaching potential. To find out more about wikis, see the Wikipedia main page.
81
Inorganic Chemistry/Foreword. Purpose and mission. This book should become the gold standard of inorganic chemistry texts in the areas of accuracy, usability, flexibility, and connection with its audience. As this text is developed it will always be available online, be printable, and freely distributable. This text should eliminate all or much of the cost for owning an up-to-the-minute, top-quality college-level inorganic chemistry text, as it and all its derivative works will remain free: free as in speech as well as free as in beer. Although you could pay for a printed version if you wanted to. Content and Contributions. This is, to the best of our knowledge, the world's first and only open content inorganic chemistry textbook. Its users will tweak and refine this book until there is no better book. We are confident that this will happen because the process has already been seen to work many times on the Wikipedia site. All content contained herein is available under licences that allow free distribution. You can copy it, print it, sell it, and create derivative works from it. Our restriction: if you create derivative works, make them available to others in a way that they can easily copy and distribute them, as we have done for you. We link to some pages outside our server. Any of this content not found under the Wikipedia site and subsites is not ensured to be under the same license, it in fact is most likely not. Authors. The initiator of this project is JaF893. At the time of writing (3/9/03) I have been the sole contributor but as time goes on it will become a group project "of the people" as many contribute and improve it by bits and pieces. EDIT (3/10/03) - has edited some of the pages and created an automatic table of contents. Licensing. All work in this book is released at the moment only under the GNU FDL license. However this is only one of many similar open content licenses, and may not be the license of choice for everyone. To take content written by JaF893 from this book for release under other licenses please contact the author through this page's associated page.
489
Inorganic Chemistry/Catalysis. Introduction. Catalysis is the ability of some species to rapidly speed up the rate at which a chemical reaction proceeds. For historical reasons, the discipline is normally split into two sub-categories; homogeneous (homo = same, geneous = phase) and heterogeneous (hetero = different). Homogeneous catalysis is concerned with catalysts that are in the same phase as the chemical reactions they are speeding up. These reactions are normally in the liquid phase and include all of biology's enzymes. While the majority of homogeneous catalysis is in the liquid phase there are gas phase and solid phase homogeneous catalytic reactions. Heterogeneous catalysts have a catalyst that is in a different phase. This type of catalysis is responsible for the vast majority of 'bulk' chemicals that are produced each year that go into making all the things we take for granted around us such as plastics, and are also extensively used for refining oil in gasoline. This chapter focuses on heterogeneous catalysis and specifically how and why they work at all. The key concept in catalysis, and indeed all of chemistry, is the tension between the thermodynamics of a particular reaction which tells you whether something "should" happen, and the kinetics which tells you "how fast" something will happen. This tension in the world around you is everywhere i.e. thermodynamics says the diamond on an engagement ring should turn into graphite, a more stable allotrope of carbon but the kinetics is such that you would be waiting a very, very long time before it happened! Catalysis works by giving chemical reactions that "should" happen a way to "actually" happen. Conceptual Analogy. The standard way to think of a chemical reaction happening is to imagine the energy of a molecule as being represented by a z co-ordinate while the reaction 'proceeds' in the x-y plane. If this sounds confusing, just think of the energy as being like the height of land features like mountains relative to their position. A molecule in this landscape would be a place where you can't go downhill without having to go uphill first, like a crater lake. Even though on a global scale, a crater lake should flow down to the sea, the local conditions around it mean that it would have to first flow uphill, which we could postulate doesn't happen on a regular basis. This analogy helps to visualise what is going on in a chemical reaction: the atoms involved when they're joined in one fashion are in an energy 'lake' and aren't able to change, but given the right conditions, such as temperature or photons, they are able to get over the energy barrier and flow down to another energy 'lake' which has the atoms joined in another fashion. This energy barrier is called the activation energy. In our analogy, imagine drilling a hole from one lake to another lake, since the water doesn't have to go 'up and over', it can flow easily to another position. This is exactly what a catalyst does, it doesn't change the total energy of the system or where the system will eventually end up (the thermodynamics dictate this), it just provides an easier way for the system to get there and hence speeds it up (it increases the rate). This analogy paints a picture that helps you remember the text-book definition of a catalyst: a substance which increases the rate at which a thermodynamic equilibrium is obtained by lowering the activation energy of the reaction pathway. That is what a catalyst does but it doesn't give us any idea of how. It is only useful in deciding whether you are observing catalysis in action, the mechanism of how heterogeneous catalysts work is far more subtle. Mechanism. According to Surface absoprtion theory heterogeneous catalysis has five stages: The ability for an atom or molecule to stick to the surface is known, brilliantly, as the Sticking Co-efficient. This is just the ratio or percentage of molecules that end up sticking on the surface. Examples. In the contact process vanadium [V] oxide (V2O2) is solid whereas the reactants SO2 and O2 are gaseous. More detailed method: 2V2O5(s) + 2SO2(g)⇔ 2SO3(g) + 2V2O4(s) 2V2O4(s) + O2 (g) ⇔ 2V2O5 (s) Therefore: 2SO2(g) + O2(g)⇔ 2SO3(g)
1,023
MUMPS Programming. MUMPS is a programming language. It is named after the acronym Massachusetts General Hospital Utility Multi-Programming Systems. If you have programmed before and would like to see a little bit of how MUMPS works and is different from other programming languages, you can get an overview. __NOEDITSECTION__
78
Ruby Programming/Overview. Ruby is an object-oriented scripting language originally developed by Yukihiro Matsumoto (also known as Matz). The main website of the Ruby programming language is ruby-lang.org. Development began in February 1993 and the first alpha version of Ruby was released in December 1994. It was developed as an alternative to scripting languages like Perl and Python. Ruby borrows heavily from Perl and the class library is essentially an object-oriented reorganization of Perl's functionality. Ruby also borrows from Lisp and Smalltalk. While Ruby does not borrow many features from Python, reading the code for Python helped Matz develop Ruby. MacOS comes with Ruby already installed. Most Linux distributions either come with Ruby preinstalled or allow you to easily install Ruby from the distribution's repository of free software. You can also download and install Ruby on Windows. The more technically adept can download the Ruby source code and compile it for most operating systems, including Unix, DOS, BeOS, OS/2, Windows, and Linux. Features. Ruby combines features from Perl, Smalltalk, Eiffel, Ada, Lisp, and Python. Object Oriented. Ruby goes to great lengths to be a purely object oriented language. Every value in Ruby is an object, even the most primitive things: strings, numbers and even true and false. Every object has a "class" and every class has one "superclass". At the root of the class hierarchy is the class BasicObject, from which all other classes, including Object, inherit. Every class has a set of "methods" which can be called on objects of that class. Methods are always called on an object — there are no “class methods”, as there are in many other languages (though Ruby does a great job at faking them). Every object has a set of "instance variables" which hold the state of the object. Instance variables are created and accessed from within methods called on the object. Instance variables are completely private to an object. No other object can see them, not even other objects of the same class, or the class itself. All communication between Ruby objects happens through methods. Mixins. In addition to classes, Ruby has "modules". A module has methods, just like a class, but it has no instances. Instead, a module can be included, or “mixed in,” to a class, which adds the methods of that module to the class. This is very much like inheritance but far more flexible because a class can include many different modules. By building individual features into separate modules, functionality can be combined in elaborate ways and code easily reused. Mix-ins help keep Ruby code free of complicated and restrictive class hierarchies. Dynamic. Ruby is a very "dynamic" programming language. Ruby programs aren’t compiled, in the way that C or Java programs are. All of the class, module and method definitions in a program are built by the code when it is run. A program can also modify its own definitions while it’s running. Even the most primitive classes of the language like String and Integer can be opened up and extended. Rubyists call this "monkey patching" and it’s the kind of thing you can’t get away with in most other languages. Variables in Ruby are dynamically typed, which means that any variable can hold any type of object. When you call a method on an object, Ruby looks up the method by name alone — it doesn't care about the type of the object. This is called "duck typing" and it lets you make classes that can pretend to be other classes, just by implementing the same methods. Singleton Classes. When I said that every Ruby object has a class, I lied. The truth is, every object has "two" classes: a “regular” class and a "singleton class". An object’s singleton class is a nameless class whose only instance is that object. Every object has its very own singleton class, created automatically along with the object. Singleton classes inherit from their object’s regular class and are initially empty, but you can open them up and add methods to them, which can then be called on the lone object belonging to them. This is Ruby’s secret trick to avoid “class methods” and keep its type system simple and elegant. Metaprogramming. Ruby is so object oriented that even classes, modules and methods are themselves objects! Every class is an instance of the class Class and every module is an instance of the class Module. You can call their methods to learn about them or even modify them, while your program is running. That means that you can use Ruby code to generate classes and modules, a technique known as "metaprogramming". Used wisely, metaprogramming allows you to capture highly abstract design patterns in code and implement them as easily as calling a method. Flexibility. In Ruby, everything is malleable. Methods can be added to existing classes without subclassing, operators can be overloaded, and even the behavior of the standard library can be redefined at runtime. Variables and scope. You do not need to declare variables or variable scope in Ruby. The name of the variable automatically determines its scope. Blocks. Blocks are one of Ruby’s most unique and most loved features. A block is a piece of code that can appear after a call to a method, like this: laundry_list.sort do |a,b| a.color <=> b.color end The block is everything between the do and the end. The code in the block is not evaluated right away, rather it is packaged into an object and passed to the sort method as an argument. That object can be called at any time, just like calling a method. The sort method calls the block whenever it needs to compare two values in the list. The block gives you a lot of control over how sort behaves. A block object, like any other object, can be stored in a variable, passed along to other methods, or even copied. Many programming languages support code objects like this. They’re called "closures" and they are a very powerful feature in any language, but they are typically underused because the code to create them tends to look ugly and unnatural. A Ruby block is simply a special, clean syntax for the common case of creating a closure and passing it to a method. This simple feature has inspired Rubyists to use closures extensively, in all sorts of creative new ways. Advanced features. Ruby contains many advanced features. You can also write extensions to Ruby in C or embed Ruby in other software.
1,447
Smalltalk Programming. Smalltalk is an object oriented programming language. It was named as a 'small' language intended to be easy to use. If you have programmed before and would like to see a little bit of how Smalltalk works and is different from other programming languages, you can get an overview. __NOEDITSECTION__
72
Prolog. Welcome to the Prolog book. This book can serve as a textbook or tutorial for anyone who wants to learn the Prolog programming language. No prior programming experience is required. Some basic knowledge of logic can come in handy. For those new to the subject, a short introduction to logic is given, but this is not required reading. The first chapters of the book (under "Basics") describe the central syntax and features of the language. The next section, "Programming", explores additional concepts that are useful when programming in Prolog. The chapters under "Basics" and "Programming" are meant to be read in order. The section "Built-in Predicates" deals with the functions available in many Prolog compilers. These and other chapters can be read in any order. __NOEDITSECTION__ Table of contents. Beginning Prolog. Basics: Programming: Built-in Predicates:
201
Fortran. External links. Compilers. __NOEDITSECTION__
18
German/Level I/Freizeit. Lesson I.4: Freizeit Dialogue. Literally, "Freizeit" means "free time", i.e., spare time. In this dialogue, Franz and Greta are familiarizing each other with their sports activities. Sports and Activities. Section Problems» Spielen, Machen and Other Verbs. All three verbs that you were introduced to in Lesson 2 are irregular in some way; however, most verbs are regular verbs. In English, the regular conjugation is very easy: only for the third person singular an "-s" is added to the infinitive ("to see" becomes "he/she/it sees"). Unfortunately, there are more endings in German. The following two tables show the endings for the two regular verbs "spielen" ("to play") and "machen" ("to do; to make"): As you see, the endings are the same for corresponding forms of "spielen" and "machen". In fact, they are the same for all regular verbs. Thus, you can always just remove the "-en" from the infinitive of a regular German verb to form the stem (e.g., "spielen" becomes "spiel-" and "machen" becomes "mach-") and then add the ending for the particular person. Here is a table with these endings: Examples. Note that in English one "plays" sport, while in German one "does" sport. You can also use the question words from Lesson 3 to form more combinations: To say "not", use "nicht". "Nicht" goes after the verb but before the sport. Compound Sentences. Both German and English have compound sentences; the applications of these are enormous. They can be used in lists and also in compound sentences. For example, The new word, "also — auch" is very important. The one grammar rule about "auch" is that it always comes after the verb. Section Problems» Other Verbs and Their Conjugations. "Schauen", "schreiben" and "schwimmen" are all regular verbs; i.e., they follow regular conjugations. To conjugate them, you first remove the "-en" from the infinitive to form the stem (i.e., "schau-", "schreib-", and "schwimm-"), and then add the correct ending. Here is an example: "Arbeiten" is an irregular verb; however, it has a simple change. Whenever the ending starts with a consonant, an "-e-" is added before it. For example, "du arbeitest" (not "du arbeitst"). As well as "er/sie/es/ihr arbeitet" (not "er/sie/es/ihr arbeitt"). "Lesen" is also an irregular verb. For the second and third person singular the form is "liest", i.e., "du/er/sie/es liest" (not "du lesst"). "Sehen" is the last irregular verb. The second person singular is "du siehst" and the third person singular is "er/sie/es sieht". Section Problems» Two More Verb Forms. There are two common verb forms in English that just don't exist in German: the ing-form (or: present progressive); e.g., "I am playing" or "he is making"; and forms with "to do"; e.g., "I do play" or "he does not play". The simple rule is: these constructions don't exist in German. Thus, you should translate "I am playing" to "ich spiele". Similarly, "I do play" is also translated to "ich spiele". Anything else ("ich mache spielen" or "ich bin spielen") is either not possible in German or has a different meaning. The phrase "I do not play" should be translated to "ich spiele nicht" (literally: "I play not") since "nicht" ("not") comes usually after the verb. This may sound like Early Modern English in a play by Shakespeare, and this is no coincidence since German and English are both West Germanic languages. Section Problems» Expressing likes and dislikes. In German, there are several ways to express likes and dislikes; this is just one of them. You can also add other verbs for other activities, e.g., "I like to read." — "Ich lese gern." or "I like to work." — "Ich arbeite gern." or "I like to watch TV." — "Ich schaue gern Fernsehen." To express preference, you can use "lieber" instead of "gern." For example, "I prefer to play basketball." — "Ich spiele lieber Basketball." or "I prefer to read." — "Ich lese lieber." To express favorite activities, you can use "am liebsten" (meaning "most of all") instead of "lieber" or "gern". For example, "Most of all, I like to play chess." — "Ich spiele am liebsten Schach." To express dislikes, you can use "nicht gern" instead of "gern", for example "I don't like to swim." — "Ich schwimme nicht gern." or "I don't like to work." — "Ich arbeite nicht gern." or "I don't like to play soccer." — "Ich spiele nicht gern Fußball." Section Problems» Numbers. Numbers are among the most important and most useful words: we need them to talk about time, amounts, money, etc. Even if you are "just" a tourist, you often cannot avoid numbers. Learning numbers can be a bit of a pain; thus, here is some advice: whenever you have time, count something in German; e.g., steps, cars, people, seconds, whatever: just count. Notice the pattern: "-teen" translates to "-zehn", and "-ty" to "-zig". There is one big problem with the numbers: in German the unit position comes before the tens and is connected by "und" ("and"). For example: "twenty-three" — "dreiundzwanzig" (literally: "threeandtwenty"), "twenty-four" — "vierundzwanzig", "thirty-five" — "fünfunddreißig", "forty-six" — "sechsundvierzig", etc. One exception is "eins" which becomes "ein-" in 21, 31, 41, etc.: "twenty-one" — "einundzwanzig" (literally: "oneandtwenty"), "thirty-one" — "einunddreißig", "forty-one" — "einundvierzig", etc. German is not the only language with this "reverse" order of numbers: Danish (another Germanic language) and Arabic do it the same way. This was also the standard way of forming numbers in older versions of English ("Four and twenty blackbirds/Baked in a pie." :w:Sing a Song of Sixpence). Section Problems» = What's On the Test = To go straight to the lesson test, go here. The test will have four parts to it: Grammar (79 points), Translating (95 points), Reading Comprehension (20 points), Vocabulary (20 points), and Previous Topics (10 points) in that order. The Grammar section will test your ability to know the verbs from this lesson and its various versions, to know articles – the genders of them and the correct usage of them, and correct word order. The Translating section is worth the most points, and it too has three sections. You must know the translations for sentences and phrases going from English to German, and be able to take a German dialogue and translate it back into English. Also you must know the translation from Numbers to German. The third section, Reading Comprehension, is Comprehension Questions you must know how to read the conversion and after reading you will be asked question on the previous conversion. The fourth section is a vocabulary section. You get 20 English words on the left and 20 German words on the right, and be asked to match them. To study for that, check out the 401 flashcards related to this lesson at FlashcardExchange.com "Part I" and FlashcardExchange.com "Part II". The last section, Previous Topics, is a quick review on Lesson 1 to get ready for this section, just look at some past notes or go to Lesson 1 and study. That is the whole test. Take it!
2,017
Perl Programming/Control flow. Control structures. The basic control structures do not differ greatly from those used in the programming language or programming language: Loops. while ($boolean) { # do something until ($boolean) { # do something Though syntactically the same, Perl does not use break and continue to change the flow of loops. Perl provides the following commands: (with C equivalents in comments) while ($boolean) { # do something if($finished) { last; # equivalent to 'break' if($done) { next; # equivalent to 'continue' # do some more Note that the statements in a while (or until) loop are not executed, if the Boolean expression evaluates to false (or true, respectively) on the first pass, even when specified at the end of the code block. Therefore the following loops are functionally equivalent: (the same applies to: do {} until) while ($boolean) { # something do { # something } while ($boolean); The do {} while and the do {} until loops are technically statement modifiers and not actual control structures. The statements will be executed at least once. print "$i\n"; foreach my $variable (@list) { print "$variable\n"; $variable is an alias to each element of the @list, starting at the first element on the first pass through the loop. The loop is exited when all the elements in the list have been exhausted. Since $variable is an alias, changing the value will change the value of the element in the "list". This should generally be avoided to enhance maintainability of the code. If $variable is omitted, the default variable $_ will be used. foreach (@list) { print "value: $_ \n"; Note that for and foreach are actually synonyms and can be used interchangeably. Blocks may have an optional continue section, which is executed at the end of each iteration. while ($i<4) { $i++; } continue { print "$i\n"; next, redo, last. When inside a loop, there are three keywords that manipulate how the loop is handled. To start the next iteration, next jumps to the end of the block. If there is a continue block, that part is executed, as is the conditional to resume the loop. To restart an iteration, redo jumps to the beginning of the block. Neither continue nor the conditional are executed. To break out of the loop, last jumps outside the end of the block. Neither continue nor the conditional are executed. given. Until version 5.10.1, Perl did not have an equivalent of the switch statement in other programming languages. Starting in that version, it became an experimental feature. In Perl 5, it first needs to be enabled with one of the following statements: use feature "switch"; use v5.14; </blockquote> <syntaxhighlight lang="perl"> given ($t) By default, the expressions in when is matched to what is found in given. In certain exceptional cases, the value may be used directly as a boolean. if-then statements. if ($boolean_expression) { # do something unless ($boolean_expression) { # do something Statements with else blocks (these also work with unless instead of if) if ($boolean) { # do something } else { # do something else if ($boolean) { # do something } elsif ($boolean) { # do something else Postfix notation. Control statements can also be written with the conditional following the statements (called "postfix"). This syntax functions (nearly) identically to the ones given above. "statement" if "Boolean expression"; "statement" unless "Boolean expression"; "statement" while "Boolean expression"; "statement" until "Boolean expression"; "statement" foreach "list";
890
Java Programming/History. On 23 May 1995, John Gage, the director of the Science Office of the Sun Microsystems along with Marc Andreesen, co-founder and executive vice president at Netscape announced to an audience of SunWorldTM that Java technology wasn't a myth and that it was going to be incorporated into Netscape Navigator. At the time the total number of people working on Java was less than 30. This team would shape the future in the next decade and no one had any idea as to what was in store. From running an unmanned vehicle on Mars to serving as the operating environment of most consumer electronics, e.g. cable set-top boxes, VCRs, toasters and PDAs, Java has come a long way from its inception. Let's see how it all began. Earlier programming languages. Before Java emerged as a programming language, C++ was the dominant player in the trade. The primary goal of the creators of Java was to create a language that could tackle most of the things that C++ offered while getting rid of some of the more tedious tasks that came with the earlier languages. Computer hardware went through a performance and price revolution from 1972 to 1991. Better, faster hardware was available at ever lower prices, and the demand for big and complex software exponentially increased. To accommodate the demand, new development technologies were invented. The C language developed in 1972 by Dennis Ritchie had taken a decade to become the most popular language amongst programmers working on PCs and similar platforms (other languages, like COBOL and FORTRAN, dominated the mainframe market). But, with time programmers found that programming in C became tedious with its structural syntax. Although people attempted to solve this problem, it would be later that a new development philosophy was introduced, one named "Object-Oriented Programming" (OOP). With OOP, one can write code that can be reused later without needing to rewrite the code over and over again. In 1979, Bjarne Stroustrup developed C++, an enhancement to the C language with included OOP fundamentals and features. Sun generated revenue from Java through the selling of licenses for specialized products such as the Java Enterprise System. The Green team. In December 1990, a project was initiated behind closed doors with the aim to create a programming tool that could render obsolete the C and C++ programming languages. Engineer Patrick Naughton had become extremely frustrated with the state of Sun's C++ and C APIs (Application Programming Interfaces) and tools. While he was considering to move towards NeXT, he was offered a chance to work on new technology and the "Stealth Project" was started, a secret nobody but he knew. This Stealth Project was later named the "Green Project" when James Gosling and Mike Sheridan joined Patrick. As the Green Project teethed, the prospects of the project started becoming clearer to the engineers working on it. No longer did it aim to create a new language far superior to the present ones, but it aimed to target devices other than the computer. Staffed at 13 people, they began work in a small office on Sand Hill Road in Menlo Park, California. This team came to be called the "Green Team" henceforth in time. The project they underwent was chartered by Sun Microsystems to anticipate and plan for the "next wave" in computing. For the team, this meant at least one significant trend, that of the convergence of digitally controlled consumer devices and computers. Reshaping thought. The team started thinking of replacing C++ with a better version, a faster version, a responsive version. But the one thing they hadn't thought of, as of yet, was that the language they were aiming for had to be developed for an embedded system with limited resources. An embedded system is a computer system scaled to a minimalistic interface demanding only a few functions from its design. For such a system, C++ or any successor would seem too large as all the languages at the time demanded a larger footprint than what was desired. The team thus had to think in a different way to go about solving all these problems. Co-founder of Sun Microsystems, Bill Joy, envisioned a language combining the power of Mesa and C in a paper named "Further" he wrote for the engineers at Sun. Gathering ideas, Gosling began work on enhancing C++ and named it "C++ ++ --", a pun on the evolutionary structure of the language's name. The ++ and -- meant, "putting in" and "taking out stuff". He soon abandoned the name and called it Oak after the tree that stood outside his office. The demise of an idea, birth of another. By now, the work on Oak had been significant but come the year 1993, people saw the demise of set-top boxes, interactive TV and the PDAs. A failure that completely ushered the inventors' thoughts to be reinvented. Only a miracle could make the project a success now. And such a miracle awaited anticipation. National Center for Supercomputing Applications (NCSA) had just unveiled its new commercial web browser for the internet the previous year. The focus of the team, now diverted towards where they thought the "next-wave" of computing would be — the internet. The team then divulged into the realms of creating the same embeddable technology to be used in the web browser space calling it an applet — "a small application". Keeping all of this in mind, the team created a list of features tackling the C++ problems. In their opinion, the project should ... The team now needed a proper identity and they decided on naming the new technology they created Java ushering a new generation of products for the internet boom. A by-product of the project was a cartoon named "Duke" created by Joe Parlang which became its identity then. Finally at the SunWorldTM conference, Andreesen unveiled the new technology to the masses. Riding along with the explosion of interest and publicity in the Internet, Java quickly received widespread recognition and expectations grew for it to become the dominant software for browser and consumer applications. Initially Java was owned by Sun Microsystems, but later it was released to open source; the term Java was a trademark of Sun Microsystems. Sun released the source code for its HotSpot Virtual Machine and compiler in November 2006, and most of the source code of the class library in May 2007. Some parts were missing because they were owned by third parties, not by Sun Microsystems. The released parts were published under the terms of the GNU General Public License, a free software license. Versions. Unlike C and C++, Java's growth is pretty recent. Here, we'd quickly go through the development paths that Java took with age. Initial Release (versions 1.0 and 1.1). Introduced in 1996 for the Solaris, Windows, Mac OS Classic and Linux, Java was initially released as the Java Development Kit 1.0 (JDK 1.0). This included the Java runtime (the virtual machine and the class libraries), and the development tools (e.g., the Java compiler). Later, Sun also provided a runtime-only package, called the Java Runtime Environment (JRE). The first name stuck, however, so usually people refer to a particular version of Java by its JDK version (e.g., JDK 1.0). Java 2 (version 1.2). Introduced in 1998 as a quick fix to the former versions, version 1.2 was the start of a new beginning for Java. The JDKs of version 1.2 and later versions are often called "Java 2" as well. For example, the official name of JDK 1.4 is "The Java(TM) 2 Platform, Standard Edition version 1.4". Kestrel (Java 1.3). Released on 8 May 2000. The most notable changes were: Merlin (Java 1.4). Released on 6 February 2002, Java 1.4 has improved programmer productivity by expanding language features and available APIs: Tiger (version 1.5.0; Java SE 5). Released in September 2004 Mustang (version 1.6.0; Java SE 6). Released on 11 December 2006. What's New in Java SE 6: Dolphin (version 1.7.0; Java SE 7). Released on 28 July 2011. Feature additions for Java 7 include: Lambda (Java's implementation of lambda functions), Jigsaw (Java's implementation of modules), and part of Coin were dropped from Java 7. Spider (version 1.8.0; Java SE 8). Java 8 was released on 18 March 2014, and included some features that were planned for Java 7 but later deferred. Work on features was organized in terms of JDK Enhancement Proposals (JEPs).
2,066
Perl Programming/About Perl. Perl is a programming language designed by Larry Wall, known today for its strong community and module archive CPAN. It was originally developed to process text and produce reports. As a result, a backronym has been formed from its name: Practical Extraction and Report Language. It makes extensive use of significant punctuation, and highly chaotic-looking code has been written in it. This has resulted in a less complimentary backronym (which is still embraced by Perl users): Pathologically Eclectic Rubbish Lister (said to be a quote from the language designer himself). Perl is Free Software, available under the Artistic License and the GPL. It was developed on Unix, and its Unix roots are pervasive. Perl is available for most operating systems but is particularly prevalent on Unix and Unix-like systems, and is growing in popularity on Microsoft Windows systems. However, it has been ported to a multitude of environments (some say as many as Java). It's a popular systems administration tool in Windows. Most of the things done in Perl transfer well from one operating system to another (provided suggested conventions are followed). As an example of Perl in action, until January 2002 the software running Wikipedia was a CGI script written in Perl. Another example is Slashdot, which runs on the Perl-based Slashcode software. When used on the web, Perl is often used in conjunction with the Apache web server and its mod_perl module. This embeds the Perl binary into the webserver so the CGI script need not fire up a new copy each time it's accessed. Other features such as database connection persistence greatly reduce the access times to the page. History. The Perl programming language was created by Larry Wall in 1987. It borrows features from C, sed, awk, shell scripting (sh), and (to a lesser extent) from many other programming languages as well. The name is normally capitalized ("Perl") when referring to the language, but not capitalized ("perl") when referring to the interpreter (e.g. "Only perl properly parses Perl.") Rationale. Perl was designed to be a practical language to extract information from text files and generate reports. One of its mottos is "There is more than one way to do it" (TIMTOWTDI - pronounced 'Tim Toady'). Another is "Perl: the Swiss Army Chainsaw of Programming Languages". One stated design goal is to make easy tasks easy and difficult tasks possible. Its versatility permits versions of many programming paradigms: procedural, functional, and object-oriented — though purists object to Perl as it is not a cleanly designed language. Perl has a powerful regular expression support built in directly to the syntax. Perl is often considered the archetypal language and has been called the "glue that holds the web together", as it is one of the most popular ../CGI/ languages. Its function as a "glue language" can be described broadly as its ability to tie together different systems and data structures that were not designed to be tied together.
703
XML - Managing Data Exchange/SyncML. Learning objectives. Upon completion of this chapter, you will be able to Introduction. Mobile devices such as PDAs, pagers, mobile phones and laptops are- by nature- not always connected to a network. Yet these devices contain applications which require information obtained from a network in order to be useful. While most PDAs and mobile phones contain applications such as calendars, task lists, and address books for storing useful information, this information is far less useful when it is static, only available on the device itself. For example, copies of static information will always be dissimilar when changes are made on one copy or the other. Synchronization offers a device the ability to connect to a network in order to update either the information on the device or the information on the network, such that both sets of information are identical and up-to-date. Given the proliferation of proprietary mobile devices and protocols, as well as the increasing consumer demand for ubiquitous mobile access of information, leading technology companies saw the need to create a standard, universal language for describing the synchronization actions between devices and applications. They formed a consortium to sponsor the SyncML initiative to create this language. Currently, the SyncML consortium has been adopted and incorporated into the Open Mobile Alliance, a larger group of over 300 companies which sponsors many collaborative technology projects and protocols. What is SyncML? SyncML or "Synchronization Markup Language" is an XML-based, industry-standard protocol for synchronizing mobile data across a variety of multiple networks, platforms and devices. SyncML started as an initiative in mid 2000 by major technology companies such as Ericsson, IBM, Palm Inc., Lotus, Matsushita Ltd. (Panasonic), Motorola, Nokia, Openwave, Starfish Software, Psion and Symbian. Their initiative's goals were to create a universal language from the myriad, proprietary, synchronization protocols used by mobile devices and provide a complete set of synchronization functionality for future devices. The consortium released version 1.0 in December 2000. They then implemented new features and resolved issues with the subsequent version releases, finalizing the protocol with version 1.1 in February 2002. The SyncML protocol is designed with these goals in mind: SyncML consists of client and server commands enclosed within DTD-defined... SyncML Fundamentals. Vocabulary. Let's begin by defining a vocabulary: Abbreviations: Messages and Packages. SyncML messages are requests from either a client or server to perform some action. The action may be to synchronize data, perform some checks on data, update a status, or handle any errors with these actions. Messages are bundled together as packages, as kind of a to-do list. Messages are a laundry list of requests, and they can be pieced together out of order if sufficient mapping information is given to identify to which package the message belongs. SyncML is designed this way to accommodate for errors and dropped messages. Should one message be dropped, a syncML client or server will know there is a problem because the mapping cannot be completed. It will then issue a request for the information to be resent. Once the data is received, the updates to the information can proceed. Structure of a SyncML message. Like SOAP, there are two parts to the SyncML message, a Sync Header <SyncHdr> and Sync Body <SyncBody>. The header contains meta-information about the request, such as the target database <Target> and source database <Source> URIs, Authentication information <Cred>, the session ID <SessionID>, the message ID <MsgID>, and SyncML version declaration <VerDTD>. The body contains the actual requests, alerts and data. Addressing. Addressing is done through the <syntaxhighlight> and <LocURI> tags. A server will have a familiar URI like http://www.chris.syncml.org/sync and a client mobile device will have an IMEI identification number like this 30400495959596904. Mapping. SyncML is based on the idea that clients and servers can have their own way of mapping information in their databases. Therefore, clients and servers must each have their own set of unique identifiers. LUID and GUID numbers only have to be unique if they are being used in a table between two communicating parties. In other words, these numbers are temporary, used for mapping data to tables and only really exist for the complete duration of transactions between client and server. The server will create a mapping table to tie the LUID and GUID together. Change Logs. The Server and Client track of changes made to their databases during synchronization through "change logs". SyncML doesn't define the change logs, instead SyncML does require that the changes and corrections be negotiated between client and server through messages. Using change logs, the Client and Server know which fields need to be updated. The implementation of change tracking in the application which will use SyncML is not defined. Sync Anchors. During Synchronization, the Client and Server need to know which fields to update. If a client/server application is checking the fields prior to updating/modifying them, how then does the client/server keep track of the position of current field in the database? The answer is "by using Sync Anchors". There are two kinds of Anchors : Last and Next. The 'Last' anchor describes which updates occurred during the last synchronization event. The 'Next' anchor describes the current and future synchronization request. These anchors describe the events from the standpoint of the sending device. Anchors are sent back and forth from client and server to keep track of what is happening to the database fields and what's going on in overall through the lifetime of the sync operation. By coordinating Sync Anchors and change logs with the type of Sync that is requested, the server application can determine and track (with change logs) which information is the most up-to-date. For example, it is possible to overwrite 'newer' information- that is information for which there is the most recent time-stamp in the change log- with older information. This could be done by choosing a sync in which the client tells the server to overwrite it's information with client data. This is called a 'refresh sync from client'. The types of syncs are described below. Syncs. There are seven types of Syncs in the SyncML 1.1 language. The following section describes the types of syncs: Sync Initiation. Sync Initiation is the process the client and server must go through prior to an actual Synchronization. The first step is for the client and server to speak the same language, exchanging and revealing each other's capabilities (as defined by device, as in amount of memory, and protocol as defined by DTD). The second step is identification of the databases to be synchronized. Next the two must decide on the type of synchronization. The third and final step is authentication. Once this step is completed successfully, the synchronization activities can begin. Authentication. The SyncML server can send the client a message containing the <Chal> tag in order to represent an authentication challenge to the information the client is attempting to access. The client must then respond, giving the username and password within the <Cred> tag. SyncML uses MD5 digest access authentication. The Client and Server exchange credentials during the authentication process, returning error codes if the process breaks down at some point. The <Cred> tag is used in the <SyncHdr> for holding the credentials to be used for authentication. Common SyncML implementations. Nokia was the first company to make a SyncML-enabled phone. It synchronized the calendar database on the phone. SyncML can synchronize to-do lists, calendars, address books, phone-books, pretty much anything an organizer can do. SyncML is capable of much more. It would be appropriate to use SyncML any time there are two disparate, remote applications which need to share the same data. SyncML Syntax. SyncML Example. Notice lines {1} and {18} start the SyncML file with the root tags. Next, the SyncHdr is defined by lines {2} and {8}. Further, lines {3,4} define the versioning information, line {5} defines the sessionID to distinguish which unique dialogue is occurring between client and server applications, line {6} shows the MsgID to uniquely identify this set of requests (this entire markup) to be performed by the requested application. Also in the syncHeader are credentials, on line {7}. The SyncBody begins on line {9}. In this part of the syncML message, device/application status {10}, target/source URIs {12,13}, and requested actions such as the sync itself between lines {11,16}, Add and Replace {14,15} commands are given. WBXML and SyncML. WAP Binary XML (WBXML) is a form of XML whereby the XML tags are abbreviated in order to shorten the markup for transmission to mobile devices, which commonly have bandwidth and memory limitations. The XML tags are encoded into a binary shorthand to save space. Let's take a look at an example so that this will make more sense. The following is WBXML binary code depicting a SyncML message. Notice in the first line there is a the document type definition, represented here in hexadecimal tokens. Can you see what happens to the following string? "//SYNCML//DTD SYNCML 1.1//EN" Immediately following this string are the characters '6D 6C 71'. Each of these represent a SyncML tag. tells the SyncML processor that this is the beginning of opaque (xml) data this represents the length of this opaque data The characters "1" followed by "." and "1" represents "</VerDTD>" All together this WBXML code snippet, "6D6C71C303"1.1"01" represents: So you can see how using WBXML shorthand would be a more compact means of representing XML, saving bandwidth for mobile devices. For more information please refer to Ed Dumbill's articles on syncML with WBXML: SyncML specifications. The best source of information on SyncML is the protocol itself. Visit the Open Mobile Alliance for the SyncML specifications. Open Mobile Alliance. Download OMA SyncML Specifications and white papers at the Open Mobile Alliance. Or check out the SyncML Articles at the Open Mobile Alliance. SyncML Implementations. Although the SyncML specifications are useful, you still have to implement the protocol in your application. There are a few toolkits and implementations out there that you can use to get a head start. SyncML Reference Toolkit. The Open Mobile Alliance has released a toolkit written in C to demonstrate SyncML. You can get it here. If you can read German, you can get a sample application using the toolkit here. Funambol. Interested in developing SyncML for Java? Check out the open source project Funambol. It offers a Java and C++ SDK that implements the SyncML data synchronization protocol, a Java-based application framework for building SyncML server applications, and a standalone SyncML server. Summary. Mobile Device Technology is improving and changing at a rapid pace. As US telecommunication companies implement Third generation (3G) WCDMA technology (wide-band code-division multiple access), or wireless broadband, we will begin to see powerful devices emerge on the market. These devices will be able to deliver full color, video, streaming multimedia and a variety of data services such as Multimedia Messaging Service (MMS) through WAP. In that infrastructure is becoming cheaper, these telecommunication companies are starting to shift towards being service providers and media vendors as opposed to communications utilities. Cingular wireless, multimedia messaging and ringtones services are a good example of the shift of their company towards being a "media platform". The companies that will survive will be the ones that listen to customers needs and make easy-to-use services. Telecommunications companies can add value to their services by creating custom applications and services that use SyncML for synchronization.
2,856
XML - Managing Data Exchange/SMIL. Learning objectives Upon completion of this chapter, you will be able to Introduction. With the explosion of the late 90's popularity of the internet, The World Wide Web Consortium (W3C) saw the need to extend the capabilities of the web with respect to information structure and media presentation. This is how they arrived at XML, the extensible language for describing information structure. Furthermore, SMIL is built upon XML: it is a specialized language to describe the presentation of media objects. Since the W3C (and everyone else) doesn't know what media types will be around in the future (virtual environments, brainwave-synch experiences, psychic/holographic/video), XML was an appropriate choice in designing SMIL to be extended to support these media. In order to integrate this technology with HTML and extend the application of media in HTML, the W3C decided to make a push towards modularizing these languages or protocols. SMIL is one of many modular languages which 'plug-in' to the larger framework of XML. What is SMIL? SMIL (pronounced "smile") is an acronym for Synchronized Multimedia Integration Language. It is thought of as an open-standard version of PowerPoint for the internet. SMIL is an XML-based language, similar in appearance to HTML, that allows for the authoring of interactive audiovisual presentations. SMIL enables the streaming of audio and video with images, text or other media types. It is a language describing the temporal and spacial placement of one or more media objects. Although SMIL can be written with a simple text editor, hand-writing SMIL documents can be a time-consuming and complicated endeavor. Therefore it is better to use a tool for generating complicated SMIL documents. World Wide Web Consortium (W3C) SYMM group. Since November 1997, the W3C SYMM group has been developing the SMIL language. It finalized SMIL 1.0 in June of 1998 and SMIL 2.0 in August of 2001. Why SMIL? Although plug-ins and media players have the ability to show many different types of media with varying support for interaction, only SMIL offers the ability to define the presentation in the form of text as a script. This feature could be called media composition. This is a powerful ability when you think about it: text presentations can be generated from other applications. Also, SMIL offers accessibility options and powerful features not present in these media players. Given that SMIL is extensible, the SMIL language has the ability to show many of proprietary objects which are used by the above players. SMIL was designed to be the overarching language for describing the presentation of all media, all layouts and interactive controls. Therefore, SMIL is not a substitute for flash, mpeg-4, or HTML. Rather, it is a new standard for describing and using all of these. SMIL History. SMIL is still being developed. Currently, attempts are being made to make SMIL easier to use in web browsers. Since SMIL is XML, the W3C developed the latest standard as an addendum to the hybrid of XML and HTML (XHTML). The following is an outline of the history of SMIL. When fully realized and implemented in the latest web browsers, XHTML+SMIL will be able to define how media elements can be controlled. HTML supports only static images and links. Web browsers use plug-ins to show videos and other media objects, so the control and interaction of the objects is left to the implementation of the plug-in. With XHTML+SMIL, the supported objects can be placed, moved or displayed according to a time-frame, interacted with using custom controls, and linked to other media objects, web pages or presentations. And since XML is extensible, support for more media objects is on the horizon. This technology has the potential to make the WWW far more interactive, allowing presenters far more control over presentations. The current SMIL 2.0 is comprehensive and fairly complete. It is divided into modules which describe different aspects of the presentation. For example, there is a structure module to describe the structure of the SMIL document itself, and there is a metadata module for describing what the SMIL document is all about. Modularity is useful for extending the SMIL schemas on a module-to-module basis when necessary, without causing unwanted interactions with the elements in other modules. Implementing SMIL. Common SMIL implementations. Currently, SMIL's most widespread usage is with MMS. MMS (Multimedia Messaging System) is a mobile device technology that is used as an envelope for sending multimedia messages to cellphones. SMIL content is placed inside the MMS message along with any associated media binaries. In this context, MMS is a kind of transport mechanism for SMIL. SMIL files and MIME Types. In order for a MIME user-agent to recognize SMIL 2.0 files, the user-agent needs to be defined: When adding this new mime-type to a web browser, the definition will need to include the 'smil' extension. SMIL Schema. The following hyperlink will direct you to the SMIL 2.0 Schemas, provided by the W3C.org. The main schema is a general description of SMIL 2.0 modules. It is followed by each module's schema. The main schema contains the include statements for all of the module's schemas. W3C.Org's SMIL Schema description SMIL Namespace Declarations. SMIL 2.0 files need to have the following namespace declaration in the beginning <smil> tag: SMIL 1.0 files have the following namespace declaration: If no default namespace is declared within the root element, the document will be processed as SMIL 1.0. SMIL Syntax. Guidelines and Rules. SMIL documents look a lot like HTML. SMIL files need to be written according to the following rules: A Simple SMIL. <?xml version="1.0" encoding="ISO-8859-1"?> <smil xmlns="http://www.w3.org/SMIL20/Language"> <head> <!-- The layout section defines regions in which to place content --> <layout> </layout> <!-- Transitions defined in head act on content defined in body --> <transition id="fade" type="fade" dur="1s"/> <transition id="push" type="pushWipe" dur="0.5s"/> </head> <!-- The body section defines the content to be used and how it will be displayed --> <body> <par> <img src="imagefile.jpg" transIn="fade"/> <video src="soundfile.aif" transOut="push"/> </par> </body> </smil> An example SMIL. <smil xmlns="http://www.w3.org/2001/SMIL20/Language"> <head> <layout> <root-layout width="320" height="240"/> <region id="text1_region" left="0" top="0" width="160" height="120"/> <region id="text2_region" left="160" top="120" width="160" height="120"/> <region id="text3_region" left="80" top="60" width="160" height="120"/> <region id="image_region" left="0" top="0" width="320" height="240"/> </layout> </head> <body> <seq> <text src="data:text/plain,First%20Slide" region="text1_region" dur="2s"/> <text src="data:text/plain,Second%20Slide" region="text2_region" dur="3s"/> <text src="data:text/plain,Third%20Slide" region="text3_region" dur="3s"/> <img src="sample_jpg.jpg" region="image_region" dur="3s"/> </seq> </body> </smil> Note that when using in-line text instead of referring to separate plain-text files as the text source, you will have to encode the text for any non-alphanumeric characters. This example uses '%20' in lines {13,14,15} as a space character. Also note that in line {13} the source for the text content begins with 'data:text/plain'. In SMIL 2.0 this is the default mime-type for text sources, so specifying it here is optional. In SMIL 1.0, however, this would have to be specified in order to use inline text. SMIL 2.0 Modules. SMIL 2.0 divides the language description by functionality into ten modules. Each module contains elements to describe structure, content, actions or attributes. The following 10 modules are associated with the SMIL 2.0 namespace. 1. Timing 2. Time Manipulations 3. Animation 4. Content Control 5. Layout 6. Linking 7. Media Objects 8. Metainformation 9. Structure 10. Transitions The timing module provides a framework of elements to decide whether elements appear concurrently, in sequence, or out of order and called by interactive events such as clicking on a hyperlink. The time manipulations module provides the ability to associate media objects with time-related information such the as length of time a media object should be displayed, and a description of the timeline used as a frame of reference for the timing module. The animation module allows media objects to be placed on a timeline defined by the time manipulations module. The content control module allows for choices of which content is played, depending on such things as language and playback capabilities, using tags such as switch present a test of the system's capabilities. The layout module contains elements that describe the spacial placement of media objects in the presentation. The linking module describes hyperlinks and linking references to media objects. The media objects module describes the pathing and typing of media objects. The metainformation module contains elements that describe meta information about the SMIL file itself or the media objects it contains. The structure module is a framework to describe the structure of the SMIL file such as the head and body and SMIL elements. The transitions module is a framework to describe transitions such as wiping and fading between the presentation of media objects. Viewing a SMIL file. In order to view a SMIL presentation, a client will need to have a SMIL player installed on his/her computer. Currently, Apple's Quicktime player, Windows Media Player (WiMP) and RealNetworks RealPlayer are among the most popular media players. It would be convenient to be able to show these SMIL files natively in web browser, eliminating the requirement of a separate SMIL player or plug-in. Currently, Microsoft's Internet Explorer has limited support for SMIL features. The open-source Mozilla project is slowly incorporating SMIL and other XML-related technologies such as SVG and MathML into their browsers, but progress is slow. It is possible they are waiting for these XML-based languages to mature. Embedding SMIL files into XHTML web pages. As mentioned, SMIL is not yet native to web browsers, so in order to put SMIL in a web page, one must embed it and open it in a plug-in. Embedding SMIL files into web pages is somewhat beyond the scope of this chapter. However, should you have a need to do this, the following links are included as references to help you. SMIL for phones. As mentioned, SMIL is often used in the latest cellular phones. Phones and vendors have varied support for MMS (multimedia messaging service), but generally, MMS uses SMIL to define the layout of multimedia content. If the MMS message contains a SMIL file, it will include other media objects, which can be text or binary (text is treated here as a media object or file to be referenced in a smil file). Just a general note on MMS: the telecommunications industry needed a system in order to charge for messages by throughput as well as a system for pushing multimedia messages from phone to phone, computer to phone or phone to computer. MMS is a standard, international system for these purposes. SMIL was adopted because it was a well-defined, standard language to describe the layout and timing of the content inside MMS messages. In adhering to these (and other) standards developed by the 3GPP in partnership with the European Telecommunications Standards Institution (ETSI) and the W3C, the industry was able to ensure interoperability of new services between vendors, providing mutual benefit and equal opportunity. SMIL tools and SMIL Info. Given that WikiBooks is a publicly-available 'open' book, it would be inappropriate to include information about or links to any commercial SMIL tools. In other words, everything that is not free or open source is not considered here. Just a sidenote: some commercial tools cost upwards of $800. It is therefore in our best interest to evaluate, provide feedback for, and contribute to opensource projects. The following are useful links (March 18th, 2004) to free and opensource tools, current SMIL projects, specifications, and tutorials: SMIL in netbeans? One can create a SMIL file in Netbeans just as one would create an XML file. Just type it up and save it as a SMIL file. You can check for well-formedness, but validation might be trickier. As mentioned previously, SMIL 2.0 requires a namespace declaration, so don't forget it. For our simple exercises, just type up a well-formed SMIL document and save it as .smil That's it! Summary. We've seen how SMIL could be used to make standalone presentations. Yet the future of SMIL may be in the connection of mobile devices to the internet. As XML standards and SMIL tools reach maturity, SMIL will be increasingly implemented in order to define interactive presentations in the same way that Macromedia FLASH does, only this presentation will be native to web browsers and micro browsers used in mobile devices. Since SMIL is an open standard and it is extensible, there will likely be other applications which will use also SMIL. Visionaries foresee the increasing ubiquity of the internet in our homes and work, on computers and mobile devices. This ubiquity is also called 'pervasive computing'. Mobile commerce would be an example of pervasive computing as cellular phones and portable devices become more useful for business and location-based services. SMIL is a language which facilitates this trend by providing either a pretty face for future business services or value-added multimedia content. References. Ayars, J., Bulterman, D., Cohen, A., et al. (ed., 2001). Synchronized Multimedia Integration Language (SMIL 2.0). Retrieved April 4, 2004 from the World Wide Web Consortium Dot Org Web Site: http://www.w3.org/TR/smil20/smil-modules.html Castagno, Roberto (ed., 2003, January). Multimedia Messaging Service (MMS); Media formats and codes. Retrieved April 4, 2004 from the Third Generation Partnership Project (3GPP) Dot Org Web Site: http://www.3gpp.org/ftp/Specs/html-info/26140.htm Michel, T. (2004, March). Syncronized Multimedia (n.a., n.d). Retrieved April 4, 2004 from the World Wide Web Consortium Web Dot Org Site: http://www.w3.org/AudioVideo/ Newman, D., Patterson, A., Schmitz, P. (ed., 2002, January). XHTML+SMIL. Retrieved April 4, 2004 from the World Wide Web Consortium Dot Org Web Site: http://www.w3.org/TR/XHTMLplusSMIL/ SMIL Tutorial Home (n.d.). Retrieved April 4, 2004 from the W 3 Schools Dot Com Web Site: http://www.w3schools.com/smil/default.asp
3,979
Managerial Economics/Interest Calculations. Interest calculations are the relationship between time and money. For example, what's the difference between having $1,000,000 (1 million) now, versus having it a year later? If the money could have been received earlier and invested at 10%, then you would have had an additional 100,000 dollars the next year. In a loan situation, you are taking money from the bank. This is money that you can spend now, so you are in effect, paying (paying the interest) to have this money on hand immediately. Conversely, when you invest, you are granting immediate money to another party, and they are paying you for this money, through interest. In this section, we will be covering interest in depth and the different ways that interest can compound, and how it's calculated. In later sections we will cover cash flows such as payments in geometric and linear patterns. Converting Interest Rates to different Interest Periods. Typically loans are given with a certain Annual interest rate, regardless of whether or not interest is calculated annually or not. To convert from an interest period where interest is applied once, to a semi annually (were it's applied twice), the annual interest rate is converted to a semi annual interest rate. This is best explained with an example. Suppose the annual interest rate is 10% and is to be applied semi-annually on a loan amount of $1000, then the interest is calculated as below: The annual interest rate: 10% Number of semi-annual time periods in an year = 2 Therefore, semi-annual interest rate = 10/2 = 5% Amount due at the end of the first half year = 1000*(1.05) = 1050 Amount due at the end of the second half year = 1050*(1.05) = 1102.50 Effectively you are halving the interest rate but multiplying it to to the amount twice. Similarly, if the interest was to be applied on a quarterly basis then you would divide the annual interest rate by 4, but also multiply it to the amount 4 times. In other words, if R is the annual interest rate, n is the number of time periods at which interest is applied then the effective rate E is given by formula_1 Bond equivalent yields (also called APR on most consumer loan documents) add these sub period rates to get an annual rate. The actual or effective rate compounds the interest according to the periods specified in the loan documents (normally continuous, daily, monthly, quarterly, semi-annually, or annually). To calc the effective rate you would add one to each of the period rates and multiply them together, then subtract one. If all your period rates are the same length and carry the same rate you can simplify the function to the form formula_2 As an example for a quarterly 12% APR you have four compounding periods (each with 3% interest per period). Your effective rate is (1+0.03)^4-1 or 12.55% (rounded to two decimal places). As your n approaches infinity the formula changes to P*e^r where e is a constant that is approximately 2.71828 (it is irrational). By convention different security types use different month and year assumptions. A few common assumptions are actual number of months/actual days in the year, 30 day months/360 day year, 30 day months/365 day year. Simple Interest. Simple interest is where interest is calculated only of the "principal". This will mean that the added amount of interest added during the interest period is constant throughout the duration of the transaction. For example if I were to take a loan of 1000 dollars at 10% interest annually. At the end of each year I would owe an addition $100 dollars, regardless of however much the loan has shrunk. Under simple interest the final amount due can be easily calculated formula_3<br> Where<br> I is the total interest due.<br> P is the Principal.<br> i is the interest rate.<br> N is the number of times interest is applied. ie Number of Interest periods per year times number of years.<br><br> The Final value of the transaction can be easily calculated under simple interest. Since the final value is the Principal plus the interest you get the following formula. formula_4<br> Where<br> F is the final value.<br> I is the total interest due.<br> P is the Principal.<br> i is the interest rate.<br> N is the number of times interest is applied. ie Number of Interest periods per year times number of years.<br><br> P = $1000<BR> i = 10%<BR> N = 1 year<BR> Calculation Simple Interest Formula<BR> formula_5<BR> formula_6<BR> formula_7<BR> formula_8<BR> <BR> Simple interest is less common than compound interest and is occasionally found in add-on loans or bonds. Compound Interest. test Compound interest is denoted by the formula formula_9 Inflation. http://www.economist.com/research/Economics/alphabetic.cfm?LETTER=I#INFLATION Equivalence Calculations. .8511 1233
1,367
Economic History. When we think about economics, we often think about people on the floor of the stock exchange, trading millions of dollars' worth of shares each day. Or we think of board room meetings, where rich old men (and a lot fewer women) make decisions which end up making them richer. While it is true that this plays an important part in economics, it is not its most fundamental aspect. Economics is the study of how societies meet their needs, the most basic of which are food, clothing, and shelter; the elements necessary for survival. Once a society has met these needs, it can then look towards more luxurious items, education, health care, sports cars, personal aircraft; the list is mind-boggling. To understand the highly complex economy in which we live at the moment, we first must see how it developed through the ages. It has been said that technology has driven economic development; indeed, a certain type of technology can be linked with new economic age. Human societies have a tendency to organise the way in which it runs, and meeting its own needs is no exception. Even in a household, there is usually some kind of system as to which chores are performed by which members of the household, which member(s) provide for the resources (in terms of income to buy food, clothing and shelter), and how much of that is saved or invested. Hunter Gatherer Societies. The very first human societies were hunter-gatherers, that is, they hunted for and gathered their food. Clothing was obtained in the same way, and shelter was whatever people could find; caves and trees, perhaps. It should be noted though, even in such a primitive "economy", technology is necessary; basic stone-age tools such as clubs and spears allowed humans to hunt. Fire allowed humans to cook food which would otherwise be too difficult to eat, and also to ward off predators. In this society, there were really only three "occupations": hunters, carers and dependents. The hunters were mostly men, and were responsible for providing the food for the society, however some women were also gatherers; picking fruits and berries. Most of the women were carers; they looked after the fire and the society in making clothes, cooking, and caring for the dependents. Dependents were almost only children; people who could be neither hunters nor carers. Very few people lived to old age to require caring for, and those with disabilities were often left to die. Agrarian Economy. The technological revolution which gave rise to the Agrarian Economy was domestication and farming. Until then, people could not decide what food they consumed; they had to eat whatever they could find. With farming, societies learned to control the types of products they would consume in a much more efficient way. Domesticating animals meant that meat; a food normally very difficult to come by; could now be obtained much more easily. As people no longer needed to roam about, they could afford to invest more resources into their dwellings; and correspondingly, houses became more sophisticated. Farming also brought humans closer together, and with the higher numbers of people, more needed to be organized. A very primitive form of "labor division" had begun; whereby people specialized in producing one commodity. Whereas before, a hunter was a hunter and a carer was a carer, now one could afford to grow only wheat, because he could trade it with someone else for meat, and so on. In some of these economies, a system of currency began to develop, however the most widespread method of trade was through barter. Gift Economy. In the traditional form of commerce, goods are exchanged for goods deemed of equal value by the parties involved in the trade. In a gift economy, actors bestow lavish gifts upon others, not for a specific material return, but for the goodwill generated or status earned as a result. Slave Labour. Slave labour was a key element in the development of many countries. It can be considered an economic system because it fulfills the needs of the society. However, the standard assumption of self ownership (see information on John Locke and others) is violated leading most to reject this system from principle. The slave-owners want to produce a certain commodity, and they do it through the cheapest way they can. They buy slaves and use them to produce their commodity, giving them no more than is necessary to protect their investment. When prices of slaves are cheap relative to the output from gang labor, this can amount to just enough to survive (food, clothing and shelter). In this way, slavery is profitable to the owners while the slaves live on less than they would demand if exchange were voluntary. It helped the investors to look for new forms of investing options. As they do not need to worry about the needs of the slaves. The positive effect of it is that it framed for the collectivity of wealth and for ideals of economic principles like mass production and reusability. Feudalism. Feudalism is yet another economic system which is historically significant; in that it was the primary state of economy in much of the world for many hundreds of years. Feudalism is a hierarchical system where the majority of the labour power is dedicated to producing food; that being the peasants or serfs. A proportion of that produce is taken by the local nobility, that controls and governs by heritage the land and any peasants residing in it (Feudalism), or at times in a smaller scale to the lord of the manor usually holding his position in return for undertakings offered to a higher lord (Manorialism). These in return, provides the serfs with land to live on, shelter, and defense against external dangers. It is still an unjust system in that there is a highly wealthy class living next to an extremely poor class, but it was the standard way of life for many people throughout the Middle Ages. Mercantilism. Mercantilism is an ideology that dominated post-Feudalism Europe, especially the colonial period. It was heavily based on protectionism, and promoted the acquiring of captive markets. This led to the colonial powers (England, Spain, France, etc.) that dominated the world stage for hundreds of years. Industrial Economy. A direct result from the industrial revolution, that not only permitted the mass production of goods but the reduction of costs in the consumption of most goods that previously had to be hand crafted and limited in numbers. Most handcrafted production moved to luxury goods and the industrialization opened way to production many production methodology, the economy of scale, the production in series, to the just in time consumption in production resources. A side result of industrialization was that labor also became less specialized and therefore less costly, as a trade-off energy prices and consumption increased and easy portable and accessible fuel gained importance. Waste management and ecological considerations can also be seen as factors to consider when talking about industrial economy, as they have become a new factor in establishing cost when establishing an industrial economy. Communist Economy. When the word "Communist" is used, it is often shrouded in fear and mystery and misunderstanding, especially in countries involved in the Cold War in particularly in the United States, that still is the primarily example for Capitalism. Put simply, it is an economic system where supposedly, economic decisions are made by the community as a whole; that is the entire community. However, most interpretations of the word or attempts to establish communism have ended up creating state-driven authoritarian economies and regimes which benefit single party political élite who are not accountable to the people at all. Command Planned Economy An economy characterized by Command Planning is notable for several distinguishing features. These are: 1. Collective or State Ownership of Capital: Capital resources such as money, property and other physical assets are owned by the State. There is none (or very little) private ownership; 2. Inputs and Outputs are Determined by the State: Typically, in a Command Planning economic system, the state has an elaborate planning mechanism in place which determines the level and proportions of inputs to be devoted to producing goods and services. Local planning authorities are handed 1 year, 5 year, 10 year or, in the case of China, up to 25 year plans. The local authorities then implement these plans by meeting with State Owned Enterprises, whereby, further plans are developed specific to the business. Inputs are allocated according to the plans, and, output targets are set; 3. Labor is allocated according to State Plans: In a command planning economy there is no choice in whom you work for. From a very early age, when a child is in school, a streaming system allocates people into designated industries. If you test well at a young age you may be able to score a good job in an intellectual area, such as working in academia, or working for the bureaucracy - which in a command planning economy is massive as enormous organizational resources are needed to research, design and implement plans. If you are unlucky enough to test poorly when you are a young child, you may be streamed into working in an industry that is not to your liking, such as dull factory work, or basket weaving. In this respect command planning differs substantially from free-market capitalism, such as countries like the USA, Canada, Australia, the United Kingdom and New Zealand (amongst others) experience. In such countries, there is no legal compulsion or government direction regarding a person's choice of employment. Irrespective of any government policy or directive, workers in free-market capitalist countries are free to compete with and against each other for jobs that are given based on the merits of the applicant. Additionally in this type of market, if a worker is unhappy with the particular line of work they are in, they are free to look elsewhere for employment. Workers are free to plan their own careers, switch jobs and careers as necessary to fulfill personal needs or goals, often using adult education to re-train for different careers. 4. Private Ownership is Not Possible: Command Planning economies do not have any form of private ownership. Therefore, under a command planning system an individual cannot own shares, own real estate, or any other form of physical or non-physical asset. People are allocated residences by the State, and, this is usually done considering where and for whom you will be working for. 5. Prices and Paying for Goods and Services: Prices are regulated entirely by the State, generally having only passing regard for the actual costs of production, but usually instead, having no regard for cost. Often a currency does not exist in a command planning economy, and, when it does its main purpose is for accounting. Instead of paying for goods and services, as and when you need to buy them, you are allocated goods and services. This is often also called rationing. In western democratic and capitalist societies the price mechanism is a fundamental operator in allocating resources. The laws of demand and supply interact, with the price of goods and services sending signals to producers and consumers alike as to what should be produced and in what quantities, and, what will be demanded and in what quantities. The law of demand states that the higher the price of a good or service the less the amount of that good or service will be consumed. In other words, the quantity of a good or service demanded, rises when the price falls and, falls when the price increases. Similarly, and in consequential opposition to the law of demand, the law of supply states that the higher the price of a good or service the greater the amount of that good or service, will be supplied to the market by a producer. In other words, a higher price attracts more producers to supply a greater amount to market. This interaction occurs without any government intervention, and, in western democratic societies in which this system has operated for hundreds of years, it has been shown that the less government intervention, the greater the allocative efficiency of resources in the economy. This is not withstanding the need to enforce contracts in a functional legal system, uphold human and individual rights, and the provision of services and goods where the private market is unwilling or unable to supply, or, it simply isn't logical to supply in any other way. 6. Incentive Effects: In a command planning economy there are none, if any, incentive effects to work harder, improve production techniques, and increase productivity and efficiency. In capitalist economic systems, it is this incentive to do well for ourselves, that generates harder work, creative solutions, enterprise, efficiency and productivity improvement. It is not, therefore, incidental that it is this incentive effect that is responsible for the economic growth of the western world in the post world war II era, and the tremendous increase in standards of living that have been enjoyed by most of us in the western world. Examples of the Types of Command Planning Economies: The best example which springs to mind when thinking of command planning economic systems is the former USSR, known as the Soviet Union. North Korea in the present, modern-day era is perhaps another example, although this is a not-quite good enough case, as North Korea is heavily supported by the rest of the world - in particular China. China itself, used to be considered a Command Economy, however, in the 70s and 80s, and more dramatically in the 90's, China is generally considered to be Market Socialist in terms of its Economic Classification. They still have Socialist policies, but, markets do operate - apparently successfully enough to generate a surplus balance of trade with virtually every western country. It is now generally thought that China's turn towards capitalism will make it the sole economic powerhouse of this century. This is happening because, unlike western economies, China is producing hundreds of thousands of very highly educated people in areas such as science, engineering and technology. Cyber-Economy. As internet access spread into homes and businesses, more people communicated with each other around the world. These new interactions promoted new businesses and commercial relationships, and soon many existing businesses created their own spaces (webpages) online to advertise their products and services. Banking functions increased as security measures improved. Banks and businesses collaborated with software engineers to establish secure electronic commercial tools such as checkout systems, shopping carts, and auctions that offered safer online commerce. The amount and nature of business transactions expanded, and today this activity is called "e-commerce" or the "cyber economy". Economic Models for the Future? The Creative Economy. The post-information age is giving rise to the creative economy, in which intrinsic human talents that cannot yet be duplicated by machines begin to dominate. In such an economy, the value of human labor lies in its creative output, rather than purely its productive output. The Relationship Economy. An economic system in which one's personal connectivity and integrity determine their wealth, prosperity and success. Such a system is made possible by the internet and populism as a means of building a globally-connected consciousness and series of values.
3,268
Russian/Lesson 1. "Lesson 1" — Как тебя зовут? Dialogue. Read an introductory dialogue between a boy, Sasha, and a girl, Katya. You can read the lines using pronunciation respelling key. Translation "(test yourself)" Hello! Formal and Informal. Russian distinguishes between formal and informal modes of address (register). Friends and family address each other using the informal register with the second person singular pronoun "ты" (you), while employees and students use the formal register with bosses and professors with the second person plural pronoun "вы" (you, referring to more than one person). Adults always use "ты" when talking to a child. In the vocabulary tables "Notes" column, the "X" denotes an exclusively informal term, and the "O" indicates an exclusively formal term. What's your name? Go to the exercise Russian names. Russian names for people are composed of a given name, a patronymic, and a family name. The given name is a person's first name, and is usually chosen by the parents at birth. The patronymic is a derivation of the father's name, modified by gender. The family name is the name shared by the immediate family and passed down by the male descendants, but also modified by gender. How are you? Go to the exercise Who is this? Go to the exercise Summary. In this lesson, you have learned: Finish the exercises and translate the introductory dialogue before moving on. External links. Lesson 2 »
363
Introduction to Psychology/Introduction. Psychology is an academic and applied discipline involving the scientific study of mental processes and behavior. Psychology also refers to the application of such knowledge to various spheres of human activity, including relating to individuals' daily lives and the treatment of mental illness. Psychology differs from the other social sciences — anthropology, economics, political science, and sociology — in that psychology seeks to explain the mental processes and behavior of "individuals". Whereas biology and neuroscience study the biological or neural processes and how they relate to the mental effects they subjectively produce, psychology is primarily concerned with the interaction of mental processes and behavior on a systemic level. The subfield of neuropsychology studies the actual neural processes while biological psychology studies the biological bases of behavior and mental states. Psychology is an academic and applied field involving the study of behavior, mind and thought and the subconscious neurological bases of behavior. Psychology also refers to the application of such knowledge to various spheres of human activity, including problems of individuals' daily lives and the treatment of mental illness. It is largely concerned with humans, although the behavior and mental processes of animals can also be part of psychology research, either as a subject in its own right (e.g. animal cognition and ethology), or somewhat more controversially, as a way of gaining an insight into human psychology by means of comparison (including comparative psychology). Psychology is commonly defined as the science of behavior and mental processes. Psychology does not necessarily refer to the brain or nervous system and can be framed purely in terms of phenomenological or information processing theories of mind. Increasingly, though, an understanding of brain function is being included in psychological theory and practice, particularly in areas such as artificial intelligence, neuropsychology, and cognitive neuroscience. Psychology describes and attempts to explain consciousness, behavior and social interaction. Empirical psychology is primarily devoted to describing human experience and behavior as it actually occurs. In the past 20 years or so psychology has begun to examine the relationship between consciousness and the brain or nervous system. It is still not clear in what ways these interact: does consciousness determine brain states or do brain states determine consciousness - or are both going on in various ways? Perhaps to understand this you need to know the definition of "consciousness" and "brain state" - or is consciousness some sort of complicated 'illusion' which bears no direct relationship to neural processes? The late 19th century marks the start of psychology as a scientific enterprise. The year 1879 is commonly seen as the start of psychology as an independent field of study, because in that year German scientist Wilhelm Wundt founded the first laboratory dedicated exclusively to psychological research in Leipzig, Germany. Wundt combined philosophical introspection with techniques and laboratory apparatuses brought over from his physiological studies with Helmholtz, as well as many of his own design. This experimental introspection was in contrast to what had been called psychology until then, a branch of philosophy where people introspected themselves. Introspection "is the direct observation or rumination of one's own heart, mind and/or soul and its processes, as opposed to extrospection, the observation of things external to one's self." Psychologist Early Systems of Psychology. Wundt's form of psychology is called "structuralism". It is in a class called systematic interpretations because It attempted to explain all behavior with reference to one systematic position. Some other "systems of psychology" are "functionalism", "behaviorism", "gestalt psychology", and "psychodynamic psychology". Functionalism is concerned with the reason for behavior and not the structure of the brain. It allowed the study of new subjects including children and animals. Behaviorism is an approach to psychology based on the proposition that behavior can be studied and explained scientifically without recourse to internal mental states. Psychologists that use behaviorism are concerned mainly with muscular movements and glandular secretions. Gestalt Psychology is a theory of mind and brain that proposes that the operational principle of the brain is holistic, parallel, and analog, with self-organizing tendencies. It has a particular interest in perceptual problems and how they can be interpreted. A Gestaltist believes that the whole is greater than or different than the sum of all of the parts. Trying to break up behavior into separate parts is simplistic because everything affects everything else. Psychodynamic psychology was first practiced by Sigmund Freud, although he didn't intend it to be a system. Perspectives. While the use of one system to solve all problems has been abandoned by most psychologists, these early systems were important in the development of new systems and ideas. There are eight major perspectives that psychologists usually take, although many use an eclectic approach instead of confining themselves to just one. The psychodynamic perspective emphasizes unconscious drives and the resolution of conflicts, the behaviorial emphasizes the acquisition and alteration of observable responses, and the approaches attempt to achieve maximum human potential as set in Maslow's hierarchy of needs. The biological perspective is the scientific study of the biological bases of behavior and mental states, very closely related to neuroscience. Evolutionary psychology is a theoretical approach to psychology that attempts to explain certain mental and psychological traits—such as memory, perception, or language as evolved adaptations, i.e., as the functional products of natural or sexual selection. Cognitive psychology accepts the use of the scientific method, but rejects introspection as a valid method of investigation. It should be noted that Herbert Simon and Allen Newell identified the 'thinking-aloud' protocol, in which investigators view a subject engaged in introspection, and who speaks his thoughts aloud, thus allowing study of his introspection. Social psychology is the scientific study of how people's thoughts, feelings, and behaviors are influenced by the actual, imagined, or implied presence of others (Allport, 1985). Wundt argued that "we learn little about our minds from casual, haphazard self-observation...It is essential that observations be made by trained observers under carefully specified conditions for the purpose of answering a well-defined question." Many scientists threw away the idea of introspection as part of psychology because the observation of stimulation was speculative without an empirical approach. However the case, an opposite to introspection called extrospection has been created with a relation to Psychophysics. Psychophysics is the branch of psychology dealing with "the relationship between physical stimuli and their perception". The important distinction is that Wundt took this method into the experimental arena and thus into the newly formed psychological field. Other important early contributors to the field of psychology include Hermann Ebbinghaus (a pioneer in studies on memory), the Russian Ivan Pavlov (who discovered the learning process of classical conditioning), and the Austrian Sigmund Freud. The mid-20th century saw a rejection of Freud's theories among many psychologists as being too unscientific, as well as a reaction against Edward Titchener's abstract approach to the mind. Edward B. Titchener (1876-1927) was an Englishman and a student of Wilhelm Wundt before becoming a professor of psychology at Cornell University. He would put his own spin on Wundt's psychology of consciousness after he emigrated to the United States. At the turn of 19th century the founding father of experimental psychology Wilhelm Wundt tried to experimentally confirm his hypothesis that conscious mental life can be broken down into fundamental elements which then form more complex mental structures. Wundt's structuralism was quickly abandoned because it could not be tested in the same way as behavior, until now, when the brain-scanning technology can identify, for example, specialized brain cells that respond exclusively to basic lines and shapes and are then combined in subsequent brain areas where more complex visual structures are formed. This line of research in modern psychology is called cognitive psychology rather than structuralism because Wundt's term never ceased to be associated with the problem of observability. The majority of mainstream psychology is based on a framework derived from cognitive psychology, although the popularity of this paradigm does not exclude others, which are often applied as necessary. Psychologists specialising in certain areas, however, may use the dominant cognitive psychology only on rare occasions. Cognitive psychology "is the psychological science which studies cognition, the mental processes that are hypothesised to underlie behavior." This covers a broad range of research domains, examining questions about the workings of memory, attention, perception, knowledge representation, reasoning, creativity and problem solving. Cognitive psychology is radically different from previous psychological approaches in two key ways. Regardless of the perspective adopted there are hundreds of specialties that psychologists practice. These specialties can usually be grouped into general fields. History. Early environment. The first use of the term "psychology" is often attributed to the German scholastic philosopher Rudolf Goeckel (Latinized Rudolph Goclenius), published in 1590.[1] More than six decades earlier, however, the Croatian humanist Marko Marulić used the term in the title of a work which was subsequently lost.[2] This, of course, may not have been the very first usage, but it is the earliest documented use at present. The term did not fall into popular usage until the German idealist philosopher, Christian Wolff (1679-1754) used it in his Psychologia empirica and Psychologia rationalis (1732-1734). This distinction between empirical and rational psychology was picked up in Diderot's Encyclopedie and was popularized in France by Maine de Biran. The root of the word psychology (psyche) is very roughly equivalent to "soul" in Greek, and (ology) equivalent to "study". Psychology came to be considered a study of the soul (in a religious sense of this term) much later, in Christian times. Psychology as a medical discipline can be seen in Thomas Willis' reference to psychology (the "Doctrine of the Soul") in terms of brain function, as part of his 1672 anatomical treatise "De Anima Brutorum" ("Two Discourses on the Souls of Brutes"). Until about the end of the 19th century, psychology was regarded as a branch of philosophy. Early modern era. In 1879, Wilhelm Wundt (1832-1920), known as "the father of psychology", founded a laboratory for the study of psychology at Leipzig University in Germany. The American philosopher William James published his seminal book, Principles of Psychology, in 1890, laying the foundations for many of the questions that psychologists would focus on for years to come. Other important early contributors to the field include Hermann Ebbinghaus (1850–1909), a pioneer in the experimental study of memory at the University of Berlin; and the Russian physiologist Ivan Pavlov (1849-1936), who investigated the learning process now referred to as classical conditioning. Meanwhile, during the 1890s, the Austrian physician Sigmund Freud, who was trained as a neurologist and had no formal training in experimental psychology, had developed a method of psychotherapy known as psychoanalysis. Freud's understanding of the mind was largely based on interpretive methods and introspection, and was focused in particular on resolving mental distress and psychopathology. Freud's theories became very well-known, largely because they tackled subjects such as sexuality and repression as general aspects of psychological development. These were largely considered taboo subjects at the time, and Freud provided a catalyst for them to be openly discussed in polite society. Although Freud's theories are only of limited interest in modern academic psychology departments, his application of psychology to clinical work has been very influential. Partly in reaction to the subjective and introspective nature of Freudian psychology, and its focus on the recollection of childhood experiences, during the early decades of the 20th century behaviorism gained popularity as a guiding psychological theory. Championed by psychologists such as John B. Watson and Edward Thorndike (and later, B.F. Skinner), behaviorism was grounded in studies of animal behavior. Behaviorists argued that psychology should be a science of behavior, not the mind, and rejected the idea that internal mental states such as beliefs, desires, or goals could be studied scientifically. In his paper "Psychology as the Behaviorist Views It" (1913), Watson argued that psychology "is a purely objective [emphasis added] experimental branch of natural science," that "introspection forms no essential part of its methods", and that "the behaviorist recognizes no dividing line between man and brute." Behaviorism reigned as the dominant model in psychology through the first half of the 20th century, largely due to the creation of conditioning theories as scientific models of human behavior, and their successful application in the workplace and in fields such as advertising. Modern era. However, it became increasingly clear that although behaviorism had made some important discoveries, it was deficient as a guiding theory of human behavior. Noam Chomsky's review of Skinner's book Verbal Behavior (that aimed to explain language acquisition in a behaviorist framework) is considered one of the major factors in the ending of behaviorism's reign. Chomsky demonstrated that language could not purely be learned from conditioning, as people could produce sentences unique in structure and meaning that couldn't possibly be generated solely through experience of natural language, implying that there must be internal states of mind that behaviorism rejected as illusory. Similarly, work by Albert Bandura showed that children could learn by social observation, without any change in overt behavior, and so must be accounted for by internal representations. Humanistic psychology emerged in the 1950s and has continued as a reaction to positivist and scientific approaches to the mind. It stresses a phenomenological view of human experience and seeks to understand human beings and their behavior by conducting qualitative research. The humanistic approach has its roots in existentialist and phenomenological philosophy and many humanist psychologists completely reject a scientific approach, arguing that trying to turn human experience into measurements strips it of all meaning and relevance to lived existence. Some of the founding theorists behind this school of thought were Abraham Maslow who formulated a hierarchy of human needs, Carl Rogers who created and developed client-centered therapy, and Fritz Perls who helped create and develop Gestalt therapy. The rise of computer technology also promoted the metaphor of mental function as information processing. This, combined with a scientific approach to studying the mind, as well as a belief in internal mental states, led to the rise of cognitivism as the dominant model of the mind. Links between brain and nervous system function were also becoming common, partly due to the experimental work of people such as Charles Sherrington and Donald Hebb, and partly due to studies of people with brain injury (see cognitive neuropsychology). With the development of technologies for accurately measuring brain function, neuropsychology and cognitive neuroscience have become some of the most active areas in contemporary psychology. With the increasing involvement of other disciplines (such as philosophy, computer science and neuroscience) in the quest to understand the mind, the umbrella discipline of cognitive science has been created as a means of focusing such efforts in a constructive way. Next chapter »
3,409
World History/Ancient Civilizations. The Neolithic Revolution and Early Agricultural Societies. Early nomadic hunter-gatherers lived off the land and had a minimal effect on the environment around them. Around 10,000 years ago people started to settle down and developed agriculture possibly in response to a warming climate. The origin of agriculture is often referred to as the Neolithic Revolution. Keep in mind that different societies domesticated plants and animals, and consequently agriculture, independently i.e. Mesopotamia, Nile River Valley, Ancient China. These farmers had to overcome obstacles such as dry land with technologies like large scale irrigation. These large agricultural byproducts, irrigation, had a large impact on the environment. Pastoralism, the branch of agriculture concerned with raising livestock, developed in Afro-Eurasian grassland, negatively affecting the environment when pastures were overgrazed. The switch to agriculture created a much more reliable and abundant food source which allowed populations to soar. This led to diversification of labor which meant that food requirements could be on the backs of certain people and new classes like artisans or warriors could develop. These people developed technologies like pottery, metallurgy or plows. The Development and Interactions of Early Societies. About 5,000 years ago the first urban societies developed laying the foundations for the first civilizations. Nearly all civilizations share the same few features—they have abundant food surpluses, contained cities, political bureaucracies, armies, defined religious and social hierarchies and long distance trading. Civilization makes its debut (8000 - 3000 BC). Neolithic means "new stone", even though agriculture was the crowning achievement of the period. Civilizations started out small. Agriculture at first tended to tie only small groups together. These groups all settled along rivers, important as a reliable and predictable source of water. As time passed, families usually worked the same plot of land over successive generations, leading to the concept of ownership. The earliest examples of settlements date to about 12000 BC to 9500 BC, and seem to predate agriculture. These settlements, termed Natufian, suggest cultivation of rye. The first such excavation was at Tell Es-Sultan, just outside of Jericho. Ancient mortars and grinding tools unearthed in a large mound in the Zagros Mountains of Iran reveal that people were grinding wheat and barley about 11,000 years ago. Grass pea, wild wheat, wild barley, and lentils were found throughout the site, including some of the earliest known samples. This was much further east than most sites known for early agriculture. These were found with stone figurines in levels where earthen buildings had been flattened and destroyed, as though civilization had kept building atop their own ruins, or re-purposing land, as needs changed. Evidence in the middle east shows pottery styles moving throughout the Arabian peninsula, especially during the late Halaf-Ubaid period, where painted pottery and flint arrowheads have been discovered in great number. Pottery decorations are used to indicate trade and cultural contact, or widespread immigration during this period. The excavations on Dalma Island in the Persian gulf show the first date stones (pits from a fruit known to be from a widely cultivated palm in the middle east) known from a human settlement, approximately 5000 BC and may be the precursor to agriculture. Interestingly, at this same site, bones were found from long-tail tuna, dolphin, dugong and turtle, gazelle, needle-fish, grouper, sea bream, emperor, and jack. Some of the groupers found would have been nearly a meter long, indicating considerable fishing skill. As agriculture became more and more widespread, people began to accumulate surpluses of food, meaning that a single family grew more than it consumed. At the same time, the increasing tendency to remain in a single location put pressure on groups to protect themselves from other still nomadic peoples. In addition, when peoples stayed rooted near one another, cultural and social bonds began to form. People began to do things in similar ways (it is a property of human nature to want to belong). Because of these factors, especially a surplus of food, labor began to specialize and branch out away from just farming. When everyone did not have to farm all of the time to live, people began to become artisans and craftsmen. Such developments also brought trade, and a class of merchants. Merchants often traveled along the same routes. Also, within individual villages, artisans contributed to the homogenization of culture. Merchants caused further interaction and exchange, known as Cultural Diffusion. Human religion also began to evolve. Rising above the past nomadic "religions", cultures developed a unified polytheism within their ranks, which led them to further bond themselves together. Priests became a class as well. As you can see, specialization of labor was a direct offshoot of an agricultural surplus. The new societies had one problem, however: now that the labor was specialized, agricultural surpluses had to happen every year without a break if the new culture was to remain intact. In stepped governments to fill the void. Government most likely began with religious leaders, such as priests, exercising control. Governments also provided roads for their citizens and merchants. They further cemented the bonds between people within villages and regions, unifying culture to the point that it might be called a "civilization". However, governments needed a way to pay the laborers who built and worked on their projects. Taxes thus first, perhaps unfortunately, appeared on the scene, usually in the form of a tax-in-kind (taking a portion of a product, such as grain from a farmer, the use of money was yet to appear). Suddenly, all the parts of an ancient civilization appeared. Governments soon fell into a type of system known as a monarchy, or rule by hereditary leaders (such as kings or princes). The reason for this was two-fold: monarchy came naturally because it was like the family, with the parents on top and the children beneath; eventually the parents grew old and the children became adults and parents in their own right and the cycle continued. Secondly, monarchy was predictable and reliable. In an age without mass communication or speedy travel, it was important for any void left by the death of a leader to be filled quickly, without fuss and strife. Most of the new governments were, however, small city-states, or independent countries composed of a city and some surrounding farmland. This was the beginning of the world's oldest civilizations in Ancient Mesopotamia. An insight into the spread of farming: The spread of farming and early domestication of plants and animals was extensive, as the practices expanded from three specific regions (7000 BC) of the world to various other regions, spreading to five continents by the year 3000 BC. Agriculture first started in the Middle East around 10,000-9500 BC. By 7000 BC it had spread to the western part of the Indian subcontinent, and by 6000 BC to Egypt. By 5000 BC, it had reached China, and around 2700 BC, corn was being farmed in Mesoamerica. The Middle East, covering the areas of modern day Turkey, Iraq, Palestine, and Israel, had domesticated cattle and pigs. They were also successful in the domestication and farming of several crops and plants like wheat, barley, rye, onions, peas, and grapes. The Mesoamericans had begun farming corn, beans, avocados, squash, pumpkins, and cotton. They had not domesticated any animals. In the Andes region (Peru), potatoes, tomatoes, lima beans, peanuts, and sweet potatoes were farmed. The Andeans had also domesticated the llama. The spread in the Middle East had the greatest expansion in terms of area. Sheep were domesticated in the greater Middle East; goats were originally domesticated in Central Europe, olives in the Mediterranean. Cotton was first farmed in the Indian sub-continent, and hemp, camels, and buckwheat were originally domesticated west of the Caspian Sea. Furthermore, in the Americas, the Mesoamericans expanded north and south, spreading farming and herding to Central and slightly further into North America. From there the practice extended to South America. The Andeans had minimum spread, expanding farming and herding to regions immediately around theirs. The farming and domestication of plants and animals, by 3000 BC, had been independently innovated in Southeast Asia, China, and North-central Africa. In Southeast Asia, rice, citrus, and chickens were originally farmed and domesticated. The farming of millet and soybean was practiced in China. Sorghum and coffee were farmed originally in north-central Africa. In a brief period of 4000 years, humans had farmed and domesticated over 30 plants and animals. The spread of farming and herding had reached over five continents, and ten regions of the world. River Valley Civilizations. The first civilizations came about in river valleys which provided a constant source of water for crops. Irrigation works were often needed which required leadership perhaps leading to the creation of the first states. In addition rivers facilitated travel helping a common culture spread along its banks. The four river valley civilizations were the world’s first and each shared many common characteristics. The four river valley civilizations: China (along the Yellow River aka Huáng Hé) Indus Valley (along the Indus River) Mesopotamia (along the Tigris and Euphrates river) Egypt (along the Nile) Each Civilization had: Whereas historians argue on what exactly civilization is, writing, cities, agriculture, government, religion and art are usually on the list. Ancient Mesopotamia. While the earliest agricultural tools are known from beneath Jericho, approximately 7000 BC, further signs of civilization and tool making quickly cropped up across the Zagros mountain range. The Halaf civilization (estimates vary but generally run either from 6100-5100 BC or 5100-4100 BC) is known from a number of different locations, primarily in Syria where pottery has been found. The different types of designs found in specific locations especially Tel Sabi Abyad) seem to indicate a significant trade, or possibly migration from the surrounding mountains. During the Halaf period, a variety of grains and herbs (including barley, emmer wheat, einkorn wheat, free threshing wheat, oats, hawthorne, crosswort flax, lentils, legumes, cornelian cherry, clover, sweet clover, fleawort, field peas, linseed, wild olive, pistachio, grape, fig and hawthorn were commonly found at the archaeological site at Ras Shamra in northwest Syria. Halaf pottery has been found as far as the earliest cities in Sumer. Mesopotamia (modern Iraq) was home to the world's first truly urban cultures -- societies featuring permanent cities whose populations were fed from the surrounding countryside, but themselves engaged in other activities besides agriculture, such as trade, specialist crafts and record-keeping. From 4000 to 3000 BC, the Sumerians established some of the first known cities in the then-moist land of Sumer (modern southern Iraq, called "Ki-en-gir" by the Sumerians). It is not currently known with certainty where the Sumerians came from, but immigration from elsewhere seems probable; their myths suggested a seafaring background. From an anthropological viewpoint Sumerians belonged to the Caucasian, Mediterranean, Balkan European race. Historians speculate that the first Sumerian settlers may have been driven by overpopulation or conflict, as Sumeria was superficially inhospitable to stone-age man; it lacked the stones needed in Neolithic life to make most tools. However, the early Sumerians discovered that mud could be dried and used as a building material, and the soil was rich in clay to use to make farm tools. Once the Sumerians began to plant, they realized that Sumeria's rich mud yielded far greater quantities of food than they could consume. This surplus resulted in some of the first known exports in history. Situated near the head of the Persian Gulf, Sumer was well-positioned for sea trade, as well as having land connections to neighboring Anatolia and Elam (modern southern Iran), both of which harbored simpler cultures. The early Sumerians began to trade their surplus grain with their neighbors for the items that Sumeria did not have, such as livestock and stone. This influx of goods (and therefore merchants) gave rise to some of the first true cities. Sumerian cities spoke the same language and worshipped the same gods. However, they were not one, with whole cities being burnt to the ground in their inter-city warfare. A typical run-of-the-mill city-state consisted of the city proper and much of the countryside around it. Early Sumerian government was strictly theocratic, and governed everything from sacrifices to taxation to irrigation. Therefore, the central point of each city was its great platform/ziggurat in the centre. These ziggurats became the main form of the later Babylonian monument architecture in the same region. Writing in its strictest sense was first invented and used by the Mesopotamians around 3100 BC. It evolved out of a Mesopotamian trade tradition. When two merchants made an agreement, they would make clay models of the items being traded and then would seal them in a clay ball. However, if one of the merchants wanted to double check the quantities agreed upon in the contract, the merchants would need to break open the clay ball, literally breaking the contract. Therefore, the merchants began to scratch little picture of the items onto the outside of the clay ball. Eventually someone realized that the ball and models were no longer necessary. Later the Sumerians created more symbols for use in writing down laws and eventually even stories. This form of writing was called "cuneiform". As many as a thousand clay tablets were found in the Uruk archaeological layer dating to the 30th century B.C. From Sumer, cuneiform script and civilization spread to all the peoples of Asia Minor (Assyrians, Hittites, Urartuans, etc). For instance, the ancient Asomtavruli alphabet of the modern Georgian language has ethno-cultural contacts with the Sumerian world. Georgian specialists study the similarity of Sumerian and Iberian-Caucasian languages. Sumerian remained the language of religion and science in the 2nd-1st millennium B.C. before its replacement by Semitic languages. But Sumerian did not confide the Semites with the Majuscule alphabet, the secret spiritual alphabet that has a lot of similarity to ancient Georgian Asomtavruli alphabet. More than 200 Sumerian and Svanian terms are identical both phonetically and semantically. Sumerians created a new simplified 22 simple letter-signs alphabet. The Semitic alphabet created by Sumerian scientists for Accadians laid the foundation for various people's writing creation and spreading (Moabs, Phoenicians, Hebrews, Greeks, Latins, Arabs and others) Sumerian sacral alphabet of 35 letter signs that concealed the Sun and the Moon calendar. After flourishing for the better part of a millennium, Mesopotamia apparently experienced a climate change, which led to drought, exhaustion of the heavily-used soil, agricultural failure, and the decline of the Sumerian city-states that had become dependent on reliable surplus food production. Neighbouring peoples and tribes launched military incursions against the weakened city-states, resulting in political power shifts and the rise of new states and cities further north. Sumerologist Samuel Noah Kramer wrote "in the last quarter of the 3rd millennium B.C. the Semites inhabiting the town of Akkad conquered Sumer and made the Sumerian scientists create an alphabet for them, which subsequently came to be called the Semitic" This event took place in 2125 B.C. The Akkadians: The First Empire. Origins of Akkad. Semitic speakers seem to have already been present in Mesopotamia at the dawn of the historical record, and soon achieved preeminence with the first Dynasty of Kish and numerous localities to the north of Sumer—where rulers with Semitic names had already established themselves by ca. the 3rd millennium BC. One of these, contemporary with the last Sumerian ruler, Lugal-Zage-Si of Uruk, was Alusarsid (or Urumus) who "subdued Elam and Barahs (Barahsi?)" thus beginning the trend towards regional empire. The first known mention of Akkad is in an inscription of Enshakushanna of Uruk, where he claims to have defeated Agade—indicating that it was in existence well before the days of Sargon of Akkad, who the Sumerian kinglist claims to have built it. Sargon has often been cited as the first ruler of a combined empire of Akkad and Sumer, although more recently discovered data suggests there had been Sumerian expansions under previous kings, including Lugal-Anne-Mundu of Adab, Eannatum of Lagash, and Lugal-Zage-Si. Sargon and his sons. The fame of the early establisher of Semitic supremacy was far eclipsed by that of Sargon of Akkad (Sharru-kin = "legitimate king", probably a title he took on gaining power[5]) (23rd century BC), who defeated and captured Lugal-Zage-Si, conquering his empire. The earliest records in Akkadian all date to the time of Sargon. Sargon was claimed to be the son of La'ibum or Itti-Bel, a humble gardener, and possibly a hierodule, prostitute, or priestess to Ishtar or Inanna. One legend related of Sargon in neo-Assyrian times says that "My mother was a changeling, my father I knew not. The brothers of my father loved the hills. My city is Azurpiranu (the wilderness herb fields), which is situated on the banks of the Euphrates. My changeling mother conceived me, in secret she bore me. She set me in a basket of rushes, with bitumen she sealed my lid. She cast me into the river which rose not over me. The river bore me up and carried me to Akki, the drawer of water. Akki, the drawer of water, took me as his son and reared me. Akki the drawer of water, appointed me as his gardener. While I was gardener Ishtar granted me her love, and for four and (fifty?) ... years I exercised kingship." Originally a cupbearer to a king of Kish with a Semitic name, Ur-Zababa, Sargon thus became a gardener, responsible for the task of clearing out irrigation canals. This gave him access to a disciplined corps of workers, who also may have served as his first soldiers. Displacing Ur-Zababa, the crown was set upon Sargon's head, and he entered upon a career of foreign conquest.[7] Four times he invaded Syria and Canaan, and he spent three years thoroughly subduing the countries of "the west" to unite them with Mesopotamia "into a single empire." However, Sargon took this process further, conquering many of the surrounding regions to create an empire that reached as far as the Mediterranean Sea and Anatolia, and extending his rule to Elam, and as far south as Magan (Oman), an area over which he reigned for 56 years. Trade extended from the silver mines of Anatolia to the lapis lazuli mines in Afghanistan, the cedars of Lebanon and the copper of Oman. This consolidation of the city-states of Sumer and Akkad reflected the growing economic and political power of Mesopotamia. The empire's breadbasket was the rain-fed agricultural system of northern Mesopotamia and a chain of fortresses was built to control the imperial wheat production. Images of Sargon were erected on the shores of the Mediterranean, in token of his victories, and cities and palaces were built at home with the spoils of the conquered lands. Elam and the northern part of Mesopotamia (Subartu) were also subjugated and rebellions in Sumer were put down. Contract tablets have been found dated in the years of the campaigns against Canaan and against Sarlak, king of Gutium. Sargon, throughout his long life, showed special deference to the Sumerian deities, particularly Inanna, his patroness, and Zababa, the warrior god of Kish. He called himself "The anointed priest of Anu" and "the great ensi of Enlil" and his daughter, Enheduanna the famous poet, was installed as priestess to Nanna at the temple in Ur. He also boasted of having subjugated the "four quarters"—the lands surrounding Akkad to the north (Subartu), the south (Sumer), the east (Elam) and the west (Martu). Some of the earliest texts credit him with rebuilding the city of Babylon (Bab-ilu) in a new location. Troubles multiplied toward the end of his reign. A later Babylonian text states "In his old age, all the lands revolted against him, and they besieged him in Akkad (the city)"...but "he went forth to battle and defeated them, he knocked them over and destroyed their vast army". Also shortly after, "the Subaru (mountainous tribes of) the upper country—in their turn attacked, but they submitted to his arms, and Sargon settled their habitations, and he smote them grievously". These difficulties broke out again in the reign of his sons. Revolts broke out during the 9-year reign of his son, Mush, who fought hard to retain the empire—and in the fifteen year reign of Mush's elder brother, Humanist. The latter king seems to have fought a sea battle against 32 kings who had gathered against him. Both appear to have been assassinated. Naram-Sin. Naram-Sin (Beloved of Sin), Sargon's grandson, who assumed the imperial title of "King Naram-Sin, of the four quarters (Lugal Naram-Sin, Šar kibrat 'arbaim)", and, like his grandfather, was addressed as "the god (Sumerian = DIN.GIR, Akkadian = ilu) of Agade" (Akkad), also faced revolts at the start of his reign. Naram-Sin also recorded the Akkadian conquest of Ebla and Armani (also read Armanum or Armanim). The Assyrians, who are direct descendants of Akkadians, to this day refer to Armenians by the inscription from Armani. They were located between Carchemish and Ebla. To better police this area, he built a royal residence at Tell Brak, a crossroads at the heart of the Khabur basin of the Jezirah. Naram-Sin is supposed to have possessed an army of over 360,000 men, the largest of any state up until that date. It enabled him to campaign against Magan (thought to be Oman) which also revolted; Naram-Sin, "marched against Magan and personally caught Mandannu, its king". The chief threat seemed to be coming from the northeastern mountaineers. A campaign against the Lullubi led to the carving of the famous stele, now in the Louvre. This newfound Akkadian wealth may have been based upon benign climatic conditions, huge agricultural surpluses and the confiscation of the wealth of other peoples.[8] The economy was highly planned. After the advancing Akkadian forces from Tell Brak took the massive (100 acre) site of Tell Leilan, they destroyed nearby villages and brought the organization of farming and grain distribution into its bureaucratic control. Grain was cleaned, and rations of grain and oil were distributed in standardized vessels made by the city's potters. Taxes were paid in produce and labour on public walls, including city walls, temples, irrigation canals and waterways, producing huge agricultural surpluses. Stele of Naram-Sin, king of Akkad, celebrating his victory against the Lullubi from Zagros. In later Babylonian texts, the name Akkad, together with Sumer, appears as part of the royal title, as in the Sumerian LUGAL KI.EN.GIRKI URUKI or Akkadian Šar māt Šumeri u Akkadi,[10] translating to "king of Sumer and Akkad". This title was assumed by the king who seized control of Nippur,[11] the intellectual and religious centre of southern Mesopotamia. During the Akkadian period, the Akkadian language became the lingua franca of the Middle East, and was officially used for administration, although the Sumerian language remained as a literary language. The spread of Akkadian stretched from Syria to Elam, and even the Elamite language was temporarily written in Mesopotamian cuneiform. Akkadian texts later found their way to far-off places, from Egypt (in the Amarna period) and Anatolia, to Persia (Behistun). Collapse of Akkad. Within 100 years the Empire of Akkad collapsed, almost as fast as it had developed, ushering in a Dark Age. By the end of the reign of Naram-Sin's son, Shar-Kali-Sharri, the empire collapsed outright from the invasion of barbarians of the Zagros known as "Gutians". It has recently been suggested that the Dark Age at the end of the Akkadian period (and First Intermediary Period of the Ancient Egyptian Old Kingdom) was associated with rapidly increasing aridity, and failing rainfall in the region of the Ancient Near East, caused by a global centennial-scale drought.[12] The fall of the empire established by Sargon seems to have been as sudden as its rise, and little is known about the Gutian period. From the fall of Akkad until around 2100 BC, there is much that is still dark. The Sumerian king list, for the period after the death of Sharkalishari, states: Evidence from Tell Leilan in Northern Mesopotamia shows what may have happened. The site was abandoned soon after the city's massive walls were constructed, its temple rebuilt and its grain production reorganised. The debris, dust and sand that followed show no trace of human activity. Soil samples show fine wind-blown sand, no trace of earthworm activity, reduced rainfall and indications of a drier and windier climate. Evidence shows that skeleton-thin sheep and cattle died of drought, and up to 28,000 people abandoned the site, seeking wetter areas elsewhere. Tell Brak shrank in size by 75%. Trade collapsed. Nomadic herders such as the Amorites moved herds closer to reliable water supplies, bringing them into conflict with farmers. This climate-induced collapse seems to have affected the whole of the Middle East, and to have coincided with the collapse of the Egyptian Old Kingdom. A relatively well-known king from that period is Gudea, king of Lagash. This collapse of rain-fed agriculture in "the Upper Country" meant the loss to southern Mesopotamia of the agrarian subsidies which had kept the Akkadian Empire solvent. Water levels within the Tigris and Euphrates fell 1.5 metres beneath the level of 2600 BC, and although they stabilised for a time during the following Ur III period, rivalries between pastoralists and farmers increased. Attempts were undertaken to prevent the former from herding their flocks in agricultural lands, such as the building of a 180 km wall between the Tigris and Euphrates under the neo-Sumerian ruler Shu-Sin. Such attempts led to increased political instability; meanwhile, severe depopulation occurred to re-establish demographic equilibrium with the less favourable climatic conditions. It has also been suggested (Burroughs, 2007) that the rapid climatic collapse, marking the Akkadian Dark Age, may have been responsible for the religiously prescribed prohibition against the raising and consumption of pigs that spread through the Ancient Middle East from the end of the third millennium BC. The period between ca. 2100 BC and 2000 BC is sometimes called the 3rd dynasty of Ur or "Sumerian Renaissance", founded by Ur-Nammu (originally a general). Though documents again began to be written in Sumerian, this dynasty may also have been Semitic; Sumerian was becoming a purely literary or liturgical language, much as Latin later would be in Medieval Europe. The Curse of Akkad. Later material described how the fall of Akkad was due to Naram-Sin's attack upon the city of Nippur. When prompted by a pair of inauspicious oracles, the king sacked the E (temple)E-kur temple, supposedly protected by the god Enlil, head of the pantheon. As a result of this, eight chief deities of the Anunaki pantheon were supposed to have come together and withdrawn their support from Akkad. For many years, the events described in "The Curse of Akkad" were thought, like the details of Sargon's birth, to be purely fictional. But now the evidence of Tel Leilan, and recent findings of elevated dust deposits in sea-cores collected off Oman, that date to the period of Akkad's collapse suggest that climate change may have been the culprit. The Babylonians. The Babylonians built the Hanging Gardens of Babylon and sun baked clay houses. They also introduced the convention of using 360 degrees in a circle, and of dividing the day into 24 hours, and each hour into 60 minutes. Ancient Andes. 3500BCE Valdiva 3500 BCE-1800BCE. Valdiva culture were an Andean Civilization of Ecuador. They lived on coastal areas of Guayas. Many of their houses were put into circular positions in the central plaza. They are known for their pottery work. Most of their pottery resembled females. Females possibly held a high position in their society. Valdivia Culture domesticated llamas and cultivated cotton. Ancient Egypt. 3100 BC-30 BC The Old Kingdom. The Old Kingdom started circa 2700 BC during Egypt's 3rd dynasty. During this period of Egyptian history the Pharaohs were absolute rulers. It was during the Old Kingdom that the Great Pyramid was built as a tomb for Khufu, a Pharaoh during Egypt's 4th dynasty. The Old Kingdom failed at around 2150 BC for a number of reasons. These included the long life span of Pepi II, who ruled 94 years. Pepi II lived to be about 100 years of age, outliving many of his heirs. Additionally, the lower Nile inundation became irregular and led to failed harvests, which may have been caused by a drier climate. The First Intermediate Period. Monarches competed for control of Egypt and civil wars were common. Famines were common during this period and it is called the dark age of Egyptian History. The Middle Kingdom. Egypt's Middle Kingdom was Egypt's golden age because of trading, and new conquest. It lasted from 2050-1650 BC. The Pharaohs period of this period called themselves good shepherds and they were not as powerful as they were during the Old Kingdom. Their pyramids were smaller. The Middle Kingdom ended because of weak Pharaohs and an invasion by Asiantic people called the Hyksos. The Second Intermediate Period. The Hyksos ruled Lower Egypt from about 1650-1550 BC until the Thebean king named Ahmose I expelled them out of the country and started the New Kingdom. The New Kingdom. During the New Kingdom Egypt was at its height of power. This period lasted from 1550-1070 BC. During this period Egypt became an empire when Thutmose III conquered Palestine, Syria, and Nubia this empire lasted to Amenhoptep VI who ended Egypt's worship of many gods in favour of one god Aton. Later his son Tutankhamen restored the old religion, Tutankhamen died at 18 leaving no heirs to the throne. Seti I restored some of Egypt's empire in Palestine and Syria and his son Ramses II fought the Hitties at Kadesh, then made the first peace treaty with them. He ruled for 67 years. The last great Pharaoh was Ramses III, who was not a relative of Ramses II. He protected Egypt from invasion. About 1070 BC the New Kingdom ended. Ancient Indian Civilization. The earliest known farming cultures in south Asia emerged in the hills of Balochistan, Pakistan, which included Mehrgarh in the 7th millennium BC. These semi-nomadic peoples domesticated wheat, barley, sheep, goat and cattle. Pottery was in use by the 6th millennium BC. Their settlement consisted of mud buildings that housed four internal subdivisions. Burials included elaborate goods such as baskets, stone and bone tools, beads, bangles, pendants and occasionally animal sacrifices. Figurines and ornaments of sea shell, limestone, turquoise, lapis lazuli, sandstone and polished copper have been found. By the 4th millennium BC we find much evidence of manufacturing. Technologies included stone and copper drills, updraft kilns, large pit kilns and copper melting crucibles. Button seals included geometric designs. Indus Valley civilization. By 4000 BC a pre-Harappan culture emerged, with trade networks including lapis lazuli and other raw materials. Villagers domesticated numerous other crops, including peas, sesame seed, dates, and cotton, plus a wide range of domestic animals, including the water buffalo which still remains essential to intensive agricultural production throughout Asia today. There is also evidence of sea-going craft. Archaeologists have discovered a massive, dredged canal and docking facility at the coastal city of Lothal, India, perhaps the world's oldest sea-faring harbour. Judging from the dispersal of artifacts the trade networks integrated portions of Afghanistan, the Persian coast, northern and central India, Mesopotamia (see Meluhha) and Ancient Egypt (see Silk Road). Archaeologists studying the remains of two men from Mehrgarh, Pakistan, discovered that these peoples in the Indus Valley Civilization had knowledge of medicine and dentistry as early as circa 3300 BC. The Indus Valley Civilization gains credit for the earliest known use of decimal fractions in a uniform system of ancient weights and measures, as well as negative numbers (see Timeline of mathematics). Ancient Indus Valley artifacts include beautiful, glazed stone faïence beads. The Indus Valley Civilization boasts the earliest known accounts of urban planning. As seen in Harappa, Mohenjo-daro and (recently discovered) Rakhigarhi, their urban planning included the world's first urban sanitation systems. Evidence suggests efficient municipal governments. Streets were laid out in perfect grid patterns comparable to modern New York. Houses were protected from noise, odors and thieves. The sewage and drainage systems developed and used in cities throughout the Indus Valley were far more advanced than that of contemporary urban sites in Mesopotamia. Vedic Civilization. The Vedic civilization is the Indo-Aryan culture associated with the Vedas, which are the oldest extant Indo-European texts, composed in Vedic Sanskrit. The exact connection of the genesis of this civilization with the Indus Valley civilization on one hand, and a possible Indo-Aryan migration on the other hand, is the subject of disputes. Early Vedic society was largely pastoral. Later on, the society became agricultural, and was organized around four Varnas, or classes. Several small kingdoms and tribes merged to form a few large ones which were often at war with each other. In addition to the principle texts of Hinduism, (the Vedas), the great Indian epics, the Ramayana and Mahabharata, the latter of which constitutes the longest poem in the world, are said to have been first written during this period, perhaps from a longer spoken tradition of unwritten recitation. The Bhagavad Gita, another primary text of Hinduism, is contained within the Mahabharata. Early Indo-Aryan presence probably corresponds to the presence of ochre coloured pottery, archaeologically. The kingdom of the Kurus marks flowering of the Vedic civilization, corresponding to the Black and Red Ware and the beginning of the Iron Age in Northern India begins, around 1100 BC, likely also contemporary with the composition of the Atharvaveda. Painted Grey Ware spread over all of Northern India marks the late Vedic period, corresponding to a wave of urbanization occurred across the Indian sub-continent, spreading from Afghanistan to Bengal, in the 7th century BC. A number of kingdoms and republics emerged across the Indo-Gangetic plain and southern India during this period. 16 Mahajanapadas (great kingdoms) are referred to in ancient literature of the period. The Mahajanapadas. By 600 BC, sixteen hereditary monarchies known as the Mahajanapadas stretched across the Indo-Gangetic plains from modern-day Afghanistan to Bangladesh. The largest of these nations were Magadha, Kosala, Kuru and Gandhara. The right of a king to his throne, no matter how it was gained, was usually legitimized through religious right and genealogies concocted by priests who ascribed to the king divine origins. Hindu rituals at that time were complicated and conducted by the priestly class. It is thought that the Upanishads, the secondary texts of ancient Hinduism, dealing mainly with philosophy, were first composed early in this period. The court language at that time was Sanskrit, while the dialects of the general population of northern India were referred to as Prakrits. In 537 BC, Gautama Buddha gained enlightenment and thus founded Buddhism, which was initially intended as a supplement to the existing Hindu Vedic dharma. Around the same time period, in mid-6th century BC, Mahavira founded Jainism. Both religions had a simple doctrine and were preached in Prakrit which helped it gain acceptance by the masses. While the geographic impact of Jainism was limited, Buddhist nuns and monks spread their teachings of Buddha to Tibet, Sri Lanka and South East Asia. In around 500 BC, the Indus Valley region was invaded by the Persian ruler Darius I making the far north-west of India a satrapy of the Achaemenid Empire. Though the Persians made Taxila the capital, their influence was marginal and governed the region for around 150 years. The Persians were defeated by Alexander the Great in the 4th century BC. In 326 BC, Alexander the Great crossed the Hindu Kush mountains and invaded what is now Pakistan. However, costly campaigns against the forces of Porus (also known as Puru), and the tired troops forced him to retreat to his empire after reaching the Beas River in Punjab. He appointed Greek governors to rule the newly acquired province to keep open trade routes between India and Greece. Maurya Dynasty. In 321 BC, exiled general Chandragupta Maurya overthrew reigning king Dhana Nanda to establish the Mauryan Empire. Chandragupta was succeeded by his son Bindusara, who expanded the kingdom over most of present day India, barring the extreme south and east. During this time, most of the subcontinent was united under a single government for the first time. The kingdom was inherited by his son Ashoka the Great who initially sought to expand his kingdom. In the aftermath of the carnage caused in the invasion of Kalinga, he renounced bloodshed and pursued a policy of non-violence or ahimsa after converting to Buddhism. The Edicts of Ashoka are the oldest preserved historical documents of India, and from Ashoka's time, approximate dating of dynasties becomes possible. The Mauryan dynasty under Ashoka was responsible for the proliferation of Buddhist ideals across the whole of East Asia and South East Asia, fundamentally altering the history and development of Asia. Ashoka the Great has been described as one of the greatest rulers the world has seen. Shunga Dynasty. The Sunga dynasty was established in 185 BC, about 50 years after Ashoka's death, when the king Brihadratha, the last of the Mauryan rulers, was brutally murdered by the then commander-in-chief of the Mauryan armed forces, Pusyamitra Sunga, while he was taking the Guard of Honour of his forces. Pusyamitra Sunga then ascended the throne. Ancient Chinese Civilization. The earliest written record of China's takes the form of inscriptions of divination records on the bones or shells of animals—so-called "oracle bones". The earliest comprehensive history of China, the "Historical Records" written by Sima Qian, a renowned Chinese historiographer of the 2nd century BC, begins perhaps 3600 BC with an account of the Five Emperors (五帝). These rulers were legendary sage-kings and moral exemplars, and one of them, the Yellow Emperor, is sometimes said to be the ancestor of all Chinese people. Following this period Sima Qian relates that a system of inherited rulership was established during the Xia dynasty, and that this model was perpetuated in the successor Shang and Zhou dynasties. It is during this period of the Three Dynasties (Chinese: 三代) that the historical China begins to appear. Xia Dynasty. Sima Qian's account dates the founding of the Xia Dynasty (夏) to some 4,000 years ago, but this date has not yet been corroborated. Some archaeologists connect the Xia to excavations at Erlitou in central Henan province, where a bronze smelter from around 2000 BC was unearthed. Early markings from this period, found on pottery and shells, have been alleged to be ancestors of modern Chinese characters, but such claims are unsupported. With no clear written records to match the Shang oracle bones or the Zhou bronze vessel writings, the Xia remains poorly understood. Shang Dynasty. Archaeological findings provide evidence for the existence of the Shang dynasty (商), ca. 1600 to 1046 BC, and the archaeological evidence is divided into two sets. The first, from the earlier Shang period (ca. 1600 to 1300) comes from sources at Erligang, Zhengzhou and Shangcheng. The second set, from the later Shang or Yin period, consists of a large body of oracle bone writings. Anyang in modern day Henan has been confirmed as the last of the six capitals of the Shang (ca. 1300 to 1046 BC). Chinese historians living in later periods were accustomed to the notion of one dynasty succeeding another, but the actual political situation in early China is known to have been much more complicated. Hence, as some scholars of China suggest, the Xia and the Shang can possibly refer to political entities that existed at the same time, just as the early Zhou (successor state of the Shang), is known to have existed at the same time as the Shang. What was the religion? Zhou Dynasty. By the end of the 2nd millennium BC, the Zhou Dynasty (周) began to emerge in the Huanghe valley, overrunning the Shang. The Zhou appeared to have begun their rule under a semi-feudal system. Nevertheless, power became decentralized during the Spring and Autumn Period when regional feudal lords began to assert their power, absorb smaller powers, and vie for hegemony. The Hundred Schools of Thought of Chinese philosophy blossomed during this period and such influential intellectual movements as Confucianism, Taoism, Legalism and Mohism were founded. After further political consolidation, seven prominent states remained by the end of 5th century BC, and the years in which these few states battled each other is known as the Warring States period. Though there remained a nominal Zhou king until 256 BC, he was largely a figurehead and held little real power. Meanwhile, neighboring territories of these warring states were gradually annexed, including areas of modern Sichuan and Liaoning, and governed under the new local administrative system of commandery and prefecture (郡县), which had been in use since the Spring and Autumn Period and was very loosely a primitive prototype of the modern system of Sheng and Xian (province and county). The final expansion in this period began during the reign of Ying Zheng, the king of Qin. His unification of the other six powers, and further annexations in the modern regions of Zhejiang, Fujian, Guangdong and Guangxi in 214 BC enabled him to proclaim himself the First Emperor (始皇帝,Shi Huangdi), forming the first Chinese empire under the Qin Dynasty (秦), that laid the foundation for the consolidation of the Chinese territories that we know today. The Hittites. The Hittites were the prescendants of the Caucasian Kartvelian group of nations and were the descendants of Sumerians. Their innovations in the design of chariots, moving the wheel to the centre from the back, gave them a military advantage over other civilizations. Another point of note is that the first international peace treaty was signed by the Hittites and the Egyptians after the Battle of Kadesh. The original copy is kept in the headquarters of the United Nations. After 600 years as a major empire in the Ancient Middle East the Hittites, crippled by the attacks of the Sea Peoples abandoned their capital, Hattusa, and seemed to vanish from history. The Assyrians. The Assyrians were a civilization located near modern Iraq, along the Tigris River. The Assyrians eventually grew to occupy modern-day Iraq, northern Egypt, the eastern parts of Asia Minor and modern-day Jordan. Assyria started around 2000 BC with Semitic barbarians invading the area and establishing the roots for a civilization. By 1800 BC the Assyrians had firm control over most of northern Mesopotamia, but later lost it to the Babylonians. By 1076 BC, the Assyrians reached the Mediterranean coast. The Empire reached its peak at around 1000 to 700 BC, with the conquering of northern Egypt and Babylon. However, the Assyrians were very harsh with the lands they conquered, and thus it's citizens were very unhappy with the ruling class. By 600 BC, their capital, Nineveh, fell to the revolting vassal states, including Babylon. Soon after, the Assyrians existed only in the history books. Though the Assyrians did not advance far in the fields of science and technology, philosophy or the arts, they were mentioned in Biblical records for being great warriors, and their tactics of war would influence later powers, such as the Persians. The Persians. The Persian Empire started in the north west corner of what is now Iran. It grew through military conquest to cover a huge region that roughly encompasses today's Iran, Iraq, Armenia, Afghanistan, Turkey, Bulgaria, many parts of Greece, Egypt, Syria, much of what is now Pakistan, Jordan, Israel, Palestine, Lebanon, Caucasia, Central Asia, Libya, and northern parts of Arabia. The empire eventually became the largest empire of the ancient world. Persepolis was the ceremonial capitol of Persia. Susa and Pasargadas also acted as capital cities at different times in Persian history. They were all in what is now Iran. What did they eat? The food prepared for Persian kings was luxurious. Persians ate stews made from meat and fruit with herbs. They ate rice and bread made with wheat. Yoghurt was also a staple in Persian food. Tablets from the time of these ancient peoples indicate that the inhabitants of Mesopotamia were using basil, cilantro, cumin and caraway in their food in 4,000 BC. Apricots, artichokes, eggplants, lemons, lime, oranges, pistachios, spinach, saffron or tarragon all came to Europe through Persia. Other condiments and spices such as cinnamon, cardamom, cloves, coriander, dill, nutmeg, pomegranates, saffron, sumac, turmeric, as well as orange-flower water and rose water were used in Persian food. Lamb and goat were the primary meats eaten by Persians. What did their buildings look like? Persians made very interesting buildings. The Ruins at Persepolis are an example of ancient Persian buildings. Persians were among the first to use mathematics, geometry, and astronomy in their building. Their buildings were grand and were created by skillful workers. Some Persian buildings had huge barrel-vaulted chambers. The Persians created huge domes of rock and clay and supported their roofs with tall columns. They also decorated the walls of their palaces with lions, bulls and flowers. The Kharaghan twin towers and the Shah Mosque are two other old buildings built in a Persian style. What did they wear? The Persian king wore a robe of honour that was a large piece of fabric that was draped around him. For the king and other aristocracy, their clothes were often decorated with golden clothing ornaments. Some of these are in the form of roundels, while others are gold plaques with loops or rings on the back so they can be sewn onto the cloth. Rich people also liked to wear gold jewelry such as bracelets with animal head carvings. Common people wore coats and pants made out of leather. Men's coats reached from their shoulders down to their knees and were fastened with a girdle. Their sleeves were somewhat tight and went down to their wrists. Originally woman's clothing was quite similar to men's clothing but as time went their style changed. Initially their clothes were short and tight but when the style changed their clothes were made longer, more voluminous and were made out of softer materials. Persian shoes were usually just pieces of leather that were wrapped around their feet and were tied up on the top. These would have look similar to moccasins. What did their writing look like? Old Persian was written from left to right in Old Persian cuneiform script. Old Persian cuneiform script was supposedly invented by King Darius I, one of ancient Persia's famous kings. There were 36 letters in their alphabet, although some of them essentially represented different syllables. For example they had one symbol for "ka" and another symbol for "ku". They used these symbols even though they also had symbols that represented "a" and "u". What did they believe? The Persian civilization spawned three major religions: Zoroastrianism, Mithraism, and Manichaeanism. The Persian thinker Zoroaster (who propagated Zoroastrianism) was the main religious movement leader. Living around 3500 years ago, he helped to unite the Persian empire. He rejected the old Persian gods and introduced that a single wise god, Ahura Mazda, ruled the world. However, Ahura Mazda was often in battle with the prince of evil and lies, Ahriman. On Earth, each person had to choose which side to support. Zoroaster's teaching were written in a book, the Zend-Avesta. It said that Ahura Mazda would conquer over the forces of evil, Ahriman, at the end. On that day, all the people would be judges for their actions. Those who did good would enter paradise. Those who did evil would be condemned to eternal suffering. Are some of them famous even today? Of course, but perhaps the most famous Persian of all time is Cyrus the Great who founded the Persian Empire. In fact, in 1992 he was ranked #87 on Michael H. Hart's list of the most influential figures in history. Other famous Persian kings were Cambises and Darius the Great. Darius III is famous only because he suffered under the hands of Alexander the Great of Greece. During Darius' reign, the whole Persian Empire was destroyed by Alexander, who first attacked the Persians in what is now modern Turkey. He then moved on into the heart of the Empire where he captured the capital Susa. Darius ran away from battle against Alexander twice, but was murdered by his governor Bessus who wanted the throne for himself. Alexander was angry this happened and respected his dead opponent. He held a great funeral for the dead king. Later, Bessus was captured and executed. What is left of them today? Persians are one of the only ancient civilizations that has made significant contributions to humanity from prehistoric times by their Persian empire all the way through to the modern day in their country Iran. Most Persians are now Muslims, although there are Jews, Christians, and Zoroastrians still living and practicing their religion in Iran. There are also some Persians, called Parsis, living in mainly the north and west of India.
12,600
Computer Programming/Functional programming. Functional programming is a paradigm that treats computer programs as mathematical functions. When programming in a pure functional style, we do not manipulate states and variables (things that change value), but focus entirely on constants and functions (things that never change). Another distinguishing feature of functional programming (FP) is that functions are treated as first class citizens. Programs written in a functional style often consist of functions that take other functions as input. This is a key feature of FP languages because it makes it very easy to build modular programs. The result is that software written in FP languages tend to be very concise. Indeed, one group of programmers in Utrecht University was able to build a tool for "constructing, editing and analyzing Bayesian networks" in only 10 000 lines of Haskell code, graphical interface included. An equivalent program in Java took 200 000 lines, twenty times as much. Want to learn more? You could See also Procedural programming. Introduction. Programmers are procrastinators. Get in, get some coffee, check the mailbox, read the RSS feeds, read the news, check out latest articles on technical websites, browse through political discussions on the designated sections of the programming forums. Rinse and repeat to make sure nothing is missed. Go to lunch. Come back, stare at the IDE for a few minutes. Check the mailbox. Get some coffee. Before you know it, the day is over. The only thing, every once in a while challenging articles actually do pop up. If you're looking at the right places you'll find at least one of these every couple of days. These articles are hard to get through and take some time, so they start piling up. Before you know it, you have a list of links and a folder full of PDF files and you wish you had a year in a small hut in the middle of the forest with nobody around for miles so you could catch up. Would be nice if someone came in every morning while you're taking a walk down the river to bring some food and take out the garbage. I don't know about your list, but a large chunk of the articles in mine are about functional programming. These generally are the hardest to get through. Written in a dry academic language, even the "ten year Wall Street industry veterans" don't understand what functional programming (also referred to as "FP") articles are all about. If you ask a project manager in Citi Group or in Deutsche Bank1 why they chose to use JMS instead of Erlang they'll say they can't use academic languages for industrial strength applications. The problem is, some of the most complex systems with the most rigid requirements are written using functional programming elements. Something doesn't add up. It's true that FP articles and papers are hard to understand, but they don't have to be. The reasons for the knowledge gap are purely historical. There is nothing inherently hard about FP concepts. Consider this article "an accessible guide to FP", a bridge from our imperative minds into the world of FP. Grab a coffee and keep on reading. With any luck your coworkers will start making fun of you for your FP comments in no time. So what is FP? How did it come about? Is it edible? If it's as useful as its advocates claim, why isn't it being used more often in the industry? Why is it that only people with PhDs tend to use it? Most importantly, why is it so damn hard to learn? What is all this closure, continuation, currying, lazy evaluation and no side effects business? How can it be used in projects that don't involve a university? Why does it seem to be so different from everything good, and holy, and dear to our imperative hearts? We'll clear this up very soon. Let's start with explaining the reasons for the huge gap between the real world and academic articles. The answer is as easy as taking a walk in the park. A Walk In The Park. Fire up the time machine. Our walk in the park took place more than two thousand years ago, on a beautiful sunny day of a long forgotten spring in 380 B.C. Outside the city walls of Athens, under the pleasant shade of olive trees Plato was walking towards the Academy with a beautiful slave boy. The weather was lovely, the dinner was filling, and the conversation turned to philosophy. "Look at these two students", said Plato carefully picking words to make the question educational. "Who do you think is taller?" The slave boy looked towards the basin of water where two men were standing. "They're about the same height", he said. "What do you mean 'about the same'?", asked Plato. "Well, they look the same from here but I'm sure if I were to get closer I'd see that there is some difference." Plato smiled. He was leading the boy in the right direction. "So you would say that there is nothing perfectly equal in our world?" After some thinking the boy replied: "I don't think so. Everything is at least a little different, even if we can't see it." The point hit home! "Then if nothing is perfectly equal in this world, how do you think you understand the concept of 'perfect' equality?" The slave boy looked puzzled. "I don't know", he replied. So was born the first attempt to understand the nature of mathematics. Plato suggested that everything in our world is just an approximation of perfection. He also realized that we understand the concept of perfection even though we never encountered it. He came to conclusion that perfect mathematical forms must live in another world and that we somehow know about them by having a connection to that "alternative" universe. It's fairly clear that there is no perfect circle that we can observe. But we also understand what a perfect circle is and can describe it via equations. What is mathematics, then? Why is the universe described with mathematical laws? Can all of the phenomena of our universe be described by mathematics?2 Philosophy of mathematics is a very complex subject. Like most philosophical disciplines it is far more adept at posing questions rather than providing answers. Much of the consensus revolves around the fact that mathematics is really a puzzle: we set up a set of basic non-conflicting principles and a set of rules on how to operate with these principles. We can then stack these rules together to come up with more complex rules. Mathematicians call this method a "formal system" or a "calculus". We can effectively write a formal system for Tetris if we wanted to. In fact, a working implementation of Tetris "is" a formal system, just specified using an unusual representation. A civilization of furry creatures on Alpha Centauri would not be able to read our formalisms of Tetris and circles because their only sensory input might be an organ that senses smells. They likely will never find out about the Tetris formalism, but they very well might have a formalism for circles. We probably wouldn't be able to read it because our sense of smell isn't that sophisticated, but once you get past the "representation" of the formalism (via various sensory instruments and standard code breaking techniques to understand the "language"), the concepts underneath are understandable to any intelligent civilization. Interestingly if no intelligent civilization ever existed in the universe the formalisms for Tetris and circles would still hold water, it's just that nobody would be around to find out about them. If an intelligent civilization popped up, it would likely discover some formalisms that help describe the laws of our universe. They also would be very unlikely to ever find out about Tetris because there is nothing in the universe that resembles it. Tetris is one of countless examples of a formal system, a puzzle, that has nothing to do with the real world. We can't even be sure that natural numbers have full resemblance to the real world, after all one can easily think of a number so big that it cannot describe anything in our universe since it might actually turn out to be finite. A Bit of History3. Let's shift gears in our time machine. This time we'll travel a lot closer, to the 1930s. The Great Depression was ravaging the New and the Old worlds. Almost every family from every social class was affected by the tremendous economic downturn. Very few sanctuaries remained where people were safe from the perils of poverty. Few people were fortunate enough to be in these sanctuaries, but they did exist. Our interest lies in mathematicians in Princeton University. The new offices constructed in Gothic style gave Princeton an aura of a safe haven. Logicians from all over the world were invited to Princeton to build out a new department. While most of America couldn't find a piece of bread for dinner, high ceilings, walls covered with elaborately carved wood, daily discussions by a cup of tea, and walks in the forest were some of the conditions in Princeton. One mathematician living in such lavish lifestyle was a young man named Alonzo Church. Alonzo received a B.S. degree from Princeton and was persuaded to stay for graduate school. Alonzo felt the architecture was fancier than necessary. He rarely showed up to discuss mathematics with a cup of tea and he didn't enjoy the walks in the woods. Alonzo was a loner: he was most productive when working on his own. Nevertheless Alonzo had regular contacts with other Princeton inhabitants. Among them were Alan Turing, John von Neumann, and Kurt Gödel. The four men were interested in formal systems. They didn't pay much heed to the physical world, they were interested in dealing with abstract mathematical puzzles instead. Their puzzles had something in common: the men were working on answering questions about "computation." If we had machines that had infinite computational power, what problems would we be able to solve? Could we solve them automatically? Could some problems remain unsolved and why? Would various machines with different designs be equal in power? In cooperation with other men Alonzo Church developed a formal system called lambda calculus. The system was essentially a programming language for one of these imaginary machines. It was based on functions that took other functions as parameters and returned functions as results. The function was identified by a Greek letter lambda, hence the system's name4. Using this formalism Alonzo was able to reason about many of the above questions and provide conclusive answers. Independently of Alonzo Church, Alan Turing was performing similar work. He developed a different formalism (now referred to as the Turing machine), and used it to independently come to similar conclusions as Alonzo. Later it was shown that Turing machines and lambda calculus were equivalent in power. This is where the story would stop, I'd wrap up the article, and you'd navigate to another page, if not for the beginning of World War II. The world was in flames. The U.S. Army and Navy used artillery more often than ever. In attempts to improve accuracy the Army employed a large group of mathematicians to continuously calculate differential equations required for solving ballistic firing tables. It was becoming obvious that the task was too great for being solved manually and various equipment was developed in order to overcome this problem. The first machine to solve ballistic tables was a Mark I built by IBM - it weighed five tons, had 750,000 parts and could do three operations per second. The race, of course, wasn't over. In 1949 an Electronic Discrete Variable Automatic Computer ("EDVAC") was unveiled and had tremendous success. It was a first example of von Neumann's architecture and was effectively a real world implementation of a Turing machine. For the time being Alonzo Church was out of luck. In late 1950s an MIT professor John McCarthy (also a Princeton graduate) developed interest in Alonzo Church's work. In 1958 he unveiled a List Processing language (Lisp). Lisp was an implementation of Alonzo's lambda calculus that worked on von Neumann computers! Many computer scientists recognized the expressive power of Lisp. In 1973 a group of programmers at MIT's Artificial Intelligence Lab developed hardware they called a Lisp machine - effectively a native hardware implementation of Alonzo's lambda calculus! Functional Programming. Functional programming is a practical implementation of Alonzo Church's ideas. Not all lambda calculus ideas transform to practice because lambda calculus was not designed to work under physical limitations. Therefore, like object oriented programming, functional programming is a set of ideas, not a set of strict guidelines. There are many functional programming languages, and most of them do many things very differently. In this article I will explain the most widely used ideas from functional languages using examples written in Java (yes, you could write functional programs in Java if you felt particularly masochistic). In the next couple of sections we'll take Java as is, and will make modifications to it to transform it into a usable functional language. Let's begin our quest. Lambda calculus was designed to investigate problems related to "calculation." Functional programming, therefore, primarily deals with calculation, and, surprisingly, uses functions to do so. A function is a very basic unit in functional programming. Functions are used for almost everything, even the simplest of calculations. Even variables are replaced with functions. In functional programming variables are simply aliases for expressions (so we don't have to type everything on one line). They cannot be modified. All variables can only be assigned to once. In Java terms this means that every single variable is declared as "final" (or "const" if we're dealing with C++). There are no non-final variables in FP. final int i = 5; final int j = i + 3; Since every variable in FP is final two fairly interesting statements can be made. It does not make sense to always write the keyword "final" and it does not make sense to call variables, well... variables. We will now make two modifications to Java: every variable declared in our functional Java will be final by default, and we will refer to variables as "symbols." By now you are probably wondering how you could possibly write anything reasonably complicated in our newly created language. If every symbol is non-mutable we cannot change the state of anything! This isn't strictly true. When Alonzo was working on lambda calculus he wasn't interested in maintaining state over periods of time in order to modify it later. He was interested in performing operations on data (also commonly referred to as "calculating stuff"). However, it was proved that lambda calculus is equivalent to a Turing machine. It can do all the same things an imperative programming language can. How, then, can we achieve the same results? It turns out that functional programs can keep state, except they don't use variables to do it. They use functions instead. The state is kept in function parameters, on the stack. If you want to keep state for a while and every now and then modify it, you write a recursive function. As an example, let's write a function that reverses a Java string. Remember, every variable we declare is final by default5. String reverse(String arg) { if(arg.length == 0) { return arg; else { return reverse(arg.substring(1, arg.length)) + arg.substring(0, 1); This function is slow because it repeatedly calls itself6. It's a memory hog because it repeatedly allocates objects. But it's functional in style. You may be interested why someone would want to program in this manner. Well, I was just about to tell you. Benefits of FP. You're probably thinking that there's no way I can rationalize the monstrosity of a function above. When I was learning functional programming I was thinking that too. I was wrong. There are very good arguments for using this style. Some of them are subjective. For example, people claim that functional programs are easier to understand. I will leave out these arguments because every kid on the block knows that ease of understanding is in the eye of the beholder. Fortunately for me, there are plenty of objective arguments. Unit Testing. Since every symbol in FP is final, no function can ever cause side effects. You can never modify things in place, nor can one function modify a value outside of its scope for another function to use (like a class member or a global variable). That means that the only effect of evaluating a function is its return value and the only thing that affects the return value of a function is its arguments. This is something unit testers will find very useful. You can test every function in your program only worrying about its arguments. You don't have to worry about calling functions in the right order, or setting up external state properly. This means you can spend less time worrying about writing mocks, stubs and other forms of fake objects and less time verifying that setup and tear down methods are run by the test suite. All you need to do is pass arguments that represent edge cases. If every function in your program passes unit tests you can be a lot more confident about quality of your software than if you were using an imperative language. In Java or C++ checking a return value of a function is not sufficient - it may modify external state that we would need to verify. Not so in a functional language. Debugging. If a functional program doesn't behave the way you expect it to, debugging it is a breeze. You will always be able to reproduce your problem because a bug in a functional program doesn't depend on unrelated code paths that were executed before it. In an imperative program a bug resurfaces only some of the time. Because functions depend on external state produced by side effects from other functions you may have to go through a series of steps in no way related to the bug. In a functional program this isn't the case - if a return value of a function is wrong, it is "always" wrong, regardless of what code you execute before running the function. Once you reproduce the problem, getting to the bottom of it is trivial. It is almost pleasant. You break the execution of your program and examine the stack. Every argument in every function call in the stack is available for your inspection, just like in an imperative program. Except in an imperative program that's not enough because functions depend on member variables, global variables, and the state of other classes (which in turn depend on these very same things). A function in a functional program depends "only" on its arguments, and that information is right before your eyes! Furthermore, in an imperative program examining a return value of a function will not give you a good idea of whether the function behaves properly. You need to hunt down dozens of objects outside its scope to verify that it performed correct actions. In a functional program all you have to do is look at the return value! Walking through the stack you look at arguments passed to functions and their return values. The minute a return value doesn't make sense you step into the offending function and walk through it. You repeat this recursively until the process leads you to the source of the bug! Concurrency. A functional program is ready for concurrency without any further modifications. You never have to worry about deadlocks and race conditions because you don't need to use locks! No piece of data in a functional program is modified twice by the same thread, let alone by two different threads. That means you can easily add threads without ever giving conventional problems that plague concurrency applications a second thought! If this is the case, why doesn't anybody use functional programs for highly concurrent applications? Well, it turns out that they do. Ericsson designed a functional language called Erlang for use in its highly tolerant and scalable telecommunication switches. Many others recognized the benefits provided by Erlang and started using it. We're talking about telecommunication and traffic control systems that are far more scalable and reliable than typical systems designed on Wall Street. Erlang systems are simply rock solid. The concurrency story doesn't stop here. If your application is inherently single threaded the compiler can still optimize functional programs to run on multiple CPUs. Take a look at the following code fragment: String s1 = somewhatLongOperation1(); String s2 = somewhatLongOperation2(); String s3 = concatenate(s1, s2); In a functional language the compiler could analyze the code, classify the functions that create strings "s1" and "s2" as potentially time consuming operations, and run them concurrently. This is impossible to do in an imperative language because each function may modify state outside of its scope and the function following it may depend on it. In functional languages automatic analysis of functions and finding good candidates for concurrent execution is as trivial as automatic inlining! In this sense functional style programs are "future proof" (as much as I hate buzzwords, I'll indulge this time). Hardware manufacturers can no longer make CPUs run any faster. Instead they increase the number of cores and attribute quadruple speed increases to concurrency. Of course they conveniently forget to mention that we get our money's worth only on software that deals with parallelization problems. This is a very small fraction of imperative software but 100% of functional software because functional programs all support parallelization out of the box. Hot Code Deployment. In the old days of Windows in order to install updates it was necessary to restart the computer. Many times. After installing a newer version of a media player. With Windows XP the situation has improved significantly, yet it still isn't ideal (I ran Windows Update at work today and now an annoying system tray icon won't go away until I restart). Unix systems have had a better model for a while. In order to install an update you only need to stop relevant components, not the whole OS. While it is a better situation, for a large class of server applications it still isn't acceptable. Telecommunication systems need to be up 100% of the time because if dialing emergency is not available due to upgrades, lives may be lost. There is no reason Wall Street firms need to bring down their systems to install software updates over the weekend. An ideal situation is updating relevant parts of the code without stopping any part of the system at all. In an imperative world this isn't possible. Consider unloading a Java class at runtime and reloading a new definition. If we were to do that every instance of a class would become unusable because the state it holds would be lost. We would need to resort to writing tricky version control code. We'd need to serialize all running instances of the class, destroy them, create instances of the new class, try to load serialized data into them hoping the loading code properly migrates the data to work with the new instance. On top of that, every time we change something we'd have to write our migration code manually. And our migration code would have to take special care not to break relationships between objects. Nice in theory, but would never work well in practice. In a functional program all state is stored on the stack in the arguments passed to functions. This makes hot deployment significantly easier! In fact, all we'd really have to do is run a diff between the code in production and the new version, and deploy the new code. The rest could be done by language tools automatically! If you think this is science fiction, think again. Erlang engineers have been upgrading live systems without stopping them for years. Machine Assisted Proofs and Optimizations. An interesting property of functional languages is that they can be reasoned about mathematically. Since a functional language is simply an implementation of a formal system, all mathematical operations that could be done on paper still apply to the programs written in that language. The compiler could, for example, convert pieces of code into equivalent but more efficient pieces with a mathematical proof that two pieces of code are equivalent7. Relational databases have been performing these optimizations for years. There is no reason the same techniques can't apply to regular software. Additionally, you can use these techniques to prove that parts of your program are correct. It is even possible to create tools that analyze code and generate edge cases for unit tests automatically! This functionality is invaluable for rock solid systems. If you are designing pace makers and air traffic control systems such tools are almost always a requirement. If you are writing an application outside of truly mission critical industries, these tools can give you a tremendous edge over your competitors. Higher Order Functions. I remember learning about the benefits I outlined above and thinking "that's all very nice but it's useless if I have to program in a crippled language where everything is final." This was a misconception. Making all variables final "is" crippled in a context of an imperative language like Java but it isn't in a context of functional languages. Functional languages offer a different kind of abstraction tools that make you forget you've ever "liked" modifying variables. One such tool is capability to work with "higher order functions." A function in such languages is different from a function in Java or C. It is a superset - it can do all the things a Java function can do, and more. We create a function in the same manner we do in C: int add(int i, int j) { return i + j; This means something different from equivalent C code. Let's extend our Java compiler to support this notation. When we type something like this our compiler will convert it to the following Java code (don't forget, everything is final): class add_function_t { int add(int i, int j) { return i + j; add_function_t add = new add_function_t(); The symbol "add" isn't really a function. It is a small class with one function as its member. We can now pass "add" around in our code as an argument to other functions. We can assign it to another symbol. We can create instances of "add_function_t" at runtime and they will be garbage collected when we no longer need them. This makes functions "first class objects" no different from integers or strings. Functions that operate on other functions (accept them as arguments) are called "higher order functions." Don't let this term intimidate you, it's no different from Java classes that operate on each other (we can pass class instances to other classes). We can call them "higher order classes" but nobody cares to because there is no strong academic community behind Java. How, and when, do you use higher order functions? Well, I'm glad you asked. You write your program as a big monolithic blob of code without worrying about class hierarchies. When you see that a particular piece of code is repeated, you break it out into a function (fortunately they still teach this in schools). If you see that a piece of logic within your function needs to behave differently in different situations, you break it out into a higher order function. Confused? Here's a real life example from my work. Suppose we have a piece of Java code that receives a message, transforms it in various ways, and forwards it to another server. class MessageHandler { void handleMessage(Message msg) { msg.setClientCode("ABCD_123"); sendMessage(msg); Now imagine that our system has changed and we now route messages to two servers instead of one. Everything is handled in exactly the same way except the client code - the second server wants it in a different format. How do we handle this situation? We could check where the message is headed and format the client code differently, like this: class MessageHandler { void handleMessage(Message msg) { if(msg.getDestination().equals("server1") { msg.setClientCode("ABCD_123"); } else { msg.setClientCode("123_ABC"); // ... sendMessage(msg); This approach, however, isn't scalable. If more servers are added our function will grow linearly and we'll have a nightmare updating it. An object oriented approach is to make "MessageHandler" a base class and specialize the client code operation in derived classes: abstract class MessageHandler { void handleMessage(Message msg) { msg.setClientCode(getClientCode()); sendMessage(msg); abstract String getClientCode(); // ... class MessageHandlerOne extends MessageHandler { String getClientCode() { return "ABCD_123"; class MessageHandlerTwo extends MessageHandler { String getClientCode() { return "123_ABCD"; We can now instantiate an appropriate class for each server. Adding servers becomes much more maintainable. That's a lot of code for such a simple modification though. We have to create two new types just to support different client codes! Now let's do the same thing in our language that supports higher order functions: class MessageHandler { void handleMessage(Message msg, Function getClientCode) { Message msg1 = msg.setClientCode(getClientCode()); sendMessage(msg1); String getClientCodeOne() { return "ABCD_123"; String getClientCodeTwo() { return "123_ABCD"; MessageHandler handler = new MessageHandler(); handler.handleMessage(someMsg, getClientCodeOne); We've created no new types and no class hierarchy. We simply pass appropriate functions as a parameter. We've achieved the same thing as the object oriented counterpart with a number of advantages. We don't restrict ourselves to class hierarchies: we can pass new functions at runtime and change them at any time with a much higher degree of granularity with less code. Effectively the compiler has written object oriented "glue" code for us! In addition we get all the other benefits of FP. Of course the abstractions provided by functional languages don't stop here. Higher order functions are just the beginning. Currying. Most people I've met have read the Design Patterns book by the Gang of Four. Any self respecting programmer will tell you that the book is language agnostic and the patterns apply to software engineering in general, regardless of which language you use. This is a noble claim. Unfortunately it is far removed from the truth. Functional languages are extremely expressive. In a functional language one does not need design patterns because the language is likely so high level, you end up programming in concepts that eliminate design patterns all together. Once such pattern is an Adapter pattern (how is it different from Facade again? Sounds like somebody needed to fill more pages to satisfy their contract). It is eliminated once a language supports a technique called "currying". Adapter pattern is best known when applied to the "default" abstraction unit in Java - a class. In functional languages the pattern is applied to functions. The pattern takes an interface and transforms it to another interface someone else expects. Here's an example of an adapter pattern: int pow(int i, int j); int square(int i) return pow(i, 2); The code above adapts an interface of a function that raises an integer to an integer power to an interface of a function that squares an integer. In academic circles this trivial technique is called currying (after a logician Haskell Curry who performed mathematical acrobatics necessary to formalize it). Because in FP functions (as opposed to classes) are passed around as arguments, currying is used very often to adapt functions to an interface that someone else expects. Since the interface to functions is its arguments, currying is used to reduce the number of arguments (like in the example above). Functional languages come with this technique built in. You don't need to manually create a function that wraps the original, functional languages will do that for you. As usual, let's extend our language to support this technique. square = int pow(int i, 2); This will automatically create a function "square" for us with one argument. It will call "pow" function with the second argument set to "2". This will get compiled to the following Java code: class square_function_t { int square(int i) { return pow(i, 2); square_function_t square = new square_function_t(); As you can see, we've simply created a wrapper for the original function. In FP currying is just that - a shortcut to quickly and easily create wrappers. You concentrate on your task, and the compiler writes the appropriate code for you! When do you use currying? This should be easy. Any time you'd like to use an adapter pattern (a wrapper). Lazy Evaluation. Lazy (or delayed) evaluation is an interesting technique that becomes possible once we adopt a functional philosophy. We've already seen the following piece of code when we were talking about concurrency: String s1 = somewhatLongOperation1(); String s2 = somewhatLongOperation2(); String s3 = concatenate(s1, s2); In an imperative language the order of evaluation would be clear. Because each function may affect or depend on an external state it would be necessary to execute them in order: first "somewhatLongOperation1", then "somewhatLongOperation2", followed by "concatenate". Not so in functional languages. As we saw earlier "somewhatLongOperation1" and "somewhatLongOperation2" can be executed concurrently because we're guaranteed no function affects or depends on global state. But what if we don't want to run the two concurrently, do we need to run them in order? The answer is no. We only need to run these operations when another function depends on "s1" and "s2". We don't even have to run them before "concatenate" is called - we can delay their evaluation until they're required within "concatenate". If we replace "concatenate" with a function that has a conditional and uses only one of its two parameters we may never evaluate one of the parameters at all! Haskell is an example of a delayed evaluation language. In "Haskell" you are not guaranteed that anything will be executed in order (or at all) because "Haskell" only executes code when it's required. Lazy evaluation has numerous advantages as well as disadvantages. We will discuss the advantages here and will explain how to counter the disadvantages in the next section. Optimization. Lazy evaluation provides a tremendous potential for optimizations. A lazy compiler thinks of functional code exactly as mathematicians think of an algebra expression - it can cancel things out and completely prevent execution, rearrange pieces of code for higher efficiency, even arrange code in a way that reduces errors, all guaranteeing optimizations won't break the code. This is the biggest benefit of representing programs strictly using formal primitives - code adheres to mathematical laws and can be reasoned about mathematically. Abstracting Control Structures. Lazy evaluation provides a higher order of abstraction that allows implementing things in a way that would otherwise be impossible. For example consider implementing the following control structure: unless(stock.isEuropean()) { sendToSEC(stock); We want "sendToSEC" executed unless the stock is European. How can we implement "unless"? Without lazy evaluation we'd need some form of a macro system, but in a language like Haskell that's unnecessary. We can implement "unless" as a function! void unless(boolean condition, List code) { if(!condition) code; Note that "code" is never evaluated if the condition is true. We cannot reproduce this behavior in a strict language because the arguments would be evaluated before "unless" is entered. Infinite Data Structures. Lazy languages allow for definition of infinite data structures, something that's much more complicated in a strict language. For example, consider a list with Fibonacci numbers. We clearly can't compute an infinite list in a reasonable amount of time or store it in memory. In strict languages like Java we simply define a Fibonacci function that returns a particular member from the sequence. In a language like Haskell we can abstract it further and simply define an infinite list of Fibonacci numbers. Because the language is lazy, only the necessary parts of the list that are actually used by the program are ever evaluated. This allows for abstracting a lot of problems and looking at them from a higher level (for example, we can use list processing functions on an infinite list). Disadvantages. Of course there ain't no such thing as a free lunch™. (Unless you're lucky.) It seems that lazy evaluation comes with a number of disadvantages. Mainly that it is, well, lazy, and sometimes doesn't allow the programmer to also be so to their heart's content, meaning, you need to employ some workarounds in certain cases. There are real world problems that require strict evaluation. For example consider the following: System.out.println("Please enter your name: "); System.in.readLine(); In a lazy language you have no guarantee that the first line will be executed before the second! This means, if laziness were an absolute principle, we wouldn't be able to do IO, to use native functions in any meaningful way (because they need to be called in order since they depend on side effects), and couldn't interact with the outside world! If we were to introduce primitives that force ordered code execution we'd lose the ability of reasoning about our code mathematically (which would take all of the benefits of functional programming with it). Fortunately not all is lost. Mathematicians got to work and developed a number of tricks to ensure code gets executed in particular order in a functional setting. So we really get the best of both worlds! These techniques include continuations, monads, and uniqueness typing. In this article we'll only deal with continuations. We'll leave monads and uniqueness typing for another time. Interestingly, continuations are useful for many things other than enforcing a particular order of evaluation. We'll talk about that as well. Continuations. Continuations to programming are what the "Da Vinci Code" supposedly is to human history: an amazing revelation of the greatest cover-up known to man. Well, maybe not, but they're certainly revealing of deceit in the same sense as square roots of negative numbers. When we learned about functions we only learned half truths based on a faulty assumption that functions must return their value to the original caller. In this sense continuations are a generalization of functions. A function must not necessarily return to its caller and may return to any part of the program. A "continuation" is a parameter we may choose to pass to our function that specifies where the function should return. The description may be more complicated than it sounds. Take a look at the following code: int i = add(5, 10); int j = square(i); The function "add" returns "15" to be assigned to "i", the place where "add" was originally called. After that the value of "i" is used to call "square". Note that a lazy compiler can't rearrange these lines of code because the second line depends on successful evaluation of the first. We can rewrite this code block using "Continuation Passing Style" or "CPS", where the function "add" doesn't return to the original caller but instead returns its result to "square". int j = add(5, 10, square); In this case "add" gets another parameter - a function that "add" must call with its result upon completion. In this case "square" is a continuation of "add". In both cases "j" will equal "225". Here lays the first trick to force a lazy language to evaluate two expressions in order. Consider the following (familiar) IO code: System.out.println("Please enter your name: "); System.in.readLine(); The two lines don't depend on each other and the compiler is free to rearrange them as it wishes. However, if we rewrite this code in CPS, there will be a dependency and the compiler will be forced to evaluate the two lines in order! System.out.println("Please enter your name: ", System.in.readLine); In this case "println" needs to call "readLine" with its result and return the result of "readLine". This allows us to ensure that the two lines are executed in order "and" that "readLine" is evaluated at all (because the whole computation expects the last value as a result). In case of Java "println" returns "void" but if it were to return an abstract value (that "readLine" would accept), we'd solve our problem! Of course chaining function calls like that will quickly become unreadable, but it isn't necessary. We could add syntactic sugar to the language that will allow us to simply type expressions in order, and the compiler would chain the calls for us automatically. We can now evaluate expressions in any order we wish without losing any of the benefits of FP (including the ability to reason about our programs mathematically)! If this is still confusing, remember that a function is just an instance of a class with one member. Rewrite above two lines so that "println" and "readLine" are instances of classes and everything will become clear. I would now wrap up this section, except that we've only scratched the surface of continuations and their usefulness. We can write entire programs in CPS, where every function takes an extra continuation argument and passes the result to it. We can also convert any program to CPS simply by treating functions as special cases of continuations (functions that always return to their caller). This conversion is trivial to do automatically (in fact, many compilers do just that). Once we convert a program to CPS it becomes clear that every instruction has some continuation, a function it will call with the result, which in a regular program would be a place it must return to. Let's pick any instruction from above code, say "add(5, 10)". In a program written in CPS style it's clear what "add"'s continuation is - it's a function that "add" calls once it's done. But what is it in a non-CPS program? We could, of course, convert the program to CPS, but do we have to? It turns out that we don't. Look carefully at our CPS conversion. If you try to write a compiler for it and think about it long enough you'll realize that the CPS version needs no stack! No function ever "returns" in the traditional sense, it just calls another function with the result instead. We don't need to push function arguments on the stack with every call and then pop them back, we can simply store them in some block of memory and use a jump instruction instead. We'll never need the original arguments - they'll never be used again since no function ever returns! So, programs written in CPS style have no stack but have an extra argument with a function to call. Programs not written in CPS style have no argument with a function to call, but have the stack instead. What does the stack contain? Simply the arguments, and a pointer to memory where the function should return. Do you see a light bulb? The stack simply contains continuation information! The pointer to the return instruction in the stack is essentially the same thing as the function to call in CPS programs! If you wanted to find out what continuation for "add(5, 10)" is, you'd simply have to examine the stack at the point of its execution! So that was easy. A continuation and a pointer to the return instruction in the stack are really the same thing, only a continuation is passed explicitly, so that it doesn't need to be the same place where the function was called from. If you remember that a continuation is a function, and a function in our language is compiled to an instance of a class, you'll realize that a pointer to the return instruction in the stack and the continuation argument are "really" the same thing, since our function (just like an instance of a class) is simply a pointer. This means that at any given point in time in your program you can ask for a "current continuation" (which is simply the information on the stack). Ok, so we know what a current continuation is. What does it mean? When we get a current continuation and store it somewhere, we end up storing the current state of our program - freezing it in time. This is similar to an OS putting itself into hibernation. A continuation object contains the information necessary to restart the program from the point where the continuation object was acquired. An operating system does this to your program all the time when it context switches between the threads. The only difference is that it keeps all the control. If you ask for a continuation object (in Scheme this is done by calling "call-with-current-continuation" function) you'll get an object that contains the current continuation - the stack (or in a CPS case the function to call next). You can store this object in a variable (or alternatively, on disk). When you choose to "restart" your program with this continuation object you will "transform" to the state of the program when you grabbed the continuation object. It's the same thing as switching back to a suspended thread or waking up an OS from hibernation, except you can do it again and again. When an OS wakes up, the hibernation information is destroyed. If it wasn't, you'd be able to wake up from the same point over and over again, almost like going back in time. You have that control with continuations! In what situations are continuations useful? Usually when you're trying to simulate state in an application of inherently stateless nature to ease your life. A great application of continuations are web applications. Microsoft's ASP.NET goes to tremendous lengths to try and simulate state so that you can write your application with less hassle. If C# supported continuations half of ASP.NET's complexity would disappear - you'd simply store a continuation and restart it when a user makes the web request again. To a programmer of the web application there would be no interruption - the program would simply start from the next line! Continuations are an incredibly useful abstraction for some problems. Considering that many of the traditional fat clients are moving to the web, continuations will become more and more important in the future. Pattern Matching. Pattern matching is not a new or innovative feature. In fact, it has little to do with functional programming. The only reason why it's usually attributed to FP is that functional languages have had pattern matching for some time, while modern imperative languages still don't. Let's dive into pattern matching with an example. Here's a Fibonacci function in Java: int fib(int n) { if(n == 0) return 1; if(n == 1) return 1; return fib(n - 2) + fib(n - 1); And here's an example of a Fibonacci function in our Java-derived language that supports pattern matching: int fib(0) { return 1; int fib(1) { return 1; int fib(int n) { return fib(n - 2) + fib(n - 1); What's the difference? The compiler implements branching for us. What's the big deal? There isn't any. Someone noticed that a large number of functions contain very complicated switch statements (this is particularly true about functional programs) and decided that it's a good idea to abstract that away. We split the function definition into multiple ones, and put patterns in place of some arguments (sort of like overloading). When the function is called, the compiler compares the arguments with the definitions at runtime, and picks the correct one. This is usually done by picking the most specific definition available. For example, "int fib(int n)" can be called with "n" equal to "1", but it isn't because "int fib(1)" is more specific. Another possibility, which you find in Haskell, is to check the patterns in the order they are defined (one of the few cases where the order of the expressions in a functional program matters, but most of your code can be written in any order you wish, which is very convenient.) For example, a function's argument might be tested against three patterns, fun (x < 100), fun (x < 1000), fun (x = anything), and when called with x = 50 the first instance of its definition will be used, although x = 50 also would fit the other two. (And in a mathematical sense, taking into account negative numbers, none of these definitions is more specific since the sets of matching patterns all have the same infinite size.) In this system you usually order your definitions so that the more specific ones come first, which automatically encompasses the other way of deciding which instance of the function will be used. Pattern matching is usually more complex than our example reveals. For example, an advanced pattern matching system will allow us to do the following: When is pattern matching useful? In a surprisingly large number of cases! Every time you have a complex structure of nested "if"s, pattern matching can do a better job with less code on your part. A good function that comes to mind is a standard "WndProc" function that all Win32 applications must provide (even though it's often abstracted away). Usually a pattern matching system can examine collections as well as simple values. For example, if you pass an array to your function you could pick out all arrays in which the first element is equal to "1" and the third element is greater than "3". Another benefit of pattern matching is that if you need to add or modify conditions, you don't have to go into one huge function. You simply add (or modify) appropriate definitions. This eliminates the need for a whole range of design patterns from the Gang of Four book. The more complex your conditions are, the more pattern matching will help you. Once you're used to it, you start wondering how you ever got through your day without it. Closures. So far we've discussed features in the context of "pure" functional languages - languages that are implementations of lambda calculus and don't include features that conflict with Church's formalism. However, many of the features of functional languages are useful outside of lambda calculus framework. While an implementation of an axiomatic system is useful because it allows thinking about programs in terms of mathematical expressions, it may or may not be practical. Many languages choose to incorporate functional elements without strictly adhering to functional doctrine. Many such languages (like Common Lisp) don't require variables to be final - you can modify things in place. They also don't require functions to depend only on their arguments - functions are allowed to access state outside of their boundaries. But they do include functional features - like higher order functions. Passing functions around in impure languages is a little bit different than doing it in the confines of lambda calculus and requires support for an interesting feature often referred to as lexical closure. Let's take a look at some sample code. Remember, in this case variables aren't final and functions can refer to variables outside of their scope: Function makePowerFn(int power) { int powerFn(int base) { return pow(base, power); return powerFn; Function square = makePowerFn(2); square(3); // returns 9 The function "makePowerFn" returns a function that takes a single argument and raises it to a certain power. What happens when we try to evaluate "square(3)"? The variable "power" isn't anywhere in scope of "powerFn" because "makePowerFn" has returned and its stack is long gone. How can "square" work, then? The language must, somehow, store the value of "power" somewhere for "square" to work. What if we create another function, "cube", that raises something to the third power? The runtime must now store two copies of power, one for each function we generated using "makePowerFn". The phenomenon of storing these values is called a "closure". Closures don't only store arguments of a host function. For example, a closure can look like this: Function makeIncrementer() { int n = 0; int increment() { return ++n; Function inc1 = makeIncrementer(); Function inc2 = makeIncrementer(); inc1(); // returns 1; inc1(); // returns 2; inc1(); // returns 3; inc2(); // returns 1; inc2(); // returns 2; inc2(); // returns 3; The runtime manages to store "n", so incrementers can access it. Furthermore, it stores various copies, one for each incrementer, even though they're supposed to disappear when "makeIncrementer" returns. What does this code compile to? How do closures work behind the scenes? Fortunately, we have a back stage pass. A little common sense goes a long way. The first observation is that local variables are no longer limited to simple scope rules and have an undefined lifetime. The obvious conclusion is that they're no longer stored on the stack - they must be stored on the heap instead8. A closure, then, is implemented just like a function we discussed earlier, except that it has an additional reference to the surrounding variables: class some_function_t { SymbolTable parentScope; // ... When a closure references a variable that's not in its local scope, it consults this reference for a parent scope. That's it! Closures bring functional and OO worlds closer together. Every time you create a class that holds some state and pass it to somewhere else, think of closures. A closure is just an object that creates "member variables" on the fly by grabbing them from the scope, so you don't have to! What's next? This article only scratches the surface of functional programming. Sometimes a small scratch can progress to something bigger and in our case it's a good thing. In the future I plan to write about category theory, monads, functional data structures, type systems in functional languages, functional concurrency, functional databases and much more. If I get to write (and in the process learn) about half of these topics my life will be complete. In the meantime, Google is our friend. Comments? If you have any questions, comments, or suggestions, please drop a note at [email protected]. I'll be glad to hear your feedback. 1When I was looking for a job in the fall of 2005 I often did ask this question. It's quite amusing how many blank stares I got. You would think that at about $300,000 a piece these people would at least have a good understanding of most tools available to them. 2This appears to be a controversial question. Physicists and mathematicians are forced to acknowledge that it isn't at all clear whether everything in the universe obeys the laws that can be described by mathematics. 3I've always hated history lessons that offer a dry chronology of dates, names, and events. To me history is about the lives of people who changed the world. It is about their private reasons behind their actions, and the mechanisms by which they affected millions of souls. For this reason this history section is hopelessly incomplete. Only very relevant people and events are discussed. 4When I was learning about functional programming I was very annoyed by the term "lambda" because I couldn't really understand what it really means. In this context lambda is a function, the single Greek letter was just easier to write in a mathematical notation. Every time you hear "lambda" when talking about functional programming just translate it in your mind to "function". 5Interestingly Java strings are immutable anyway. It's rather interesting to explore the reasons for this treachery, but that would distract us from our goal. 6Most functional language compilers optimize recursive functions by transforming them to their iterative alternatives whenever possible. This is called a tail call optimization. 7The opposite isn't always true. While it is sometimes possible to prove that two pieces of code are equivalent, it isn't possible in all situations. 8This is actually no slower than storing on the stack because once you introduce a garbage collector, memory allocation becomes an O(1) operation.
12,540
Computer Programming/Functional programming/At a glance. Characteristics. . In such cases we generally write recursive functions to do the same computation. Features. Here are some typical features of functional languages The languages. There are many so-called functional languages. The most widely used pure functional languages (that is, ones whose programs have no side effects) are Haskell and Erlang. Other popular functional languages which are not pure in the strict sense but still support the functional programming style in its full splendor are ML, Objective Caml, Scheme and .
121
C Programming/Libraries. A "library" in C is a collection of header files, exposed for use by other programs. The library therefore consists of an "interface" expressed in a codice_1 file (named the "header") and an "implementation" expressed in a codice_2 file. This codice_2 file might be precompiled or otherwise inaccessible, or it might be available to the programmer. (Note: Libraries may call functions in other libraries such as the Standard C or math libraries to do various tasks.) The format of a library varies with the operating system and compiler one is using. For example, in the Unix and Linux operating systems, a library consists of one or more "object files", which consist of object code that is usually the output of a compiler (if the source language is C or something similar) or an assembler (if the source language is assembly language). These object files are then turned into a library in the form of an archive by the "ar" archiver (a program that takes files and stores them in a bigger file without regard to compression). The filename for the library usually starts with "lib" and ends with ".a"; e.g. the "libc.a" file contains the Standard C library and the "libm.a" the mathematics routines, which the linker would then link in. Other operating systems such as Microsoft Windows use a ".lib" extension for libraries and an ".obj" extension for object files. Some programs in the Unix environment such as lex and yacc generate C code that can be linked with the libl and liby libraries to create an executable. We're going to use as an example a library that contains one function: a function to parse arguments from the command line. Arguments on the command line could be by themselves: -i have an optional argument that is concatenated to the letter: -ioptarg or have the argument in a separate argv-element: -i optarg The library also has four declarations that it exports in addition to the function: three integers and a pointer to the optional argument. If the argument does not have an optional argument, the pointer to the optional argument will be null. In order to parse all these types of arguments, we have written the following "getopt.c" file: /* variables */ int opterr = 1; /* getopt prints errors if this is on */ int optind = 1; /* token pointer */ int optopt; /* option character passed back to user */ char *optarg; /* flag argument (or value) */ /* function */ /* return option character, EOF if no more or ? if problem. The arguments to the function: argc, argv - the arguments to the main() function. An argument of "--" stops the processing. opts - a string containing the valid option characters. an option character followed by a colon (:) indicates that the option has a required argument. int getopt (int argc, char **argv, char *opts) static int sp = 1; /* character index into current token */ register char *cp; /* pointer into current token */ if (sp == 1) /* check for more flag-like tokens */ if (optind >= argc || argv[optind][0] != '-' || argv[optind][1] == '\0') return EOF; else if (strcmp (argv[optind], "--") == 0) optind++; return EOF; optopt = argv[optind][sp]; if (optopt == ':' || (cp = strchr (opts, optopt)) == NULL) if (opterr) fprintf (stderr, "%s: invalid option -- '%c'\n", argv[0], optopt); /* if no characters left in this token, move to next token */ if (argv[optind][++sp] == '\0') optind++; sp = 1; return '?'; if (*++cp == ':') /* if a value is expected, get it */ if (argv[optind][sp + 1] != '\0') /* flag value is rest of current token */ optarg = argv[optind++] + (sp + 1); else if (++optind >= argc) if (opterr) fprintf (stderr, "%s: option requires an argument -- '%c'\n", argv[0], optopt); sp = 1; return '?'; else /* flag value is next token */ optarg = argv[optind++]; sp = 1; else /* set up to look at next char in token, next time */ if (argv[optind][++sp] == '\0') /* no more in current token, so setup next token */ sp = 1; optind++; optarg = 0; return optopt; /* END OF FILE */ The interface would be the following "getopt.h" file: #define GETOPT_H /* exported variables */ extern int opterr, optind, optopt; extern char *optarg; /* exported function */ int getopt(int, char **, char *); /* END OF FILE */ At a minimum, a programmer has the interface file to figure out how to use a library, although, in general, the library programmer also wrote documentation on how to use the library. In the above case, the documentation should say that the provided arguments codice_4 and codice_5 both shouldn't be null pointers (or why would you be using the codice_6 function anyway?). Specifically, it typically states what each parameter is for and what return values can be expected in which conditions. Programmers that use a library, are normally not interested in the implementation of the library -- unless the implementation has a bug, in which case he would want to complain somehow. Both the implementation of the getopts library, and programs that use the library should state codice_7, in order to refer to the corresponding interface. Now the library is "linked" to the program -- the one that contains the main() function. The program may refer to dozens of interfaces. In some cases, just placing codice_7 may appear correct but will still fail to link properly. This indicates that the library is not installed correctly, or there may be some additional configuration required. You will have to check either the compiler's documentation or library's documentation on how to resolve this issue. What to put in header files. As a general rule, headers should contain any declarations and macro definitions (preprocessor codice_9s) to be "seen" by the other modules in a program. Possible declarations: In the above codice_10 example file, one function (codice_6) is declared and four global variables (codice_12, codice_13, codice_14, and codice_15) are also declared. The variables are declared with the storage class specifier codice_16 in the header file because that keyword specifies that the "real" variables are stored elsewhere (i.e. the codice_17 file) and not within the header file. The codice_18 trick is colloquially called include guards. This is used so that if the codice_10 file were included more than once in a translation unit, the unit would only see the contents once. Alternatively, codice_20 in a header file can also be used to achieve the same thing in some compilers (codice_21 is an unportable catchall). Linking Libraries Into Executables. Linking libraries into executables varies by operating system and compiler/linker used. In Unix, directories of linked object files can be specified with the -L option to the cc command and individual libraries are specified with the -l (small ell) option. The -lm option specifies that the libm math library should be linked in, for example.
1,776
Puzzles/Statistical puzzles/3 Bags of Marbles. Puzzles | Statistical puzzles | 3 Bags of Marbles You have three bags, each containing two marbles. Bag #1 contains two white marbles, bag #2 contains two black marbles, and bag #3 contains one white marble and one black marble. You pick a random bag and take out one marble. Given that this is a white marble, what is the probability that the remaining marble from the same bag is also white? solution
116
Puzzles/Statistical puzzles/3 Bags of Marbles/Solution. Puzzles | Statistical puzzles | Puzzles/Statistical puzzles/3 Bags of Marbles | Solution 2/3, or approximately 66.7% Reasoning. The most common wrong answer is 50%. This is due to the misconception that you are given the information that you have picked either bag #1 or bag #3 [Challenge: This is not a misconception - This information is already provided in the question - a fact] . This is not the case, as explained below: Label each of the marbles: bag 1 contains 1a and 1b, bag 2 contains 2a and 2b, and bag 3 contains 3a (white) and 3b (black). Because you picked a random bag and a random marble, each marble has an equal chance of being picked. Given that you picked a white marble, you have the following distribution: First marble: Given this information, we look at each situation: If you are in the first two situations, your second marble will be a white marble, therefore, adding 1/3 and 1/3, you get 2/3 chance of getting a white marble Note: This solution is INCORRECT - see the section titled "Correct Answer" below. Algebraic explanation. Let W be the event of drawing a white marble, WW be the event of drawing from bag 1 (two white). Then P(WW | W) = P(WW ∧ W) / P(W) = P(WW) / P(W) = (1/3) / (1/2) = 2/3. Note: This is an algabraic representation of the INCORRECT solution above. Please see the "Correct Answer" section below. Correct answer. Correct answer - 50% - is commonly considered wrong, but really - past events have no influence on future probabilities at all (You cannot count "You have picked bag #1" twice. You just either did it or not). Right now You have one white marble in your hand and knowledge, that another one is either black or white depending on which bag (out of two) you selected. Challenge: You essentially just start by picking a marble--and there are three white marbles. Two of those white marbles are in the same bag as another white marble; so, given that you've picked one of the three white marbles, 2/3 of the time its pair matches--right? Rebuttal: You're thinking about this wrong - since you picked a white marble, you know you have chosen from either bag #1 or bag #3. Now, there are only two possible outcomes - either you have bag #1, in which case the other marble is white, or bag #3 in which case it's black. And the probability is 50% that the other marble in your chosen bag is white.
666
Korean/Lesson I1. Korean Conversation, Level I, Lesson 1: Greetings. Welcome to the first conversation lesson for learning Korean. By now you should be familiar with hangeul (the Korean writing system) and how to form syllables. If you are not yet familiar with hangeul, see Korean/Alphabet. It is highly recommended that you know these basics before you embark on learning how to make sentences and commencing dialogue. In this first section, we will introduce basic Korean sentence structure, basic vocabulary, and greetings in Korean. Note that the following dialogue uses the formal, very polite -습니다/습니까 verb endings, which are appropriate for introduction into the Korean language, however, is seldom used within everyday conversation in Korea, save for several set phrases, such as thank you, excuse me, etc. Dialogue. The simple dialogue below is between Korean native 찬호 and Joseph (조세프) from America. Joseph is interested in Korean culture and language, and was able to meet 찬호 through a program in his school. Here, they meet for the first time: Overview. The conversation began with 찬호 asking this: Here, we learn our first bit of Korean. "안녕하십니까?" is a common formal greeting in Korean. It literally means "Are you at peace?". "씨" is a title which means "Mr". Joseph replied like this: "예" means "yes". Then Joseph asked 찬호 the same question. Typically, the response to "안녕하십니까?" is "예", but it is not necessary to respond that way, as we learn from 찬호's response: "만나서 반갑습니다" means "Nice to meet you." This can also be shortened to "반갑습니다", but since 찬호 and Joseph have first met, it is best to be as polite as possible. "만나서" means "because we've met". Here, we learn some important things about making a Korean sentence. "저" means "I," and "저도요" means "Me too". Then Joseph says: "저는 집에 갑니다." This means "I go home." We'll dissect this sentence more in just a moment. First, let us finish analyzing the conversation: Look carefully at how each says "Good bye" to each other. 찬호 says "안녕히 가십시오" while Joseph says "안녕히 계십시오" Why do their replies differ from each other? Well, Joseph is leaving, while it is assumed that 찬호 is staying. So, 찬호 tells Joseph to "Go in peace" (like spock!) and Joseph tells 찬호 to "Stay in peace." It may sound funny, but that's how it works in Korea. Remember these two carefully and try not to mix them up! Grammar: "I go home.". The short sentence 저는 집에 갑니다 ("I go home.") reveals a great deal of usable grammar: Let's discuss 는, 에, and 갑니다. As mentioned above, 저 means "I". In Korean, "는" marks the primary topic of a sentence. Joseph is talking primarily about himself, so he says "저는". Note that if the primary topic ends in a consonant, "는" changes to "은" so it's easier to pronounce. So, if Joseph wanted to talk primarily about his house (집) instead of himself, he would say "집은". "에" is in a similar class of elements (called "particles"), but it marks the location, such as "to school (학교에), to the bathroom (화장실에)," and so forth. However, if Joseph wanted to say "to me", he would say "저에게", not "저에." The difference is that "에" means "to that thing or place" and "에게" (the dative particle) means "to that person." This is an important distinction to remember, but even if you make a mistake, a Korean will probably still understand. Finally, we see the verb, "갑니다." Now, if you were to look up "go" in a Korean dictionary, it would probably say "가다." This is the verb's unconjugated dictionary or "base" form. "가" is the actual root of the verb, or "Verb Stem" (VS). When we put the verb into a Korean sentence, it must be conjugated. The standard, polite statement conjugation in Korean is {VS + ㅂ/습니다}. What does this mean? This means we take the verb stem (가) and add "ㅂ니다" if the stem ends in a vowel and "습니다" if the verb stem ends in a consonant. In this case, "가" ends in a vowel, so we slip the ㅂ under it (갑) and add "니다" = "갑니다". If the verb was "먹다 (to eat)" then we would add "습니다" because the verbstem ends in a consonant (먹). Thus, we have "먹습니다." A special thing to remember about this is, when conjugated, the verb is actually pronounced "감니다" like there's a ㅁ on the bottom. This is because of a special pronunciation rule called "nasalization" which we won't discuss here, but keep it in mind. In order to make a question, the form is {VS + ㅂ/습니까}. An astute student would see something like that in "안녕하십니까", which is actually a question. So, if 찬호 wanted to ask "Do you go (are you going)?" he would ask "갑니까?" (Remember pronunciation: "감니까"). Armed with this information, we can now make a statement or a question with almost any verb. Practice: 연습. Conjugate the following verbs into statement form (VS + ㅂ/습니다) and question form (VS + ㅂ/습니까?). Click "▶" to check your answers: Determine whether the topic marker should be "은" or "는": Determine whether the particle should be "에" or "에게":
1,477
Hindi/Introduction. हिन्दी The word "Hindi" written in Devanagari Usage. While the language has emigrated to all parts of the world, the noteworthy use of the language is in its country of origin - . A large number of languages and dialects are spoken there, and no single one is spoken by all. The proper term for the form of Hindi used in northern India is Hindustani which is spoken in and around Delhi and borrows equally from other languages such as Urdu and Punjabi. Hindi though, is the most widely understood (~80%) and spoken (~66%) language in the region. <BR> Writing System. Hindi is written in the script (देवनागरी) a left-to-right writing system with a very characteristic top line. Several other languages such as Marathi, Nepali and Sanskrit use the Devanagari script. History. Hindi originated in 17th century by the mixing of the Polulau languages of the areas around Delhi (capital of India) with "Urdu" and "Persian" (brought in by Muslim rulers from the west). Hindi is derived from "Prakrit" from which the Indo-Aryan languages are derived. Hindi is heavily influenced by Urdu and even Persian, although it still retains the Devanagari script of Sanskrit. Spoken Hindi and spoken Urdu are so similar that they are mutually intelligible by native speakers. In their literary forms, however, Hindi borrows more heavily from Sanskrit while Urdu borrows vocabulary from Persian and Arabic.
381
Arabic/Arabic alphabet. Here are all the official letters of the Arabic alphabet in order. The following image shows which letters have an equivalent in the English language. Note that the "r" differs from the English one; it is a trill like in Spanish and Russian.<br> Because you know English, you have an advantage that speakers of other Western European Languages don't have:<br> The rest of the letters have no true English equivalents. Before you learn them they will sound silent, or seem like another letter. We will learn to pronounce and recognize these letters later. Arabic Letters have tails. Some Arabic letters have extra parts to them. These parts are only written at the end of words, and a few of them are optional. Look at the picture above. These extra parts have been cut off and brightened so you can see the important part of each letter. Without the extra parts, you see what letters look like at the beginning of words. Some letters. In the picture before the one above, there were some letters that didn't seem to have any extra parts. Some don't. These don't connect to letters after them—connecting them to letters after them would make words very difficult to read, and is not allowed. We boxed these letters in the picture directly above. Some letters do connect to letters after them, but don't have tails; instead, the whole shape of the letter changes. These letters are circled above, and their different shapes are shown in the picture below.. Explanation. Arabic letters change shape according to their place within a word. Usually this means not writing a tail, because the letter is not at the end of the word. But because Arabic is meant to be written mainly by hand, there are also other changes (i.e., shortcuts) that make writing easier. Here is an important shortcut. Because the shortcut is always used in handwriting, it has made its way into Arabic printing. Notice how the hole in the middle and final forms of the letter get covered presumably due to thick ink. This comes from calligraphy, Arabic has an incredibly rich calligraphic history. There are even more shortcuts (mainly ligatures) that we will cover later. Just in case you didn't notice, Arabic is written and read from right to left. The Arabic alphabet is very focused on representing sounds. Some of the sounds may be hard to distinguish for English speakers. See Arabic sounds and Wikipedia:Arabic Alphabet for more details on sounds. The alphabet does not have capital letters (letters especially designed for names or certain grammar cases). But the way letters are written does depend on the location of the letter in a word. A letter at the beginning of a word (initial) is often written slightly different from the same letter at the ending of a word (final), or somewhere in between (medial). The easiest way to learn the language is to try to recognize certain shapes in the letters (like hooks, bows, and points). Based on these shared shapes, the letters can be divided in shape groups. See Arabic alphabet (by group) to learn more on how to tell the written shapes apart, and how to write them. = Synthetic table = Each Arabic letter is made up of two parts: a shape, a number of dots. Rules for all writing systems using the Arabetic (writing using Arabic shapes, with dots) system. The following Rules apply. In Arabic Arabetics, dots can only be above or below the shape, never both at the same time. The way the dots are placed relative to each other, (i.e. diagonally, vertically, in a triangle) does not make different letters.
836
XML - Managing Data Exchange/Recursive relationships. <br><br> Introduction. Recursive relationships are an interesting and more complex concept than the relationships you have seen in the previous chapters. A recursive relationship occurs when there is a relationship between an entity and itself. For example, a one-to-many recursive relationship occurs when an employee is the manager of other employees. The employee entity is related to itself, and there is a one-to-many relationship between one employee (the manager) and many other employees (the people who report to the manager). Because of the more complex nature of these relationships, we will need slightly more complex methods of mapping them to a schema and displaying them in a style sheet. The one-to-one recursive relationship. Continuing with the tour guide model, we will develop a schema that shows cities that have hosted the Olympics and the previous host city. Since the previous host is another city and only one city can be the previous host this is a one to one recursive relationship. host.xsd (XML schema for a one-to-one recursive model). <?xml version="1.0" encoding="UTF-8"?> <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified" attributeFormDefault="unqualified"> <xsd:element name="cities"> <xsd:complexType> <xsd:sequence> <xsd:element name="city" type="cityType" maxOccurs="unbounded"/> </xsd:sequence> </xsd:complexType> </xsd:element> <xsd:complexType name="cityType"> <xsd:sequence> <xsd:element name="cityID" type="xsd:ID"/> <xsd:element name="cityName" type="xsd:string"/> <xsd:element name="cityCountry" type="xsd:string"/> <xsd:element name="cityPop" type="xsd:integer"/> <xsd:element name="cityHostYr" type="xsd:integer"/> <xsd:element name="cityPreviousHost" type="xsd:IDREF" minOccurs="0" maxOccurs="1"/> </xsd:sequence> </xsd:complexType> </xsd:schema> host.xml (XML document for a one-to-one recursive model). <?xml version="1.0" encoding="UTF-8"?> <cities xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance' xsi:noNamespaceSchemaLocation='host.xsd'> <city> <cityID>c1</cityID> <cityName>Atlanta</cityName> <cityCountry>USA</cityCountry> <cityPop>4000000</cityPop> <cityHostYr>1996</cityHostYr> </city> <city> <cityID>c2</cityID> <cityName>Sydney</cityName> <cityCountry>Australia</cityCountry> <cityPop>4000000</cityPop> <cityHostYr>2000</cityHostYr> <cityPreviousHost>c1</cityPreviousHost> </city> <city> <cityID>c3</cityID> <cityName>Athens</cityName> <cityCountry>Greece</cityCountry> <cityPop>3500000</cityPop> <cityHostYr>2004</cityHostYr> <cityPreviousHost>c2</cityPreviousHost> </city> </cities> The one-to-many recursive relationship. A hypothetical sports team is divided into squads with each squad having a captain. Every person on the team is a player, regardless of whether they are a squad captain. Since a squad captain is a player, this situation meets the definition of a recursive relationship—a squad captain is also a player and has a one-to-many relationship with the other players. This is a one-to-many recursive relationship because one captain has many players under him/her. See the example below for how to model the relationship. team.xsd (XML schema for a one-to-many recursive model). <?xml version="1.0" encoding="UTF-8"?> <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" elementFormDefault="unqualified"> <xsd:element name="team"> <xsd:complexType> <xsd:sequence> <xsd:element name="player" type="playerType" maxOccurs="unbounded"/> </xsd:sequence> </xsd:complexType> </xsd:element> <xsd:complexType name="playerType"> <xsd:sequence> <xsd:element name="playerID" type="xsd:ID"/> <xsd:element name="playerName" type="xsd:string"/> <xsd:element name="playerCap" type="playerC" minOccurs="0" maxOccurs="unbounded"/> </xsd:sequence> </xsd:complexType> <xsd:complexType name="playerC"> <xsd:sequence> <xsd:element name="memberOf" type="xsd:IDREF"/> </xsd:sequence> </xsd:complexType> </xsd:schema> team.xml (XML document for a one-to-many recursive model). <?xml version="1.0" encoding="UTF-8"?> <team xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance' xsi:noNamespaceSchemaLocation='Recursive1toMSchema.xsd'> <player> <playerID>c1</playerID> <playerName>Tommy Jones</playerName> <playerCap> <memberof>c3</memberof> </playerCap> </player> <player> <playerID>c2</playerID> <playerName>Eddie Thomas</playerName> <playerCap> <memberof>c3</memberof> </playerCap> </player> <player> <playerID>c3</playerID> <playerName>Sean McCombs</playerName> </player> <player> <playerID>c4</playerID> <playerName>Patrick O’Shea</playerName> <playerCap> <memberof>c3</memberof> </playerCap> </player> </team> Natural one-to-many recursive structure. A more natural approach for most one-to-many recursive relationships is to use XML's hierarchical nature to directly represent the heirarchy. Consider Locations: <?xml version="1.0" encoding="UTF-8"?> <location type="country"> <name>USA</name> <sub-locations> <location type="state"> <name>Ohio</name> <sub-locations> <location type="city"><name>Akron</name></location> <location type="city"><name>Columbus</name></location> </sub-location> </location> </sub-locations> </location> The many-to-many recursive relationship. Think you're getting a feel for recursive relationships yet? Well, there is still the third and final relationship to add to your repertoire — the many-to-many recursive. A common example of a many-to-many recursive relationship is when one item can be comprised of many items of the same data type as itself, and each of those sub-items may belong to another parent item of the same data type. Sound confusing? Let's look at the example of a product that can consist of a single item or multiple items (i.e., a packaged product). The example below describes tourist products that can be packaged together to create a new product. product.xsd (XML schema for a many-to-many recursive model). <?xml version="1.0" encoding="UTF-8"?> <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" elementFormDefault="unqualified"> <xsd:element name="products"> <xsd:complexType> <xsd:sequence> <xsd:element name="product" type="prodType" maxOccurs="unbounded"/> </xsd:sequence> </xsd:complexType> </xsd:element> <xsd:complexType name="prodType"> <xsd:sequence> <xsd:element name="prodID" type="xsd:ID"/> <xsd:element name="prodName" type="xsd:string"/> <xsd:element name="prodCost" type="xsd:decimal" minOccurs="0"/> <xsd:element name="prodPrice" type="xsd:decimal"/> <xsd:element name="components" type="componentsType" minOccurs="0" maxOccurs="1"/> </xsd:sequence> </xsd:complexType> <xsd:complexType name="componentsType"> <xsd:sequence> <xsd:element name="component" type="xsd:IDREF"/> <xsd:element name="componentqty" type="xsd:integer"/> </xsd:sequence> </xsd:complexType> </xsd:schema> product.xml (XML document for a many-to-many recursive model). <?xml version="1.0" encoding="UTF-8"?> <?xml-stylesheet type="text/xsl" href="product.xsl"?> <products xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="product.xsd"> <product> <prodID>p1000</prodID> <prodName>Animal photography kit</prodName> <prodPrice>725</prodPrice> <components> <component>p101</component> <componentqty>1</componentqty> </components> </product> <product> <prodID>p101</prodID> <prodName>Camera case</prodName> <prodCost>150</prodCost> <prodPrice>300</prodPrice> </product> </products> Summary. When the child has the same type of data as its parent in a parent-child type data relationship, this is a sign of the existence of a recursive relationship. The xsd:ID and xsd:IDREF elements can be used in a schema to create primary key-foreign key values in an XML document. Exercises. <br> Answers. External Links
3,451
Compiler Construction/State.java. // State.java Copyright 2005 Takuya Murata This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA import java.util.*; import java.io.*; public final class State { public static interface Delta { public void move (int input, Collection<State> result); public static final Delta nil = new Delta () { public static final int EMPTY = -2, BEGIN_INPUT = -1, EOF = -1, ACCEPT = 0; public String label; // for the debugging purpose. private Delta delta = nil; public State () { this.label = super.toString ().replaceAll ("^.+@", "@"); private State (String label, int i) { this.label = label + super.toString ().replaceAll ("^.+@", "@"); public State (String label) { this.label = label; public void setTransition (final int entry, final State dest) { final Delta prev = delta; delta = new Delta () { public void move (int input, Collection<State> result) { if (entry == input) result.add (dest); prev.move (input, result); }; public void setTransition (final String inputs, final State dest) { final Delta prev = delta; delta = new Delta () { public void move (int input, Collection<State> result) { if (inputs.contains (input)) result.add (dest); prev.move (input, result); }; public void setTransition (final Delta d) { final Delta prev = delta; delta = new Delta () { public void move (int input, Collection<State> result) { d.move (input, result); prev.move (input, result); }; public static final State[] toArray (Collection<State> col) { return col.toArray (new State[col.size ()]); public static Set<State> closure (Collection<State> t) { Set<State> ret = new HashSet<State> (t); for (;;) { Collection<State> u = new ArrayList<State> (); for (State s : t) { Delta d = s.delta; d.move (State.EMPTY, ret); d.move (State.EMPTY, u); if (u.isEmpty ()) break; else t = u; return ret; public static Set<State> move (Set<State> t, int input) { assert BEGIN_INPUT <= input && input < 256; Set<State> ret = new HashSet<State> (); for (State s : closure (t)) s.delta.move (input, ret); return ret; public State[] move (int input) { return toArray (move (Collections.singleton (this), input)); // A set of states reachable from this state without shifting an input. public State[] closure () { return toArray (closure (Collections.singleton (this))); public State[] move (CharSequence string) { Set<State> ret = Collections.singleton (this); for (int i = 0; i < string.length (); i++) ret = move (ret, string.charAt (i)); return toArray (ret); private static class SingleItemSet<T> extends AbstractList<T> implements Set<T> { private T item = null; public T set (int i, T item) { T ret = this.item; assert 0 <= i && i < size (); this.item = item; return ret; public void add (int i, T item) { assert i == 0; this.item = item; public State moveDFA (int input) { if (input == EMPTY) return this; SingleItemSet<State> t = new SingleItemSet<State> (); delta.move (input, t); if (!t.isEmpty ()) return t.first (); else return null; public State moveDFA (CharSequence string) { State s = this; for (int i = 0; i < string.length (); i++) { s = s.moveDFA (string.charAt (i)); if (s == null) return null; return s; private static State createState (Set<State> t, Map<Set<State>, State> table) { State existing = table.get (t); if (existing != null) return existing; // We now need to make a new state for this states set. State q = new State ("q" + table.size ()); table.put (t, q); for (int i = BEGIN_INPUT; i < 256; i++) { assert i != EMPTY : i; Set<State> u = move (t, i); if (!u.isEmpty ()) q.setTransition (i, createState (u, table)); return q; public State toDFA () { Map<Set<State>, State> table = new HashMap<Set<State>, State> (); return createState (Collections.singleton (this), table); private void prettyPrint (StringBuffer buf, Collection<State> marked) { if (marked.contains (this)) return; marked.add (this); buf.append (label + "["); boolean notfirst = false; for (int i = BEGIN_INPUT; i < 256; i++) { Set<State> t = move (Collections.singleton (this), i); if (!t.isEmpty ()) { if (notfirst) buf.append (", "); if (i == EMPTY) buf.append ("@e"); else if (i == ACCEPT) buf.append ("@acc"); else buf.append ((char) i); buf.append (":" + t); notfirst = true; buf.append ("]\n"); for (int i = BEGIN_INPUT; i < 256; i++) { Set<State> t = move (Collections.singleton (this), i); for (State s : t) s.prettyPrint (buf, marked); public String outputString () { Set<State> marked = new HashSet<State> (); StringBuffer buf = new StringBuffer (); this.prettyPrint (buf, marked); return buf.toString (); public String toString () { return label; // Create states and transitions for a string sequence public static final State[] stringSequence (CharSequence string) { int len = string.length (); State q[] = new State[len + 1]; // need s[len] for (int i = 0; i <= len; i++) q[i] = new State ("q" + i, 0); for (int i = 0; i < len; i++) q[i].setTransition (string.charAt (i), q[i + 1]); return new State[] { q[0], q[len] }; public static final State[] stringSequenceIgnoreCase (CharSequence string) { int len = string.length (); State q[] = new State[len + 1]; // need s[len] for (int i = 0; i <= len; i++) q[i] = new State ("q" + i, 0); for (int i = 0; i < len; i++) { char lower = Character.toLowerCase (string.charAt (i)), upper = Character.toUpperCase (lower); q[i].setTransition (lower, q[i + 1]); q[i].setTransition (upper, q[i + 1]); return new State[] { q[0], q[len] };
2,159
Linux Guide/Installing (advanced). There are 4 ways of "installing" Linux: Dual-booting or saving data. Preliminary note. You most likely do not need to do this as it is integrated into the installers Generally, installers have excellent partitioning tools so this is all part of the installation. If not, or if you are not installing it is easiest to use a live CD distro that has GParted on it, such as Ubuntu. GParted does not support LVM volumes used on more complicated partitioning setups, however, Fedora and Debian's installer, for example, can install and partition LVM volumes. Hard way. To install Linux without erasing the contents of the hard drive requires a spare partition. One solution is to install an extra hard drive. However, one can also non-destructively resize an existing partition. A FAT-type volume can be resized with FIPS and an NTFS volume with ntfsresize. If using FIPS, the hard drive will need to be defragmented before the resizing, but defragmentation is a good idea no matter what the file system. What size? You would be hard-pressed to fit a normal desktop Linux system in under 2GB. It's advisable to give Linux more space than that, however, because many, many applications are available for free for Linux, and especially with a high-speed Internet connection, one is likely to install quite a lot of them. You should plan on leaving at least 20% of each of your hard drive partitions free at all times -- modern file systems (such as NTFS, ext3 and ReiserFS) try to keep fragmentation low on their own, but they need extra space to do it with. Manual resizing. Easiest way. The volume resizing is a safe process, but afterwards the hard drive must be repartitioned. An error here can destroy the data on the hard drive, so double-check all commands. A typical session with ntfsresize ("/dev/hda1" is the most likely name for the NTFS partition. In this case, it is 10 GB in size.): paul@faust:/$ su Password: "You must be root to run ntfsresize. Under Knoppix {"what about other live CDs?" Under Gentoo's LiveCD, you are already root, so the "su" will not prompt for a password. Anyone know about others? I'd assume no-password or already-root would cover most of them...}, you will not be asked for a password unless you had already set one." faust:/# umount /dev/hda1 "This step is only needed if hda1 is already mounted, which is unlikely. However, if it is not needed, it will only give an error message and not do anything." faust:/# ntfsresize -i /dev/hda1 ntfsresize v1.9.0 NTFS volume version: 3.1 Cluster size : 4096 bytes Current volume size: 10999992832 bytes (11000 MB) Current device size: 11013617664 bytes (11014 MB) Checking filesystem consistency ... 100.00 percent completed Accounting clusters ... Space in use : 4197 MB (38.2%) Estimating smallest shrunken size supported ... File feature Last used at By inode $MFT : 8223 MB 0 Multi-Record : 3160 MB 14852 You might resize at 4196970496 bytes or 4197 MB (freeing 6803 MB). Please make a test run using both the -n and -s options before real resizing! "ntfsresize, version 1.90 and later, will automatically move files (including ones that the Windows defragmenter can't) in order to resize the partition, so defragmentation is not necessary before resizing (it might be easier to defragment while the partition is larger, though, so it's a good opportunity)." "The next step does a test run of the resizing process. Here, the user decided to leave Windows with about 6GB of space." faust:/# ntfsresize -n -s 6000M /dev/hda1 ntfsresize v1.9.0 NTFS volume version: 3.1 Cluster size : 4096 bytes Current volume size: 10999992832 bytes (11000 MB) Current device size: 11013617664 bytes (11014 MB) New volume size : 5999993344 bytes (6000 MB) Checking filesystem consistency ... 100.00 percent completed Accounting clusters ... Space in use : 4197 MB (38.2%) Needed relocations : 251614 (1031 MB) Schedule chkdsk for NTFS consistency check at Windows boot time ... Resetting $LogFile ... (this might take a while) Relocating needed data ... 100.00 percent completed Updating $BadClust file ... Updating $Bitmap file ... Updating Boot record ... The read-only test run ended successfully. "Now, write down the exact number of megabytes passed on the command line here (in this case, 6000). (The file system will probably not be resized to the exact size you specify, but ignore that — use what you entered.) You will need to resize the partition to the same size later." "Run ntfsresize with the same parameters, except leaving out the -n. This resizes the ntfs filesystem, but not the partition." "Splitting the partition is the only remaining task. Be sure to give it the hard drive (like "/dev/hda") as a parameter, rather than the partition ("/dev/hda1")." faust:/# cfdisk /dev/hda "If you don't have cfdisk, use fdisk instead. It has a less friendly interface, but it has exactly the same commands. Either way, no changes are made to the disk until you tell the program to (w)rite out the new partition table. If you accidentally write out the wrong partition structure, you should be able to save your data by replacing it with the correct one before doing anything to the affected partitions." You need to Partition recommendations. Note: If you're an advanced user and want to have few Linux systems installed side-by-side, or different file systems for experimenting, configuring Logical Volume Manager may be a good idea. More:
1,572
C Programming/Language Reference. Table of keywords. ANSI (American National Standards Institute) C (C89)/ISO C (C90). Very old compilers may not recognize some or all of the C89 keywords codice_1, codice_2, codice_3, codice_4, codice_5, as well as any later standards' keywords. ISO C (C99). These are supported in most new compilers. ISO C (C11). These are supported only in some newer compilers Although not technically a keyword, C99-capable preprocessors/compilers additionally recognize the special preprocessor operator codice_6, which acts as an alternate form of the codice_7 directive that can be used from within macro expansions. For example, the following code will cause some compilers (incl. GCC, Clang) to emit a diagnostic message: #define EMIT_MESSAGE(str) EMIT_PRAGMA(message(str)) #define EMIT_PRAGMA(content) _Pragma(#content) EMIT_MESSAGE("Hello, world!") Some compilers use a slight variant syntax; in particular, MSVC supports codice_8 instead of codice_6. Specific compilers may also—in a non-standards-compliant mode, or with additional syntactic markers like codice_10—treat some other words as keywords, including codice_11, codice_12, codice_13, codice_14, codice_15, codice_16, codice_17, codice_18, or codice_19. However, they typically allow these keywords to be overridden by declarations when operating in standards-compliant modes (e.g., by defining a variable named codice_19), in order to avoid introducing incompatibilities with existing programs. In order to ensure the compiler can maintain access to extension features, these compilers usually have an additional set of proper keywords beginning with two underscores (codice_21). For example, GCC treats codice_11, codice_23, and codice_24 somewhat identically, but the latter two are always guaranteed to have the expected meaning since they can't be overridden. Many of the newly introduced keywords—namely, those beginning with an underscore and capital letter like codice_25 or codice_26—are intended to be used only indirectly in most situations. Instead, the programmer should prefer the use of standard headers such as codice_27 or codice_28, which typically use the preprocessor to establish an all-lower-case variant of the keyword (e.g., <q>codice_29</q> or <q>codice_30</q>). These headers serve the purpose of enabling C and C++ code, as well as code targeting different compilers or language versions, to interoperate more cleanly. For example, by including codice_27, the tokens <q>codice_32</q>, <q>codice_33</q>, and <q>codice_34</q> can be used identically in either C99 or C++ without having to explicitly use codice_35 in C99 or codice_32 in C++. See also the list of reserved identifiers . Table of operators. Operators in the same row of this table have the same precedence and the order of evaluation is decided by the associativity ("left-to-right" or "right-to-left"). Operators closer to the top of this table have "higher" precedence than those in a subsequent group. Character sets. Programs written in C can read and write any character set, provided the libraries that support them are included/used. The source code for C programs, however, is usually limited to the ASCII character set. In a file containing source code, the end of a line is sometimes, depending on the operating system it was created on not a newline character but compilers treat the end of each line as if it were a single newline character. Virtually all compilers allow the $, @, and ` characters in string constants. Many compilers also allow literal multibyte Unicode characters, but they are not portable. Certain characters must be escaped with a backslash to represent themselves in a string or character constant. These are: Additionally, some compilers allow these characters: \xhh, where the 'h' characters are hexadecimal digits, is used to represent arbitrary bytes (including \x00, the zero byte). \uhhhh or \Uhhhhhhhh, where the 'h' characters are hexadecimal digits, is used to portably represent Unicode characters.
1,122
Physics with Calculus/Introduction/For Biologists. Living organisms are part of the physical world. The science of Biology depends upon physics and chemistry in many ways. When a chimpanzee uses its eyes, photons interact with molecules in the retina to trigger chemical reactions inside cells. The light-induced chemical changes lead to the movement of ions across cell membranes and the propagation of electrical signals along axons leading into the brain from the eyes. For vision, most animals are mainly dependent upon light that comes to the Earth from the nearest star. The photopigments in our eyes have been selected through the process of evolution to efficiently interact with just those colors of light that predominate in sunlight. A fruit tree can capture the energy of photons and convert that energy into chemical energy that is stored in sugar molecules. When a chimpanzee eats, food molecules become available as sources of energy inside cells for purposes like pumping ions across cell membranes. These pumped ions make possible the electrical signals of neurons that allow a chimpanzee to be consciously aware of what it sees. Most life on Earth depends on the conversion of matter to energy by fusion reactions inside the sun. Atoms such as iron that are required for the normal function of our cells were produced by nuclear reactions inside stars many billions of years ago. Many powerful tools for biology research depend on technologies that rely on the work of physicists. Scanning laser microscopes allow us to probe the structure of cells by making use of the physical fact that certain particles such as photons can be packed densely into the same physical space. Brain scanning techniques rely upon nuclear disintegrations or the magnetic properties of atoms. There is no real boundary between physics and biology; some scientists work in hybrid fields such as biophysics. It is often convenient to specialize in either biology or physics, but ultimately the results biology and physics must be consistent. As a biology major, you are aware of the idea that human understandings of life have changed dramatically during recorded history and continue to change. It is only relatively recently that biological evolution could be understood in terms of mutations in DNA molecules. In the history of the study of life there was a dramatic conceptual reorientation from the idea that biological species were fixed forms to the current view of living organisms as dynamically evolving forms. Similarly, physics has undergone such conceptual revolutions. We now know that conservation of energy and conservation of mass do not hold when there is conversion between energy and mass. However, in biology there are many situations where it is still useful to make use of ideas like conservation of energy and conservation of mass. In Part I, we start our exploration of physics with these fundamental physical concepts. Physics: Calculus-based
599
Physics with Calculus/Introduction/Textbook. This is an introductory-level physics textbook for engineering and science students with a strong mathematical background. It is assumed that the student had a year of calculus, covering differentiation and basic integrals. For those less mathematically-inclined, there are other physics textbooks such as the . While there are resources available online for the mathematics required for the material, an effort has been made to make this book self-contained in that respect. Where possible, physical concepts will be first introduced in terms of historical context and descriptions of their significance. Basic mathematical treatments are given with an emphasis on specific examples, and the motivation behind the manipulation of symbols will be explained where mathematical abstraction is necessary. For a more mathematical and fundamental approach, try the Modern Physics. Top: Introductions Next: Physics with Calculus/Introduction/Physics
194