Chatroom
 

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Bad Astronomy and Universe Today Forum > General > Questions and Answers
Register FAQ Members List Calendar Mark Forums Read

   

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #151 (permalink)  
Old 22-May-2008, 07:07 PM
loglo's Avatar
loglo loglo is offline
Senior Member
 
Join Date: Apr 2006
Location: Sydney,AU
Posts: 621
Default

Quote:
Originally Posted by TomT View Post
I would put the emphasis on probably because what you get is hypotheses and theories, which don't all agree. Here are some examples of your suggested Astronomy 101 type sources.

http://en.wikipedia.org/wiki/Spiral_galaxy
http://curious.astro.cornell.edu/que...php?number=199
http://www.sciam.com/article.cfm?id=...ss-creates-and

What an elementary description does say is that the arms are more dense star forming regions, and the space between arms less dense. No numbers are given. This does confirm the approach grav is undertaking, which is trying to simulate the spiral arm structure in his mass calculation.

If grav eventually can find a way to include mass variation, including some mass within the gaps between his simulated arms, and end up with a solution that is close to the total galaxy mass based on M/L, then he will have the answer.

TomT
I found a reference to the density of stars between the arms in the MW a while ago. Lost it in a computer crash but I recall the figure was 5% less dense between the arms than inside them and that the error bar was fairly large. Can't for the life of me recall the name on the paper, just that the lead author was a woman.
Reply With Quote
  #152 (permalink)  
Old 22-May-2008, 11:30 PM
StupendousMan's Avatar
StupendousMan StupendousMan is offline
Senior Member
 
Join Date: Sep 2006
Posts: 461
Default

Quote:
Originally Posted by TomT View Post
I would put the emphasis on probably because what you get is hypotheses and theories, which don't all agree.

TomT
Okay, how about some measurements? Two spirals with strong arms (in the visible) are M51 and M99. Papers describing infrared observations of these galaxies to study the arm-interarm contrast in light, and to estimate the contrast in mass, are

http://adsabs.harvard.edu/abs/1993ApJ...418..123R
http://adsabs.harvard.edu/abs/1996ApJ...460..651G

The authors estimate that the arm-interarm mass contrast ranges from around 1.5 to around 3.5 in these galaxies.
Reply With Quote
  #153 (permalink)  
Old 23-May-2008, 08:01 AM
Ken G's Avatar
Ken G Ken G is online now
Senior Member
 
Join Date: Oct 2005
Posts: 10,325
Default

But note that requires knowledge of the mass/light ratio, which is the first thing the "all-the-matter-in-the-disk" people need to dispute. So it is consistent for them to increase that ratio, and that would be more easily done in the spiral arms where the light is not coming from the bulk of the mass (it is coming from the young massive stars). I expect that is also true in the IR. So it is actually consistent for them to crank up the mass in the arms, relative to the interarms. I doubt it will make much difference for the rotation curves, and might introduce new difficulties related to the propagation of the spiral density waves responsible for the mass contrast between the arms and the inter-arms.
__________________
Lurking behind every good answer is an even better question.
Reply With Quote
  #154 (permalink)  
Old 24-May-2008, 06:53 AM
knicholson knicholson is offline
Member
 
Join Date: Nov 2004
Posts: 90
Default To Grav, equations

I had difficulty following your equations of Post 135. Can you give me an outline of what you are doing, similar to mine below?

Outline of Ken N equations in astro-ph/0309762 v2, pages7,8 :

A. Forward problem, given galaxy dimensions (incl thickness) and density distribution.

1. Find acceleration field for a single rod along a line bisecting and perpendicular to the rod.

2. Compute mass of single rod and find acceleration field for a single ring made up of rods, in the plane of the ring.

3. Find acceleration field for a disk made up of rings, in the plane of the disk.

4. Compute rotation speeds from accelerations.

B. Reverse problem, given galaxy dimensions and measured rotation speeds

1. Using an arbitrary density distribution compute rotation speeds as in A.

2. Compare measured and computed speeds at the outer radius of each ring (i). Correct the density in each ring(i) in a direction to reduce the error in speeds at its outer rim. Recompute through A until all speed errors are less than a desired limit.

I believe it would help to compute the acceleration field of a single ring, with h=rmax/20, to see the comparison with the elliptic integral solution for a "wire" ring, and with my Fig 7 of the paper.

Ken N

Last edited by knicholson; 24-May-2008 at 02:38 PM.
Reply With Quote
  #155 (permalink)  
Old 24-May-2008, 08:42 AM
astromark's Avatar
astromark astromark is offline
Senior Member
 
Join Date: Jun 2004
Location: Wanganui, New Zealand.
Posts: 2,439
Default

This is not the definitive answer to this question; The last word is not mine...
I think you are missing a small point. No two galaxies are identical. Consequentially no sameness of structure will be found. Its like comparing models of smoke clouds. Some of you are looking for what can not be found. The Composition, velocities and actual structures are always going to differ. You will not find a formula for star velocity near the core as the variables are so hard to nail down. I have just spent the last hour re-reading this thread and its links... Its as close as we can get as yet. The computer models are a very useful tools, but can not paint the whole picture. Bigger telescopes and imaging of greater detail might reveal more of the secret lives of galaxies... waiting... Mark.
Reply With Quote
  #156 (permalink)  
Old 25-May-2008, 12:01 AM
knicholson knicholson is offline
Member
 
Join Date: Nov 2004
Posts: 90
Default

To Astromark

It's true. There are lots of galaxy shapes. But for a large class of galaxies it's possible to get a good number for the mass (SMD) distribution, and a reasonable estimate for the density distribution. Some of these are:

