[sage-devel] Error building pdf documentation

2015-05-21 Thread Joao Alberto de Faria
Hello everyone, 
I've been trying to build the pdf documentation for ticket 17282, 
however I keep getting the same failures:

[schemes  ] None:None: WARNING: citation not found: Fulton
[schemes  ] /home/joao/sage-dev/src/doc/en/reference/schemes/index.rst:: 
WARNING: unusable reference target found: ../genindex.html
[schemes  ] /home/joao/sage-dev/src/doc/en/reference/schemes/index.rst:: 
WARNING: unusable reference target found: ../py-modindex.html
[schemes  ] /home/joao/sage-dev/src/doc/en/reference/schemes/index.rst:: 
WARNING: unusable reference target found: ../search.html
[schemes  ] writing... done
[schemes  ] copying TeX support files...
[schemes  ] done
[schemes  ] build succeeded, 4 warnings.
env /dev/null pool_size=400 save_size=5 extra_mem_top=200 
pdflatex  'schemes.tex'
env: pdflatex: No such file or directory
make: *** [schemes.pdf] Error 127
Error building the documentation.
Traceback (most recent call last):
  File /home/joao/sage-dev/src/doc/common/builder.py, line 1626, in 
module
getattr(get_builder(name), type)()
  File /home/joao/sage-dev/src/doc/common/builder.py, line 229, in pdf
raise RuntimeError(failed to run $MAKE all-pdf in %s%tex_dir)
RuntimeError: failed to run $MAKE all-pdf in 
/home/joao/sage-dev/src/doc/output/latex/en/reference/schemes

I was hoping someone with more information on how the pdf docs build could 
help shed some light onto this for me.
-Thank you all in advance

-- 
You received this message because you are subscribed to the Google Groups 
sage-devel group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-devel] Error building pdf documentation

2015-05-21 Thread Joao Alberto de Faria
thank you! that solved my issue!

On Thursday, May 21, 2015 at 6:34:59 PM UTC-4, Justin C. Walker wrote:


 On May 21, 2015, at 15:06 , Joao Alberto de Faria wrote: 

  Hello everyone, 
 I've been trying to build the pdf documentation for ticket 17282, 
  however I keep getting the same failures: 
  
  [schemes  ] None:None: WARNING: citation not found: Fulton 
  [schemes  ] /home/joao/sage-dev/src/doc/en/reference/schemes/index.rst:: 
  WARNING: unusable reference target found: ../genindex.html 
  [schemes  ] /home/joao/sage-dev/src/doc/en/reference/schemes/index.rst:: 
  WARNING: unusable reference target found: ../py-modindex.html 
  [schemes  ] /home/joao/sage-dev/src/doc/en/reference/schemes/index.rst:: 
  WARNING: unusable reference target found: ../search.html 
  [schemes  ] writing... done 
  [schemes  ] copying TeX support files... 
  [schemes  ] done 
  [schemes  ] build succeeded, 4 warnings. 
  env /dev/null pool_size=400 save_size=5 extra_mem_top=200 
  pdflatex  'schemes.tex' 

 From this error: 
  env: pdflatex: No such file or directory 

 I assume that you either do not have TeX installed, or that it is not 
 accessible in the usual places (i.e., in any of the directories listed in 
 your PATH enivronment variable). 

 If my assumption is wrong, or my explanation not helpful, please reply. 

 HTH 

 -- 
 Justin C. Walker, Curmudgeon at Large 
 Institute for the Absorption of Federal Funds 
 --- 
 While creating wives, God promised men 
 that good and obedient wives would be 
 found in all corners of the world. 
 Then He made the earth round. 
 -- 










-- 
You received this message because you are subscribed to the Google Groups 
sage-devel group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


[sage-devel] Factoring p-adic polynomials

2015-04-28 Thread Joao Alberto de Faria
What is the difficulty in factoring polynomials with multiple roots over 
the p-adic ring? 

[[[ R.x=Qp(5)[]
f=x^2
g=gcd(f,f.derivative())
(f/g).factor() ]]]

returns the following error:

sage.rings.padics.precision_error.PrecisionError: p-adic factorization
not well-defined since the discriminant is zero up to the requestion
p-adic precision


this works fine over the rationals:


[[[ R.x=QQ[]
f=x^2
g=gcd(f,f.derivative())
(f/g).factor() ]]]

I'm not well versed in p-adics, is this impossible or just not implemented?

-- 
You received this message because you are subscribed to the Google Groups 
sage-devel group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


[sage-devel] Re: Factoring p-adic polynomials

2015-04-28 Thread Joao Alberto de Faria
The problem is that this issue also occurs for 
 R.x=Qp(5)[]
f=x^2
f.factor(), I was trying to fiddle with it and accidently copied the wrong 
code

On Tuesday, April 28, 2015 at 1:38:49 PM UTC-4, Nils Bruin wrote:

 On Tuesday, April 28, 2015 at 10:28:06 AM UTC-7, Joao Alberto de Faria 
 wrote:

 What is the difficulty in factoring polynomials with multiple roots over 
 the p-adic ring? 

 [[[ R.x=Qp(5)[]
 f=x^2
 g=gcd(f,f.derivative())
 (f/g).factor() ]]]

 returns the following error:

 sage.rings.padics.precision_error.PrecisionError: p-adic factorization
 not well-defined since the discriminant is zero up to the requestion
 p-adic precision


 You didn't do what you think you did there:

 sage: f/g
 ((1 + O(5^20))*x^2)/((1 + O(5^20))*x)

 It looks like sage is being conservative here in taking out apparent 
 common factors. Calling factor on that will probably attempt to factor 
 numerator and denominator separately. You'd really want to do a long 
 division here:

 sage: f // g
 (1 + O(5^20))*x
 sage: (f//g).factor()
 (1 + O(5^20))*x + (O(5^20))

 Checking the remainder:

 sage: f % g
 (O(5^20))*x^2

 so it's indeed indistinguishable from 0.


-- 
You received this message because you are subscribed to the Google Groups 
sage-devel group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


[sage-devel] Code fails on SECOND attempt only... please help!

2014-10-15 Thread Joao Alberto de Faria
In the midst reviewing ticket 16986, my reviewer came up with the following 
example that fails:

R.z=PolynomialRing(QQ)
K.w=NumberField(z^3+2)
R.t=PolynomialRing(K)
L.v=K.extension(t^2+t+1)
P.x,y=ProjectiveSpace(L,1)
H=End(P)
f=H([x^3-2*y^3,v*y^3])
f.rational_preimages(P([0,1]))

However, when I run it on my machine, I get it to run with no problems, 
returning 

[(-w*v : 1), (-w : 1), (w*v + w : 1)]

BUT, when I run it a second time, making no changes, I get the following error:
Traceback (click to the left of this block for traceback)
...
TypeError: unable to convert 1/2*w^2*v to a rational

After restarting my notebook, I receive the first answer, and upon running it a 
second time, I get the second error.
I've tried running on other copies of Sage, and the same thing happens, it will 
work the first time, but fail the second time.

On further investigation, using the .dumps function, it seems that f is 
changing every time we compile. However, it seems that it only ever changes the 
very
first time. What I mean to say by that is that when I dump f after running it 
the first time it will be different than when I dump f after running it a 
second time.
From the second time on, dumping f will always return the same string. 

This is weird, what is the underlying mechanics causing this, and how can we 
trace it more explicitly. 




-- 
You received this message because you are subscribed to the Google Groups 
sage-devel group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


[sage-devel] Defining Polynomial Rings with same variable name

2014-09-29 Thread Joao Alberto de Faria
While reviewing some code, I realized that the following is currently 
allowed:
P.x,x,x,x,x,x = PolynomialRing(QQ,6)
P

Multivariate Polynomial Ring in x, x, x, x, x, x over Rational Field

I believe that an object should not be allowed to have repeat instances of the 
same variable names. I don't get any actual wrong answers, but I feel as if it 
should be addressed.

After looking around, I have found two separate instances in the code base for 
_assign_names, in category_object.pyx and parent_gens.pyx, both in 
sage/structure. I think that the code should check for duplicates at this 
point. However this seems too high up in the sage hierarchy for me to want to 
mess around with it in good conscious.

Is there any reason the code currently operates as is? Or do people agree that 
this needs to be fixed?

-- 
You received this message because you are subscribed to the Google Groups 
sage-devel group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


[sage-devel] Groebner Basis over Function Fields

2014-09-24 Thread Joao Alberto de Faria
When trying to run the following code:


R.t = FunctionField(QQ)
S.x, y = PolynomialRing(R,2)
I = S.ideal([x^2 - y^2, y-t])
I.groebner_basis()

I receive the following error:
AttributeError: 'str' object has no attribute 'parent' 

After testing the code again with the 'toy:buchberger2 GB algorithm, I 
found that it was able to do it. Looking into the code it fails when 
passing into singular and isn't currently handled by the current error 
exceptions. To me, it seems that all that needs to be done is to add an 
AttributeError to the except list in the multi_polynomial_ideal  grobner 
basis definiton. However, I have very little knowledge as to how Function 
Fields are implemented, so I was just wondering if this would be a reliable 
fix. If not, I was wondering if anyone could help shed some light on what 
can be done regarding this issue.

-- 
You received this message because you are subscribed to the Google Groups 
sage-devel group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


[sage-devel] Groebner Basis over Function Fields

2014-09-24 Thread Joao Alberto de Faria
When running the following code, 

R.t=FunctionField(QQ)
S.x,y = PolynomialRing(R,2)
I=S.ideal([x^2-y^2,y-t])
I.groebner_basis()

i am getting the following error: 

AttributeError: 'str' object has no attribute 'parent'

After checking other grobner basis algorithms, it seems to work using the toy 
algorithm. My first inclination is to go into multi_polynomial_ideal and 
add Attribute Error to its list of excepts, however I do not know enough about 
Function Field implementation to do this with sound mind. Would this fix be 
sufficient, or is this a deeper issue?

-- 
You received this message because you are subscribed to the Google Groups 
sage-devel group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


[sage-devel] Re: Groebner Basis over Function Fields

2014-09-24 Thread Joao Alberto de Faria
I've looked over the code, and it seems fine to me, however I am not that 
versed in function fields. I believe that the best person to review 
something like this would be someone who understands the function field 
functionality better than I do. I am more than willing to officially review 
it though.

On Wednesday, September 24, 2014 8:45:28 AM UTC-4, Simon King wrote:

 Hi all, 

 On 2014-09-24, Simon King simon...@uni-jena.de javascript: wrote: 
  No. I rather think the _element_constructor_ method of function fields 
  should be able to deal with input that is a string. 
  
  I will open a trac ticket for it. 

 ... which is #17033 and needs review. 

 Best regards, 
 Simon 



-- 
You received this message because you are subscribed to the Google Groups 
sage-devel group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.