Re: [fricas-devel] AInterval

2025-06-23 Thread Waldek Hebisch
On Mon, Jun 23, 2025 at 08:02:50AM +0200, 'Ralf Hemmecke' via FriCAS - computer algebra system wrote: > On 6/23/25 02:00, Waldek Hebisch wrote: > > I think that instead of > > > > if R has OrderedSemiGroup then > >SemiRng > > > > > > you need > > > > if R has Order

Re: [fricas-devel] AInterval

2025-06-23 Thread 'Ralf Hemmecke' via FriCAS - computer algebra system
On 6/23/25 01:22, Waldek Hebisch wrote: ATM I did not look at conditions and categories. However, I have noticed a different issue. Namely, Interval is supposed to be an implementation of interval artithmetic. Which means that interval obtained as result of interval arithmetic is supposed to co

Re: [fricas-devel] AInterval

2025-06-23 Thread Waldek Hebisch
On Mon, Jun 23, 2025 at 08:12:06AM +0200, 'Ralf Hemmecke' via FriCAS - computer algebra system wrote: > On 6/23/25 01:22, Waldek Hebisch wrote: > > ATM I did not look at conditions and categories. However, > > I have noticed a different issue. Namely, Interval is > > supposed to be an implementa

Re: [fricas-devel] AInterval

2025-06-22 Thread 'Ralf Hemmecke' via FriCAS - computer algebra system
On 6/23/25 02:00, Waldek Hebisch wrote: I think that instead of if R has OrderedSemiGroup then SemiRng you need if R has OrderedSemiGroup and R has SemiRng then SemiRng ... That is SemiGroup and AbelianSemiGroup do not imply distributivity, so SemiRn

Re: [fricas-devel] AInterval

2025-06-22 Thread Waldek Hebisch
On Mon, Jun 23, 2025 at 12:29:20AM +0200, 'Ralf Hemmecke' via FriCAS - computer algebra system wrote: > On 6/21/25 00:02, Waldek Hebisch wrote: > > BTW, did you think about making it a bit more general? > > Also, AFAICS when you have Ring as an argument, then the result > > is valid SemiRing.

Re: [fricas-devel] AInterval

2025-06-22 Thread Waldek Hebisch
On Mon, Jun 23, 2025 at 12:29:20AM +0200, 'Ralf Hemmecke' via FriCAS - computer algebra system wrote: > On 6/21/25 00:02, Waldek Hebisch wrote: > > BTW, did you think about making it a bit more general? > > Also, AFAICS when you have Ring as an argument, then the result > > is valid SemiRing.

Re: [fricas-devel] AInterval

2025-06-22 Thread 'Ralf Hemmecke' via FriCAS - computer algebra system
On 6/21/25 00:02, Waldek Hebisch wrote: > BTW, did you think about making it a bit more general? Also, AFAICS when you have Ring as an argument, then the result is valid SemiRing. I've just tried to make AIntervalCategory more general. I hope I got the conditions and export categories corr

Re: [fricas-devel] AInterval

2025-06-21 Thread Waldek Hebisch
On Sat, Jun 21, 2025 at 01:40:15PM +0200, 'Ralf Hemmecke' via FriCAS - computer algebra system wrote: > Ooops. In OrderedRing I find > > positive? x == x>0 > negative? x == x<0 > sign x == > positive? x => 1 > negative? x => -1 > zero? x => 0 > e

Re: [fricas-devel] AInterval

2025-06-21 Thread 'Ralf Hemmecke' via FriCAS - computer algebra system
Ooops. In OrderedRing I find positive? x == x>0 negative? x == x<0 sign x == positive? x => 1 negative? x => -1 zero? x => 0 error "x satisfies neither positive?, negative? or zero?" abs x == positive? x => x negative? x =>

Re: [fricas-devel] AInterval

2025-06-21 Thread Waldek Hebisch
On Sat, Jun 21, 2025 at 01:11:12PM +0200, 'Ralf Hemmecke' via FriCAS - computer algebra system wrote: > While looking into the generalization of AInterval, I realized that abs is > defined in OrderedRing. > > https://fricas.github.io/api/OrderedRing.html#index-1 > > Technically, it would be OK t

Re: [fricas-devel] AInterval

2025-06-21 Thread 'Ralf Hemmecke' via FriCAS - computer algebra system
While looking into the generalization of AInterval, I realized that abs is defined in OrderedRing. https://fricas.github.io/api/OrderedRing.html#index-1 Technically, it would be OK to define it already in OrderedAbelianGroup. Basically the definition is abs(x) == if x>0 then x else -x so w

Re: [fricas-devel] AInterval

2025-06-20 Thread Waldek Hebisch
On Fri, Jun 20, 2025 at 10:55:32PM +0200, 'Ralf Hemmecke' via FriCAS - computer algebra system wrote: > Hi Waldek, > > I've just created a pull request factoring out some interval arithmetic that > is not necessarily bound to floating point operatioons. > > https://github.com/fricas/fricas/pull/

Re: [fricas-devel] AInterval

2025-06-20 Thread Waldek Hebisch
On Fri, Jun 20, 2025 at 10:55:32PM +0200, 'Ralf Hemmecke' via FriCAS - computer algebra system wrote: > Hi Waldek, > > I've just created a pull request factoring out some interval arithmetic that > is not necessarily bound to floating point operatioons. > > https://github.com/fricas/fricas/pull/

[fricas-devel] AInterval

2025-06-20 Thread 'Ralf Hemmecke' via FriCAS - computer algebra system
Hi Waldek, I've just created a pull request factoring out some interval arithmetic that is not necessarily bound to floating point operatioons. https://github.com/fricas/fricas/pull/200 If you accept, I will reformat to fit the FriCAS style, i.e. using foo : Type instead of foo: Type