Skip to content

Commit

Permalink
Add the capability to check whether a B-series is energy-preserving (#…
Browse files Browse the repository at this point in the history
…117)

* comentario

* requested changes to the PR: added function for bseries 'BSeries_Energy_Preserving', translated comments into English, erased two packages, changed the name of some variables and flags.

* generalized the function 'bush_detector_ for any iniital index. Changed the name of 'adjoint()' for 'rightmost_energy_preserving_tree()'

* added the files 'examples.jl' with four examples; also added the file for the code of the CSRK project.

* simplified the function 'symfact_normalization', and realized that the only function taken from 'Combinatorics' is 'permutations'.

* added docstrings. Deleted the function 'BMinus'. Eliminated the variable 'signal' from the main functions. Renamed the function 'IsEnergyPreserving' for 'energy_preserving_trees_test'

* added docstrings and modified the CSRK.jl. Added tests to the runtests.jl

* added Energy_Preserving.jl to src

* fixed first function in CSRK.jl

* added a module in Energy_Preserving.jl. In the file 'BSeries.jl' I added the lines 'include("Energy_Preserving.jl")', 'using .Energy_Preserving', and 'export OrderMethod'

* added 'include("Energy_Preserving.jl")' to the BSeries file, and wrote 'export Energy_Preserving.OrderMethod' and 'using Energy_Preserving'

* Committing local changes

* added the code of Energy_Preserving to src/BSeries.jl

* removed files from this branch: examples.jl, Energy_Preserving.jl and CSRK.jl

* removed the file 'src/Energ_Preserving.jl'

* Modified the docstring and added main reference for 'is_energy_preserving'

* added the line 'export is_energy_preserving, OrderMethod'

* removed Revise from  the file 'Project.toml'

* changes in BSeries.jl: changed the name of 'OrderMethod', added the functoin 'permutations' from Combinatorics

* removed Combinatorics from dependencies

* Modifications so that the 5 tests passed

* changed the version of Combinatorics to "1"

* Update src/BSeries.jl

Co-authored-by: Hendrik Ranocha <ranocha@users.noreply.github.com>

* Update src/BSeries.jl

Co-authored-by: Hendrik Ranocha <ranocha@users.noreply.github.com>

* moved the line of Combinatorics alphabetically
 Please enter the commit message for your changes. Lines starting

* changed docstrngs in secondary functions for comments

* removed comments from renormalize_bseries and used 'eachindex'

Co-authored-by: Hendrik Ranocha <ranocha@users.noreply.github.com>

* several modifications, but the tests still passed. changed dictionaries for arrays, renamed some as 'ribs', and made the code shorter.

* changed dictionaries for arrays, used the word 'ribs' for some variables and eliminated the function 'reverse_leafs'

* eliminated the function 'get_permutations'

* modified the function 'renormalize_bseries!' so that it receives a bseries and modifies it. Also, added docstring and exported this function.

* added the 'max_order' parameter to 'energ_preserving_order(A,b,max_order)'

* modified the function 'energy_preserving_order' so that its input is a rk method. Then, also modified the runtests file

* added references to RK methods in the tests

* changed 'spine/ribs' for 'trunk/branch'

* modified the function 'is_energy_preserving' to iterate over each order instead of all the trees every time

* added comments to the new functino 'low_order_energy_preserving'

* added 'assert'. Deleted 'add_one_to_the_left' function and fixed ortography issues

* put the function 'get_trunk' inside the function 'get_branches', so that this is only one function now.

* modified the function 'equivalent_trees': now its faster and the function 'is_energy_preserving' is really fast for order 10

* changed variables names in the function 'equivalent_trees'

* modified the 'runtest' file for higher orders for the AVF method

* modified the comments about the function 'low_order_energy_preserving'

* format

* format

* fix typo

---------

Co-authored-by: David Ketcheson <dketch@gmail.com>
Co-authored-by: Hendrik Ranocha <ranocha@users.noreply.github.com>
  • Loading branch information
3 people authored Jun 13, 2023
1 parent 04b2f99 commit fdfc459
Show file tree
Hide file tree
Showing 3 changed files with 491 additions and 1 deletion.
2 changes: 2 additions & 0 deletions Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ authors = ["Hendrik Ranocha <mail@ranocha.de> and contributors"]
version = "0.1.48"

[deps]
Combinatorics = "861a8166-3701-5b0c-9a16-15d98fcdc6aa"
Latexify = "23fbe1c1-3f47-55db-b15f-69d7ec21a316"
LinearAlgebra = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e"
OrderedCollections = "bac558e1-5e72-5ebc-8fee-abe8a469f55d"
Expand All @@ -23,6 +24,7 @@ SymPyExt = "SymPy"
SymbolicsExt = "Symbolics"

[compat]
Combinatorics = "1"
Latexify = "0.15, 0.16"
OrderedCollections = "1"
Polynomials = "2.0.23, 3 - 3.2.8, 3.2.10"
Expand Down
Loading

0 comments on commit fdfc459

Please sign in to comment.