Miikka Vaisala
|
204f075343
|
AC_unit_magnetic in dsl
|
2020-11-19 15:14:28 +08:00 |
|
jpekkila
|
830b8ad179
|
Disabled LBFIELD by default as there are no autotests for it
|
2020-09-14 13:27:09 +03:00 |
|
Miikka Vaisala
|
b815b62aa7
|
Enhanced simulation cc. Now magnetic fields diagnostics invoked if needed.
Also more exit condition so that the simulation will terminate if nan happens or timestep becomes too short.
|
2020-09-11 14:59:32 +08:00 |
|
Miikka Vaisala
|
450526b8e1
|
B-field calculation to the DSL file.
Still needs corresponding things elsewhere...
|
2020-09-11 13:23:01 +08:00 |
|
Miikka Vaisala
|
7848dedfbe
|
Gauge correction to the induction equation for the sake of numerical stability.
Used in my dynamo work, but apparantly was not done to the main repo.
|
2020-09-11 11:58:09 +08:00 |
|
jpekkila
|
f21c6a8c0b
|
Disabled LFORCING and LUPWD temporarily until the new MPI standalone module is properly tested
|
2020-08-24 18:46:38 +03:00 |
|
jpekkila
|
0ccd4e3dbc
|
Major improvement: uniforms can now be set to default values. The syntax is the same as for setting any other values, f.ex. 'uniform Scalar a = 1; uniform Scalar b = 0.5 * a;'. Undefined uniforms are still allowed, but in this case the user should load a proper value into it during runtime. Default uniform values can be overwritten by calling any of the uniform loader funcions (like acDeviceLoadScalarUniform). Improved also error checking. Now there are explicit warnings if the user tries to load an invalid value into a device constant.
|
2020-01-28 18:17:31 +02:00 |
|
Miikka Vaisala
|
185b33980f
|
Forcing function bug correction.
|
2020-01-14 13:58:11 +08:00 |
|
jpekkila
|
ea4438f331
|
Adapted the old example of helical forcing with profiles to conform with the revised syntax
|
2019-10-07 19:43:25 +03:00 |
|
jpekkila
|
ff12332f06
|
Clarified the syntax for real number literals. 1.0 is the same precision as AcReal, 1.0f is an explicit float and 1.0d is an explicit double.
|
2019-10-07 18:24:32 +03:00 |
|
jpekkila
|
6560be7056
|
Moved the old mhd solver to mhd_solver_DEPRECATED and replaced it with the new stencil_kernel.ac file
|
2019-10-07 17:36:30 +03:00 |
|
jpekkila
|
8c1e603a98
|
On second thought, let's revert the changes in mhd_solver and use the file I already modified instead of doing the same changes twice
|
2019-10-07 17:29:53 +03:00 |
|
jpekkila
|
16c8b1e748
|
Autoformatting
|
2019-10-07 17:17:58 +03:00 |
|
jpekkila
|
c8e0586b60
|
Renamed the old .sas and .sdh files to regular headers and added #pragma once.
|
2019-10-07 17:17:26 +03:00 |
|
Miikka Vaisala
|
f8e82d41af
|
Can now set the endtime for simulation, instead of step number.
|
2019-10-02 15:09:26 +08:00 |
|
Miikka Vaisala
|
1b0e9803b0
|
Compiles and runs again.
Now to actual testing. Can we read and cotinue from and old file?
|
2019-10-02 13:52:38 +08:00 |
|
jpekkila
|
7d76250f70
|
Updated stencil_process.sps with the revised syntax for real literals
|
2019-10-01 21:20:28 +03:00 |
|
jpekkila
|
2c8c49ee24
|
Removed or updated some old .gitignore files
|
2019-09-24 17:50:41 +03:00 |
|
Miikka Vaisala
|
f5733e5144
|
Turnin LSINK off by default to prepare for merge to master.
|
2019-09-16 11:15:44 +08:00 |
|
Miikka Vaisala
|
bd55c42fe5
|
Hann-windowing for the sink
|
2019-09-03 16:38:16 +08:00 |
|
Miikka Vaisala
|
dac509241f
|
Cleanup, comments and a new template.
|
2019-09-03 15:24:58 +08:00 |
|
Miikka Vaisala
|
b3ed0937fe
|
Changes according to JP's comments in the Issue #8.
|
2019-09-03 10:19:22 +08:00 |
|
Miikka Vaisala
|
ac92123842
|
Made a note about a bug in 083ff59 , just to remember that code is now more correct.
|
2019-09-02 18:40:38 +08:00 |
|
Miikka Vaisala
|
f3a36ec276
|
Moved definition location of AC_nx_min etc. Otherwide DSL does not compile the code correctly!!!
|
2019-09-02 18:29:16 +08:00 |
|
Miikka Vaisala
|
b4cd92da0c
|
Now compiles and runs.
PLEASE NOTE THAT FLAGS NEED TO BE SET SEPARATELY IN simulation.cc and renderer.cc FOR LSINK and LFORCING!
|
2019-09-02 14:47:58 +08:00 |
|
Miikka Vaisala
|
02ac6c956f
|
Desperately trying to port the new changes of DSL.
Still work to do.
|
2019-09-02 14:04:27 +08:00 |
|
Miikka Vaisala
|
6eeb225924
|
Merge branch 'master' into sink_20190723
Hopefully the merge isssues were resolved.
|
2019-09-02 11:58:48 +08:00 |
|
jpekkila
|
20138263f4
|
The previous attempt (dsl_feature_completeness_2019-08-23) to enable arbitrary kernel functions was a failure: we get significant performance loss (25-100%) if step_number is not passed as a template parameter to the integration kernel. Apparently the CUDA compiler cannot perform some optimizations if there is a if/else construct in a performance-critical part which cannot be evaluated at compile time. This branch keeps step_number as a template parameter but takes rest of the user parameters as uniforms (dt is no longer passed as a function parameter but as an uniform with the DSL instead).
|
2019-08-27 17:36:33 +03:00 |
|
Miikka Vaisala
|
1410e57866
|
Preparing isothermal collapse.
|
2019-08-22 18:18:30 +08:00 |
|
Miikka Vaisala
|
a81bc22fb6
|
Write now sink infor to time series. Also a bug cerrection for sink switch.
|
2019-08-22 11:52:02 +08:00 |
|
jpekkila
|
5d2b658fb0
|
Autoformatted the DSL files
|
2019-08-20 18:41:26 +03:00 |
|
JackHsu
|
5b686bc659
|
Fixed on/off switch for forcing and accretion, now forcing only happens for first 1000 steps (currently hard-coded), and accretion only happen after 1000 steps.
|
2019-08-20 23:12:42 +08:00 |
|
jpekkila
|
5b7408eb55
|
User config param overhaul complete, works. If I haven't missed anything, all fields and user parameters, and everything related to simulation can now be declared with the DSL. The only thing that you need to do is to fill the declared symbols with data, like with OpenGL and GLSL.
|
2019-08-19 18:43:16 +03:00 |
|
jpekkila
|
51cf1f1068
|
The C header is now generated from the DSL, stashing the changes just to be sure since I might overwrite something when updating the compilation scripts to work with this new scheme
|
2019-08-19 18:19:28 +03:00 |
|
jpekkila
|
bcdd827a4f
|
Added a proper declarations for all user-specified uniform. Note: built-in uniforms are not correctly translated into CUDA
|
2019-08-19 17:05:56 +03:00 |
|
jpekkila
|
0208d55e4e
|
Moved STENCIL_ORDER and NGHOST out of user-defined parameter as these are actually internal defines used to configure the built-in functions. Additionally, renamed all explicitly declared uniforms from dsx -> AC_dsx in the DSL in preparation for having clear connection between DSL uniforms and the library parameter handles created by the user (AcRealParam etc)
|
2019-08-19 16:40:47 +03:00 |
|
Miikka Vaisala
|
5d93d743c7
|
Improved sink particle stability vie Truelove criterion.
|
2019-08-19 14:38:36 +08:00 |
|
Miikka Vaisala
|
1bfb0390ad
|
Seemingly reasonable sink for both density and velocity.
|
2019-08-16 13:29:34 +08:00 |
|
Miikka Vaisala
|
f921840505
|
Changed to step function
|
2019-08-16 11:44:41 +08:00 |
|
Miikka Vaisala
|
a8fbced89d
|
Error correction.
|
2019-08-16 11:36:39 +08:00 |
|
Miikka Vaisala
|
53bd3d4aa4
|
Correction factor for the equation.
|
2019-08-16 11:13:21 +08:00 |
|
Miikka Vaisala
|
60f2af0971
|
Renamed accretion_profile -> sink_accretion. More intuitive.
|
2019-08-16 09:52:12 +08:00 |
|
JackHsu
|
6c50c0a40e
|
sink effetc in equations.
|
2019-08-15 19:23:26 +08:00 |
|
JackHsu
|
a5bb56873a
|
Now resets accretion buffer at every step.
|
2019-08-15 17:51:39 +08:00 |
|
JackHsu
|
c7df5be068
|
tried new accretion profile, and added some to-do's.
|
2019-08-14 18:43:22 +08:00 |
|
JackHsu
|
56c51e5315
|
fixed the undefined error in compilation.
|
2019-08-13 18:36:12 +08:00 |
|
JackHsu
|
0587d08b01
|
Had some rough draft of accretion criterion.
|
2019-08-13 18:31:57 +08:00 |
|
JackHsu
|
927a5e74f2
|
Made accretion time-dependent now, need to come up with better accretion crition than truelove.
|
2019-08-13 18:06:29 +08:00 |
|
JackHsu
|
ff59431d65
|
Added modularized term for accretion range, which is some wave function, and module that'll allow time-dependent accretion.
|
2019-08-13 17:43:52 +08:00 |
|
JackHsu
|
8c7176d702
|
Completed function to sum VTXBUF_ACCRETION and updates mass of sink particle. Needs further work with crashing problem.
|
2019-08-12 19:02:22 +08:00 |
|