Hadoop两个常识点,高分请教

Posted

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了Hadoop两个常识点,高分请教相关的知识,希望对你有一定的参考价值。

1.HDFS处理文件
前提:通过JAVA API保存文件,一般指定源文件位置和保存到HDFS上的位置,取文件同样根据保存的位置去取。
问题:有没有一种保存方式,我只指定源文件位置,让Hadoop将这个文件拷贝到HDFS的随机位置上,只要返回一个唯一标识给我就行,当然,我也可以通过这个唯一标识拿到这个文件

2.运行MapReduce的方法
前提:我们运行MapReduce,一般是写好code,打成xxx.jar,然后登陆Server用hadoop jar xxx.jar来运行
问题:如果我们是在一个web应用中,要运行某个mapreduce的工作,一般是怎么做的

     “Hadoop保存到随机位置”以及“唯一标识”;HDFS也是一种文件系统,对于文件系统来讲唯一标识就是其文件的全路径;从这个意义上讲,只有生成一个随机的全路径就可以实现你的需求了。比如:设定全路径的最大深度为5,那么你只需要以下步骤实现:

      随机生成0~5之间的数字n,比如n=3;

      依照n再随机生成n个层次上的目录名称(长度也可随机,不过需要自己实现);比如  asdadasd,asdjhdfk,kjdsfhgkfh;

      组成全路径:hdfs://asdadasd/asdjhdfk/kjdsfhgkfh/<FileName.dat>

    在web应用中使用M/R,和纯Java应用一样:

      开发好你的mr程序;

      开发好一个独立的java程序,该程序的功能就是调用m/r的客户端api提交job;

      将该Java程序运行时需要的所有jar包部署到web server(比如tomcat)的<tomcat>/lib/ext目录下,让你的web程序可以装载需要的hadoop的类库;

      将该java程序嵌入到你的servlet里的service方法里(或者post或者get方法)即可。

追问

对于第二个问题,我还有一些不解,我们传统的MR程序,一般是打成jar包,然后直接通过Hadoop的命令来执行,比如说 hadoop mr.jar com.xxx.mainclass。 但是如果放到web应用里,把main方法里的代码放到get方法里,直接去调用执行,但因为没有了hadoop这个内置命令来运行这个jar,不知道能否能成功

追答

可以的。Hadoop其实不是什么内置命令,就是一个普通的java程序,只不过依赖很多Hadoop的jar包而已,只要你能够提供这些jar,并将相应的配置参数传递给给你的web程序,你照样可以起到MR程序。你可以找找Hadoop的开发文档看看就明白了。

参考技术A 1、API里有查看某个文件的各个数据块分别存储在哪一个数据节点(datanode)的函数接口的,但是你所说的随机好像是不可以的吧,这是Hadoop自己的内部的调度机制了,你可能还不是很理解Hadoop的分布式文件系统的具体的存储的方式,建议再找本书看看;2、之前我写过的还是走的Linux下的shell,如果你的web应用部署在linux服务器上(和控制节点在一台服务器上),那么你可以通过正常的打包成jar,然后利用java执行shell的接口,执行你打包好的jar,具体的你可以参见java如何执行shell。追问

关于第二点,你的意思是不是这样的:
web 程序执行shell(Runtime.exec()) -> shell调用jar (hadoop jar xxx.jar) ->jar执行mapreduce 。
这个是我能想到的方案,既然实现mapreduce功能也是在jar包里,为什么不能用web应用直接调用呢,是因为必须要依赖hadoop环境吗?

追答

是的,不过这个我就没有好的办法了,不好意思啊

高分求达尔文进化论常识性英文简介

能进得了维基百科 我就不会来这发帖子了
拒绝贴网站

佳答案
现代生物学之父:查尔斯·达尔文
http://www.sina.com.cn 2004/06/17 11:37 英语广场

Father of Modern Biology: Charles Darwin

Charles Darwin's whole life was changed by one lucky chance. In 1831, before he went on the voyage1 of the Beagle2, he was a very ordinary young man of twenty-two. No one in England—certainly not Darwin himself —had any idea of the future he had before him.

His sister Caroline gave him his first lessons. He was both lazy and naughty, and everyone was glad that he went away to school after his mother's death when he was eight.

Charles soon became a keen collector. He collected anything that caught his interest: insects3, seashells, coins and interesting stones. He said later that his collection prepared him for his work as a naturalist4.

He was not a very clever boy, but Charles was good at doing the things that interested him. He also took pleasure in carrying out experiments. But he could not learn Latin and Greek which in those days were an important part of education. He was a disappointment to his father, who was sure that he would bring nothing but shame to himself and his family.

In 1825, when Charles was sixteen, his father sent him to Edinburgh to study medicine, saying :“As you like natural history5 so much, perhaps we can make a doctor of you.”

But Charles found the lectures boring, and the dissections6 frightening. But at Edinburgh he was able to go to natural history lectures. In 1826 he read a paper on sea-worms to the Natural History Society. This paper was his first known work on this subject.

Then his father decided to send Charles to Cambridge University to study to become a priest. With hard work, he did quite well. And, in the countryside around Cambridge, he was able to shoot, fish and collect insects.

He seemed likely to become a country priest like hundreds of others, sharing his time between his work and his interest in natural history and country life. He had a deep faith in God and a lasting interest in religion7. At this time he did not doubt that every word of the Bible was true.

Then a letter from Captain Robert FitzRoy changed his life. FitzRoy was planning to make a voyage around the world on a ship called the Beagle. He wanted a naturalist to join the ship, and Darwin was recommended8. That voyage was the start of Charles Darwin's great life work.

In those days a great many people believed that every word written in the Bible was true. Darwin hoped that the plants and animals that they found in the course of their voyage would prove the truth of the Bible story of the great Flood9.

He began to observe everything. When they got to Rio de Janeiro in South America, Charles was overcome with joy to see so many different creatures, so much life and colour. His notebooks were full of detailed observations.

Then they reached dry land at Punta Alta. There Darwin discovered his first fossils10. Why, he wondered, were there horse bones at Punta Alta, when there had been no horses in the New World until Cortez brought his from Spain11?

They came to Tierra del Fuego at the tip of South America. It was a strange place, with terrible storms. Its people grew no food, and they slept on the wet ground. Darwin observed their looks and habits.

“How can people be so different, if all are descended12 from Adam and Eve in the Garden of Eden?” Charles wondered.

A trip into the mountains showed Darwin seashells at a height of 12,000 feet. Lower down were fossil trees.

“So those trees once stood by the sea,” thought Darwin. “The sea came up and covered them. Then the sea-bed rose up...”. To a man who had been taught that every word in the Bible was true, this was very puzzling.

In Chile, where Darwin saw earthquakes and volcanoes, he began to see what must have happened. The centre of the earth, he decided, was very hot. The surface of the earth was thinner in some places. It was in these places that earthquakes and volcanoes developed.

As the Beagle sailed around the world, Darwin began to wonder how life had developed on earth. He saw volcanic islands in the sea, and wondered how living things had got there.

But people who believed every word of the Bible thought that God had made all creatures and Man. But, if that was true, why did some of the fossils look like “mistakes” which had failed to change and, for that reason, died out?

On went Beagle, to Tahiti13, New Zealand and Australia. There, Darwin saw coral and coral islands for the first time. How had these islands come about14? Soon, he had the answer. Coral was made up of the bodies of millions of tiny creatures, piled up over millions of years —a million years for each island. Darwin wrote it all down in his notebooks.

After five years he was home. He was never again the healthy young man who climbed mountains and carried heavy bags of fossils for miles.

He set to work, getting his collection in order. And, in 1839, he married his cousin15, Emma Wedgwood. It was a happy marriage with ten children. He could be found working in his study, with a child beside him.

His first great work The Zoology of the Beagle was well received, but he was slow to make public his ideas on the origins16 of life. He was certainly very worried about disagreeing with the accepted views of the Church.

Happily, the naturalists at Cambridge persuaded Darwin that he must make his ideas public. So Darwin and Wallace, another naturalist who had the same opinions as Darwin, produced a paper together. A year later Darwin's great book, On the Origin of Species by Means of Natural Selection appeared. It attracted a storm.

People thought that Darwin was saying they were descended from monkeys. What a shameful idea! Although most scientists agreed that Darwin was right and that the story of Adam and Eve was merely a story, the Church was still so strong that Darwin never received any honours for his work.

Many years later, he published his other great work, The Descent of Man. He gave a lecture at the Royal Institution17, when the whole audience stood up and clapped18.

His health grew worse, but still he worked. “When I have to give up observation, I shall die,” he said. He was still working on 17, April, 1882. He was dead two days later.
翻译

现代生物学之父:查尔斯·达尔文
一次偶然的机遇改变了查尔斯·达尔文的一生。1831年踏上贝格尔号的航程之前,他还是个普普通通的22岁青年。没有人,当然也包括他自己,知道他的未来是什么样子。

姐姐卡罗琳教会了他许多人生第一课。他是个懒惰又淘气的孩子,8岁那年母亲去世后他总算进了学校,人人都为此而高兴。

不久查尔斯爱上了收集,收集所有他感兴趣的东西:昆虫呀、海贝呀,还有硬币和奇形怪状的石头。他后来说这些收集为他成为博物学家打下了基础。

查尔斯并不是个特别聪明的孩子,但只要感兴趣的事情他都做得很棒。他还喜欢做各种试验,但却学不好拉丁文和希腊文,这在当时的教育中可是很重要的一部分。父亲对他颇感失望,认定他只会一事无成,辱没家门。

1825年,查尔斯16岁,父亲将他送到爱丁堡学医,说“既然你如此喜欢博物学,或许我们可以把你培养成一名医生。”

但是查尔斯却烦透了那些讲座,也惧怕解剖,不过在爱丁堡他可以去听博物学方面的讲座。1826年,他在博物学社宣读了一篇有关海船蛀虫的文章,这是该领域中他第一篇为人所知的作品。

随后他父亲决定送他去剑桥大学学习,将来当一名牧师。由于刻苦努力,他学得相当不错,而且得以在剑桥附近的乡村射猎、钓鱼以及收集各种昆虫。

看来,他像数以百计的其他学生一样可能成为一位乡村牧师,工作的同时,还可以兼顾自己对博物学和乡村生活的兴趣。他笃信上帝,对宗教有不减的热情。当时他毫不怀疑《圣经》字字真实。

可是一封来自罗伯特·菲茨洛伊船长的信改变了他的一生。菲茨洛伊计划驾驶“贝格尔号”海船做一次环球航行,他想要一位博物学家加盟,有人推荐了达尔文。此次航海成为查尔斯终生伟业的起点。

那时很多人笃信《圣经》。达尔文希望航海过程中发现的各种动植物能证明《圣经》中有关那场洪水的文字确有其事。

他开始对万物进行观察。他们到达南美洲的里约热内卢时,看到种类如此繁多的生物,那么生机盎然而色彩斑斓,查尔斯欣喜若狂,他的笔记本上全是详细的观察记录。

随后他们到了Punta Alta 的干旱地带,达尔文在那儿发现了首批化石。奇怪的是,Cortez将马从西班牙带进美洲之前,Punta Alta是没有马的,为什么却有马骨化石呢?

他们又去了南美洲南端的火地岛。那是个奇异的地方,狂风暴雨不断,当地人不种粮食作物,而且在湿漉漉的地上席地而眠。达尔文仔细观察他们的相貌和习惯。

“如果人类都是伊甸园亚当和夏娃的后代,为什么又如此不同呢?”查尔斯感到纳闷。

在海拔一万两千英尺的山上,达尔文发现了海贝,稍低处还有树木化石。

达尔文想:“这么说这些树原来长在海边,海水上涨淹没了它们,后来海底上升了……。”对一个向来接受《圣经》字字箴言灌输的人来说,这真让人疑惑不解。

在智利,达尔文亲眼目睹了地震和火山,他开始明白其中的原因。他认为,地球中心非常炽热,地球表面某些地方要薄一些,地震和火山往往爆发于这些地方。

跟随着贝格尔号做环球航行,达尔文开始思考地球上生命的演变。他看到海中的火山岛,就会对那里生物的由来感到好奇。

而笃信《圣经》的人认为所有的生物和人类都是上帝创造的。可果真如此,为什么有的化石看起来像是上帝的“失误”?它们未能适应变化,也因此而绝迹了。

贝格尔号继续航行至塔希提岛、新西兰和澳大利亚。达尔文在那些地方第一次见到了珊瑚和珊瑚岛。这些岛是怎么形成的?很快,他就有了答案。珊瑚由数百万微小生物的遗骸组成,经过数百万年的堆积,每一百万年就形成了一座岛屿。达尔文将这一切写进他的笔记里。

五年后他回到家,不再是那个能翻山越岭、并扛着沉重的化石一口气行走数英里的健康小伙儿了。

他着手整理他的收集物。1839年,他和表妹艾玛·维奇伍德结婚,婚后生活幸福,育有十个孩子。人们发现他在书房工作时,总有一个孩子在身旁。

他的第一部大作《贝格尔号的生态园》颇受欢迎,但他却不急于将自己对生命起源的看法公诸于世,他确实非常担心自己的理论与教会广为接受的观点发生冲突。

所幸剑桥大学的博物学家们都劝说达尔文公开他的观点,因此达尔文和另一位持相同观点的博物学家瓦雷斯共同发表了一篇文章。一年后,他的巨著《物竞天择,物种起源》问世并掀起了轩然大波。

人们认为达尔文在说人是猴子的后代,这种观点简直有失体面!虽然大多数科学家同意达尔文是对的,亚当和夏娃之说仅仅是故事而已,但教会的力量如此强大,这部著作没有给达尔文带来任何荣誉。

许多年后,他出版了另一部名著《人类的演化》。他在皇家研究院作了一次演讲,全场听众一致起立为之鼓掌。

他的健康每况愈下,但他工作不止,并说“我不得不放弃观察的时候,我也就完了。”1882年4月17日还在工作的他,两天以后与世长辞。

这里有个十分简单的:1. Darwin's evolutionary theory and its impact

Charles Darwin(1809-1882) was an English naturalist and author. His Origin of Species (1859) and Decent of Men (1871) exerted a strong impact in the history of Western thought. In his books, Darwin hypothesized that over the millennia man had evolved from lower forms of life. Humans were special, not because God had created them in His image, but because they had successfully adapted to changing environmental conditions and had passed on their survival?making characteristics genetically. Survival of the fittest is the fact or principle of the survival of the forms of plant and animal life best fitted for existing conditions, while related but less fit forms become extinct.
参考技术A In biology, evolution is the change in the inherited traits of a population from generation to generation. These traits are the expression of genes that are copied and passed on to offspring during reproduction. Mutations in these genes can produce new or altered traits, resulting in heritable differences (genetic variation) between organisms. New traits can also come from transfer of genes between populations, as in migration, or between species, in horizontal gene transfer. Evolution occurs when these heritable differences become more common or rare in a population, either non-randomly through natural selection or randomly through genetic drift.

Natural selection is a process that causes heritable traits that are helpful for survival and reproduction to become more common, and harmful traits to become rarer. This occurs because organisms with advantageous traits pass on more copies of these traits to the next generation.[1][2] Over many generations, adaptations occur through a combination of successive, small, random changes in traits, and natural selection of those variants best-suited for their environment.[3] In contrast, genetic drift produces random changes in the frequency of traits in a population. Genetic drift arises from the element of chance involved in which individuals survive and reproduce.

