Translate

Monday, February 8, 2016

Observing in 2-D Gets a Bit More Complicated

We are bounded in a nutshell of Infinite Space: Reading #1: Observing in 2-D Gets a Bit More Complicated

The primary source for information throughout this semester will be Astrophysics in a Nutshell by Dan Maoz, where he introduces the reader to the basics of Astrophysics and the new world we are now embarking on get to know. Among the first topics discussed, we have the explanations of how Astronomy primarily uses the Electromagnetic Spectrum to conduct its observations of the deep fields of space. We also come to realize how Astrophysics is one of the few disciplines that requires interaction of many fields of study in order to more fully comprehend the phenomenon we are observing, be it chemical, physical, optical, relativistic, geological, meteorological, or perhaps biological.

Within the optical, there are many factors that come into play when observing, and how each of these are accounted for and used to better images depends on knowledge of physics, atmospheric science, and a foundation of quantum mechanics where needed. As we saw in a previous exercise (), an essential part of optical science in Astronomy is the use of telescopes and how these resolve images. In this same exercise, we were able to assume the resolution of a set of receptors in order to achieve interferometry is based on the equation \[\theta = \frac{\lambda}{D},\] where D is the distance between the receptors, \(\lambda\) is the wavelength, and \(\theta\) is the angle of resolution.

However, this equation only describes the resolution in one dimension, and when attempting to resolve in two dimensions the equation becomes \[ \theta = 1.22 \frac{\lambda}{D} .\] This factor of 1.22 has its origins in the calculations of Sir George Airy in the nineteenth century, who found how the diffraction pattern found in observations of stars and other objects, one of many concentric rings, could be accounted for mathematically.  His descriptions are now known as the Airy Disk, accounting for the maxima and minima of an image and how these change the expression for angular resolution. (Carroll & Ostlie, 2007, 146-147).


This factor comes from an integration of a Fourier Transformation in 2D, which makes as much sense to me as it does to you. But, there is a simpler way to understand this factor. Accept that there are these series of differential equations called the Bessel functions, and one of these accurately describes these concentric rings in a series of solutions to the equation. The solutions are : \[ J_1 = 3.8317 , 7.0156, 13.3237…\] and these can be used to define \[ ka \sin \theta = J_1\] where k is the wave number, a is the radius of the separation of the receptors, and \(\theta \) is the angle of resolution. 

Using some substitution and small angle approximation, we get: \[ \theta = \frac{3.83}{ka}\] where k is defined as \[k = 2\pi / \lambda\] so \[ \theta = \frac{3.83 \lambda}{2\pi a} \] \[ \theta = 1.22 \frac{\lambda}{D}\] and we now understand where this 1.22 factor comes from.  

Ever seen the pictures of the dozens of satellite dishes all in a row, here’s why

We are bounded in a nutshell of Infinite Space: Worksheet # 4, Problem #3: Ever seen the pictures of the dozens of satellite dishes all in a row, here’s why

Problem 3: Interferometers. Wait, interfere-what?

Interferometers are giant telescopes comprised of multiple smaller telescopes. Imagine two 1-meter telescopes in the CHARA array, separated by 330 meters (you should look up CHARA later). Use the double-slit experiment to think about how these two telescopes might be able to measure the angular diameter of a star with R = 5 Rd at a distance of 150 light years. What is the maximum wavelength λ at which this star can be resolved? Think about plane-parallel waves arriving from a star that is barely resolved. Instead of a point-source, the star will be a very narrow top-hat on the sky.



In case you haven’t, this is the Very Large Array (VLA), in New Mexico, which is one of the examples of how the properties of light are used to create extraordinary measurements and images from space. Knowing light has a double property of being a particle (known as a photon) and a wave, we can take advantage of the wave property in order combine many sources of the light using constructive interference, a property all waves have (either electromagnetic or vibrational).

Constructive interference is when you take two or more waves that have the same phase (time at which their valleys and peaks pass a certain point), and combine them so their amplitudes are added on to each other to make a more powerful signal. When you have several telescopes, or Satellites, you can receive a signal from a distant star at several points, and by catching each wave at just the right point, you can combine several signals to get a clearer image. (A full explanation of the basic theory for how this works can be found here: http://hyperphysics.phy-astr.gsu.edu/hbase/phyopt/slits.html).

Now, as to the problem at hand, we have a situation like this:

Where the distance from the star to the two satellites is so enormous that the distances from each dish is virtually identical, which also stems from a small angle approximation from the incredible distance. From some other facts from the question, we know the distance to the star is 150 light years, which can be turned into meters with: \[ c_{Speed~of~Light} \times t_{Seconds ~in ~a ~year} \times \delta_{Distance ~to~Star} [ly]  =\delta_{Distance ~to~Star} [m] \] \[ 3\times 10^8 \frac{m}{s} \times 3.15 \times 10^7 \frac{s}{year} \times 150 ly = 1.42 \times 10^{18} m .\]

Next, we find the size of the star in meters. We know this star’s diameter is \(5R_\odot\) ad we must find the diameter. So: \[R_{\odot} = 6.96 \times 10^8 m\] \[  D_\star = 2 \times 5 \times R_{\odot} \] \[ D_\star = 7.0 \times 10^9 m ,\]

Imagining the star’s diameter to be the opposite side, and the distance to it the hypotenuse of a triangle with an extremely small angle, we can use the following approximation to find the angle: \[\theta = frac{D_\star}{ \delta_{Distance ~to~star}} \] \[\theta = \frac{7.0 \times 10^ 9 m}{1.42 \times 10^{18} m}\] \[ \theta = 4.93 \times 10^{-9} .\]


And now we can use the equation established by the Double Slit experiment for Constructive Interference: \[ \theta = \frac{\lambda}{D} ,\] where D is the distance between the two signal recipients , and \(\lambda\) is the wavelength of the signal, what we are trying to find. So, using this equation, we have: \[ \theta \cdot D = \lambda\] \[ \lambda = 4.93 \times 10^{-9} \cdot 200 m \] \[ \lambda = 9.86 \times 10^{-7} = 986 nm ,\] the maximum wavelength which can be resolved. 

So it turns out the stars don’t revolve around us…

We are bounded in a nutshell of Infinite Space: Worksheet # 3, Problem #2: So it turns out the stars don’t revolve around us…

The Local Sidereal Time (LST) is the right ascension that is at the meridian right now. LST = 0:00 is at noon on the Vernal Equinox (the time when the Sun is on the meridian March 20th, for 2013 and 2014).

a) What is the LST at midnight on the Vernal Equinox?
b) What is the LST 24 hours later (after midnight in part ’a’)?
c) What is the LST right now (to the nearest hour)?
d) What will the LST be tonight at midnight (to the nearest hour)?
e) What LST will it be at Sunset on your birthday?

As I am sure many (and I sincerely hope all) of you have convinced yourself the Earth revolves around the Sun, and the Earth is indeed a near-sphere-like object, we’ll skip over this portion (that being said, if you want to learn more about how to prove this with a couple of simple facts, look here: http://www.physlink.com/Education/AskExperts/ae535.cfm ). Suffice to say, the fact we have two main, noticeable, rotations we are experiencing at all times means there are certain considerations which need to be taken into account when creating a precise, universal system for measuring and plotting the observable skies.

First of all, we have the Earth’s rotation on its own axis which goes from the South Pole to the North Pole, which means there are portions of the 24 hour rotation when we can see the light of far off stars and galaxies (night), and a time when we cannot, i.e. the Sun is bright enough the during the day it outshines anything else. This is compounded on a 365 full on-axis rotation (day) long journey around the Sun, which means the stars we see change according to which part of our orbit we’re on (full view of this here: https://www.youtube.com/watch?v=R2lP146KA5A). This is also complicated by the fact the Earth’s axis is rotated slightly, which is the entire reason we have seasons of the year as one hemisphere of the Earth receives more light/energy than the other.

Altogether, this series of rotations and shifts causes a noticeable difference in how the sky we observe is consistently different day to day. This is due to how, let’s say, we wish to see a specific star and have it appear directly above the observer, at 90 degrees from the horizon, then when the Earth has moved \(\frac{1}{365}\) part of a circle, then there is additional rotation time needed in order for the star to be at the right position once again. Look here:  


This entire concept is known as Sidereal Time, and the adjustment made every day to account for this Sidereal Time shift is: \[Sidereal ~Time ~Shift = \frac{24~ hours \times 60 \frac{min}{hour}}{365 ~days}\] \[ Sidereal ~Time ~Shift = 4 \frac{min}{day},\] which means every Sidereal Day is 23 hours and 56 minutes long.

Furthermore, we have an additional concept called Local Sidereal Time (LST), which is the Right Ascension Hour (an actual time at which an object is on the stellar meridian (the line that intersects the Earth’s equator projected onto the stars at 90 degrees)). We add on the actual, physical hour of the present day to the shift accumulated since noon on the 20 of March (in the case of 2015), which is the Vernal Equinox, the day when the daytime and nighttime are the same length. This turns out to be:


a) Now, starting the problem, we want to find out the LST at midnight on the Vernal Equinox. Here, we know the time difference from noon to midnight is 12 hours, which corresponds to the \(H\) in the \[LST = H_{Hour~ Angle} + \alpha_{Right ~Ascension},\] and the LST shift for half a day is simply 2 minutes (half of 4 minutes), so the LST at midnight is just \[12:02 .\]

b) Letting time elapse for an additional 24 hours, we know a day is equal to 4 more minutes in LST, so on one day past the Vernal Equinox at midnight, the LST would be \[ 12:06 .\]   

c) Assuming we are defining “right now” as the first time we solved this problem, on Tuesday, February 2, 2016 at 3:00 pm, we can make some wide analyses to find the LST.
From the 2015 Vernal Equinox to February 2, 2016, 318 days have passed. For every day, the LST gains an additional 4 minutes on its shift from the current time. So, if we take the change in Right Ascension, which is the shift, \(\alpha\) :\[\alpha = 318 days \times 4 \frac{min}{day} \div 60 \frac{min}{hour} = 21.2 hours = 21:12 ,\] and we now add the 0.5 minute LST shift from the three hours that elapsed since noon, the final \( \alpha \) is \( 21: 13 \). Therefore, by adding the Hour Angle (H), \(3:00\), we have \[LST = \alpha + H \] \[LST_{Feb~ 2, ~ 2016,~ 3:00PM } = ~21:13~ + ~3:00 \] \[ LST_{Feb~ 2, ~ 2016,~ 3:00PM } = 0: 13 \approx 0:00.\]

d) Furthermore, by having the basis for February 2, at 3pm, it is only a matter of adjusting a bit more to have the LST for midnight on the same day. It is currently 3:00 pm, which means 9 more hours will elapse, and the corresponding LST shift would be 1.5 minutes \[ \frac{4}{24} = \frac{x}{9}\] \[x = 1.5,\] so the new time would be the addition of the shift and the actual hour change: \[ LST_{Midnight} = 0:16 + 9:00 + 0:02\] \[ LST_{Midnight} = 9:18 \approx 9:00 .\]

e) Undeerstanding the basic mechanics of LST, we can now use it to extrapolate it to other dates, like my birthday, October 7, on its sunset: 6:14 pm. So if the Vernal equinox this year is March 20, we start here with the 0:00 date. Now we add on the days from that day till my birthday, being:
\[11_{March} + 30_{April} + 31_{May} + 30_{June} +31_{July} + 31_{August} + 30_{September} + 7_{October} = 201 ~days\] \[ LST ~Shift = 201 ~days \times 4\frac{min}{day} = 804 min = 13:24 ,\]

And knowing the precise time of the sunset plus its shift since noon (approximately 1 minute), we have: \[LST_{Sunset} = 13:24 + 6:14 + 0:01 ,\] \[ LST_{Sunset} = 19:39 .\]


*Small disclaimer, my real birthday is a couple of days off from what we used here, but you know, identity theft is a thing in this world now. 

Monday, February 1, 2016

An equation like few others

The Friedman Robertson Walker Metric is perhaps one of the most useful equations when determining the nature of the universe, dependent of our understanding of the early universe and the ramifications this had on the present. Founded on the work of Einstein in describing relativity and the fabric of space-time, the equation allows for the description of universes with completely different geometries and conceptions of reality, while still preserving some of the discoveries made by the likes of Hubble and Friedman himself (for more on his equations look at posts Cosmology 101 Parts 1 & 2)

\[ds^2 = -c^2 dt^2 + a^2(t) \left[\frac{dr^2}{1-kr^2} + r^2 (d\theta^2 + \sin^2\theta ~ d\phi^2)\right].\]

Previously, we had the chance to see this equation in how it is used (after many steps of simplifying, and integrating, and deriving) to find the radius of the universe’s event horizon, the farthest we can see back in time.

As we wade into the water again...


Hi everyone, and welcome to the second edition of “We are bounded in a nutshell of infinite space” for the class Astronomy 16 at Harvard College (note the change in URL and the fact my mother will most likely call me soon to inquire as to why I won’t let her see my blog (her words, not mine)). Nonetheless, we continue.

My name is Rodrigo Cordova, I am in my second semester of freshman year at Harvard College, with the current intent to spend the rest of my days studying astrophysics (unless dark energy turns out to be water fowl we missed this whole time, in which case I am OUT OF HERE (yes, that is my only objection, moving on)). I was born and raised on the balmy 80 degree (Fahrenheit/ 31 C) island, Puerto Rico, which I am proud to call my home and nostalgic of every time I cannot place an accent on my last name, because admissions officers do not understand the meaning of this symbol. My interests include camping, painting, leatherwork, stargazing, and generally lacking sleep.

But all jokes aside, I have had the opportunity to learn some amazing things the past months in the incredible institution I have the privilege and responsibility to attend, and I plan to keep putting my best forward this semester and the rest of the time in this field. I want to continue exploring, discovering, learning and reflecting on the same questions which started this blog (see: http://ay16-rodrigocordova.blogspot.com/2015/09/we-are-bounded-in-nutshell-of-infinite.html ). I, like many others, have just set foot in the ocean lying before me, the water seems cool and inviting, now all which is left is to jump in, and see what lies ahead (to paraphrase Carl Sagan).

“Give me a place to stand and I shall move the world”

                                                          -Aristarchus

Wednesday, December 9, 2015

Our Universe a Supercomputer Created

We are bounded in a nutshell of Infinite space: Blog Post #37, Illustris Simulation Worksheet: Our Universe a Supercomputer Created

An incredible feat of astronomical research and data use, the Illustris Simulation attempts to demonstrate how the observable universe has developed over billions of years in order to create the superclusters and incredible webs of gas and dark matter we can detect, in some ways. With the simulation, we can observe how galaxies and other immense structures have halos, extensions of the individual galaxies and clusters made of dark matter which wrap around the objects we ordinarily associate with matter.

By going to the a Illustris Simulation website (http://www.illustris-project.org/explorer/) and going to its “The Explorer” tab, one could see how the universe looks like today, according to the simulation, and see how dark matter, gas density, gas velocity, temperature, X-ray emissions, all of it, interact with one another and are present in the same areas.  Furthermore, by selecting on the tab’s “Spatial Query on Click” option, we can identify specific details about a set of halos. From this data, we will focus on the halo and star mass data. Seeing a table similar to the one below, we can export this data (essentially copying and pasting it out) and get something like this:

Exporting this data as a CSV file (save as CSV) and importing into Python software, we can start to analyze it.

First off, we prepare the environment for the program:
import numpy as np
import matplotlib
import matplotlib.pyplot as plt
Then we upload the specific data:
file = np.loadtxt(fname='data.txt')

And name the specific columns (we eliminated them before exporting the data, since Python doesn’t recognize text as data):
id, xpos, ypos, halo_mass, star_mass, umag, bvcolor= file.T

We then define our data, what we are going to use, exactly, and prepare a histogram to understand the scatter of the halo masses:
halo_mass_data = halo_mass
log_mass_bins = np.arange(9, 12,0.1)

plt.xlabel("Log Halo Mass")
plt.ylabel("Number")
plt.hist(halo_mass_data, bins = log_mass_bins)
plt.show()


Now with these, we produce a table which looks like:
Thus indicating how there is a greater number of lower mass halos than there are high mass halos.

Using some simple division to see what percentage of the halo mass was stellar mass, and then averaging all these values to understand the standard, about 85% of the halo mass is stellar mass.

If we were to qualitatively analyze how Dark Matter Density and Gas Density compare to one another, we can see how, at a large scale, the densest dark matter regions correspond directly with the densest gas regions, they follow the same filament structures and appear to have the all the clusters of gas and dark matter in the same regions.
Gas Density

Dark Matter Density 


However, once the images are zoomed in towards the smaller scales, with individual galactic clusters, the similarities give way to stark contrasts. The most evident one is how the gas density image illustrates how gas is most dense around and in galaxies, as one would expect. But for dark matter, the presence of a galaxy and the presence of the greatest density of dark matter does not correspond precisely, as you can see from the images of the same area below:
 
Dark Matter Density Close Up

Gas Density Close Up 

Furthermore, by observing the large scale structures, it is evident dark matter is more closely confined to the filamentary structure, not the gas, which is clearly more spread out across the universe. We can reason this out by understanding how the mass of dark matter is what is holding galaxies and bigger structures together. These filaments are the pathways which regular matter follows, so it is attracted to it and thus coalesces around it, but is in the process of doing so, as shown of how all matter has slowly organized itself into filaments set by the dark matter. If you analyze specific galaxies, you will also find how the gas density of individual galaxies is highest near the nucleus, the area “near” the black hole at the center of the galaxy. Also, the largest galaxies are rarely found on their own in the less dense areas, rather they are clearly in the presence of many other galaxies and have developed a cluster around itself.   


Single Galaxy as seen in Gas Density Filter
Range of Galaxies in a Cluster, in the Visible Light Filter

Thereafter, if we look at this video (http://www.illustris-project.org/movies/illustris_movie_cube_sub_frame.mp4 ) and analyze the proceedings of the dark matter and gas temperature; we see how their evolution seems to coincide in many ways, the dark matter giving the structure of how the diffuse gas would gain its “shape” from the filaments first set by the dark matter. So, we can understand that the structure formation is led by the dark matter, it itself become more defined as time goes on, but it was still the first to have a basic structure that the baryons (gas) followed and thus created the structure we see at the end.

Also, if we were to read the time and redshift data, we can see there is a range of time when the gas structure begins to “brighten”, which in this diagram means become energized. We know the most common element in the universe is hydrogen, so we also know that it requires a minimum amount of energy to ionize and move its electrons into higher orbits. From this understanding of a bit of atomic physics and quantum mechanics, we can recognize ionized hydrogen by its wavelength (and shift caused by redshift). Furthermore, the fact we can see the hydrogen is also an important fact, for it signaled the end of the “Dark Ages”, the time between the big bang and the first light emitted from ionized hydrogen, and the beginning “Epoch of Reionization”. This, according to the video, occurs at approximately 0.5 billion years after the Big Bang and at redshift 9.5-9.8. Also, if we focus on how quickly stellar mas is forming (how many stars are beginning to ignite) we see how there is a definite range in which stellar mass begins to develop very rapidly. Here, in the period between 4.5 and 7 billion years, the stellar mass increases by approximately 27 billion solar masses, the most sustained rapid growth seen in the simulation, although there were some “incredibly quick” periods every few billion years afterwards that also had this rapid increment.

Another aspect of the simulation to consider is how, near the beginning, small structures were coming together to form the largest structures, following the filament structure laid out by dark matter .But these large structures eventually star breaking up and creating a more diffuse structure, although it is more highly energized than it was before the explosions. This high energization allows smaller structures to form and combine again and lead to more explosion, a cycle of destruction and creation. This pattern is likely caused by the force of gravity attracting the large masses together, tugging them along towards the filaments of dark matter, which we know has to emit a rather large gravitational force. This is the reason the structures form along filaments, the gravity that binds the dark matter together in the way that it has maintained itself for over 13 billion years continues to control how the baryons reorganize themselves. The filaments are the basic gravitational structure of the universe, and normal matter adheres to it by the forces that act on it over the span of billions of years.


Images, videos, and data taken from:

https://www.youtube.com/watch?v=NjSFR40SY58  

Just how stretched out can the universe get?

We are bounded in a nutshell of Infinite space: Blog Post #36, Worksheet # 12.1, Problem #1 & #2d: Just how stretched out can the universe get?  

1. Linear perturbation theory. In this and the next exercise we study how small fluctuations in the initial condition of the universe evolve with time, using some basic fluid dynamics. In the early universe, the matter/radiation distribution of the universe is very homogeneous and isotropic. At any given time, let us denote the average density of the universe as \(\bar{\rho}(t)\). Nonetheless, there are some tiny fluctuations and not everywhere exactly the same. So let us define the density at comoving position r and time t as \(\rho (x,t)\) and the relative density contrast as \[\delta(r,t) = \frac{\rho(r,t) - \bar{\rho}(t)}{ \bar{\rho}(t)}\]. In this exercise we focus on the linear theory, namely, the density contrast in the problem remains small enough so we only need consider terms linear in \(\delta\). We assume that cold dark matter, which behaves like dust (that is, it is pressureless) dominates the content of the universe at the early epoch. The absence of pressure simplifies the fluid dynamics equations used to characterize the problem.

(a) In the linear theory, it turns out that the fluid equations simplify such that the density contrast \(\delta\) satisfies the following second-order differential equation \[\frac{d^2\delta}{dt^2} + \frac{2\dot{a}}{a} \frac{d\delta}{dt} = 4\pi G \bar{\rho}\delta,\] where \(a(t)\) is the scale factor of the universe. Notice that remarkably in the linear theory this equation does not contain spatial derivatives. Show that this means that the spatial shape of the density fluctuations is frozen in comoving coordinates, only their amplitude changes. Namely this means that we can factorize \[\delta(x,t) = D(t)\tilde{\delta}(x)\] , where \(\tilde{\delta}(x)\) is arbitrary and independent of time, and \(D(t)\) is a function of time and valid for all x. \(D(t)\)  is not arbitrary and must satisfy a differential equation. Derive this differential equation.

(b) Now let us consider a matter dominated flat universe, so that \(\bar{\rho}(t) = a^{-3} \rho_{c,0}\) where \(\rho_{c,0}\) is the critical density today, \(3H_0 ^2/8\pi G\) as in Worksheet 11.1 (aside: such a universe sometimes is called the Einstein-de Sitter model). Recall that the behavior of the scale factor of this universe can be written \(a(t) = (3H_0 t /2)^{2/3}\) , which you learned in previous worksheets, and solve the differential equation for \(D(t)\). Hint: you can use the ansatz \(D(t) \propto t^q\)  and plug it into the equation that you derived above; and you will end up with a quadratic equation for q. There are two solutions for q, and the general solution for D is a linear combination of two components: One gives you a growing function in t, denoting it as \(D_+ (t)\); another decreasing function in t, denoting it as \(D_- (t)\).

(c) Explain why the \(D)_+\) component is generically the dominant one in structure formation, and show that in the Einstein-de Sitter model, \(D_+ (t) \propto a(t)\).

(a) The key for this problem is solving to eliminate the x, which would make the differential equation true for all space and would change for a specific time. Thus, starting off with the original equation \[\frac{d^2\delta}{dt^2} + \frac{2\dot{a}}{a} \frac{d\delta}{dt} = 4\pi G \bar{\rho}\delta,\] and the equivalency of the space-time factor with its specific parts separated into time and space: \[\delta(x,t) = D(t)\tilde{\delta}(x)\] we just have to plug into the first equation and take the time derivative to solve: \[ \ddot{D}(t)\tilde{\delta}(x) + \frac{2\dot{a}}{a} \dot{D}(t)\tilde{\delta}(x)= 4\pi G \bar{\rho} D(t)\tilde{\delta}(x),\] and since we can show with this that the space dimension is not affected, the common factor on both sides can be eliminated: \[ \ddot{D}(t) + \frac{2\dot{a}}{a} \dot{D}(t) = 4\pi G \bar{\rho} D(t),\] and we thus have a differential equation valid for all x.


(b) First off, we need to establish the correct expressions for the scale factor and the critical density: \[ a(t) = \left(\frac{3H_0 t}{2}\right)^{2/3},\] and if we were to take the first derivative: \[ \dot{a}=\frac{2}{3} \left(\frac{3H_0 t}{2}\right)^{-1/3} \frac{3h_0}{2} \] \[\dot{a} =H_0 \left(\frac{3H_0 t}{2}\right)^{-1/3} ,\] and then divided by the original definition of the scale factor: \[\frac{\dot{a}}{a}= \frac{ H_0 \left(\frac{3H_0 t}{2}\right)^{-1/3}}{\left(\frac{3H_0 t}{2}\right)^{2/3}}\] \[\frac{\dot{a}}{a} = \frac{H_0}{\frac{3H_0 t}{2}}, \] we now have: \[\frac{\dot{a}}{a} = \frac{2}{3t}.\]

As for the critical density: \[\bar{\rho}(t) = a^{-3} \rho_{c,0},\] so the value of a can simply be put into the density expression: \[\bar{\rho}(t) = \left[\left(\frac{3H_0 t}{2}\right)^{2/3}\right]^{-3} \rho_{c,0}\] \[ \rho_{c,0} = 3H_0 ^2/8\pi G\] \[\bar{\rho}(t) = \frac{4}{9 H_0 ^2 t^2} \frac{3H_0 ^2 }{8\pi G} \]  \[\bar{\rho}(t) = \frac{1}{6\pi G t^2}.\]

Taking the differential equation we solved for all space, we can place the values we have just found like: \[ \ddot{D}(t) + \frac{2\dot{a}}{a} \dot{D}(t) = 4\pi G \bar{\rho} D(t),\] \[ \ddot{D}(t) + \frac{2\dot{a}}{a} \dot{D}(t) = 4\pi G D(t) \frac{1}{6\pi G t^2},\] \[ \ddot{D}(t) + 2\left(\frac{2}{3t}\right) \dot{D}(t) = \frac{2 D(t)}{3 t^2},\] \[ \ddot{D}(t) + \frac{4}{3t} \dot{D}(t) - \frac{2}{3t^2} D(t) = 0 .\] And now that the equation has been simplified as much as it can be, we add in some squiggle math, knowing an important relationship between density with respect to time and time to a variable q:\[D(t) \propto t^q\] and taking the necessary derivatives, we have: \[ q(q-1) t^{q-2} + \frac{4}{3t} q t^{q-1}- \frac{2}{3t^2} t^q  \sim 0 .\] \[ q(q-1) t^{q-2} + \frac{4}{3t} q t^{q-1}- \frac{2}{3t^2} t^q  \sim 0 .\] \[ (q^2 - q) t^{q-2} + \frac{4}{3} q t^{q-2}- \frac{2}{3} t^{q-2}  \sim 0 .\] So after simplifying the equation a bit, we can take out a couple of common factor and be left with a solvable polynomial: \[ t^{q-2} [(q^2 - q) + \frac{4}{3} q - \frac{2}{3t}] \sim 0 .\] \[ \frac{t^{q-2}}{3} [ 3q^2  + q - 2 \sim 0 ,\] and now we can use the quadratic formula to solve for q \[ q = \frac{-1 + \sqrt{1-4(3)(-2)}}{2(3)}\] \[ q = \frac{2}{3} ~,~ -1\] with these two values for q, they correspond to the increasing and decreasing functions the problem talks about, as: \[D_+ (t) \propto t^{2/3} ~,~ D_- (t) \propto \frac{1}{t} ,\] which means that a combination of these two expressions describes the entirety of the density with respect to time function: \[D(t) \approx D_+ (t) + D_- (t) .\]


(c) Because of the nature of \( D_+ (t) \) and its value we now know, it is clearly the dominant factor in establishing the development of density I the universe over time, for its growth is much more sustained and clear than that of \( D_- (t) \), which actually tends towards 0. However, the \(D_- (t)\) part of the function once was the dominant figure, at very low/small t, which makes it an important factor to consider. Furthermore, the \(D_+ (t)\) model closely resembles (it is actually identical to) the description of the expansion of the universe in a matter dominated universe, as we saw in a previous post (http://ay17-rcordova.blogspot.com/2015/11/cosmology-101-part-2.html), which indicates how a flat universe expands is identical to the scale factor for a matter dominated universe. 


2. Spherical collapse. Gravitational instability makes initial small density contrasts grow in time. When the density perturbation grows large enough, the linear theory, such as the one presented in the above exercise, breaks down. Generically speaking, non-linear and non-perturbative evolution of the density contrast have to be dealt with in numerical calculations. We will look at some amazingly numerical results later in this worksheet. However, in some very special situations, analytical treatment is possible and provide some insights to some important natures of gravitational collapse. In this exercise we study such an example.

(d) Plot r as a function of t for all three cases (i.e. use y-axis for r and x-axis for t), and show that in the closed case, the particle turns around and collapse; in the open case, the particle keeps expanding with some asymptotically positive velocity; and in the flat case, the particle reaches an infinite radius but with a velocity that approaches zero.

(d)Taking key facts from the other parts of this problem, we know that for a closed universe, the equations for the distance from the origin r and the time that defines this are: \[r =A(1-\cos\eta),\] \[t = B(\eta - \sin\eta), ~~(0 \leq \eta \leq 2\pi),\] whereas for an open universe, the equations are: \[r = A(\cosh\eta - 1),\] \[t = B(\sinh\eta - \eta), ~~(0\leq \eta \leq \infty). \] Finally, for a flat universe, the equations become: \[ r = A\eta^2 / 2,\] \[t = B\eta^3 / 6, ~~ (0\leq \eta \leq \infty),\] where one can be expressed in terms of the other as: \[t = B\eta^3 / 6\] \[\eta = \frac{\sqrt[3]{6t}}{B}\] \[ r = A\eta^2 / 2\] \[ r = \frac{A \left(\frac{\sqrt[3]{6t}}{B}\right)^2}{ 2},\] \[ r = \frac{A\left(\frac{6t}{B}\right)^{2/3}}{2}.\] Knowing these values, limits and expressions, we can plot these into Python and create a good model to describe how particles act in these descriptions of the universe.

First, we just have to create the environment for the program:
import numpy as np
import matplotlib
import matplotlib.pyplot as plt

Next, we start describing each of the r and t and the \(\eta\) limits, for each system, while setting the 
constants to 1 since these are only scale factor and do not directly influence the overall shape the graph takes:
#closed
n1=np.arange(0,2.*np.pi, 0.1)
r1=1.*(1.-np.cos(n1))
t1=1.*(n1-np.sin(n1))
plt.plot(t1,r1,label="Closed")

We do this process again with the open universe, first describing the limits (scaled here so they all fit in one graph at the end) and then the equations with the constants once again set to 1.
#open
n2=np.arange(0,2.7,0.1)
r2=1.*(np.cosh(n2)-1.)
t2=1.*(np.sinh(n2)-n2)
plt.plot(t2,r2,label="Open")

And here, for the flat case, we place the solved equation for r in terms of t we derived earlier and give t the limits as we did in the open universe description.
#flat
t3=np.arange(0,2.*np.pi,0.1)
r3= (((6.*t3)**(2./3.))/2.)
plt.plot(t3,r3,label="Flat")

Now with the final programs to define the plot with labels and legends:
plt.legend(loc=2)
plt.xlabel('Scaled Time')
plt.ylabel('Scaled Growth of the Radius of the Universe')
plt.show()

We have:
Full code used:
import numpy as np
import matplotlib
import matplotlib.pyplot as plt

#closed
n1=np.arange(0,2.*np.pi, 0.1)
r1=1.*(1.-np.cos(n1))
t1=1.*(n1-np.sin(n1))
plt.plot(t1,r1,label="Closed")

#open
n2=np.arange(0,2.7,0.1)
r2=1.*(np.cosh(n2)-1.)
t2=1.*(np.sinh(n2)-n2)
plt.plot(t2,r2,label="Open")

#flat
t3=np.arange(0,2.*np.pi,0.1)
r3= (((6.*t3)**(2./3.))/2.)
plt.plot(t3,r3,label="Flat")

plt.legend(loc=2)
plt.xlabel('Scaled Time')
plt.ylabel('Scaled Growth of the Radius of the Universe')

plt.show()