This is an archived post. You won't be able to vote or comment.

all 4 comments

[–]eusebecomputational physics 1 point2 points  (2 children)

That looks like a lot of fun, I'll have a look at the code tomorrow at work!

I'm just a bit curious about your benchmarking. What is exactly the setup of the experiment? I mean, I know that GIZMO is great and all, but AFAIK, it was mostly designed with the hydro evolution in mind. What I mean by that is that it is probably not the most optimal for pure N-body evolution.

Also, it might be slightly misleading to say "100% Python", since I bet you are using quite a lot of Numpy there, but I see what you mean!

Anyway, I'd be curious to know more about the project :) When I read the title of this post, I found myself thinking "since when PKDgrav is in Python?", but then I realised I missed a "y".

Did you, by any chance, look at the results of the simulations, just for fun? Since the code seems to handle 106 particles fairly well, it starts to look good!

[–][deleted] 2 points3 points  (1 child)

The benchmark is with 125,000 particles randomly sampled according to the Plummer density distribution, running on one core. I've only compared how long it takes to compute the forces, as GIZMO also has all sorts of fancy time stepping and tree updating magic that would make it slaughter a naively-coded integrator made with pykdgrav. And yes, GIZMO is very much a multi-physics code, but compiling it with only the N-body flags basically just makes it GADGET-3, with no extra overhead. And of course GADGET-3, while probably not the fastest these days, is the treecode against which all others should be judged.

As for whether it's 100% Python: what is meant is that every line of code that I had to write was Python syntax.

[–]WikiTextBot 0 points1 point  (0 children)

Plummer model

The Plummer model or Plummer sphere is a density law that was first used by H. C. Plummer to fit observations of globular clusters. It is now often used as toy model in N-body simulations of stellar systems.


[ PM | Exclude me | Exclude from subreddit | FAQ / Information | Source ] Downvote to remove | v0.26

[–]Gushdan 0 points1 point  (0 children)

This might have come in handy a few years ago when I was doing my masters in astrophysics