Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
C
comp-sci-project
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
nguyed99
comp-sci-project
Commits
5eb1edaa
Commit
5eb1edaa
authored
1 year ago
by
nicoa96
Browse files
Options
Downloads
Patches
Plain Diff
simulate
parent
fb1db657
No related branches found
No related tags found
1 merge request
!10
Nicoa96 main patch 73354
Pipeline
#59649
passed
1 year ago
Stage: test-jobs
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
jobs/src/Galaxy_Collision_Simulation/3D/simulate.py
+12
-0
12 additions, 0 deletions
jobs/src/Galaxy_Collision_Simulation/3D/simulate.py
with
12 additions
and
0 deletions
jobs/src/Galaxy_Collision_Simulation/3D/simulate.py
0 → 100644
+
12
−
0
View file @
5eb1edaa
"""
This code is used to run the simulation of the galaxy collision.
Adjust the number of Particles (num_particles), the number of time steps (num_steps),
the time step (time_step), the number of snapshots to display and if the axes of
the plots shoulb be fixed or not (fix_axes), and then run the simulation
"""
from
galaxysimulation
import
GalaxyCollisionSimulation
sim
=
GalaxyCollisionSimulation
(
num_particles
=
2
)
sim
.
simulate
(
num_steps
=
10000
,
time_step
=
0.001
)
sim
.
display_snapshots
(
200
,
fix_axes
=
True
)
\ No newline at end of file
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment