Softpedia
 


LINUX CATEGORIES:



GLOBAL PAGES >>
NEWS ARCHIVE >>
SOFTPEDIA REVIEWS >>
MEET THE EDITORS >>
WEEK'S BEST
  • Linux Kernel 3.9.2 / 3....
  • LibreOffice 3.6.6 / 4.0.3
  • MPlayer 1.1.1
  • systemd 204
  • Arch Linux 2013.05.01
  • Blender 2.67
  • KDE Software Compilatio...
  • CrunchBang Linux Stable...
  • Elementary OS 0.1 / 0.2...
  • SystemRescueCd 3.6.0
  • Home > Linux > Programming > Perl Modules

    Astro::Cosmology 0.90

    Download button

    No screenshots available
    Downloads: 372  View global page NEW!  Tell us about an update
    User Rating:
    Rated by:
    NOT RATED
    0 user(s)
    Developer:

    License / Price:

    Last Updated:

    Category:
    Douglas Burke | More programs
    Perl Artistic License / FREE
    October 29th, 2007, 20:05 GMT
    ROOT / Programming / Perl Modules

     Read user reviews (0)  Refer to a friend  Subscribe

    Astro::Cosmology description

    Astro::Cosmology is a Perl module that can calculate cosmological distances, volumes, and times.

    Astro::Cosmology is a Perl module that can calculate cosmological distances, volumes, and times.

    This module provides a set of routines to calculate a number of cosmological quantities based on distance and time. Some are a bit complex - e.g. the volume element at a given redshift - while some, such as the conversion between flux and luminosity, are more mundane.

    To calculate results for a given cosmology you create an Astro::Cosmology object with the desired cosmological parameters, and then call the object's methods to perform the actual calculations. If you aren't used to objects, it may sound confusing; hopefully the SYNOPSIS section below will help (after all, a bit of code is worth a thousand words). The advantage of using an object-orientated interface is that the object can carry around the cosmological parameters, so you don't need to keep on specifying them whenever you want to calculate anything; it also means you can write routines which can just accept an Astro::Cosmology object rather than all the cosmological parameters.

    This module requires that the PDL distribution is installed on your machine; PDL is available from CPAN or http://pdl.perl.org/

    WARNING

    Whilst I believe the results are accurate, I do not guarantee this. Caveat emptor, as the Romans used to say...

    SYNOPSIS

    use Astro::Cosmology qw( :constants );

    # what is the luminosity distance, in metres, for
    # a couple of cosmologies
    #
    my $z = sequence(10) / 10;
    my $eds = Astro::Cosmology->new;
    my $sn = Astro::Cosmology->new( matter => 0.3, lambda => 0.7 );

    my $de = 1.0e6 * PARSEC * $eds->lum_dist($z);
    my $ds = 1.0e6 * PARSEC * $sn->lum_dist($z);

    # let's change the parameters of the $sn cosmology
    $sn->setvars( lambda=>0.6, matter=>0.2 );

    UNITS

    If H0 is set to 0, then the units used are the Hubble distance, volume per steradian, or time. If greater than zero, distances are measured in Mpc, volumes in Mpc^3/steradian, and time in years.

    Product's homepage

    Requirements:

    · Perl

      


    TAGS:

    cosmological distances | cosmological volumes | cosmological times | cosmological | distances | volumes

    Go to top

    WindowsGamesDriversMacLinuxScriptsMobileHandheldNews

    SUBMIT PROGRAM   |   ADVERTISE   |   GET HELP   |   SEND US FEEDBACK   |   RSS FEEDS   |   UPDATE YOUR SOFTWARE   |   ROMANIAN FORUM