NGC 4013 (by Hubble), and NGC 4565 (from Jeff MacQuarrie's home page) for edge-on views

Andromeda and NGC 3198 for face-on views

I can't seem to copy photos so you'll have to look them up. The pictures give good edge-on views for estimating thickness, and pictures of galaxies at an angle sufficient to measure the speeds. Of course the density varies appreciably in z (normal to the disk), but this can be handled in a reasonable way. See my paper astro-ph/0309762 v2.

For some of these, the dimensions (including thickness) are well know or can be estimated pretty well. We have to start somewhere.

Ken N

Last edited by knicholson; 25-May-2008 at 05:23 AM. Reason: finish post
Reply With Quote
  #157 (permalink)  
Old 25-May-2008, 01:55 AM
grav grav is offline
Senior Member
 
Join Date: May 2006
Posts: 2,388
Default

Quote:
Originally Posted by knicholson View Post
I had difficulty following your equations of Post 135. Can you give me an outline of what you are doing, similar to mine below?
Okay, well, first of all, I think I have the 'i' and 'j' terms backwards from what you have. I am using 'i' for the ring and 'j' for the position between rings in the program.

Lines 10 - 50 set up the parameters used; Nn=# of points across the x axis for each ring, N=# of rings, then the dimensions and other parameters of the disk, across points along x separated by Dx=R/N/Nn.

Lines 60 - 69 set up the rotation speed curve and finds the acceleration that would be necessary for each position outside of each ring for each rotation speed. The rotation curve used in the program climbs steadily to 1/3 of the radius of the galaxy and then levels off at Vv. (EDIT- Line 66 should have been '66 for S=1 to N')

Lines 90 - 100 start a loop finding for each position outside of a ring, then another loop for the rings.

Line 105 sets the ratios of density of each of the rings to 1 for the reverse problem, as a ratio to the initial arbitrary density De. This could have also been done in lines 66 - 69.

Lines 110 - 115 find the radius to the inside and outside of a ring.

Lines 120 - 140 add the acceleration across x for a ring. Finding for the height in the first part of an integration of a disk where R for the position lies along the x axis gives the formula for a single rod, or

Int G D (R - x) dx dy dz / [(R-x)^2 + y^2 + h^2]^(3/2)
= Int 2 G D (R - x) h dx dy / [(R - x)^2 + y^2] / sqrt[(R - x)^2 + y^2 + h^2]

Finding for the second part across the y axis gives

= Int 4 G D dx atan[h sqrt(r^2 - x^2) / (R - x) / sqrt[R^2 - 2Rx + r^2 +h^2]

so the program runs points across the x axis for the last integration for a disk with a radius equal to the outside of a ring and then subtracts the acceleration of a disk with a radius equal to the inside of a ring, giving just the acceleration of the ring itself.

Line 150 - 170 store the acceleration for each ring on each position in an array, sets the acceleration back to zero, then continues to run through the loops for the rest of the rings and positions in the same way.

Lines 200 - 215 set up the loop for each position for the reverse problem, sets the acceleration at the start of each loop, and adds the mass of each ring that lies in front of each of the positions.

Lines 220 - 235 add the acceleration of each of the rings on a particular position, using the accelerations in the array and multiplying by the current ratio of densities for each of the rings.

Lines 245 - 250 slightly decreases the density of the ring directly in front of the position if the total acceleration is greater than the acceleration necessary at that position for the rotation speed, or slightly increases it if it is too small.

Lines 260 - 290 print the densities of the rings, then the total mass across the rings for each full run, sets the mass back to zero, and starts the run over. The values eventually level out.
__________________
Let's put together the pieces of The Grand Puzzle . (website)

"Let's define another operator, Sz, which we won't pay any attention to."
"This transformation will automatically make zero equal zero."
"It may be true that zero equals zero -- and that is certainly an equality -- but I don't want to go into the details at this time."
Reply With Quote
  #158 (permalink)  
Old 25-May-2008, 04:31 AM
knicholson knicholson is offline
Member
 
Join Date: Nov 2004
Posts: 90
Default Equations

To Grav

Thanks, I'll try again. Ken N
Reply With Quote
  #159 (permalink)  
Old 25-May-2008, 09:42 AM
knicholson knicholson is offline
Member
 
Join Date: Nov 2004
Posts: 90
Default Ken N equations

To Grav

I had trouble in your equations connecting line 95 D=R/N*J with density since that is the outer radius of ring J.

In lines 130 and 138 solving for the angle B, you divide by (D-x). Should this be (R-x)?

In lines 135 and 139 solving for A, should De be D? Also it seems that B should be sin(B) or some trig function. Products with the angle can only be done for small angles.

I included my equations, where you may get some ideas. I believe they allow much faster computing, especially for the convergence with the reverse problem. They're set up to print to a seperate file, but you can print to the screen by changing all print #1, to print.
Note square root is sqr(x) instead of sqrt(x). I'm sure there are other differences, but I didn't see them. Be careful with the dimensions. To run problem 4 you must first run problem 3.

Ken N

' name is glxy6sht.bas, by Ken Nicholson 5/11/08
' short version of glxy6.bas


' define
' Note: Dimensionless forms all end in d, and are divided
' by these normalizing values:
' accelerations by akrim
' lengths by rmax
' mass by mtot
' SMD by SMD average
' speeds by vkrim

' at(j) = acceleration of test mass at radius j caused by
' all rings, plus to center, pc/yr^2
' a(i,j) = acceleration of test mass at radius j caused by
' ring i with unit density, plus to center, pc/yr^2
' akrim = kepler acceleration at the galaxy rim,
' g*mtot/(rmax)^2, pc/yr^2
' dr = ring incremental radius, rmax/nr, pcs
' dth = 2*pi/nrod
' dvol(i)= volume of ring i, pc^3
' g = gravitational constant, 4.498e-15 pc^3/(msun*yr^2),
' h = disc thickness at radius rr, pcs
' lytps= changes light years to parsecs, 3.066067E-1 pcs/ltyr
' m = mass of galaxy inside rm, msuns
' msun = sun mass, 1.989e33 gms
' mtot = total mass of galaxy, msuns
' nr = number of rings
' nrod = number of rods/ring
' pc = parsec, 3.085678e13 km
' pytks = mutiplier to change v(pc/yr) to v(km/sec)
' = 9.7778e5
' r = radius to centerline circle of a ring, pcs
' rr = radius to segment rod, pcs
' = (rm-dr)+(rm-.44*dr/(rm-dr/2)*dr/2
' rho = density of ring, msuns/pc^3,
' rhoav = average galaxy density, mtot/voltot, msuns/pc^3
' rm = radius to a measured or computed rotation speed,
' = radius to outside edge of a ring
' rmax = galaxy max radius, pc
' SMD = surface mass density, rho * h at radius rr, msuns/pc^2
' smdav = mtot/(pi*rmax^2), msuns/pc^2
' rt = test-mass radius, pc
' th = angle around ring, 0 at radius to test mass, rad
' v = test mass orbital speed, sqr(a*r), km/sec
' vk = kepler orbital speed not at rim
' = sqr(g*mtot/r)*pytks, km/sec
' vkrim = vk at galaxy rim, sqr(rmax*akrim)*pytks, km/sec
' vm = measured orbital speed, km/sec
' vmmx = max of vm, km/sec
' year = 3.155815e7 secs

open "o", #1, "glxyout.bas"

defint i-k, n
dim a(80,100),at(100),atd(100),dvol(80),h(80), m(80), md(80),rho(80)
dim rhod(80),rm(80),rmd(80),r(80),rd(80),rr(80),rrd(80 ),rt(100)
dim rtd(100),SMD(80),SMDd(80),v(100),vd(100),vk(100),v kd(100)
dim vm(100),vmsq(80)

' constants
pi = 3.141593: g = 4.498e-15: pytks = 977780!: lytps=3.066067E-1
cls

print" choose problem"
print" 1. flat disk, forward"
print" 2. flat disk, grav's problem, reverse"
print" 3. sphere, forward"
print" 4. sphere, reverse using output of problem 3. Run problem 3 to make choice at end"
input"choose from above"; i :cls

on i goto 10,20,30

' disk description, choose forward (irev=0) or reverse (irev=1)
10 a$="flat disk, 20 rings, 120 rods, forward problem"
irev=0: rmax=10000
nr=20: dr=rmax/nr: nrod=120: dth=2*pi/nrod
for i=1 to nr: rm(i)=dr*i: r(i)=(i-0.5)*dr
rr(i)=(rm(i)-dr)+(rm(i)-0.44*dr)/(rm(i)-dr/2)*dr/2
h(i)=100: rho(i)=1: next i
nt=1.2*nr: for i=1 to nt: rt(i)=dr*i: next i
goto 100

20 a$="grav's problem, 20 rings, 120 rods, h=const, reverse"
irev=1: rmax=lytps*100000/2
nr=10: dr=rmax/nr: nrod=120: dth=2*pi/nrod
for i=1 to nr: rm(i)=dr*i: r(i)=(i-0.5)*dr
rr(i)=(rm(i)-dr)+(rm(i)-0.44*dr)/(rm(i)-dr/2)*dr/2
h(i)=1000*lytps: rho(i)=0.5 : vm(i)=i/6*220: vmmx=220
if i>6 then vm(i)=220
next i
nt=1.2*nr: for i=1 to nt: rt(i)=dr*i: next i
goto 100

30 a$="sphere, 80 rings, 360 rods, fwd "
irev=0: rmax=10000: volc=4/3*pi*rmax^3
print: print #1, "problem 3, ";a$
nr=80: dr=rmax/nr: nrod=360: dth=2*pi/nrod
for i=1 to nr: rm(i)=dr*i: r(i)=(i-0.5)*dr
rr(i)=(rm(i)-dr)+(rm(i)-0.44*dr)/(rm(i)-dr/2)*dr/2
h(i)=2*sqr(rmax^2-r(i)^2): rho(i)=1
next i
nt=1.2*nr: for i=1 to nt: rt(i)=dr*i: next i
goto 100

40 a$="sphere, 80 rings, 360 rods, rev "
irev=1: rmax=10000: volc=4/3*pi*rmax^3
print: print #1, "problem 4, ";a$
nr=80: dr=rmax/nr: nrod=360: dth=2*pi/nrod
for i=1 to nr: rm(i)=dr*i: r(i)=(i-0.5)*dr
rr(i)=(rm(i)-dr)+(rm(i)-0.44*dr)/(rm(i)-dr/2)*dr/2
h(i)=2*sqr(rmax^2-r(i)^2): rho(i)=0.5
vm(i)=v(i)
next i: vmmx=vm(nr)rint"vmmx=";vmmx:input z
nt=1.2*nr: for i=1 to nt: rt(i)=dr*i: next i
goto 100


'forward problem start
' compute a(i,j), dvol(i), for rho=1, find vol
100 for j=1 to nt: for i=1 to nr: a(i,j)=0: next i:next j
print #1, "nr,nt =";nr;ntrint: print
vol=0: for j=1 to nt: for i=1 to nr
da=0: ddm=r(i)*dth*dr*h(i)
if j >1.1 then goto 110
dvol(i)=2*pi*r(i)*dr*h(i): vol=vol+dvol(i)
110 for k=1 to nrod/2: th=(k-.5)*dth: dum1=(rt(j)-rr(i)*cos(th))
dum2=rr(i)*sin(th): csq=dum1^2+dum2^2
dda=2*g*ddm/sqr(csq+(h(i)/2)^2)*dum1/csq
da=da+dda: next k
a(i,j)=a(i,j)+da: next i: next j

' given rho, a(i,j) then compute v(j)
krho =0
120 krho=krho+1: for j=1 to nt: at(j)=0: for i=1 to nr
dat=rho(i)*a(i,j): at(j)=at(j)+dat: next i
vsq=rt(j)*at(j): if vsq < 0 then vsq=0
v(j)=sqr(vsq)*pytks: next j
if irev=0 then goto 140


'density correction for reversible problem
iflag=0: nflag=0: errmx=-1: errmn=1
121 for i =1 to nr
errv=(vm(i)-v(i))/vmmx: frho=.75*errv
if abs(errv) >1e-6 then iflag=1
if errv<errmn then errmn=errv
if errv>errmx then errmx=errv
if abs(frho)>.5 then frho=.5*sgn(errv)
rho(i)=(1+frho)*rho(i)
nflag=nflag+iflag: next i
if krho mod 10 <> 0 then goto 123
cls: print"convergence watch"
print"krho,iflag,nflag,errmx,errmn = ";krho;iflag;nflag;errmx;errmn
' input x
123 if iflag=0 then goto 140
goto 120

'compute m,smd,mtot,rhoav,smdav,akrim,vkrim,md,rhod,atd,vd
140 mtot=0: rhomax=0: smdmax=0: ab=0
for i=1 to nr: ab=ab+rho(i)*dvol(i): m(i)=ab
smd(i)=rho(i)*h(i)
if rho(i)>rhomax then rhomax=rho(i)
if SMD(i)>SMDmax then SMDmax=SMD(i)
next i: mtot=m(nr)
rhoav=mtot/vol: SMDav=mtot/(pi*rmax^2)
akrim=g*mtot/rmax^2: vkrim=sqr(g*mtot/rmax)*pytks
for i=1 to nr: md(i)=m(i)/mtot:rhod(i)=rho(i)/rhoav
SMDd(i)=SMD(i)/SMDav: next i : input x :cls
for i=1 to nt: atd(i)=at(i)/akrim: vd(i)=v(i)/vkrim: next i

' printout for dimensioned results
150 print #1, " dimensioned results, corr vol=";volc: print #1,
print #1, "rmax, vol, mtot, SMDav, rhoav, = ": print #1," ";
print #1, using"##.####^^^^ ";rmax;vol;mtot;SMDav;rhoav;
print #1,
print #1,"SMDmax,rhomax,vkrim,vmmx,akrim = ": print #1," ";
print #1, using"##.####^^^^ ";SMDmax;rhomax;vkrim;vmmx;akrim
print #1,: print #1,_
" j r rr rho SMD rm m "
iprnt=nr/10
for j=1 to nr
if j mod iprnt <> 0 then goto 152
print #1, using"### ";j;
print #1, using"##.####^^^^ ";r(j);rr(j);rho(j);SMD(j);rm(j);m(j)
152 next j: print #1,
print #1, "i rt at v vm "
for i=1 to nt
if i mod iprnt <> 0 then goto 154
print #1, using"##";i;: print #1, using"##.######^^^^ ";rt(i);at(i);v(i);vm(i)
154 next i: input z: cls

'dimensionless forms
akrim=g*mtot/rmax^2: vkrim=sqr(rmax*akrim)*pytks
for i=1 to nt: rtd(i)=rt(i)/rmax
atd(i)=at(i)/akrim: vd(i)=v(i)/vkrim: next i
for j=1 to nr: rd(j)=r(j)/rmax: rrd(j)=rr(j)/rmax: rhod(j)=rho(j)/rhoav
SMDd(j)=SMD(j)/SMDav
rmd(j)=rm(j)/rmax: md(j)=m(j)/mtot
next j

'printout for dimensionless results
print #1,: print #1,: print #1, " dimensionless results"
print #1,
print #1," j rrd rhod rmd md rd SMDd"
for j=1 to nr
if j mod iprnt <> 0 then goto 170
print #1, using"###";j;
print #1, using"####.####";rrd(j);rhod(j);rmd(j);md(j);rd(j) ;SMDd(j)
170 next j: print #1, : print #1,
print #1, " i rtd atd vd "
for i=1 to nt
if i mod iprnt <> 0 then goto 172
print #1, using"###";i;
print #1, using"####.####";rtd(i);atd(i);vd(i)
172 next i : input z


290 print #1,: print #1,"number of cycles = ";krho: print #1,
input"run problem 4? yes =1 ",x: cls : if x=1 then goto 40


300 end

Last edited by knicholson; 25-May-2008 at 09:30 PM.
Reply With Quote
  #160 (permalink)  
Old 25-May-2008, 02:10 PM
grav grav is offline
Senior Member
 
Join Date: May 2006
Posts: 2,388
Default

Quote:
Originally Posted by knicholson View Post
To Grav

I had trouble in your equations connecting line 95 D=R/N*J with density since that is the outer radius of ring J.

In lines 130 and 138 solving for the angle B, you divide by (D-x). Should this be (R-x)?

In lines 135 and 139 solving for A, should De be D? Also it seems that B should be sin(B) or some trig function. Products with the angle can only be done for small angles.
Oh, whoops. I knew that would get me in trouble and/or cause some confusion sooner or later. When performing the integrations, I use r and R for the radius and distance from the center, but the computer doesn't differentiate between the two, so I started using D for R instead. Then when it came to finding for densities, I used D in the integrations and De in the program for that, but also used D() for the ratio of the density for a ring, so you might want to change that to De() to see it better. That'll make all De's densities and D and Dx distances. Um, yeah. Sorry about that.

Here are the integrations from my last post again, rewritten to match the program more closely.

Quote:
Lines 120 - 140 add the acceleration across x for a ring. Finding for the height in the first part of an integration of a disk where R for the position lies along the x axis gives the formula for a single rod, or

Int G De (D - x) dx dy dz / [(D-x)^2 + y^2 + h^2]^(3/2)
= Int 2 G De (D - x) h dx dy / [(D - x)^2 + y^2] / sqrt[(D - x)^2 + y^2 + h^2]

Finding for the second part across the y axis gives

= Int 4 G De dx atan[h sqrt(r^2 - x^2) / (D - x) / sqrt[(D - x)^2 - x^2 + r^2 + h^2]

so the program runs points across the x axis for the last integration for a disk with a radius equal to the outside of a ring and then subtracts the acceleration of a disk with a radius equal to the inside of a ring, giving just the acceleration of the ring itself.
__________________
Let's put together the pieces of The Grand Puzzle . (website)

"Let's define another operator, Sz, which we won't pay any attention to."
"This transformation will automatically make zero equal zero."
"It may be true that zero equals zero -- and that is certainly an equality -- but I don't want to go into the details at this time."
Reply With Quote
  #161 (permalink)  
Old 25-May-2008, 03:43 PM
grav grav is offline
Senior Member
 
Join Date: May 2006
Posts: 2,388
Default

Quote:
Originally Posted by knicholson View Post
I included my equations, where you may get some ideas. I believe they allow much faster computing, especially for the convergence with the reverse problem. They're set up to print to a seperate file, but you can print to the screen by changing all print #1 to print.
Thanks, Ken N. I'll look those over.

As far as the speed goes, finding the acceleration across a uniformly dense disk is exponentially faster with mine, because I only have to run it over one dimension, across the x axis, instead of two with rods and rings. Otherwise it is the same as yours, incorporating the rods with the first integration, but I then just cut out the "middle man" as far as the rings go. But with finding for varying densities across the rings for the reverse problem, I do need the rings, of course, so I end up running it in two dimensions anyway, basically just subtracting one large disk from a smaller one each time to make the rings, which is the same as running it over two dimensions anyway and would actually end up taking twice as long as yours to run it in the same way, but the preciseness of the last integration I'm using is immense, so I could actually run it over many less points to gain the same accuracy. That doesn't include how I'm doing it for the reverse problem, though, so it's open to suggestions. I haven't tried to improve on that yet, but it only takes a few seconds anyway.

You said that last program you posted for the sphere took you 30 seconds to run, so I ran mine over the same number of points as a comparison. It took 8 minutes, whereas it should have taken the same amount of time for the same number of points. I am running my numbers for 48 digits past the decimal point, though, and running my distances in meters, giving something like 20 digits in front of the decimal place for that, so up to 70 digits per number. I probably don't need quite that many digits for my values, but I do try to be precise. Limiting the digits to something like 10 ran it in about a minute and a half. I could also probably run it faster if I didn't have the screen print out the i's and j's with every loop. I like to do that so I can see where the program is at when running it over a very large number of points. Still, all in all, I think your CPU must be two to three times faster than mine with the language you are using.

I've noticed that rods around the rings does have more applications than mine does, such as with finding for spiral arms. So I've recently been trying to find a way to integrate for the rods around the rings as precisely as possible. It would be exactly the same as yours, but I still don't quite trust that rigging for the positions of the rods, clever as it is. Sorry. I just want to see it mathematically and more precisely. In another thread, I came up with something similar to that type of rigging which stabilized the regression of orbits when run over large intervals in a simulation program. It did great, but others were still skeptical because I could not show it mathematically, only by use of brute program crunching, and they could not be sure it would work the same for all configurations, and they were probably right in that sense for that concern, and so they would still have to compare results to the original "slow" program each time anyway to be sure, which would kind of defeat the purpose, since they might have just as well run that one in the first place, then.

In any case, I am now basically trying to adopt your program and work through it now, attempting to find a formula for the positioning of the rods as accurately as possible, or an integration for blocks around the ring to replace the rods altogether, hopefully with a preciseness similar to the one I've been using, because I want to use it for the spiral arms and other applications. The integrations are still being very, very stubborn as usual, but then, so am I.
__________________
Let's put together the pieces of The Grand Puzzle . (website)

"Let's define another operator, Sz, which we won't pay any attention to."
"This transformation will automatically make zero equal zero."
"It may be true that zero equals zero -- and that is certainly an equality -- but I don't want to go into the details at this time."
Reply With Quote
  #162 (permalink)  
Old 25-May-2008, 04:34 PM
knicholson knicholson is offline
Member
 
Join Date: Nov 2004
Posts: 90
Default Note small correction

To Grav

Note the correction ( print #1, to print) if needed.

Perhaps part of the speed is from the program I use. It's compiled Basic, called Quick Basic, by Microsoft back in 1985. It's the only program I've used since I retired back in 1986. All previous was Fortran which had enormous libraries, but lacked a lot of flexibility. I really like this compiled Basic.

I only use standard precision (8 place) instead of double. Seems quite adequate.

Good luck with your equations, and your attempts to code up spiral arms. Actually it shouldn't be very hard if you keep the steps simple and let the computer combine them. Be sure to make notes to youself for each step. It makes it a lot easier to track down the errors.

Ken N
Reply With Quote
  #163 (permalink)  
Old 25-May-2008, 07:37 PM
TomT TomT is offline
Senior Member
 
Join Date: Jan 2005
Posts: 629
Default Two-armed Spiral Galaxy Model

To grav and StupendousMan,
After looking through the papers referenced by SM, I think the "ying yang" model grav proposed has some merit with modifications. The density within the spiral arms vs the regions between arms is in the ratio 3.5 to 1.5. If I understand the M51 paper correctly, the variation is essentially linear, going from a minimum at a point midway between arms to a maximum at a midpoint of an arm. So if the minimum is rho0, the max is 7/3*rho0. Then a two armed spiral would be represented by density variation in the r and z directions as before, with variation in the theta direction starting at rho0 at say theta = 0. Then it would increase linearly to 7/3*rho0 at theta = 90, decrease back to rho0 at theta = 180, and then repeat. This could be simulated by your alternating rod - ring segment model, to get the spiral shape. Quite a challenge.
TomT
Reply With Quote
  #164 (permalink)  
Old 25-May-2008, 09:10 PM
grav grav is offline
Senior Member
 
Join Date: May 2006
Posts: 2,388
Default

Quote:
Originally Posted by TomT View Post
To grav and StupendousMan,
After looking through the papers referenced by SM, I think the "ying yang" model grav proposed has some merit with modifications. The density within the spiral arms vs the regions between arms is in the ratio 3.5 to 1.5. If I understand the M51 paper correctly, the variation is essentially linear, going from a minimum at a point midway between arms to a maximum at a midpoint of an arm. So if the minimum is rho0, the max is 7/3*rho0. Then a two armed spiral would be represented by density variation in the r and z directions as before, with variation in the theta direction starting at rho0 at say theta = 0. Then it would increase linearly to 7/3*rho0 at theta = 90, decrease back to rho0 at theta = 180, and then repeat. This could be simulated by your alternating rod - ring segment model, to get the spiral shape. Quite a challenge.
TomT
I have been spending some more time trying to work through some integrations for Ken N's rods and rings model, so I can use it for the spiral arms. I could use mine, but it would be a little complicated, and I want a better form of integration anyway if possible. In light of the recent discussions, I've basically dropped the rings and voids thing, and I'll go for running the rods part of the way around each ring and jumping to the next to imitate the spiral arms better. I'll fill in the rest of each ring with 40% of the same density used for the part of the arm in each ring, so that the spiral arm will be 2.5 times denser than the rest of each ring locally.
__________________
Let's put together the pieces of The Grand Puzzle . (website)

"Let's define another operator, Sz, which we won't pay any attention to."
"This transformation will automatically make zero equal zero."
"It may be true that zero equals zero -- and that is certainly an equality -- but I don't want to go into the details at this time."
Reply With Quote
  #165 (permalink)  
Old 27-May-2008, 10:55 PM
grav grav is offline
Senior Member
 
Join Date: May 2006
Posts: 2,388
Default

Ken N,

I'm having a tough time here. Let me verify a few results from you using your program. I need the results for the forward problem only for the rotation speeds of a disk of uniform density with a thickness that is 1/100 of the radius, like you've been using, with dimensionless results in comparison to the rotation speed on the surface of a sphere with the same mass and radius as the disk, using 80 rings and 810 rods per ring.

1. Placing the rods directly in the middle of a ring around the circumference, what do you get for the rotation speed at the rim?

2. Placing the rods directly in the middle of a ring around the circumference, what do you get for the rotation speed at 1/20 of the radius?

3. Using your latest formula for placing the rods, rr(i)=(rm(i)-dr)+(rm(i)-0.44*dr)/(rm(i)-dr/2)*dr/2, what do you get for the rotation speed at 1/20 of the radius?
__________________
Let's put together the pieces of The Grand Puzzle . (website)

"Let's define another operator, Sz, which we won't pay any attention to."
"This transformation will automatically make zero equal zero."
"It may be true that zero equals zero -- and that is certainly an equality -- but I don't want to go into the details at this time."
Reply With Quote
  #166 (permalink)  
Old 29-May-2008, 08:08 AM
knicholson knicholson is offline
Member
 
Join Date: Nov 2004
Posts: 90
Default computing check

To Grav

The speed at the rim is much higher than for nrod=120! I was expecting vd=1.75 or so. I don't know what to say yet. I'll look it over. There shouldn't be much difference once the number of rods is fairly big.

rods in middle of ring: rim speed vd= 1.9616, speed at rmax/20 vd= 0.0268

rods at 0.56 dr for inner circle: rim speed vd= 1.9617, speed at rmax/20 vd= 0.0461

Ken N

problem 1, flat disk, 80 rings, 810 rods, fwd, inner circle rods at dr/2
nr,nt = 80 96

dimensionless results

j rrd rhod rmd md rd SMDd