Skip to content

Add how to obtain the unicode of the symbols in docstrings #724

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Jun 14, 2025

Conversation

lbenet
Copy link
Member

@lbenet lbenet commented Jun 6, 2025

No description provided.

@OlivierHnt
Copy link
Member

Thanks @lbenet for the PR. When one types ? ⊏ (or any other unicode symbol), Julia already informs the user on how to write it down. E.g.

help?> 
"" can be typed by \in<tab>
[.....]

During our last call, I thought that the purpose of this PR was to add to the documentation something about the submodule IntervalArithmetic.Symbols (which is almost undocumented except for https://juliaintervals.github.io/IntervalArithmetic.jl/stable/manual/construction/#More-constructors).
E.g. we should add a markdown table like

| Symbol             | Equivalent Function         | Description                                                  |
|-------------------|----------------------------|--------------------------------------------------------------|
| `..(a, b)`         | `interval(a, b; format=:infsup)` | Create interval `[a, b]` using bounds                        |
| `±(m, r)` (`\pm<tab>`)      | `interval(m, r; format=:midpoint)` | Create interval `[m - r, m + r]` using midpoint-radius form  |
| `≛(x, y)` (`\starequal<tab>`)    | `isequal_interval(x, y)`   | Check interval equality                                      |
| `⊑(x, y)` (`\sqsubseteq<tab>`) | `issubset_interval(x, y)`  | Check if `x` is a (non-strict) subset of `y`                |
| `⋤(x, y)` (`\sqsubsetneq<tab>`) | `isstrictsubset(x, y)`     | Check if `x` is a strict subset of `y`                      |
| `⪽(x, y)` (`\subsetdot<tab>) | `isinterior(x, y)`         | Check if `x` is in the interior of `y`                      |
| `(x, y)`  (`\preceq<tab>`)        | `precedes(x, y)`           | Precedes relation                         |
| `(x, y)` (`\prec<tab>`)  | `strictprecedes(x, y)`     | Strictly precedes relation                                   |
| `(x, y)` (`\sqcup<tab>`)        | `hull(x, y)`               | Interval hull of `x` and `y`                                 |
| `(x, y)` (`\sqcap<tab>`)       | `intersect_interval(x, y)` | Intersection of intervals                                    |
| ``  (`\emptyset<tab>`)         | `emptyinterval()`          | Empty interval                                           |
| ``   (`\bbR<tab>`)             | `entireinterval()`         | Entire real line                                         |

@lbenet
Copy link
Member Author

lbenet commented Jun 9, 2025

Uuups 😮 :blush... I must admit I didn't remember the trick with the UTF acceted symbols. I'll change this PR following the suggestion to add a table with the symbols.

@OlivierHnt
Copy link
Member

OlivierHnt commented Jun 13, 2025

@lbenet if you have a bit of time, it would be nice to merge this PR over the weekend, and release what should be the last pre-1.0 release of IntervalArithmetic.

@lbenet lbenet force-pushed the lb/docstring_symbols branch from 91d42b2 to 0038a69 Compare June 14, 2025 18:04
@lbenet
Copy link
Member Author

lbenet commented Jun 14, 2025

@OlivierHnt I've removed the trivial suggestions of the former commits and pushed the suggested changes., whichI inserted the docs in the manual section. I will not have time this afternoon nor tomorrow, so feel free to make any change you think is worth in this PR, so it does not slow down the release of pre-1.0.

@OlivierHnt OlivierHnt merged commit 2b92879 into master Jun 14, 2025
32 checks passed
@OlivierHnt OlivierHnt deleted the lb/docstring_symbols branch June 14, 2025 18:28
@lbenet
Copy link
Member Author

lbenet commented Jun 14, 2025

Thanks a lot!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants