Exemple #1
0
def NASAorbit(planet, sma, per, tilt = Quantity.below(90),
              Float=Quantity.fromDecimal,
              u=day, Mm=mega*metre, O=Orbit, S=Spin, **what):
    # no eccentricities supplied ... but they are all bound orbits ...
    # no tilt supplied, aside from retrograde or not ...
    if per < 0: tilt, per = tilt + 90, -per
    # no error bars supplied, but all periods gave two decimal places
    # sma is really radius / (1 - eccentricity), but endure it and let per's error-bar infect it
    return O(planet, sma * Mm, S(Float(per, 2, None, u), tilt), **what)
Exemple #2
0
def NASAorbit(planet,
              sma,
              per,
              tilt=Quantity.below(90),
              Float=Quantity.fromDecimal,
              u=day,
              Mm=mega * metre,
              O=Orbit,
              S=Spin,
              **what):
    # no eccentricities supplied ... but they are all bound orbits ...
    # no tilt supplied, aside from retrograde or not ...
    if per < 0: tilt, per = tilt + 90, -per
    # no error bars supplied, but all periods gave two decimal places
    # sma is really radius / (1 - eccentricity), but endure it and let per's error-bar infect it
    return O(planet, sma * Mm, S(Float(per, 2, None, u), tilt), **what)
Exemple #3
0
    def __init__(self, period, tilt=Quantity.below(90), **what):
        """Initialises a Spin object.

        Takes two positional arguments:

          period -- a Quantity with dimensions of time; the period of the
          rotation described; stored as self.period.

          tilt -- angle, in degrees, between the axis of spin and some fixed
          direction provided by your context; a.k.a. inclination.  Should lie
          between 0 and 90.  Default is an error bar covering this whole range,
          meaning `unspecified'.  Is stored as self.tilt; can be accessed as an
          angle value (i.e. multiplied by arc.degree) as self.inclination.

        Takes arbitrary keyword arguments after the manner of Object (q.v.).
        """
        self.__upinit(**what)
        self.period, self.tilt = self.__time(period), tilt
Exemple #4
0
    def __init__(self, period, tilt=Quantity.below(90), **what):
        """Initialises a Spin object.

        Takes two positional arguments:

          period -- a Quantity with dimensions of time; the period of the
          rotation described; stored as self.period.

          tilt -- angle, in degrees, between the axis of spin and some fixed
          direction provided by your context; a.k.a. inclination.  Should lie
          between 0 and 90.  Default is an error bar covering this whole range,
          meaning `unspecified'.  Is stored as self.tilt; can be accessed as an
          angle value (i.e. multiplied by arc.degree) as self.inclination.

        Takes arbitrary keyword arguments after the manner of Object (q.v.).
        """
        self.__upinit(**what)
        self.period, self.tilt = self.__time(period), tilt
Exemple #5
0
     92 * mega * metre,
     Columbo=Hoop("Columbo Gap", Saturn, 77.8 * mega * metre, width=100 * km),
     Maxwell=Hoop("Maxwell Gap", Saturn, 87.5 * mega * metre, width=270 * km))
Ring("Saturn's B Ring", Saturn, 92 * mega * metre, 117.58 * mega * metre)
Ring(
    "The Cassini Division",
    Saturn,
    117.58 * mega * metre,
    122.2 * mega * metre,
    width=4.7 * mega * metre,
    note=
    "gap between rings, not actually a ring; and not actually quite empty, either",
    Huygens=Hoop("Huygens Gap",
                 Saturn,
                 117.58 * mega * metre,
                 width=Quantity.flat(285, 440, None, km)))
Ring("Saturn's A Ring",
     Saturn,
     122.2 * mega * metre,
     136.78 * mega * metre,
     Encke=Hoop("Encke Division",
                Saturn,
                133.57 * mega * metre,
                width=325 * km),
     Keeler=Hoop("Keeler Gap", Saturn, 136.53 * mega * metre, width=35 * km))
Ring(
    "Saturn's F Ring",
    Saturn,
    140.0875 * mega * metre,
    140.3525 * mega * metre,
    # radius 140.22 Mm, width 30 to 500 km
Exemple #6
0
def NASelement(name, symbol, Z, A, isos=None, abundance=None, melt=None, boil=None, **what):
    """Create an Element based on my Nuffield Advanced Data book's data.

    Required arguments:
      name -- string giving the full name of the element.
      symbol -- string giving the (one or two letter) symbol of the element.
      Z -- atomic number.

    Optional arguments:
      A -- molar mass * mol / g; a.k.a. atomic mass / AMU (default, None, means
           unknown).
      isos -- description of isotopes (see below); default is None.
      abundance -- relative terrestrial abundance, scaled to make Si score 100;
                   default is None, indicating an artificial element.
      melt -- melting temperature / K
      boil -- boiling temperature / K

    plus any further keyword arguments, to taste.  See Element's constructor for
    further details; it receives a suitably scaled abundance.

    I have, rather arbitrarily, supposed that the phase change temperatures
    given in the NAS data book generally have an error bar of +/- half a Kelvin,
    except where marked as 'uncertain' (five K) or 'highly uncertain' (fifty K
    if the cited value's last two digits are zeros, otherwise ten K).  Roughly
    as arbitrarily, where several forms of the elment are listed, I've used the
    lowest melting point and highest boiling point, ignoring any phase changes
    between forms and listing any sublimation (typically relevant only to one
    form, not the one whose melting and boiling are used) separately as sublime.

    The description of isotopes, if given, should either be a list of atomic
    mass numbers for which an isotope is known (for artificial elements and
    those natural radioactives whose isotopic composition varies wildly) or a
    mapping from known atomic mass numbers to relative abundances (or to None
    for those radioactive isotopes which normally have negligible abundance).
    If the sum of these relative abundances isn't 1, they'll be (fudged to make
    it 100 - because the NAS book is a bit off on some elements - and then)
    scaled down to make it 1.

    Both the element's terrestrial abundance and the relative abundance of its
    isotopes will be given an error bar, if they don't already have one, to
    accord with the limited precision indicated in the NAS table. """

    if abundance is None:
        what["abundance"] = None  # artificial elements
    else:
        try:
            abundance.width
        except AttributeError:  # need an error bar (guess: two decimal places of precision)
            abundance = Quantity.fromSigFigs(abundance, 2)
        # NAS data book gives abundances relative to Silicon = 100, but notes
        # that Silicon's true abundance is believed to be 27.72 %
        what["abundance"] = abundance * 0.2772

    try:
        A.width
    except AttributeError:  # give it an error bar
        try:
            isos[:]  # radioactive/artificial elements
        except TypeError:
            A = Quantity.fromDecimal(A, 4)  # real ones
        else:
            A = Quantity.within(A, 0.5 * max(1, max(isos) - min(isos)))

    temp = {}
    if melt is not None:
        try:
            melt.width
        except AttributeError:
            melt = Quantity.fromDecimal(melt, 1)
        temp["melt"] = melt * Kelvin

    if boil is not None:
        try:
            boil.width
        except AttributeError:
            boil = Quantity.fromDecimal(boil, 1)
        temp["boil"] = boil * Kelvin

    try:
        temp["sublime"] = what["sublime"]
    except KeyError:
        pass
    else:
        del what["sublime"]
    if temp:
        T = Temperatures(**temp)
    else:
        T = None

    ans = Element(name, symbol, Z, A, T, **what)

    try:
        isos[:]
    except TypeError:
        try:
            isos.update
        except AttributeError:
            pass  # no information
        else:
            # dictionary: { isotope: relative abundance }
            weights = filter(None, isos.values())
            total = sum(weights)
            if total == 1:
                fix, scale = None, 1  # weights given as fractions
            else:
                # Otherwise, assume given as percentages; but the NAS table
                # has several entries that don't sum accurately to 100.
                scale = 0.01
                if total == 100:
                    fix = None
                else:  # bodge: blur the non-tiny weights to make it all sum right ...
                    assert 80 < total < 120, "Perhaps these aren't percentages after all"
                    fix = 1 + (100 - total) * Quantity.below(2) / sum(filter(lambda x: x > 1, weights))

            # Perhaps we can improve on this ...
            for k, v in isos.items():
                iso = Isotope(Z, k - Z)
                if v:
                    unit = 1
                    if v < 1:
                        while unit > v:
                            unit = unit * 0.1
                        unit = unit * 0.1
                    if fix and v > 1:
                        v = v * fix  # bodge
                    v = Quantity.within(v, unit * 0.01)
                    iso.abundance = v * scale
    else:
        # sequence: known isotopes
        for k in isos:
            Isotope(Z, k - Z)

    return ans
Exemple #7
0
        # sequence: known isotopes
        for k in isos:
            Isotope(Z, k - Z)

    return ans


Float, About = Quantity.fromDecimal, Quantity.within

atom(
    1,
    0,
    "Hydrogen",
    "H",
    "The simplest atom; the most abundant form of matter",
    mass=Quantity.within(1673.43, 0.08, harpo * gram),
    nucleus=proton,
)
atom(
    1,
    1,
    "Deuterium",
    "D",
    "(Ordinary) Heavy Hydrogen",
    nucleus=nucleus(
        1,
        1,
        "deuteron",
        doc="Deuterium's nucleus",
        # roughly the sum of proton and neutron:
        mass=2.01355321271 * AMU,
Exemple #8
0
                        while unit > v: unit = unit * .1
                        unit = unit * .1
                    if fix and v > 1: v = v * fix # bodge
                    v = Quantity.within(v, unit * .01)
                    iso.abundance = v * scale
    else:
        # sequence: known isotopes
        for k in isos:
            Isotope(Z, k - Z)

    return ans

Float, About = Quantity.fromDecimal, Quantity.within

atom(1, 0, 'Hydrogen', 'H', 'The simplest atom; the most abundant form of matter',
     mass=Quantity.within(1673.43, .08, harpo * gram),
     nucleus=proton)
atom(1, 1, 'Deuterium', 'D', '(Ordinary) Heavy Hydrogen',
     nucleus=nucleus(1, 1, 'deuteron', doc="Deuterium's nucleus",
                     # roughly the sum of proton and neutron:
                     mass = 2.01355321271 * AMU,
                     # roughly the *difference* between proton and neutron:
                     magneticmoment = 0.433073457e-26 * Joule / Tesla))
atom(1, 2, 'Tritium', 'T', 'Radioactive Heavy Hydrogen')
atom(2, 2, 'Helium', 'He', 'Second most abundant form of matter',
     nucleus=nucleus(2, 2, 'alpha', doc="Helium's nucleus"))

Hydrogen = NASelement('Hydrogen', 'H', 1, Float(1.0079, 5), {1: 99.985, 2: .015, 3: None}, .57, 14, 20)
Helium = NASelement('Helium', 'He', 2, 4.0026, {3: 1.3e-4, 4: 100}, 1.3e-6, boil=4)
Lithium = NASelement('Lithium', 'Li', 3, 6.939, {6: 7.42, 7: 92.58}, 2.9e-2, 454, 1604)
Beryllium = NASelement('Beryllium', 'Be', 4, 9.0122, {9: 1}, 2.6e-3, 1556, Float(2750, -1))
Exemple #9
0
See p. 210, table 32.\n"""

    if not isinstance(when, find):
        when = find(None, when)

    # pity about not knowing eccentricities ...
    return rock(name,
                sol.orbiter(Q(period, 2, None, yr)),
                Q(1, 2, 12, mass * ton),
                maxdiameter=Q(maxdiam, 0, None, ml),
                periterrion=Q(1, 2, 6, miss * ml), # closest approach to Terra
                discovery=when)

Ceres = DwarfAster('Ceres',
                   Orbit(Sun, Quantity.fromDecimal(413.9, 1, 6, km), None),
                   Quantity.fromDecimal(.87, 2, 21, kg),
                   surface = Spheroid(Quantity.fromDecimal(466, 0, None, km)),
                   number = 1,
                   discovery=Discovery("Piazzi", 1801,
                                       day="January 1st 1801",
                                       __doc__="""The discovery of Ceres.

A team of astronomers set out, in 1800, to look for a planet between Mars and
Jupiter, as anticipated by the Titius-Bode law (see Sun.Bode); starting on the
first day of the new year, Piazzi noticed a moving star which was, in due
course, recognised as what they were looking for, even though it was a bit
smaller than they expected and a few more showed up soon enough.\n"""),
                  __doc__="""The first asteroid discovered.

See Ceres.discovery and Sun.Bode for further details.  Piazzi actually named
Exemple #10
0
    if not isinstance(when, find):
        when = find(None, when)

    # pity about not knowing eccentricities ...
    return rock(
        name,
        sol.orbiter(Q(period, 2, None, yr)),
        Q(1, 2, 12, mass * ton),
        maxdiameter=Q(maxdiam, 0, None, ml),
        periterrion=Q(1, 2, 6, miss * ml),  # closest approach to Terra
        discovery=when)


Ceres = DwarfAster('Ceres',
                   Orbit(Sun, Quantity.fromDecimal(413.9, 1, 6, km), None),
                   Quantity.fromDecimal(.87, 2, 21, kg),
                   surface=Spheroid(Quantity.fromDecimal(466, 0, None, km)),
                   number=1,
                   discovery=Discovery("Piazzi",
                                       1801,
                                       day="January 1st 1801",
                                       __doc__="""The discovery of Ceres.

A team of astronomers set out, in 1800, to look for a planet between Mars and
Jupiter, as anticipated by the Titius-Bode law (see Sun.Bode); starting on the
first day of the new year, Piazzi noticed a moving star which was, in due
course, recognised as what they were looking for, even though it was a bit
smaller than they expected and a few more showed up soon enough.\n"""),
                   __doc__="""The first asteroid discovered.
Exemple #11
0
It is (USGS assures me) probable that Simon Marius discovered the same moons at
about the same time, maybe as much as a month earlier: but Galileo published
first.
""")
Io = NASAmoon("Io", Jupiter, _tmp, 422, 1.77,
              NASAshell(1830, 1819, 1815), "silicates, sulphur, SO2", 893.3, 3.53)
Europa = NASAmoon("Europa", Jupiter, _tmp, 670.9, 3.551181,
                  # http://www.solarviews.com/eng/europa.htm
                  # Mean orbital velocity = 13.74 km / s
                  # Orbital eccentricity = 0.009
                  # Orbital inclination = 0.470 degrees
                  # Escape velocity = 2.02 km / s
                  # Visual geometric albedo = 0.64
                  # Magnitude = 5.29 Vo
                  NASAshell(1569, 1565), "ice", 479.7, Quantity.within(3, .01))
Ganymede = NASAmoon("Ganymede", Jupiter, _tmp, 1070, 7.15,
                    NASAshell(2634), "dirty ice", 1482, 1.94)
Callisto = NASAmoon("Callisto", Jupiter, _tmp, 1883, 16.69,
                    NASAshell(2403), "dirty ice", 1076, 1.851)
Amalthea = NASAmoon("Amalthea", Jupiter,
                    Discovery("E.E. Barnard", 1892, date="1892 September 9",
                              location="Mt. Hamilton",
                              etymology="""Greek Mythology.

Amalthea was a naiad, who nursed baby Jove.  Her pet goat fed him.
Flammarion suggested her name for this moon.
"""),
                    181, 0.50, NASAshell(131, 73, 67), "rock, sulphur")
Himalia = NASAmoon("Himalia", Jupiter,
                   Discovery("C.D. Perrine", 1904, date="1904 December 4",
Exemple #12
0
from body import Object, Ring, Shell, Planetoid, MinorPlanet, DwarfPlanet

Float = Quantity.fromDecimal
About = Quantity.within

Pluto = KLplanet(
    'Pluto',
    KLsurface(.23,
              .05,
              Spin(6 * day + 9 * hour, 118),
              flattening=0,
              material="CH4 ice",
              temperature=Centigrade(About(-233, 5))),
    Orbit(Sun, Float(5936, 1, 9, metre), Spin(250 * year, 17.13), .253),
    .0025,
    Quantity.flat(1.8, 2.1),  # according to Solstation (K&L gave 1.1 g/cc)
    DwarfPlanet,  # in place of Planet
    atmosphere="trace CH4",
    discovery=Discovery('Clyde Tombaugh',
                        1930,
                        date="1930 February 18 or 23",
                        location="Lowell observatory, Flagstaff, Arizona",
                        story="""Discovery of Pluto

Lowell, among others, noticed that the orbits of Neptune and Uranus wobbled,
hinting at another planet further out.  Lowell predicted the planet's orbit and
set in motion a project to find it - which continued after his death and lead to
successful discovery.

The telescope which took the discovery pictures was only installed in 1929 (on
'Mars Hill' no less).
Exemple #13
0
SAOmoon(Saturn, _kav, "S9", 18486, 939.90)
SAOmoon(Saturn, _kav, "S10", 17452, 860.03)
SAOmoon(Saturn, Discovery("Holman", 2000), "S11", 17874, 888.54)
SAOmoon(Saturn, _glad, "S12", 19747, 1038.11)

# http://antwrp.gsfc.nasa.gov/apod/ap20071024.html
Ring("Saturn's D Ring", Saturn, 67 * mega * metre, 74.5 * mega * metre)
Ring("Saturn's C Ring", Saturn, 74.5 * mega * metre, 92 * mega * metre,
     Columbo=Hoop("Columbo Gap", Saturn, 77.8 * mega * metre, width=100 * km),
     Maxwell=Hoop("Maxwell Gap", Saturn, 87.5 * mega * metre, width=270 * km))
Ring("Saturn's B Ring", Saturn, 92 * mega * metre, 117.58 * mega * metre)
Ring("The Cassini Division", Saturn, 117.58 * mega * metre, 122.2 * mega * metre,
     width = 4.7 * mega * metre,
     note="gap between rings, not actually a ring; and not actually quite empty, either",
     Huygens=Hoop("Huygens Gap", Saturn, 117.58 * mega * metre,
                  width=Quantity.flat(285, 440, None, km)))
Ring("Saturn's A Ring", Saturn, 122.2 * mega * metre, 136.78 * mega * metre,
     Encke=Hoop("Encke Division", Saturn, 133.57 * mega * metre, width=325 * km),
     Keeler=Hoop("Keeler Gap", Saturn, 136.53 * mega * metre, width=35 * km))
Ring("Saturn's F Ring", Saturn, 140.0875 * mega * metre, 140.3525 * mega * metre,
     # radius 140.22 Mm, width 30 to 500 km
     width=Quantity.flat(30, 500, None, km))
Ring("Saturn's E Ring", Saturn, 180 * mega * metre, 480 * mega * metre)
# Average thickness: c. 100 m.  If all gathered together, they'd form a body
# only 500 km in diameter (and the NASA book uses "diameter", in some of its
# data tables, as a synonym for "radius" - d'oh).  Diagrams also show an
# "unnamed" object in orbit at 118 Mm, shepherding the B ring.

del Discovery, Ring, Hoop, NASAmoon, NASAshell, NASAtrojan, SAOmoon, _glad, _kav, _tmp, \
    mega, metre, km, Quantity
Exemple #14
0
def NASelement(name,
               symbol,
               Z,
               A,
               isos=None,
               abundance=None,
               melt=None,
               boil=None,
               density=None,
               **what):
    """Create an Element based on my Nuffield Advanced Data book's data.

    Required arguments:
      name -- string giving the full name of the element.
      symbol -- string giving the (one or two letter) symbol of the element.
      Z -- atomic number.

    Optional arguments:
      A -- molar mass * mol / g; a.k.a. atomic mass / AMU (default, None, means
           unknown).
      isos -- description of isotopes (see below); default is None.
      abundance -- relative terrestrial abundance, scaled to make Si score 100;
                   default is None, indicating an artificial element.
      melt -- melting temperature / K
      boil -- boiling temperature / K
      density -- in g/cc at 298K; or a tuple (d, T), d in g/cc at T as liquid

    plus any further keyword arguments, to taste.  See Element's constructor for
    further details; it receives a suitably scaled abundance.

    I have, rather arbitrarily, supposed that the phase change temperatures
    given in the NAS data book generally have an error bar of +/- half a Kelvin,
    except where marked as 'uncertain' (five K) or 'highly uncertain' (fifty K
    if the cited value's last two digits are zeros, otherwise ten K).  Roughly
    as arbitrarily, where several forms of the elment are listed, I've used the
    lowest melting point and highest boiling point, ignoring any phase changes
    between forms and listing any sublimation (typically relevant only to one
    form, not the one whose melting and boiling are used) separately as sublime.

    The description of isotopes, if given, should either be a list of atomic
    mass numbers for which an isotope is known (for artificial elements and
    those natural radioactives whose isotopic composition varies wildly) or a
    mapping from known atomic mass numbers to relative abundances (or to None
    for those radioactive isotopes which normally have negligible abundance).
    If the sum of these relative abundances isn't 1, they'll be (fudged to make
    it 100 - because the NAS book is a bit off on some elements - and then)
    scaled down to make it 1.

    Both the element's terrestrial abundance and the relative abundance of its
    isotopes will be given an error bar, if they don't already have one, to
    accord with the limited precision indicated in the NAS table. """

    if abundance is None: what['abundance'] = None  # artificial elements
    else:
        try:
            abundance.width
        except AttributeError:  # need an error bar (guess: two decimal places of precision)
            abundance = Quantity.fromSigFigs(abundance, 2)
        # NAS data book gives abundances relative to Silicon = 100, but notes
        # that Silicon's true abundance is believed to be 27.72 %
        what['abundance'] = abundance * .2772

    try:
        A.width
    except AttributeError:  # give it an error bar
        try:
            isos[:]  # radioactive/artificial elements
        except TypeError:
            A = Float(A, 4)  # real ones
        else:
            A = About(A, .5 * max(1, max(isos) - min(isos)))

    if density is not None:
        if not isinstance(density, Quantity):
            try:
                density, temp = density
            except TypeError:
                temp = 298 * Kelvin
            else:
                temp *= Kelvin
            density = Float(density, 2, units=gram / cc, measured=temp)
        what['density'] = density

    temp = {}
    if melt is not None:
        try:
            melt.width
        except AttributeError:
            melt = Float(melt, 1)
        temp['melt'] = melt * Kelvin

    if boil is not None:
        try:
            boil.width
        except AttributeError:
            boil = Float(boil, 1)
        temp['boil'] = boil * Kelvin

    try:
        temp['sublime'] = what['sublime']
    except KeyError:
        pass
    else:
        del what['sublime']
    if temp: T = Temperatures(**temp)
    else: T = None

    ans = Element(name, symbol, Z, A, T, **what)

    try:
        isos[:]
    except TypeError:
        try:
            isos.update
        except AttributeError:
            pass  # no information
        else:
            # dictionary: { isotope: relative abundance }
            weights = [x for x in isos.values() if x]
            total = sum(weights)
            if total == 1: fix, scale = None, 1  # weights given as fractions
            else:
                # Otherwise, assume given as percentages; but the NAS table
                # has several entries that don't sum accurately to 100.
                scale = .01
                if total == 100: fix = None
                else:  # bodge: blur the non-tiny weights to make it all sum right ...
                    assert 80 < total < 120, "Perhaps these aren't percentages after all"
                    fix = 1 + (100 - total) * Quantity.below(2) \
                          / sum(x for x in weights if x > 1)

            # Perhaps we can improve on this ...
            for k, v in isos.items():
                iso = Isotope(Z, k - Z)
                if v:
                    unit = 1
                    if v < 1:
                        while unit > v:
                            unit = unit * .1
                        unit = unit * .1
                    if fix and v > 1: v = v * fix  # bodge
                    v = About(v, unit * .01)
                    iso.abundance = v * scale
    else:
        # sequence: known isotopes
        for k in isos:
            Isotope(Z, k - Z)

    return ans
Exemple #15
0
See study.LICENSE for copyright and license information.
"""

from study.value.units import Object, Quantity, \
     mega, year, day, hour, minute, metre, kg, bar, arc, Centigrade
from home import Sun, Earth, KLplanet, KLsurface
from common import Orbit, Spin, Discovery
Float = Quantity.fromDecimal

Mercury = KLplanet('Mercury',
                   KLsurface(.382,
                             .38,
                             Spin(58 * day + 16 * hour, 0),
                             flattening=0,
                             material="silicates",
                             temperature=Centigrade(Quantity.within(110,
                                                                    290))),
                   Orbit(Sun, Float(57.91, 2, 9, metre),
                         Spin(.241 * year, 7.005), .2056),
                   .0553,
                   5.43,
                   atmosphere="trace Na",
                   discovery=Discovery("prehistoric",
                                       -1e4,
                                       etymology="""Latin: Mercurius.

From Latin, named for the messenger of the goods; so called because it moves so
fast.  Compare the element hydrargyrum.
"""))

Mercury.surface.temperature.document(
    """Mercury's wildly varying surface temperature
Exemple #16
0
According to http://www.xs4all.nl/~mke/Gliese710.htm this is a red dwarf
headed our way at 50,400 km/hr, 50 times the size of Earth, 100,000 times as
massive and due to arrive in about 1.4 mega years.  However, solstation
reports that astronomers don't expect it to disturb the Oort cloud enough to
'create a substantial increase in the long-period comet flux at Earth's
orbit'.

Apparently, we're also due (not quite so close, but nearer than Proxima
Centauri, our current nearest neighbour) visits from Barnard's star (10,000
years hence) and &alpha; Centauri (A/B).\n""")

Gliese710.Solstation(
    'K5-M1 V',
    Float(63, 1),
    '18:19:50.8-1:56:19.0',
    Quantity.flat(.4, .6, .42),
    # but xs4all.n./~mke gave 1e5 * Earth.mass
    Float(4.2, 1, -2),
    Float(.67, 1),  # 'possibly 67 percent'
    aliases=('NSV 10635', 'Gl 710', 'Hip 89825', 'BD-01 3474', 'HD 168442',
             'HD 168442', 'U449', 'Vys/McC 63'),
    # http://www.solstation.com/stars2/gl710.htm
    # gives "within 1.1 ly (0.34 pc)"; i.e. c. 7e4 AU
    closestapproach=4e4 * AU)

Centaur.Alpha = System(
    "&alpha; Centauri",
    __doc__="""&alpha; Centauri has been known since ancient times.

It's the fourth brightest star in the night sky as well as the brightest star
in constellation Centaurus; it's been known about for millennia.\n""",
Exemple #17
0
from outer import Neptune
from common import Orbit, Spin, Discovery, Spheroid, Surface
from rock import NASAmoon, NASAshell
from body import Object, Ring, Shell, Planetoid, MinorPlanet, DwarfPlanet

Float = Quantity.fromDecimal
About = Quantity.within

Pluto = KLplanet('Pluto',
                 KLsurface(.23, .05, Spin(6 * day + 9 * hour, 118),
                           flattening = 0, material="CH4 ice",
                           temperature=Centigrade(About(-233, 5))),
                 Orbit(Sun, Float(5936, 1, 9, metre),
                       Spin(250 * year, 17.13), .253),
                 .0025,
                 Quantity.flat(1.8, 2.1), # according to Solstation (K&L gave 1.1 g/cc)
                 DwarfPlanet, # in place of Planet
                 atmosphere="trace CH4",
                 discovery=Discovery('Clyde Tombaugh', 1930,
                                     date="1930 February 18 or 23",
                                     location="Lowell observatory, Flagstaff, Arizona",
                                     story="""Discovery of Pluto

Lowell, among others, noticed that the orbits of Neptune and Uranus wobbled,
hinting at another planet further out.  Lowell predicted the planet's orbit and
set in motion a project to find it - which continued after his death and lead to
successful discovery.

The telescope which took the discovery pictures was only installed in 1929 (on
'Mars Hill' no less).
"""))
Exemple #18
0
                 __doc__ = """Gliese 710

According to http://www.xs4all.nl/~mke/Gliese710.htm this is a red dwarf
headed our way at 50,400 km/hr, 50 times the size of Earth, 100,000 times as
massive and due to arrive in about 1.4 mega years.  However, solstation
reports that astronomers don't expect it to disturb the Oort cloud enough to
'create a substantial increase in the long-period comet flux at Earth's
orbit'.

Apparently, we're also due (not quite so close, but nearer than Proxima
Centauri, our current nearest neighbour) visits from Barnard's star (10,000
years hence) and &alpha; Centauri (A/B).\n""")

Gliese710.Solstation('K5-M1 V', Float(63, 1),
                     '18:19:50.8-1:56:19.0',
                     Quantity.flat(.4, .6, .42),
                     # but xs4all.n./~mke gave 1e5 * Earth.mass
                     Float(4.2, 1, -2),
                     Float(.67, 1), # 'possibly 67 percent'
                     aliases=('NSV 10635', 'Gl 710', 'Hip 89825', 'BD-01 3474',
                              'HD 168442', 'HD 168442', 'U449', 'Vys/McC 63'),
                     # http://www.solstation.com/stars2/gl710.htm
                     # gives "within 1.1 ly (0.34 pc)"; i.e. c. 7e4 AU
                     closestapproach = 4e4 * AU)

Centaur.Alpha = System("&alpha; Centauri",
                        __doc__="""&alpha; Centauri has been known since ancient times.

It's the fourth brightest star in the night sky as well as the brightest star
in constellation Centaurus; it's been known about for millennia.\n""",
                        aliases=("Rigil Kentaurus",),
Exemple #19
0
import body
from common import Orbit, Spin, Discovery, Surface, \
     SurfacePart, Ocean, Island, Continent, LandMass

from study.chemy.physics import Cosmos
# some rough data from my Nuffield data book:
Universe = body.Object('Observable Universe', None,
                       """The observable universe

See also chemy.physics.Cosmos
""",
                       mass=1e52 * kg, radius=3e26 * metre,
                       # some slightly more definite data:
                       age = Quantity.within(1, .01, 13.7 * giga * year,
                                             """The age of our universe.

This is only about 60 mega years short of 2**201 Planck times.  Compare with
Hubble's constant (q.v.) and note that multiplying the two together gives an
answer just a little bit less than 1.\n"""),
                       temperature = Cosmos.temperature,
                       composition = { 'dark energy': .73,
                                       'cold dark matter': .23,
                                       'atoms': .04 },
                       # microwave background: mass density and number density:
                       photon = Object(mass = 4.68e-31 * kg / metre**3,
                                       number = 413e6 / metre**3))
del Cosmos

# See also: http://www.daviddarling.info/encyclopedia/L/LocalGroup.html
# Data from apod:
LocalGroup = body.Group("The Local Group",
                        # Error bar is a wild guess, based on MilkyWay.orbit.speed
Exemple #20
0
import body
from common import Orbit, Spin, Discovery, Surface, \
     SurfacePart, Ocean, Island, Continent, LandMass

from study.chemy.physics import Cosmos
# some rough data from my Nuffield data book:
Universe = body.Object('Observable Universe', None,
                       """The observable universe

See also chemy.physics.Cosmos
""",
                       mass=1e52 * kg, radius=3e26 * metre,
                       # some slightly more definite data:
                       age = Quantity.within(1, .01, 13.7 * giga * year,
                                             """The age of our universe.

This is only about 60 mega years short of 2**201 Planck times.  Compare with
Hubble's constant (q.v.) and note that multiplying the two together gives an
answer just a little bit less than 1.\n"""),
                       temperature = Cosmos.temperature,
                       composition = { 'dark energy': .73,
                                       'cold dark matter': .23,
                                       'atoms': .04 },
                       # microwave background: mass density and number density:
                       photon = Object(mass = 4.68e-31 * kg / metre**3,
                                       number = 413e6 / metre**3))
del Cosmos

# See also: http://www.daviddarling.info/encyclopedia/L/LocalGroup.html
# Data from apod:
LocalGroup = body.Group("The Local Group",
                        # Error bar is a wild guess, based on MilkyWay.orbit.speed
Exemple #21
0
Available source for more data:
http://solarsystem.nasa.gov/planets/profile.cfm?Object=Mars&Display=Facts

See study.LICENSE for copyright and license information.
"""

from study.value.units import Object, Quantity, \
     mega, year, day, hour, minute, metre, kg, bar, arc, Centigrade
from home import Sun, Earth, KLplanet, KLsurface
from common import Orbit, Spin, Discovery
Float = Quantity.fromDecimal

Mercury = KLplanet('Mercury',
                   KLsurface(.382, .38, Spin(58 * day + 16 * hour, 0),
                             flattening = 0, material = "silicates",
                             temperature=Centigrade(Quantity.within(110, 290))),
                   Orbit(Sun, Float(57.91, 2, 9, metre),
                         Spin(.241 * year, 7.005), .2056),
                   .0553, 5.43, atmosphere="trace Na",
                   discovery=Discovery("prehistoric", -1e4,
                                       etymology="""Latin: Mercurius.

From Latin, named for the messenger of the goods; so called because it moves so
fast.  Compare the element hydrargyrum.
"""))

Mercury.surface.temperature.document("""Mercury's wildly varying surface temperature

As Mercury spins only slightly (less than a factor of two) faster than it
orbits, its surface spends long periods alternately directly exposed to the
Sun's heat and utterly hidden from it.  Without an atmosphere to re-distribute