Ok, this is very unimportant problem, nevertheless one could think about 
coercion principles.
 
The bad guy is ScanRoman, but the strange thing is, that in order to find a - 
for a variable x and a number 4, AXIOM/FriCAS rather looks for a routine to 
coerce the variable to a number and not - as I would expect here - to go to 
Polynomials. 

Hence, one really has to work very hard to get a polynomial over the 
RomanNumerals.


I(1) -> (x-4::ROMAN)

   (1)  VI
                                               Type: Polynomial(RomanNumeral)
(2) -> x

   (2)  x
                                                            Type: Variable(x)
(3) -> x::ROMAN

   (3)  X
                                                           Type: RomanNumeral
(4) -> a::ROMAN
 
   >> Error detected within library code:
   Improper character in Roman numeral: 
   A

(4) -> )set mess sel on
(4) -> a::ROMAN        
 
   >> Error detected within library code:
   Improper character in Roman numeral: 
   A

(4) -> d::ROMAN

   (4)  D
                                                           Type: RomanNumeral

(6) -> M::ROMAN

   (6)  M
                                                           Type: RomanNumeral
(7) -> (y-4::ROMAN)    

 Function Selection for -
      Arguments: (VARIABLE(y),ROMAN) 
   -> no appropriate - found in Variable(y) 
   -> no appropriate - found in RomanNumeral 
   -> no appropriate - found in Symbol 
   -> no appropriate - found in Polynomial(RomanNumeral) 
   -> no appropriate - found in Variable(y) 
   -> no appropriate - found in RomanNumeral 
   -> no appropriate - found in Symbol 
 
 [1]  signature:   (POLY(ROMAN),POLY(ROMAN)) -> POLY(ROMAN)
      implemented: slot $$$ from POLY(ROMAN)
 
 
   >> Error detected within library code:
   Improper character in Roman numeral: 
   Y

(7) -> x : POLY ROMAN := 'x

   (7)  X
                                               Type: Polynomial(RomanNumeral)
(8) -> (x-4::ROMAN)        

 Function Selection for -
      Arguments: (POLY(ROMAN),ROMAN) 
   -> no appropriate - found in Polynomial(RomanNumeral) 
   -> no appropriate - found in RomanNumeral 
   -> no appropriate - found in RomanNumeral 
 
 [1]  signature:   (POLY(ROMAN),POLY(ROMAN)) -> POLY(ROMAN)
      implemented: slot $$$ from POLY(ROMAN)
 

   (8)  VI
                                               Type: Polynomial(RomanNumeral)
(9) -> (x-4)       

 Function Selection for -
      Arguments: (POLY(ROMAN),PI) 
   -> no appropriate - found in Polynomial(RomanNumeral) 
   -> no appropriate - found in PositiveInteger 
   -> no appropriate - found in Integer 
   -> no appropriate - found in PositiveInteger 
   -> no appropriate - found in Integer 
 
 [1]  signature:   (POLY(ROMAN),POLY(ROMAN)) -> POLY(ROMAN)
      implemented: slot $$$ from POLY(ROMAN)
 

   (9)  VI
                                               Type: Polynomial(RomanNumeral)

(13) -> x :: Symbol :: Polynomial ROMAN

   (13)  X
                                               Type: Polynomial(RomanNumeral)


(25) -> x:=monomial(1, 
monomial(1,'x)$IndexedExponents(Symbol))$Polynomial(ROMAN)

   (25)  x
                                               Type: Polynomial(RomanNumeral)
(26) -> (x-5::ROMAN)^2                                                          
 

          2
   (26)  x  - X x + XXV
                                               Type: Polynomial(RomanNumeral)




Mit freundlichen Grüßen

Johannes Grabmeier

Prof. Dr. Johannes Grabmeier
Köckstraße 1, D-94469 Deggendorf
Tel. +49-(0)-991-2979584, Tel. +49-(0)-171-5503789
Tel. +49-(0)-991-3615-100 (d),  Fax: +49-(0)-3224-192688


-- 
You received this message because you are subscribed to the Google Groups 
"FriCAS - computer algebra system" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/fricas-devel?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to