One definition of a species is a group of organisms that can reproduce with one another and produce fertile offspring. However, when a species is separated into populations that are prevented from interbreeding, mutations, genetic drift, and the selection of novel traits cause the accumulation of differences over generations and the emergence of new species.[4] The similarities between organisms suggest that all known species are descended from a common ancestor (or ancestral gene pool) through this process of gradual divergence.[1]

The theory of evolution by natural selection was first proposed by Charles Darwin and Alfred Russel Wallace and set out in detail in Darwin's 1859 book On the Origin of Species.[5] In the 1930s, Darwinian natural selection was combined with Mendelian inheritance to form the modern evolutionary synthesis,[3] in which the connection between the units of evolution (genes) and the mechanism of evolution (natural selection) was made. This powerful explanatory and predictive theory has become the central organizing principle of modern biology, providing a unifying explanation for the diversity of life on Earth.[6]

Contents [hide]
1 Heredity
2 Variation
2.1 Mutation
2.2 Recombination
3 Mechanisms
3.1 Natural selection
3.2 Genetic drift
3.3 Gene flow
4 Outcomes
4.1 Adaptation
4.2 Co-evolution
4.3 Co-operation
4.4 Speciation
4.5 Extinction
5 Evolutionary history of life
5.1 Origin of life
5.2 Common descent
5.3 Evolution of life
6 History of evolutionary thought
7 Social and religious controversies
8 Uses in technology
9 Further reading
10 External links
11 References

Heredity

DNA structure, bases are in the center, surrounded by phosphate–sugar chains in a double helixFor more details on this topic, see Introduction to genetics, Genetics, and Heredity.
Inheritance in organisms occurs through discrete traits – particular characteristics of an organism. In humans, for example, eye color is an inherited characteristic, which individuals can inherit from one of their parents.[7] Inherited traits are controlled by genes and the complete set of genes within an organism's genome is called its genotype.[8]

The complete set of observable traits that make up the structure and behavior of an organism is called its phenotype. These traits come from the interaction of its genotype with the environment.[9] As a result, not every aspect of an organism's phenotype is inherited. Suntanned skin results from the interaction between a person's genotype and sunlight; thus, a suntan is not hereditary. However, people have different responses to sunlight, arising from differences in their genotype; a striking example is individuals with the inherited trait of albinism, who do not tan and are highly sensitive to sunburn.[10]

Genes are regions within DNA molecules that contain genetic information.[8] DNA is a long molecule with four types of bases attached along its length. Different genes have different sequences of bases; it is the sequence of these bases that encodes genetic information. Within cells, the long strands of DNA associate with proteins to form structures called chromosomes. A specific location within a chromosome is known as a locus. If the DNA sequence at a locus varies between individuals, the different forms of this sequence are called alleles. DNA sequences can change through mutations, producing new alleles. If a mutation occurs within a gene, the new allele may affect the trait that the gene controls, altering the phenotype of the organism. However, while this simple correspondence between an allele and a trait works in some cases, most traits are more complex and are controlled by multiple interacting genes.[11][12]

Variation
For more details on this topic, see Genetic variation and Population genetics.
Because an individual's phenotype results from the interaction of their genotype with the environment, the variation in phenotypes in a population reflects the variation in these organisms' genotypes.[12] The modern evolutionary synthesis defines evolution as the change over time in this genetic variation.[13] The frequency of one particular allele will fluctuate, becoming more or less prevalent relative to other forms of that gene. Evolutionary forces act by driving these changes in allele frequency in one direction or another. Variation disappears when an allele reaches the point of fixation — when it either disappears from the population or replaces the ancestral allele entirely.[14]

Variation comes from mutations in genetic material, migration between populations (gene flow), and the reshuffling of genes through sexual reproduction. Variation also comes from exchanges of genes between different species, through horizontal gene transfer in bacteria, and hybridization in plants.[15] Despite the constant introduction of variation through these processes, most of the genome of a species is identical in all individuals of that species.[16] However, even relatively small changes in genotype can lead to dramatic changes in phenotype; for example, chimpanzees and humans differ in only about 5% of their genomes.[17]

Mutation
For more details on this topic, see Mutation and Molecular evolution.
Genetic variation comes from random mutations that occur in the genomes of organisms. Mutations are changes in the DNA sequence of a cell's genome and are caused by radiation, viruses, transposons and mutagenic chemicals, as well as errors that occur during meiosis or DNA replication.[18][19][20] These mutagens produce several different types of change in DNA sequences; these can either have no effect, alter the product of a gene, or prevent the gene from functioning. Studies in the fly Drosophila melanogaster suggest that about 70 percent of mutations are deleterious, and the remainder are either neutral or have a weak beneficial effect.[21] Due to the damaging effects that mutations can have on cells, organisms have evolved mechanisms such as DNA repair to remove mutations.[18] Therefore, the optimal mutation rate for a species is a trade-off between short-term costs, such as the risk of cancer, and the long-term benefits of advantageous mutations.[22]

