File:Friedmann universes.svg

From Vero - Wikipedia
Jump to navigation Jump to search

Original file (SVG file, nominally 620 × 500 pixels, file size: 3 KB)

This file is from Wikimedia Commons and may be used by other projects. The description on its file description page there is shown below.

Summary

Description
English: The age and ultimate fate of the universe can be determined by measuring the Hubble constant today and extrapolating with the observed value of the deceleration parameter, uniquely characterized by values of density parameters (ΩM for matter and ΩΛ for dark energy). A "closed universe" with ΩM > 1 and ΩΛ = 0 comes to an end in a Big Crunch and is considerably younger than its Hubble age. An "open universe" with ΩM ≤ 1 and ΩΛ = 0 expands forever and has an age that is closer to its Hubble age. For the accelerating universe with nonzero ΩΛ that we inhabit, the age of the universe is coincidentally very close to the Hubble age.


Intended as a replacement for Universe.svg and Universos.gif.
Date
Source Own work
Author BenRG
SVG development
InfoField
 The SVG code is valid.
 This diagram was created with an unknown SVG tool.
  This diagram uses embedded text that can be easily translated using a text editor.
This diagram supersedes the file Universe.svg. It is recommended to use this file rather than the other one.

Deutsch  English  español  فارسی  français  magyar  Bahasa Indonesia  italiano  日本語  한국어  македонски  മലയാളം  Nederlands  polski  prūsiskan  português do Brasil  русский  slovenščina  svenska  中文(简体)  中文(繁體)  +/−

minor quality

Formulas

This diagram uses the following exact solutions to the Friedmann equations:

See also

Some of the shown models are implemented as an animation at Cosmos-animation.

Perl code

use strict;
use Svg;
use Math::Trig qw(sinh cosh acos asinh acosh pi);

sub ScaleFunc {
	my ($H0, $M0, $with_lambda) = @_;
	if ($M0 == 1) {
		my $q0 = 2/(3*$H0);
		return sub { my ($q) = @_; ($q - $q0, (1.5 * $H0 * $q) ** (2/3)) };
	}
	if ($with_lambda) {
		my $L0 = 1 - $M0;
		# assume 0 < $M0 < 1
		my $a = ($M0/$L0) ** (1/3);
		my $b = 1.5 * $H0 * sqrt($L0);
		my $q0 = asinh(sqrt($L0/$M0)) / $b;
		return sub { my ($q) = @_; ($q - $q0, $a * (sinh($b * $q) ** (2/3))) }
	} else {
		# \Omega_{\Lambda_0} = 0
		my $k0 = 1 - $M0;
		if ($M0 == 0) {
			return sub { my ($q) = @_; ($q - 1/$H0, $q * $H0) }
		} else {
			my $a = $M0 / (2 * abs($k0));
			my $b = 1 / ($H0 * sqrt(abs($k0)));
			my $c = $a * $b;
			if ($M0 > 1) {
				my $d = $a * (2 / ($H0 * $M0) - acos(2/$M0 - 1) * $b);
				return sub { my ($q) = @_; ($c * ($q - sin($q)) + $d, $a * (1 - cos($q))) }
			} else {
				# 0 < M < 1
				my $d = $a * (acosh(2/$M0 - 1) * $b - 2 / ($H0 * $M0));
				return sub { my ($q) = @_; ($c * (sinh($q) - $q) + $d, $a * (cosh($q) - 1)) }
			}
		}
	}
}

sub SubscriptedText {
	my $text = shift;
	$text->add(shift);
	my $sub = 0;
	for my $t (@_) {
		$sub = !$sub;
		$text->tspan($sub ? (dy => 4, 'font-size' => 12) : (dy => -4))->add($t);
	}
}

my ($image_width,$image_height) = (620,500);
my ($origin_x, $origin_y) = (30.5,450.5);
my $pad_right = 70;
my ($tlo, $thi, $ahi) = (-15,18,2.5);

