this is going to be a boring video no
not that kind of boring
there we go all i'm going to do is show
you how to simulate the universe on your
own computer
we're going to be using after effects
and it doesn't really matter what
version you have as long as it's fairly
recent to start with we need some
initial conditions we want to know what
the universe looked like just after the
big bang so we're going to use the data
from the wmap satellite which took
pictures of the cosmic microwave
background you can get these images from
the wmap website but they're in the
weird egg-shaped mall vita projection
and we'd like them to be in the
equirectangular projection and there are
ways of changing coordinates but for now
i'll provide you with a sample of cmb
data looks like this it's pretty
exciting
actually you can even just use the
fractal noise in after effects because
that's what the cmb is basically it's
gaussian random noise so anyway once we
have our cmb data image file
we'll create a new composition with it
and immediately we'll pre-comp it
because we're going to be using a
particle plug-in to start with let's
clean up this data a little bit so i'm
just going to add some levels
just to make it a little bit more punchy
and that's within the pre-comp now in
the main composition we need to create
just a blank solid
and this will rename particles because
it will contain our particles and we
will add particle playground which is
the basic plugin for doing particles and
after effects to start with if we play
we see we have this beautiful and
annoying cannon so we'll turn off the
cannon now we have nothing so we're
going to use the grid to seed our
particles we want the grid to match the
size of our comp so it'll be 500 by 500
and say maybe we want 20 by 20 particles
that enough now let's go 40 by 40.
all right now we have particles except
if we play we see that it creates a new
particle at every position on every
frame so we want to keyframe these
numbers and just go to the next frame
and then set them to
zero so we only get one particle for
each point starting off and now if we
play
they're all falling down because there's
gravity now this is gravity like a
constant force in the downward direction
which isn't what we want we want
particles to attract each other so i'm
going to turn this off and we will go to
the repel section
and we want the particles to attract so
we'll just add in a negative amount on
the repel so let's do minus 0.1 just to
start with now as we play it nothing
happens because the radius for the force
to take effect is too small so we'll set
this up to 50 and hopefully that'll
catch some nearby particles this isn't
realistic gravity is basically either
you're attracted to something if it's
relatively close to you or you're not
attracted to it at all if it's farther
away real gravity falls off like one
over r squared but anyway if we play
this now we'll see that the particles
are indeed attracting each other the
ones in the middle don't move very much
because they're pulled equally on both
sides but the ones the outside get
pulled in and as we wait we'll see a
beautiful symmetric mishmash of
particles but this isn't really what we
want we want the particles to attract
each other based on the density of the
early universe and so the bright spots
on the cmb data that we used are high
density and the dark spots are low
density so we want to seat our particles
using the cmb so we can see things
better i'm going to turn off the cmb add
a white solid behind the particles and
make the particles black
now we're going to set the persistent
property of opacity of the particles
so we're going to use the cmb data as
the source and we will map the red to
opacity
now we see the places where the cmb data
was brightest or dark black and the
places where it was darkest are faint
turn it back on and you can see that so
now if we simulate forward we're still
going to get the same thing because all
we've done is affect the opacity of the
particles and not their mass so to
affect the mass of the particles we go
into the repel settings and we want to
select using a selection map of the same
the cmb data and
that's all we have to do
now the particles that are darker will
attract more and the particles that are
lighter will attract less so let's play
this forward and see what happens
so you can see that the particles that
are darker are the ones that are
attracting all the others to them and
the particles that are lighter are
literally lighter they're less dense
although we've got the simulation fairly
well order how about the color to get
the color nice we wanted it to be really
bright where the particles overlap and
faint where they don't because when the
particles in the real universe come
together they heat up and you get bright
things like stars
so to do that we actually need to make
these a little bit less opaque so that
the brightness adds up so i'm going to
go back in here to our persistent
property mapper and change the opacity
max setting to something like 0.15 so
now everything's going to be very faint
but that's all right that's what we want
so now i'm going to go back into project
and create a new composition
and call it simulation
with color and to create the color all
we have to do is we'll create an
adjustment layer
and the first thing we do is we add a
levels to it and that's going to allow
us to control just how dark and bright
these particles are so we'll bring up
the levels actually a little bit to make
the particles more visible then we're
going to color it so we'll use colorama
oh that's interesting what we're gonna
do is we'll just change the output cycle
from none to negative as our starting
point so that basically just inverts the
colors and then near the white end we
want it to be a little bit orange to
match the millennium simulation let's
just pick your favorite orange okay we
have orange there and then somewhere in
the near the mid-darker end we're going
to make it a blue purple again to match
the millennium simulation so now i think
we've ramped our levels up a little bit
too much and one last thing i'm going to
add on a fast blur
to take off those hard edges of the
particles so just a blurriness of one
and now let's see what happens
look at this these galaxies
or these dense spots they're gonna
collide
and there you have it simulation of the
large-scale structure of the universe on
your laptop
you