CSC211 – Lab 5

advertisement
CSC211 – Lab 10
Class Menagerie
1 - Introduction
Phylogeny (or phylogenesis) is the origin and evolution of a set of organisms, usually a
set of species. A major task of systematics (the classification of living things) is to
determine the ancestral relationships among known species (both living and extinct).
A class hierarchy is an excellent mechanism for studying phylogeny because every
species descends from exactly one parent species (this is not strictly true because there is
gene flow between closely related species breeding successful hybrids, virus sometimes
transfer genes between unrelated species, etc.). This relationship is denoted (in a very
approximate manner) by the various taxa of classification: domain, kingdom, phylum,
class, order, family, genus, and species. The taxonomic tree does not only represent the
phylogenetic history of the planet because it was constructed by humans examining the
species still extant and only recently having access to fossil evidence of extinct species.
Therefore, the situation is a bit complicated by the fact that some taxa are polyphyletic,
meaning that they do not contain their most recent common ancestor, or paraphyletic,
meaning that they do not contain all of their descendants. Reptiles are, for example, a
paraphyletic group because birds are direct descendants of the most recent common
ancestor of the reptiles. Protists are also a paraphyletic group because there descendants
would include all plants and mammals!
2 – The Assignment
We’re going to construct a phylogenetic tree. It will, of course, be a tiny subtree of the
tree of life, but it will be substantial enough for us to do some interesting things. I’m
going to give you a number of organisms by genus and species and it will be up to you to
arrange them in the tree. At the head of the tree will be the abstract Organism class:
public abstract
protected
protected
protected
protected
protected
protected
protected
protected
class Organism {
abstract String getDomain();
abstract String getKingdom();
abstract String getPhylum();
abstract String getClass();
abstract String getOrder();
abstract String getFamily();
abstract String getGenus();
abstract String getSpecies();
public String identify() {
return getGenus() + " " + getSpecies() +
"\n\tDomain: " + getDomain() +
"\n\tKingdom: " + getKingdom() +
"\n\tPhylum: " + getPhylum() +
"\n\tClass: " + getClass() +
"\n\tOrder: " + getOrder() +
"\n\tFamily: " + getFamily() +
"\n\tGenus: " + getGenus() +
"\n\tSpecies: " + getSpecies();
}
}
The abstract methods will be implemented by subclasses to return Latin names for the
relevant taxa. We will never use overriding in this assignment because we will only be
implementing these abstract methods once in any chain of descent.
We will represent the taxa with abstract classes that will overwrite some of the methods.
For example, if there is a Rodent class, then Rodent will override its parent’s getOrder()
methods:
public abstract class Rodent {
…
public String getOrder() {
return "Rodentia";
}
…
}
We are seeking a minimal tree, so we do not need to include an abstract for each and
every taxa involved – that would result in way too many classes! Instead, we only have a
class for each branch point in the list of species. So, if Agkistrodon piscivorus is the only
snake in our tree, it should override getSpecies(), getGenus(), and getFamily(). In
addition no taxa name should be returned in more than one place, i.e. there should be
one occurance of the String “mammalia” in your code and your class hierarchy should
ensure that getClass() returns “mammalia” for all mammals.
You’ll find it quite simple to determine the phylogeny of each species that I’ve given
you. Simply type the binomial name into Wikipedia.
project 1 – create a class for each species in the species list (should be the binomial name
consisting of genus and species that I give you).
project 2 – research the taxonomy of each species and look for commonalities. Start
grouping closely related species by creating abstract classes to represent those taxa where
branching occurs. Remember, there will be no overriding, just implementation of
abstract methods. For each species and method, the method will be implemented in
precisely one ancestor of that species (or the species itself).
project 3 – add a main() method to Organism with code that creates an instance of each
Species and writes the results of calling identify() on them to a file called
“phylogeny.txt.”
report 1 – show me your phylogenetic tree, using either a chart or indentation to show
the structure.
report 2 – as always, describe what you’ve done clearly and succinctly.
3 – The Species List
Saccharomyces cerevisiae
Agkistrodon piscivorus
Panthera leo
Haliaeetus leucocephalus
Amoeba proteus
Geotria australis
Thunnus alalunga
Zaglossus bruijni
Plasmodium falciparum
Anhanguera santanae
Repenomamus robustus
Osedax mucofloris
Paramecium aurelia
Rosa canina
Carcharodon carcharias
Canis lupus
Bothriocyrtum californicum
Macrocheira kaempferi
Cannabis sativa
Thuja plicata
Yersinia pestis
Allosaurus atrox
Aptenodytes forsteri
Download