my $svg = new Svg(width => $image_width, height => $image_height);
#	$svg->rect(width => $image_width, height => $image_height, fill => 'gray');
$svg->defs()->marker(id => 'arrowhead', refX => 0, refY => 3, markerWidth => 10, markerHeight => 6, markerUnits => 'userSpaceOnUse', orient => 'auto')->path(d => 'M 0,0 L 10,3 L 0,6 z');
my $traces = $svg->group(stroke => 'black', 'stroke-width' => 2, fill => 'none');
my $axes = $svg->group(stroke => 'black', 'stroke-width' => 1, fill => 'none');
my $labels = $svg->group('font-family' => 'Nimbus Roman No9 L, Times, serif', 'font-size' => 20, 'text-anchor' => 'middle', stroke => 'none', fill => 'black');
my $H0 = 1 / 13.95;
my $M0 = 0.279;
my ($graphscalex,$graphscaley) = (($image_width-$origin_x-$pad_right)/($thi-$tlo), -$origin_y/$ahi);
my ($graphofsx,$graphofsy) = ($origin_x - $tlo * $graphscalex, $origin_y);
for my $z ([0,0,30,'none'],[$M0,0,3.17,'1,4'],[1,0,26,'2,2'],[6,0,2*pi,'1,3,4,3'],[$M0,1,27,'5,3']) {
	my ($m0,$with_lambda,$max_q,$dashes) = @$z;
	my $f = ScaleFunc($H0,$m0,$with_lambda);
	my (@x,@y);
	for my $i (0..200) {
		($x[$i],$y[$i]) = &$f($i / 200 * $max_q);
	}
	$traces->path('stroke-dasharray' => $dashes, ($m0 == 6 ? () : ('marker-end' => 'url(#arrowhead)')), d => MakePath(\@x, \@y, $graphscalex, $graphscaley, $graphofsx, $graphofsy, 1));
}
$axes->line(x1 => $origin_x, y1 => $image_height-20, x2 => $origin_x, y2 => 20, 'marker-end' => 'url(#arrowhead)');
$axes->line(x1 => 10, y1 => $origin_y, x2 => $image_width - $pad_right + 10, y2 => $origin_y, 'marker-end' => 'url(#arrowhead)');
$labels->text(x => ($origin_x + $image_width) / 2, y => $image_height-10)->add('Billions of years from now');
my $path = '';
for my $gyr (-13.7, -10, -5, 0, 5, 10, 15) {
	my $x = int($gyr * $graphscalex + $graphofsx);
	my $y = $origin_y-5;
	$path .= "M$x.5,${y}l0,10";
	$labels->text(x => $x, y => $origin_y + 20)->add($gyr);
}
$axes->path(d => $path);
$labels->circle(cx => $graphofsx, cy => $graphscaley + $graphofsy, r => 4);
$labels->text(x => $graphofsx-5, y => $graphscaley + $graphofsy, 'text-anchor' => 'end')->add('Now');
$labels->text()->rotate(-90)->translate($origin_x - 8, $origin_y / 2)->add("Average distance between galaxies");
my $trace_labels = $labels->group('font-family' => 'DejaVu Serif, serif', 'font-size' => 16);
SubscriptedText($trace_labels->text(x => 465, y => 30, 'text-anchor' => 'end'), "\x{3A9}", 'M', " = 0.3, \x{3A9}", "\x{39B}", " = 0.7");
SubscriptedText($trace_labels->text(x => 520, y => 50, 'text-anchor' => 'start'), "\x{3A9}", 'M', ' = 0');
SubscriptedText($trace_labels->text(x => 535, y => 70, 'text-anchor' => 'start'), "\x{3A9}", 'M', ' = 0.3');
SubscriptedText($trace_labels->text(x => 540, y => 95, 'text-anchor' => 'start'), "\x{3A9}", 'M', ' = 1');
SubscriptedText($trace_labels->text(x => 540, y => 400, 'text-anchor' => 'start'), "\x{3A9}", 'M', ' = 6');

$svg->write('Friedmann universes.svg');

Licensing

Public domain I, the copyright holder of this work, release this work into the public domain. This applies worldwide.
In some countries this may not be legally possible; if so:
I grant anyone the right to use this work for any purpose, without any conditions, unless such conditions are required by law.

Captions

Solutions of the Friedmann Equations (not hand drawn)

Items portrayed in this file

depicts

23 September 2009

image/svg+xml

File history

Click on a date/time to view the file as it appeared at that time.

Date/TimeThumbnailDimensionsUserComment
current22:09, 23 September 2009Thumbnail for version as of 22:09, 23 September 2009620 × 500 (3 KB)wikimediacommons>BenRGNimbus Roman doesn't have Greek letters; switch to DejaVu Serif

The following 2 pages use this file: