login  home  contents  what's new  discussion  bug reports     help  links  subscribe  changes  refresh  edit

Edit detail for #411 "forbidden" type generated by trigonometric expression revision 3 of 5

1 2 3 4 5
Editor: kratt6
Time: 2008/01/21 07:18:02 GMT-8
Note:

added:

From kratt6 Mon Jan 21 07:18:01 -0800 2008
From: kratt6
Date: Mon, 21 Jan 2008 07:18:01 -0800
Subject: 
Message-ID: <20080121071801-0800@axiom-wiki.newsynthesis.org>


Hm, actually, I'm not quite sure.  Usually, domain constructions containing "redundancy", like FRAC FRAC INT or EXPR POLY INT should be avoided, especially in the interpreter. (In SPAD code, they are sometimes unavoidable)  Curiously, the interpreter does not reject EXPR FRAC INT, nor EXPR FRAC COMPLEX INT.  On the other hand, EXPR COMPLEX FRAC INT is actually different from EXPR COMPLEX INT.

In any case, it seems quite difficult to work with objects of type EXPR COMPLEX FRAC INT.  For example, you cannot convert them to EXPR COMPLEX FLOAT...

Submitted by : kratt6 at: 2008-01-05T13:11:33-08:00 (16 years ago)
Name :
Axiom Version :
Category : Severity : Status :
Optional subject :  
Optional comment :

The following challenge posted by Vladimir yields EXPR COMPLEX FRAC INT as result type. I think it should be EXPR COMPLEX INT. Declaring the variable helps.

axiom
ex1 := cot(1/2*(3/8*%pi*2^(1/2)-1/2*2^(1/2)*atan(3/5)-1/4*2^(1/2)*atan(27+73/4*2^(1/2))-1/4*2^(1/2)*atan(42/41+12/41*2^(1/2))+1/4*2^(1/2)*atan(144/103+148/103*2^(1/2))-1/4*%i*2^(1/2)*atanh(-51945/813577+28/2440731*((714295812*(833932+86508*93^(1/2))^(1/3)-4881462*(833932+86508*93^(1/2))^(2/3)+3963747144)/(833932+86508*93^(1/2))^(1/3))^(1/2)+28/2440731*6^(1/2)*((238098604*(833932+86508*93^(1/2))^(1/3)*((714295812*(833932+86508*93^(1/2))^(1/3)-4881462*(833932+86508*93^(1/2))^(2/3)+3963747144)/(833932+86508*93^(1/2))^(1/3))^(1/2)+813577*((714295812*(833932+86508*93^(1/2))^(1/3)-4881462*(833932+86508*93^(1/2))^(2/3)+3963747144)/(833932+86508*93^(1/2))^(1/3))^(1/2)*(833932+86508*93^(1/2))^(2/3)-660624524*((714295812*(833932+86508*93^(1/2))^(1/3)-4881462*(833932+86508*93^(1/2))^(2/3)+3963747144)/(833932+86508*93^(1/2))^(1/3))^(1/2)+4852325397096*(833932+86508*93^(1/2))^(1/3))/(833932+86508*93^(1/2))^(1/3)/((714295812*(833932+86508*93^(1/2))^(1/3)-4881462*(833932+86508*93^(1/2))^(2/3)+3963747144)/(833932+86508*93^(1/2))^(1/3))^(1/2))^(1/2))+1/8*%i*2^(1/2)*log(18/7)+1/8*log(81*(69/97+2/97*2^(1/2))^(%i*2^(1/2))*((26+7*%i-(10+4*%i)*2^(1/2))*(1/3+1/18*6^(1/2)*((62*(1052+108*93^(1/2))^(1/3)+(1052+108*93^(1/2))^(2/3)+28)/(1052+108*93^(1/2))^(1/3))^(1/2)+1/18*((744*(1052+108*93^(1/2))^(1/3)*((62*(1052+108*93^(1/2))^(1/3)+(1052+108*93^(1/2))^(2/3)+28)/(1052+108*93^(1/2))^(1/3))^(1/2)-6*((62*(1052+108*93^(1/2))^(1/3)+(1052+108*93^(1/2))^(2/3)+28)/(1052+108*93^(1/2))^(1/3))^(1/2)*(1052+108*93^(1/2))^(2/3)-168*((62*(1052+108*93^(1/2))^(1/3)+(1052+108*93^(1/2))^(2/3)+28)/(1052+108*93^(1/2))^(1/3))^(1/2)+2376*6^(1/2)*(1052+108*93^(1/2))^(1/3))/(1052+108*93^(1/2))^(1/3)/((62*(1052+108*93^(1/2))^(1/3)+(1052+108*93^(1/2))^(2/3)+28)/(1052+108*93^(1/2))^(1/3))^(1/2))^(1/2))/(3+2^(1/2)))^(2*%i*2^(1/2))/((2+3*%i-2*%i*2^(1/2))^(4*%i*2^(1/2))))-acoth(2))*2^(1/2));
Type: Expression Complex Fraction Integer

Re: forbidden --Bill Page, Sun, 06 Jan 2008 04:58:35 -0800 reply
Why do you say EXPR COMPLEX FRAC INT is "forbidden"?

Hm, actually, I'm not quite sure. Usually, domain constructions containing "redundancy", like FRAC FRAC INT or EXPR POLY INT should be avoided, especially in the interpreter. (In SPAD code, they are sometimes unavoidable) Curiously, the interpreter does not reject EXPR FRAC INT, nor EXPR FRAC COMPLEX INT. On the other hand, EXPR COMPLEX FRAC INT is actually different from EXPR COMPLEX INT.

In any case, it seems quite difficult to work with objects of type EXPR COMPLEX FRAC INT. For example, you cannot convert them to EXPR COMPLEX FLOAT...