Skip to content

Commit

Permalink
A first Lie group! (#8)
Browse files Browse the repository at this point in the history
* Start addition operation and translation group as a first easy test Lie group.
* Setup zenodo and vale (only on command line for now).
* Start dummy types and the interface tests.
* fix table formatting
* a few typos

---------

Co-authored-by: Mateusz Baran <[email protected]>
  • Loading branch information
kellertuer and mateuszbaran authored Oct 23, 2024
1 parent 93d1ce7 commit c695564
Show file tree
Hide file tree
Showing 83 changed files with 3,820 additions and 461 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
runs-on: ${{ matrix.os }}
strategy:
matrix:
julia-version: ["1.6", "1.10", "~1.11.0-0"]
julia-version: ["1.6", "1.10", "1.11"]
os: [ubuntu-latest, macOS-latest]
steps:
- uses: actions/checkout@v4
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/documenter.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ jobs:
version: "1.4.551"
- uses: julia-actions/setup-julia@latest
with:
version: "1.10"
version: "1.11"
- name: Julia Cache
uses: julia-actions/cache@v2
- name: Cache Quarto
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,4 @@ temp
tutorials/*.ipynb
tutorials/*_files/*
tutorials/_freeze
.vscode/settings.json
19 changes: 19 additions & 0 deletions .vale.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
StylesPath = docs/styles
MinAlertLevel = warning
Vocab = LieGroups

MinAlertLevel = suggestion

Packages = Google, write-good

[*.md]
BasedOnStyles = Vale, Google, write-good

[NEWS.md, CONTRIBUTING.md]
BasedOnStyles = Vale, Google
Google.Will = false ; given format and really with intend a _will_
Google.Headings = false ; some might jeally ahabe [] in their headers


[*.jl]
BasedOnStyles = Vale, Google, write-good
29 changes: 24 additions & 5 deletions .zenodo.json
Original file line number Diff line number Diff line change
@@ -1,17 +1,36 @@
{

"creators": [
{
"affiliation": "University of California, San Francisco",
"name": "Axen, Seth",
"orcid": "0000-0003-3933-8247"
},
{
"affiliation": "AGH University of Science and Technology",
"name": "Baran, Mateusz",
"orcid": "0000-0001-9667-5579"
},
{
"affiliation": "NTNU Trondheim",
"name": "Bergmann, Ronny",
"orcid": "0000-0001-8342-7218"
},
{
"name": "Tu, Yueh-Hua"
},
{
"affiliation": "KTH Royal Institute of Technology",
"name": "Verdier, Olivier",
"orcid": "0000-0003-3699-6244"
}
],
"description": "LieGroups.jl provides a library of Lie groups.",
"description": "LieGroups.jl is a library of Lie groups, Lie algebras",
"keywords": [
"Riemannian manifolds",
"Lie groups",
"Julia",
"Programming"
"Lie group",
"Lie algebra",
"manifold",
"Julia"
],
"license": "MIT",
"title": "LieGroups.jl",
Expand Down
40 changes: 19 additions & 21 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1,53 +1,51 @@
# Contributing to `LieGroups.jl`

First, thanks for taking the time to contribute.
Any contribution is appreciated and welcome.
We appreciate and welcome any contribution.

The following is a set of guidelines to [`LieGroups.jl`](https://juliamanifolds.github.io/LieGroups.jl/).

#### Table of contents

- [Contributing to `LieGroups.jl`](#Contributing-to-manoptjl)
- [Contributing to `LieGroups.jl`](#Contributing-to-liegroupsjl)
- [Table of Contents](#Table-of-Contents)
- [I just have a question](#I-just-have-a-question)
- [How can I file an issue?](#How-can-I-file-an-issue)
- [How can I contribute?](#How-can-I-contribute)
- [How to just ask a question](#How-to-ask-a-question)
- [How to file an issue](#How-to-file-an-issue)
- [How to contribute](#How-to-contribute)
- [Code style](#Code-style)

## I just have a question
## How to just ask a question

The developer can most easily be reached in the Julia Slack channel [#manifolds](https://julialang.slack.com/archives/CP4QF0K5Z).
You can most easily reach the developers in the Julia Slack channel [#manifolds](https://julialang.slack.com/archives/CP4QF0K5Z).
You can apply for the Julia Slack workspace [here](https://julialang.org/slack/) if you haven't joined yet.
You can also ask your question on [discourse.julialang.org](https://discourse.julialang.org).

## How can I file an issue?
## How to file an issue

If you found a bug or want to propose a feature, please open an issue in within the [GitHub repository](https://github.com/JuliaManifolds/LieGroups.jl/issues).

## How can I contribute?
## How to contribute

Currently we are still consolidating most details and defaults, but feel free to contribute to these discussions within this repository.
Currently most details are still work-in-progress.
Feel free to contribute ideas, features you would like to see, Lie groups you want to have or would like to contribute, or any other idea for `LieGroups.jl`. For these, use either the [discussions](https://github.com/JuliaManifolds/LieGroups.jl/discussions) or [issues](https://github.com/JuliaManifolds/LieGroups.jl/issues) in the [GitHub repository](https://github.com/JuliaManifolds/LieGroups.jl)

## Code style

Try to follow the [documentation guidelines](https://docs.julialang.org/en/v1/manual/documentation/) from the Julia documentation as well as [Blue Style](https://github.com/invenia/BlueStyle).
Run [`JuliaFormatter.jl`](https://github.com/domluna/JuliaFormatter.jl) on the repository in the way set in the `.JuliaFormatter.toml` file, which enforces a number of conventions consistent with the Blue Style.
Please follow the [documentation guidelines](https://docs.julialang.org/en/v1/manual/documentation/) from the Julia documentation as well as [Blue Style](https://github.com/invenia/BlueStyle).
Run [`JuliaFormatter.jl`](https://github.com/domluna/JuliaFormatter.jl) on the repository running `using JuliaFormatter; format(".")` on the main folder of the project.

Please follow a few internal conventions:

- Any implemented function should be accompanied by its mathematical formulae if a closed form exists.
- A Lie group, a Lie group action or a Lie algebra should be implemented in it own file
- Include the mathematical formulae for any implemented function if a closed form exists.
- Define a Lie group, a Lie group action, or a Lie algebra in its own file. Include all related functions in the same file
- an alphabetical order of functions in every file is preferable.
- The preceding implies that the mutating variant of a function follows the non-mutating variant.
- usually, both the allocating and the mutating variants of a function should be documented. For avoiding duplication, one doc string attached to both is preferrable
- Document both the allocating and the mutating variants of a function. To avoid duplication, attach one doc string defined before both functions and attach it to both.
- There should be no dangling `=` signs.
- Always add a newline between things of different types (struct/method/const).
- Always add a newline between methods for different functions (including allocating/mutating variants).
- Add a newline between things of different types (struct/method/const).
- Add a newline between methods for different functions (including allocating/mutating variants).
- Prefer to have no newline between methods for the same function; when reasonable, merge the documentation strings.
- All `import`/`using`/`include` should be in the main module file.
- `import` is discouraged and the explicit full name, like `Base.exp` should be used when implementing functions

Concerning documentation

- Avoid using `import` and use the explicit full name, like `Base.exp`, when implementing functions, that extend functions of other packages.
- if possible provide both mathematical formulae and literature references using [DocumenterCitations.jl](https://juliadocs.org/DocumenterCitations.jl/stable/) and BibTeX where possible
- Always document all input variables and keyword arguments
6 changes: 2 additions & 4 deletions NEWS.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ All notable Changes to the Julia package `LieGroups.jl` will be documented in th
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [0.1.0] - unreleased
## [0.1.0] unreleased

Everything denoted by “formerly” refers to the previous name in [`Manifolds.jl`](https://juliamanifolds.github.io/Manifolds.jl/stable/).

Expand All @@ -15,7 +15,7 @@ Everything denoted by “formerly” refers to the previous name in [`Manifolds.
* `LieGroup` (formerly `GroupManifold`) as well as the concrete groups
* `AdditiveGroup` (formerly `TranslationGroup`)
* `AbstractGroupOperation` as well as its concrete subtypes
* `AdditiveGroupOperation`
* `AdditionGroupOperation` (formerly `AdditionOperation`)
* `AbstractGroupActionType` with its 2 specific (new) abstract
* `AbstractLeftGroupActionType`
* `AbstractRightGroupActionType`
Expand All @@ -24,8 +24,6 @@ Everything denoted by “formerly” refers to the previous name in [`Manifolds.
* `RightGroupOperation` (formerly `RightBackwardAction`)
* `InverseLeftGroupOperation` (formerly `RightForwardAction`)
* `InverseRightGroupOperation` (formerly `LeftBackwardAction`)
* `LieGroups.AbstractGroupOperation` as well as its concrete subtypes
* `AdditiveGroupOperation`
* `apply`and `apply!`
* `base_manifold` to access the manifold within a Lie group
* `compose` and `compose!`
Expand Down
8 changes: 7 additions & 1 deletion Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,22 @@ authors = ["Seth Axen <[email protected]>", "Mateusz Baran <mateuszbaran89@gma
version = "0.1.0"

[deps]
LinearAlgebra = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e"
Manifolds = "1cead3c2-87b3-11e9-0ccd-23c62b72b94e"
ManifoldsBase = "3362f125-f0bb-47a3-aa74-596ffd7ef2fb"

[compat]
Aqua = "0.8"
LinearAlgebra = "1.6"
Manifolds = "0.10"
ManifoldsBase = "0.15.16"
Test = "1.6"
julia = "1.6"

[extras]
Aqua = "4c88cf16-eb10-579e-8560-4a9242c79595"
Manifolds = "1cead3c2-87b3-11e9-0ccd-23c62b72b94e"
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"

[targets]
test = ["Test", "Manifolds"]
test = ["Test", "Aqua", "Manifolds"]
4 changes: 2 additions & 2 deletions Readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@

This is a package to rework the Lie group features of [`Manifolds.jl`](https://juliamanifolds.github.io/Manifolds.jl/stable/) in a unified way into a separate package.

This especially also includes a few different choices in default behabiour that
This especially also includes a few different choices in default behaviour that
is different from the [`Manifolds.jl`](https://juliamanifolds.github.io/Manifolds.jl/stable/) one. For purely manifold-based operations, any Lie group still is “build upon” a Riemannian manifold.

See [#5](https://github.com/JuliaManifolds/LieGroups.jl/issues/5) for an overview of fatures that are plannned.
See [#5](https://github.com/JuliaManifolds/LieGroups.jl/issues/5) for an overview of features that we plan to implement.
Feel free to add to this list with opening further issues.
10 changes: 8 additions & 2 deletions docs/make.jl
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ if "--quarto" ∈ ARGS
Pkg.build("IJulia") # build `IJulia` to the right version.
Pkg.activate(@__DIR__) # but return to the docs one before
run(`quarto render $(tutorials_folder)`)
return nothing
end
else # fallback to at least create empty files for Optimize and Implement
# touch(joinpath(@__DIR__, "src/tutorials/Optimize.md"))
Expand Down Expand Up @@ -117,10 +118,15 @@ makedocs(;
"Home" => "index.md",
"About" => "about.md",
(tutorials_in_menu ? [tutorials_menu] : [])...,
"An Interface for Lie Groups" => "interface.md",
"Interfaces" => [
"Lie group" => "interface/group.md",
"Lie algebra" => "interface/algebra.md",
"Group operation" => "interface/operations.md",
"Group action" => "interface/actions.md",
],
"Lie groups" => [
"List of Lie Groups" => "groups/index.md",
"Additive group" => "groups/additive.md",
"Translation group" => "groups/translation.md",
],
"Contributing to LieGroups.jl" => "contributing.md",
"Notation" => "notation.md",
Expand Down
5 changes: 4 additions & 1 deletion docs/src/about.md
Original file line number Diff line number Diff line change
@@ -1 +1,4 @@
# About LieGroups.jl
# About LieGroups.jl

`LieGroups.jl` is a “spin-off” from [`Manifolds.jl](https://juliamanifolds.github.io/Manifolds.jl/stable/), where `GroupManifolds` where implemented around 2021.
Around the same time, [Yueh-Hua Tu](https://github.com/yuehhua) started a package `LieGroups.jl`, which was continued than here with a full rewrite to use the manifolds from `Manifolds.jl`.
13 changes: 0 additions & 13 deletions docs/src/groups/additive.md

This file was deleted.

6 changes: 4 additions & 2 deletions docs/src/groups/index.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# Alphabetical List of Lie groups
# An overview of Lie groups

# Alphabetical list of Lie groups

| Group | Manifold | ```` | Comment |
|:------|:---------|:---------:|:------|
| [`AdditiveGroup`](@ref) | [`Euclidean`](@extref `Manifolds.Euclidean`) | [`+`](@ref AdditiveGroupOperation) | |
| [`TranslationGroup`](@ref) | [`Euclidean`](@extref `Manifolds.Euclidean`) | [`+`](@ref AdditionGroupOperation) | |
7 changes: 7 additions & 0 deletions docs/src/groups/translation.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# The Lie group of translations on a Euclidean space

```@docs
TranslationGroup
```

For this Lie group, all implementations are already covered by the defaults in [the generic addition operation](@ref addition-operation-sec).
105 changes: 0 additions & 105 deletions docs/src/interface.md

This file was deleted.

Loading

0 comments on commit c695564

Please sign in to comment.