Duplication of part of a chromosomeLarge sections of DNA can also be duplicated, which is a major source of raw material for evolving new genes, with tens to hundreds of genes duplicated in animal genomes every million years.[23] Most genes belong to larger families of genes of shared ancestry.[24] Novel genes are produced either through duplication and mutation of an ancestral gene, or by recombining parts of different genes to form new combinations with new functions.[25][26] For example, the human eye uses four genes to make structures that sense light: three for color vision and one for night vision; all four arose from a single ancestral gene.[27] An advantage of duplicating a gene (or even an (entire genome) is that overlapping or redundant functions in multiple genes allows alleles to be retained that would otherwise be harmful, thus increasing genetic diversity.[28]

Changes in chromosome number may also involve the breakage and rearrangement of DNA within chromosomes. For example, two chromosomes in the Homo genus fused to produce human chromosome 2; this fusion did not occur in the chimpanzee lineage and chimpanzees retain these separate chromosomes.[29] In evolution, the most important role of such chromosomal rearrangements may be to accelerate the divergence of a population into new species by preserving genetic differences within populations.[30]

Sequences of DNA that can move about the genome, such as transposons, make up a major fraction of the genetic material of plants and animals, and may have been important in the evolution of genomes.[31] For example, more than a million copies of the Alu sequence are present in the human genome, and these sequences have now been recruited to perform functions such as regulating gene expression.[32] Another effect of these mobile DNA sequences is that when they move within a genome, they can mutate or delete existing genes and thereby produce genetic diversity.[33]

Recombination
For more details on this topic, see Genetic recombination and Sexual reproduction.
In asexual organisms, genes are inherited together, or linked, as they cannot mix with genes in other organisms during reproduction. However, the offspring of sexual organisms contain a random mixture of their parents' chromosomes that is produced through independent assortment. In the related process of genetic recombination, sexual organisms can also exchange DNA between two matching chromosomes.[34] These shuffling processes can allow even alleles that are close together in a strand of DNA to be inherited independently. However, as only about one recombination event occurs per million base pairs in humans, genes close together on a chromosome may not be shuffled away from each other, and tend to be inherited together.[35] This tendency is measured by finding how often two alleles occur together, which is called their linkage disequilibrium. A set of alleles that is usually inherited in a group is called a haplotype, and this co-inheritance can indicate that the locus is under positive selection (see below).[36]

Recombination in sexual organisms helps to remove harmful mutations and retain beneficial mutations.[37] Consequently, when alleles cannot be separated by recombination – such as in mammalian Y chromosomes, which pass intact from fathers to sons – harmful mutations accumulate.[38][39] In addition, recombination can produce individuals with new and advantageous gene combinations. These positive effects of recombination are balanced by the fact that this process can cause mutations and separate beneficial combinations of genes.[37] The optimal rate of recombination for a species is therefore a trade-off between conflicting factors.

Mechanisms
There are three basic mechanisms of evolutionary change: natural selection, genetic drift, and gene flow. Natural selection favors genes that improve capacity for survival and reproduction. Genetic drift is the random sampling of a generation's genes during reproduction, causing random changes in the frequency of alleles, and gene flow is the transfer of genes within and between populations. The relative importance of natural selection and genetic drift in a population varies depending on the strength of the selection and the effective population size, which is the number of individuals capable of breeding.[40] Natural selection usually predominates in large populations, while genetic drift dominates in small populations. The dominance of genetic drift in small populations can even lead to the fixation of slightly deleterious mutations.[41] As a result, changing population size can dramatically influence the course of evolution. Population bottlenecks, where the population shrinks temporarily and therefore loses genetic variation, result in a more uniform population.[14] Bottlenecks also result from alterations in gene flow such as decreased migration, expansions into new habitats, or population subdivision.[40]

Natural selection

Natural selection of a population for dark coloration.For more details on this topic, see Natural selection and Fitness (biology).
Natural selection is the process by which genetic mutations that enhance reproduction become, and remain, more common in successive generations of a population. It has often been called a "self-evident" mechanism because it necessarily follows from three simple facts:

Heritable variation exists within populations of organisms.
Organisms produce more offspring than can survive.
These offspring vary in their ability to survive and reproduce.
These conditions produce competition between organisms for survival and reproduction. Consequently, organisms with traits that give them an advantage over their competitors pass these advantageous traits on, while traits that do not confer an advantage are not passed on to the next generation.

The central concept of natural selection is the evolutionary fitness of an organism. This measures the organism's genetic contribution to the next generation. However, this is not the same as the total number of offspring: instead fitness measures the proportion of subsequent generations that carry an organism's genes.[42] Consequently, if an allele increases fitness more than the other alleles of that gene, then with each generation this allele will become more common within the population. These traits are said to be "selected for". Examples of traits that can increase fitness are enhanced survival, and increased fecundity. Conversely, the lower fitness caused by having a less beneficial or deleterious allele results in this allele becoming rarer — they are "selected against".[2] Importantly, the fitness of an allele is not a fixed characteristic, if the environment changes, previously neutral or harmful traits may become beneficial and previously beneficial traits become harmful.[1]

Natural selection within a population for a trait that can vary across a range of values, such as height, can be categorized into three different types. The first is directional selection, which is a shift in the average value of a trait over time — for example organisms slowly getting taller.[43] Secondly, disruptive selection is selection for extreme trait values and often results in two different values becoming most common, with selection against the average value. This would be when either short or tall organisms had an advantage, but not those of medium height. Finally, in stabilizing selection there is selection against extreme trait values on both ends, which causes a decrease in variance around the average value.[44] This would, for example, cause organisms to slowly become all the same height.

A special case of natural selection is sexual selection, which is selection for any trait that increases mating success by increasing the attractiveness of an organism to potential mates.[45] Traits that evolved through sexual selection are particularly prominent in males of some animal species, despite traits such as cumbersome antlers, mating calls or bright colors that attract predators, decreasing the survival of individual males.[46] This survival disadvantage is balanced by higher reproductive success in males that show these hard to fake, sexually selected traits.[47]

An active area of research is the unit of selection, with natural selection being proposed to work at the level of genes, cells, individual organisms, groups of organisms and even species.[48][49] None of these models are mutually-exclusive and selection may act on multiple levels simultaneously.[50] Below the level of the individual, genes called transposons try to copy themselves throughout the genome.[51] Selection at a level above the individual, such as group selection, may allow the evolution of co-operation, as discussed below.[52]

Simulation of genetic drift of 20 unlinked alleles in populations of 10 (top) and 100 (bottom). Drift is more rapid in the smaller population.
Genetic drift
For more details on this topic, see Genetic drift and Effective population size.
Genetic drift is the change in allele frequency from one generation to the next that occurs because alleles in the offspring generation are a random sample of those in the parent generation, and are thus subject to sampling error.[14] As a result, when selective forces are absent or relatively weak, allele frequencies tend to "drift" upward or downward in a random walk. This drift halts when an allele eventually becomes fixed, either by disappearing from the population, or replacing the other alleles entirely. Genetic drift may therefore eliminate some alleles from a population due to chance alone, and two separate populations that began with the same genetic structure can drift apart by random fluctuation into two divergent populations with different sets of alleles.[53] The time for an allele to become fixed by genetic drift depends on population size, with fixation occurring more rapidly in smaller populations.[54]

Although natural selection is responsible for adaptation, the relative importance of the two forces of natural selection and genetic drift in driving evolutionary change in general is an area of current research in evolutionary biology.[55] These investigations were prompted by the neutral theory of molecular evolution, which proposed that most evolutionary changes are the result the fixation of neutral mutations that do not have any immediate effects on the fitness of an organism.[56] Hence, in this model, most genetic changes in a population are the result of constant mutation pressure and genetic drift.[57]

Gene flow
For more details on this topic, see Gene flow, Hybrid, and Horizontal gene transfer.

Male lions leave the pride where they are born and take over a new pride to mate. This results in gene flow between prides.Gene flow is the exchange of genes between populations, which are usually of the same species.[58] Examples of gene flow within a species include the migration and then breeding of organisms, or the exchange of pollen. Gene transfer between species includes the formation of hybrid organisms and horizontal gene transfer.

Migration into or out of a population can change allele frequencies. Immigration may add new genetic material to the established gene pool of a population. Conversely, emigration may remove genetic material. As barriers to reproduction between two diverging populations are required for the populations to become new species, gene flow may slow this process by spreading genetic differences between the populations. Gene flow is hindered by mountain ranges, oceans and deserts or even man-made structures such as the Great Wall of China, which has hindered the flow of plant genes.[59]

Depending on how far two species have diverged since their last common ancestor, it may still be possible for them to produce offspring, as with horses and donkeys mating to produce mules.[60] Such hybrids are generally infertile, due to the two different sets of chromosomes being unable to pair up during meiosis. In this case, closely-related species may regularly interbreed, but hybrids will be selected against and the species will remain distinct. However, viable hybrids are occasionally formed and these new species can either have properties intermediate between their parent species,
参考技术B ● DARWIN'S THEORY OF EVOLUTION ●

Darwin's model of evolution, known as "the survival of the fittest", is widely accepted by most of the contemporary scientific community, as well as the general public, as a "fact of life" as there is little doubt this process does play a significant part in changing the characteristics within the pre-existing gene pool of a species. (a process known as micro-evolution within species) On the face of it, Darwin's theory is so elegantly simple and in accordance with so many of the day-to-day observations of modern genetics that it does indeed appear to be self evident.

However, close examination of a whole raft of scientific data reveals the absence of virtually any empirical scientific evidence in support of the theory, either regarding the alleged spontaneous generation of life in first place, let alone the evolution of life forms from one species into another. If anything, the fossil evidence to date indicates the spontaneous appearance, without the existence of any earlier related life forms, of a vast number of life forms around 600 million years ago known as the 'Cambrian explosion', followed by very long periods (tens of millions of years) of minor changes occurring within species (a process known as Stasis) and the absence of any examples of possible evolutionary links between species prior to, during, or after this period.

以上是关于Hadoop两个常识点,高分请教的主要内容,如果未能解决你的问题,请参考以下文章

高分请教:WIN10加域后,多种功能受限

(高分请教)256色的定义是啥?

数学基本常识公式

高分求教!

史上AI最高分!谷歌大模型创美国医师执照试题新纪录,科学常识水平媲美人类医生...

高分求达尔文进化论常识性英文简介