Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reissner–Nordström metric visualization (possibly, geodesics too?) #657

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

aSimpson02
Copy link

@aSimpson02 aSimpson02 commented May 14, 2024

Created a new notebook/example focusing on the reissner nordstrom metric, a non EV metric solution.- #626

@auto-assign auto-assign bot requested a review from JeS24 May 14, 2024 13:11
@JeS24
Copy link
Member

JeS24 commented May 18, 2024

@aSimpson02 Could you update the PR description with the issue number and a list of changes that you have made? I believe, the related issue is #626 (first one in the list there).

@JeS24
Copy link
Member

JeS24 commented May 18, 2024

Also, update the PR title accordingly.

@aSimpson02
Copy link
Author

hi, thanks for the feedback, I will be working on this today.

@aSimpson02 aSimpson02 changed the title Annie branch reissner nordstrom metric May 24, 2024
@aSimpson02
Copy link
Author

hi I have updated the PR description and title, please let me know if i need to change anything else.

Copy link
Member

@JeS24 JeS24 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@aSimpson02 Thanks for the PR. Some changes & additions are needed. The referenced issue (#626) talks about adding tutorial notebooks to showcase the ability to pass custom Python functions that define a metric, to the Geodesic module, to compute geodesics in such spacetimes. See https://github.com/einsteinpy/einsteinpy/pull/625/files for an example with the Kerr metric (_kerr). Your notebook only defines and plots the metric. Can you try integrating it with Geodesic like it is done in this example: https://github.com/a3ahmad/einsteinpy/blob/e56fd9ed7a752f0997ae63a2ceee2247fc2a9019/tests/test_geodesic/test_geodesic.py#L175 with _kerr?

Besides this, there are two non-issues that should be noted regardless:

  1. The RN metric is an electro-vacuum (EV) solution. Although, for the sake of this example notebook, it's not an issue.
  2. The geometric unit system used by the numerical part of EinsteinPy sets $G = c = M = 1$ (so-called M-units). So, mass is technically not required, but we'll keep it as-is.

docs/source/_static/anim.gif Show resolved Hide resolved
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Restore this file.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Restore this file.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  1. Add a title at the top in markdown (text):

    # Reissner–Nordström metric
    
  2. Fix capitalization and use markdown to style the text, like so (See: https://github.com/aSimpson02/einsteinpy/blob/main/docs/source/examples/Visualizing%20Frame%20Dragging%20in%20Kerr%20Spacetime.ipynb for an example)

    ### Importing libraries
    
    ### Defining the metric function
    
    ### Compute metric components
    
    ### Visualise the metric
    

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hi I have attempted the markdown style, please tell me if this is ideal, thank you !

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks fine.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Though, the capitalization of the last header is incorrect.
image
### Visualise the metric

@JeS24 JeS24 changed the title reissner nordstrom metric Reissner–Nordström metric visualization (possibly, geodesics too?) May 25, 2024
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hi apologies, I accidentally clicked resolved, I am currently working on this issue now.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No problem.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If you run into any problems during the restoration process, don't hesitate to ask for help.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hi, apologies, I am struggling to restore the files that I accident deleted here in the pull request, can you recommend me any way I can retrieve them back into the project.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The fastest way would be to move the Reissner-Nordström metric.ipynb notebook file out of the local git repo folder, and to reset the local git repo to the last commit, before your changes, like so:

# NOTE: First, move the Reissner-Nordström metric.ipynb out of the repo (as a backup).
# Use Finder / File Explorer for this or use the `mv` command if using terminal.

# Then, reset the repo locally:
git fetch --all
git pull
git reset --hard e56fd9ed7a752f0997ae63a2ceee2247fc2a9019 # <-- Hash of the last commit before your changes. This command would reset your local git repo to this commit. This should restore those files locally.

# Force-push the change to your fork on GitHub, so that the other files are restored everywhere
git push -f

# Move the file back to `.../docs/source/examples/`
# Use Finder / File Explorer for this or use the `mv` command if using terminal.

# Then, commit & push again.
git commit -m "Added Reissner-Nordström metric.ipynb"
git push

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants