Opened 13 years ago

Closed 13 years ago

#196 closed bug (fixed)

description of farey starts with factorize

Reported by: gorzel Owned by: somebody
Priority: trivial Milestone: 3-1-1
Component: doc Version: 3-1-0
Keywords: Cc:

Description

The description of farey on

Singular/3-1-0/html/sing_197.htm#SEC238

starts with factorize

	
5.1.31 farey

Syntax:
    factorize ( poly_expression )
    factorize ( poly_expression, 0 )
    factorize ( poly_expression, 2 ) 
Type:
    list of ideal and intvec
Syntax:
    farey ( bigint_expression, bigint_expression )
    farey ( ideal_expression, bigint_expression ) 
Type:
    number/ideal 
Purpose:
    lift the first argument modulo the second to the rationals 
Note:
    The current coefficient field must be the rationals. 
Example:
     	

      ring r=0,x,dp;
      farey(2,32003);
    ==> 2

An other example showing that really something is happing may be more useful.

Change History (3)

comment:1 Changed 13 years ago by hannes

Resolution: fixed
Status: newclosed

comment:2 Changed 13 years ago by gorzel

Resolution: fixed
Status: closedreopened

Now you have changed three time factorize to farey. This is likewise wrong. Just erase the first five lines, the correct description of the command is already found in the subsequent lines!

To be explicit: This

Syntax:
    factorize ( poly_expression )
    factorize ( poly_expression, 0 )
    factorize ( poly_expression, 2 ) 
Type:
    list of ideal and intvec

was changed to

Syntax:
    farey ( poly_expression )
    farey ( poly_expression, 0 )
    farey ( poly_expression, 2 ) 
Type:
    list of ideal and intvec

but these lines have to be killed!

And once again: A better example, and also one for farey ( ideal_expression, bigint_expression ) would be useful.

> farey(bigint(7),bigint(32));
3/5
> typeof(_);
number
> farey(ideal(5/3x,3/7y),32);
_[1]=-1/3x
_[2]=3y
> typeof(_);
ideal

Finally, it seems that farey also works in other non-documented cases:

> ring r=0,(x,y,z),dp;
> farey(13/4,320);   //  farey(number,bigint); 
_[1,1]=-1/3
> typeof(_);         // return type matrix should be number instead
matrix

> matrix M[2][2] = 1/3,2/5,3/7,x;
> farey(M,32);                         // farey(matrix,bigint);
_[1]=3*gen(2)+gen(1)
_[2]=x*gen(2)+2*gen(1)
> typeof(_);                           // return type module, but it should be matrix again?!
module

> farey(module(M),32);                 // farey(module,bigint);
_[1]=3*gen(2)+gen(1)
_[2]=x*gen(2)+2*gen(1)
> typeof(_);                           // return type module
module

comment:3 Changed 13 years ago by hannes

Resolution: fixed
Status: reopenedclosed

no, description fixed in the correct way

Note: See TracTickets for help on using tickets.