Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
SWIFTsim
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
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
SWIFT
SWIFTsim
Commits
d25b91be
Commit
d25b91be
authored
9 years ago
by
Matthieu Schaller
Browse files
Options
Downloads
Patches
Plain Diff
Print some information about the SPH to stdout in engine_init()
parent
11de7fe7
No related branches found
No related tags found
2 merge requests
!136
Master
,
!94
Integer timeline
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/engine.c
+5
-0
5 additions, 0 deletions
src/engine.c
src/hydro.h
+5
-0
5 additions, 0 deletions
src/hydro.h
with
10 additions
and
0 deletions
src/engine.c
+
5
−
0
View file @
d25b91be
...
...
@@ -52,6 +52,7 @@
#include
"cycle.h"
#include
"debug.h"
#include
"error.h"
#include
"hydro.h"
#include
"minmax.h"
#include
"part.h"
#include
"timers.h"
...
...
@@ -2272,6 +2273,9 @@ void engine_init(struct engine *e, struct space *s, float dt, int nr_threads,
e
->
ti_current
=
0
;
message
(
"Minimal timestep size: %e"
,
e
->
timeBase
);
/* Print information about the hydro scheme */
message
(
"Hydrodynamic scheme: %s"
,
SPH_IMPLEMENTATION
);
if
((
e
->
policy
&
engine_policy_fixdt
)
==
engine_policy_fixdt
)
{
e
->
dt_min
=
e
->
dt_max
;
...
...
@@ -2384,3 +2388,4 @@ void engine_print_policy(struct engine *e) {
fflush
(
stdout
);
#endif
}
This diff is collapsed.
Click to expand it.
src/hydro.h
+
5
−
0
View file @
d25b91be
...
...
@@ -25,14 +25,19 @@
#if defined(MINIMAL_SPH)
#include
"./hydro/Minimal/hydro_iact.h"
#include
"./hydro/Minimal/hydro.h"
#define SPH_IMPLEMENTATION "Minimal version of SPH (Price 2010)"
#elif defined(GADGET2_SPH)
#include
"./hydro/Gadget2/hydro_iact.h"
#include
"./hydro/Gadget2/hydro.h"
#define SPH_IMPLEMENTATION "Gadget-2 version of SPH (Springel 2005)"
#elif defined(DEFAULT_SPH)
#include
"./hydro/Default/hydro_iact.h"
#include
"./hydro/Default/hydro.h"
#define SPH_IMPLEMENTATION "Default version of SPH"
#else
#error "Invalid choice of SPH variant"
#endif
void
hydro_print_scheme
();
#endif
/* SWIFT_HYDRO_H */
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