Re: [sage-support] Errors building Sage 10.3 in Sonoma 14.3.1

2024-03-27 Thread John H Palmieri
I'm having the same problem (I think) with Sage 10.4.beta0 on two different 
Apple Silicon machines.

On Wednesday, March 27, 2024 at 9:58:10 AM UTC-7 Dima Pasechnik wrote:

> I've cut out the interesting part of the log.
> It's a linker error (IMHO the linking should be done with C++, not
> with C compiler, but that's probably OK on macOS).
> Related to GiNaC (not a surprise)
>
> Anyway, I haven't seen this sort of errors before. Something for Apple 
> fans...
>
>
> On Wed, Mar 27, 2024 at 3:54 PM Jon Higa  
> wrote:
> >
> > Switched to this, continuing in the same directory:
> >
> > git clean -xdf
> > source .homebrew-build-env
> > make configure
> > ./configure --prefix=/usr/local/sage/10.3 --enable-database_odlyzko_zeta 
> --disable-editable 
> --with-python=/opt/homebrew/opt/pyt...@3.11/bin/python3.11
> > make
> >
> > New logs attached.
> >
> > Thanks.
> >
> > On Wednesday, March 27, 2024 at 6:24:37 AM UTC-4 Dima Pasechnik wrote:
> >
> > sagemath doesn't officially support Python 3.12.
> > Can you try with 3.11 instead?
> >
> >
> >
> > --
> > You received this message because you are subscribed to the Google 
> Groups "sage-support" group.
> > To unsubscribe from this group and stop receiving emails from it, send 
> an email to sage-support...@googlegroups.com.
> > To view this discussion on the web visit 
> https://groups.google.com/d/msgid/sage-support/9bfc9093-a640-4c75-9b62-0fd21ab3474en%40googlegroups.com
> .
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/2682d574-73c4-4ff7-8c5b-477563f61cf5n%40googlegroups.com.


Re: [sage-support] Re: sage 10.3.b2 build problem on OSX 12.7.1

2023-12-16 Thread John H Palmieri
Another quick solution (cherry-picked from the PR I mentioned) would be to 
change the first line of build/pkgs/editables/dependencies from 

 | $(PYTHON_TOOLCHAIN) $(PYTHON)

to 

 | flit_core $(PYTHON)


On Saturday, December 16, 2023 at 6:45:44 AM UTC-8 Heiko Knospe wrote:

> Hi, 
>
> same build problem with flit_core for sage 10.3.b2 on Debian 11:
>
> [editables-0.5] Thread model: posix
>
> [editables-0.5] Supported LTO compression algorithms: zlib zstd
>
> [editables-0.5] gcc version 10.2.1 20210110 (Debian 10.2.1-6) 
>
> [editables-0.5] 
>
> [editables-0.5] Package 'editables' is currently not installed
>
> [editables-0.5] No legacy uninstaller found for 'editables'; nothing to do
>
> [editables-0.5] Installing editables-0.5
>
> [editables-0.5] Looking in links: 
> /home/xxx/sage/local/var/lib/sage/venv-python3.9/var/lib/sage/wheels
>
> [editables-0.5] Processing 
> /home/xxx/sage/local/var/lib/sage/venv-python3.9/var/tmp/sage/build/editables-0.5/src
>
> [editables-0.5]   Installing build dependencies: started
>
> [editables-0.5]   Running command pip subprocess to install build 
> dependencies
>
> [editables-0.5]   Looking in links: 
> /home/xxx/sage/local/var/lib/sage/venv-python3.9/var/lib/sage/wheels
>
> [editables-0.5]   ERROR: Could not find a version that satisfies the 
> requirement flit_core>=3.3 (from versions: none)
>
> [editables-0.5]   ERROR: No matching distribution found for flit_core>=3.3
>
> [editables-0.5]   error: subprocess-exited-with-error
>
> [editables-0.5]   
>
> [editables-0.5]   × pip subprocess to install build dependencies did not 
> run successfully.
>
> [editables-0.5]   │ exit code: 1
>
> [editables-0.5]   ╰─> See above for output.
>
> My (quick and dirty) workaround was to copy 
> flit_core-3.9.0-py3-none-any.whl 
> <https://www.piwheels.org/simple/flit-core/flit_core-3.9.0-py3-none-any.whl#sha256=e5b2a84881cf1f40eb5b0115e1d3a429765e0f43743b79e871352bb8e0c95952>
>  from https://www.piwheels.org/project/flit-core/ to 
> local/var/lib/sage/venv-python3.9/var/lib/sage/wheels. Then compiling sage 
> works and flit_core-3.9.0 is installed.
>
> - Heiko
>
> David Joyner schrieb am Samstag, 16. Dezember 2023 um 12:40:00 UTC+1:
>
>> On Fri, Dec 15, 2023 at 3:04 PM John H Palmieri  
>> wrote:
>>
>>> In sage-release, Matthias pointed to missing dependencies for editables, 
>>> fixed in https://github.com/sagemath/sage/pull/36885. Maybe you can 
>>> just do "make flit_core" (to build the missing dependency) and then "make".
>>>
>>
>> That works, thanks!!
>>
>> BTW, on startup I got this:
>>
>> ./sage
>>
>> ┌┐
>>
>> │ SageMath version 10.3.beta2, Release Date: 2023-12-13  │
>>
>> │ Using Python 3.11.1. Type "help()" for help.   │
>>
>> └┘
>>
>> ┏┓
>>
>> ┃ Warning: this is a prerelease version, and it may be unstable. ┃
>>
>> ┗┛
>>
>> /Users/davidjoyner/sagefiles/sage-10.3.beta2/local/var/lib/sage/venv-python3.11.1/lib/python3.11/site-packages/prompt_toolkit/application/application.py:988:
>>  
>> DeprecationWarning: There is no current event loop
>>   loop = asyncio.get_event_loop()
>>
>> Seems to be working fine though.
>>
>> Thanks again, John.
>>  
>>
>>>
>>>
>>> On Friday, December 15, 2023 at 10:52:10 AM UTC-8 David Joyner wrote:
>>>
>>>> Hi:
>>>>
>>>> I tried to compile sage and got this:
>>>>
>>>> The following package(s) may have failed to build (not necessarily
>>>>
>>>> during this run of 'make all-start'):
>>>>
>>>>
>>>> * package: editables-0.5
>>>>
>>>>   last build time: Dec 15 10:48
>>>>
>>>>   log file:
>>>> /Users/davidjoyner/sagefiles/sage-10.3.beta2/logs/pkgs/editables-0.5.log
>>>>
>>>>
>>>> The corresponding log is attached.
>>>>
>>>>
>>>> Does anyone have any suggestions on how to fix this?
>>>>
>>>> - David
>>>>
>>>>
>>>> -- 
>>> You received this message because you are subscribed 

[sage-support] Re: sage 10.3.b2 build problem on OSX 12.7.1

2023-12-15 Thread John H Palmieri
In sage-release, Matthias pointed to missing dependencies for editables, 
fixed in https://github.com/sagemath/sage/pull/36885. Maybe you can just do 
"make flit_core" (to build the missing dependency) and then "make".


On Friday, December 15, 2023 at 10:52:10 AM UTC-8 David Joyner wrote:

> Hi:
>
> I tried to compile sage and got this:
>
> The following package(s) may have failed to build (not necessarily
>
> during this run of 'make all-start'):
>
>
> * package: editables-0.5
>
>   last build time: Dec 15 10:48
>
>   log file:
> /Users/davidjoyner/sagefiles/sage-10.3.beta2/logs/pkgs/editables-0.5.log
>
>
> The corresponding log is attached.
>
>
> Does anyone have any suggestions on how to fix this?
>
> - David
>
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/ce30cd4c-f431-4eb8-ac35-f4ab5e941e49n%40googlegroups.com.


[sage-support] Re: Problems viewing crystals from sage

2023-12-12 Thread John H Palmieri
Please add comments to that ticket.

On Tuesday, December 12, 2023 at 6:15:31 PM UTC-8 Andrew wrote:

> Thanks John. 
>
> Yes, I think you are right because this PR is about exactly this issue 
> and, more importantly, it adds the code that I want to brutalise. I missed 
> this when used git blame to look for recent changes to sage.misc.latex. 
> This fits as view() was working without issues for me a month or so ago and 
> this was only merged at the end of October.
>
> Since https://github.com/sagemath/sage/pull/36529 is already merged is it 
> too late to add a comment on the ticket?
>
> Andrew
>
>
> On Wednesday 13 December 2023 at 12:30:03 pm UTC+11 John H Palmieri wrote:
>
>> Could this be related to https://github.com/sagemath/sage/pull/36529?
>>
>>
>> On Tuesday, December 12, 2023 at 3:50:55 PM UTC-8 Andrew wrote:
>>
>>> Playing around with this a little more, I think that this is a 
>>> bug/timing issue in sage.misc.latex.py (or in subprocess.run, or a mac 
>>> oddity since it only started happening recently). 
>>>
>>> What seems to be happening is that the generated PDF file, output_file, 
>>> is being deleted before the viewer is able to open it. Specifically, if I 
>>> add time.sleep(2) before the tmp.cleanup  then the viewer opens as expected.
>>>
>>> def run_viewer():
>>> run([viewer, output_file], capture_output=True)
>>> time.sleep(1)## adding this, together with import time, 
>>> fixes the problem
>>> tmp.cleanup()
>>>
>>> (This around line 1957 of latex.py.) Certainly this explains my 
>>> experience of the command working sometimes and failing at other times. On 
>>> the other hand, it is a little strange because subprocess.run is supposed 
>>> to wait for the process to finish. A shorter example that exhibits the 
>>> problem, at least on the two macs that I have available, is
>>>
>>> sage: view(crystals.LSPaths( 
>>> RootSystem(['A',4]).weight_space().basis()[1] ) )
>>>
>>> If people agree that this is a bug then I am happy to post a fix.
>>>
>>> Andrew
>>>
>>>
>>> On Monday 11 December 2023 at 4:35:59 pm UTC+11 Andrew wrote:
>>>
>>>> I am trying to view crystal graphs from inside sage, and I am going a 
>>>> little nuts. Sometimes view(...) works as I expect but most of the time it 
>>>> doesn't, and I see the error message:
>>>>
>>>> The document “sage.pdf” could not be opened. The file doesn’t exist.
>>>>
>>>> (my emphasis). I compiled sage from source and I am running:
>>>>
>>>> SageMath version 10.3.beta1
>>>> Release Date: 2023-12-10 
>>>> Using Python 3.11.6.
>>>>
>>>> on a 2022 macbook pro (M1 max), running Sonoma 14.1.2. I installed 
>>>> dot2tex using:
>>>> sage -i dot2tex, which 
>>>> which installed without errors. Running
>>>> sage: from sage.graphs.graph_latex import check_tkz_graph
>>>> sage: check_tkz_graph() 
>>>> does not report any problems with my set up.
>>>>
>>>> I get the error message above using the the sage commands:
>>>>
>>>> sage: L=RootSystem(['A',4]).weight_space().basis()
>>>> sage: G=crystals.LSPaths(['A',4], L[1])
>>>> sage: G
>>>> The crystal of LS paths of type ['A', 4] and weight Lambda[2]
>>>> sage: view(G)
>>>>
>>>> I get the same error if I try the examples from the "Classical 
>>>> crystals" thematic tutorial, 
>>>> <https://doc.sagemath.org/html/en/thematic_tutorials/lie/crystals.html#installing-dot2tex>
>>>>  
>>>> such as:
>>>>
>>>> sage: B = crystals.Tableaux(['A',2], shape=[2,1])
>>>> sage: view(B, tightpage=True) 
>>>>
>>>> When it does work, a nice tikz generated pdf file pops up. Am I missing 
>>>> some steps? Can anyone tell me what I am doing wrong?
>>>>
>>>> Andrew
>>>>
>>>>
>>>>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/7227e438-d87f-4ec7-8511-8be2413a68d1n%40googlegroups.com.


[sage-support] Re: Problems viewing crystals from sage

2023-12-12 Thread John H Palmieri
Could this be related to https://github.com/sagemath/sage/pull/36529?


On Tuesday, December 12, 2023 at 3:50:55 PM UTC-8 Andrew wrote:

> Playing around with this a little more, I think that this is a bug/timing 
> issue in sage.misc.latex.py (or in subprocess.run, or a mac oddity since 
> it only started happening recently). 
>
> What seems to be happening is that the generated PDF file, output_file, is 
> being deleted before the viewer is able to open it. Specifically, if I add 
> time.sleep(2) before the tmp.cleanup  then the viewer opens as expected.
>
> def run_viewer():
> run([viewer, output_file], capture_output=True)
> time.sleep(1)## adding this, together with import time, fixes 
> the problem
> tmp.cleanup()
>
> (This around line 1957 of latex.py.) Certainly this explains my experience 
> of the command working sometimes and failing at other times. On the other 
> hand, it is a little strange because subprocess.run is supposed to wait for 
> the process to finish. A shorter example that exhibits the problem, at 
> least on the two macs that I have available, is
>
> sage: view(crystals.LSPaths( 
> RootSystem(['A',4]).weight_space().basis()[1] ) )
>
> If people agree that this is a bug then I am happy to post a fix.
>
> Andrew
>
>
> On Monday 11 December 2023 at 4:35:59 pm UTC+11 Andrew wrote:
>
>> I am trying to view crystal graphs from inside sage, and I am going a 
>> little nuts. Sometimes view(...) works as I expect but most of the time it 
>> doesn't, and I see the error message:
>>
>> The document “sage.pdf” could not be opened. The file doesn’t exist.
>>
>> (my emphasis). I compiled sage from source and I am running:
>>
>> SageMath version 10.3.beta1
>> Release Date: 2023-12-10 
>> Using Python 3.11.6.
>>
>> on a 2022 macbook pro (M1 max), running Sonoma 14.1.2. I installed 
>> dot2tex using:
>> sage -i dot2tex, which 
>> which installed without errors. Running
>> sage: from sage.graphs.graph_latex import check_tkz_graph
>> sage: check_tkz_graph() 
>> does not report any problems with my set up.
>>
>> I get the error message above using the the sage commands:
>>
>> sage: L=RootSystem(['A',4]).weight_space().basis()
>> sage: G=crystals.LSPaths(['A',4], L[1])
>> sage: G
>> The crystal of LS paths of type ['A', 4] and weight Lambda[2]
>> sage: view(G)
>>
>> I get the same error if I try the examples from the "Classical crystals" 
>> thematic tutorial, 
>> 
>>  
>> such as:
>>
>> sage: B = crystals.Tableaux(['A',2], shape=[2,1])
>> sage: view(B, tightpage=True) 
>>
>> When it does work, a nice tikz generated pdf file pops up. Am I missing 
>> some steps? Can anyone tell me what I am doing wrong?
>>
>> Andrew
>>
>>
>>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/c47fda1e-16dc-4a87-a17b-dc5393aca1afn%40googlegroups.com.


[sage-support] Re: Integral result differ from Wolfram|Alpha

2023-11-13 Thread John H Palmieri
Isn't log(log(x)^2) = 2 * log(log(x))? Is this your concern, or is it the 
absolute value?

On Monday, November 13, 2023 at 1:32:11 PM UTC-8 Bùi Gia Nghĩa wrote:

> Hi!
> I have used Sage Cell Server to integrate the function (ln(x)^2 - 1) / (x 
> * ln(x)). It should resulted in (ln(x)^2) / 2 - |ln(ln(x))| + C, as noted 
> by my textbook and Wolfram|Alpha, but instead resulted in 1/2*log(x)^2 - 
> 1/2*log(log(x)^2). 
> (I do notice that SageMath use log(a) to denote natural logarithm, so 
> that's not the question here).
> Anyone knows why it happen? I think that this is a bug from some system 
> SageMath use to calculate this, but I am new to SageMath so have zero 
> knowledge about the system.
> Here is the exact code I input:
> var("x")
> f = (log(x)**2 - 1) / (x * log(x))
> integral(f, x)
>
> Thanks in advance!
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/cdc2eaeb-3201-46e3-a37e-c90e747756c1n%40googlegroups.com.


Re: [sage-support] Computing the kernel of a map between polynomial algebras

2023-10-30 Thread John H Palmieri
Thanks, Dima. That works for me, too, and it's much faster than Sage was. 
Now I'm trying some bigger examples...


On Monday, October 30, 2023 at 3:56:00 PM UTC-7 Dima Pasechnik wrote:

> Hi John,
> I tried running msolve on your input (more precisely, converting it
> into the problem of
> finding the Grobner basis w.r.t. to the elimination order, as I
> explained), and I see that
> it's an injective map.
>
> Computation takes about 3 minutes on an old laptop.
> Specifically, I merely run msolve at the command line, on the attached
> input file x2,
> and output file y2
> as follows. Here -v 2 is verbosity level, -t 4 means 4 threads, -e 10
> means eliminate
> the 1st 10 variables.
> (I renamed the variables in (almost) alphabetical order, as I thought
> msolve cannot
> handle variable names like you have, but, no it wasn't actually necessary)
>
> As far as I can see, the outputted basis does not have elements which only
> have the varibles in the domain of your map (in x2 they are p, q, r,
> s, t, u, v),
> meaning that the map has no nontrivial kernel.
>
> $ msolve -f x2 -o y2 -v 2 -g 2 -t 4 -e 10
>
> On Mon, Oct 30, 2023 at 9:02 PM Dima Pasechnik  wrote:
> >
> >
> >
> > On Mon, 30 Oct 2023, 20:50 Dima Pasechnik,  wrote:
> >>
> >>
> >>
> >> On Mon, 30 Oct 2023, 20:25 John H Palmieri,  
> wrote:
> >>>
> >>>
> >>>
> >>> On Monday, October 30, 2023 at 12:28:18 PM UTC-7 Dima Pasechnik wrote:
> >>>
> >>> On Mon, Oct 30, 2023 at 5:04 PM John H Palmieri  
> wrote:
> >>> >
> >>> > Are endomorphisms better to work with? I might be able to extend my 
> map to an endomorphism of the larger ring, if that would make the 
> computation easier. Probably just send xi1 -> xi1, xi2 -> xi2, etc.
> >>>
> >>> these are "already there", as if phi is an endomorphism then ker(phi)
> >>> is generated by a-phi(a) - so
> >>> whenever phi(a)=a this reduces to 0.
> >>>
> >>>
> >>>
> >>> I don't understand this. Define phi: k[x,y,z] -> k[x,y,z] by
> >>>
> >>> x -> y
> >>> y -> z
> >>> z -> 0
> >>>
> >>> Then x - phi(x) = x - y is not in the kernel. What do you mean by 
> "ker(phi) is generated by a-phi(a)"?
> >>
> >>
> >> OK, sorry, we're getting confused.
> >> You are interested in checking whether phi, like this:
> >> phi: k[x,y,z] -> k[x',y',z']
> >> x->y', y->z', z->0
> >>
> >> is an epimorphism. This is the same as saying that the kernel of phi, 
> which is the intersection of the ideal
> >> (x-y', y-z', z) in k[x,y,z,x',y',z'] with k[x,y,z], is trivial, i.e., 
> zero. (in this case it's not trivial, it contains z).
> >>
> >> So yes, one can think of phi as inducing an endomorphism of 
> k[x,y,z,x',y',z'], of a special kind.
> >> How this relates to endomorphisms of k[x,y,z], I don't know.
> >
> >
> > if phi had a fixed point, like x->cx with c in k^*,
> > then one could be a bit more economic, and do not introduce x' (and the 
> corresponding ideal generator x-cx'), but immediately substitute it with 
> x/c.
> >
> >
> >>
> >>
> >>>
> >>>
> >>>
> >>> >
> >>> > On Monday, October 30, 2023 at 7:14:16 AM UTC-7 Dima Pasechnik wrote:
> >>> >>
> >>> >> On Mon, Oct 30, 2023 at 12:54 PM Kwankyu  wrote:
> >>> >> >
> >>> >> > Isn't this what you want?
> >>> >> >
> >>> >> > sage: R. = QQ[]
> >>> >> > sage: phi = R.hom([x,x])
> >>> >> > sage: phi
> >>> >> > Ring endomorphism of Multivariate Polynomial Ring in x, y over 
> Rational Field
> >>> >> > Defn: x |--> x
> >>> >> > y |--> x
> >>> >> > sage: phi.kernel()
> >>> >> > Ideal (x - y) of Multivariate Polynomial Ring in x, y over 
> Rational Field
> >>> >>
> >>> >> that's the kernel of the endomorphism phi of R.
> >>> >> John's question is a bit different, and it will require
> >>> >> finding the intersection of such an ideal with the domain of his 
> map.
> >>> >> His R=F_2[h20,...,h50,xi1,...,xi5] and phi induces an endomorphism 
> of
> >>> >> R with the kernel .
> >>> >> Then phi

Re: [sage-support] Computing the kernel of a map between polynomial algebras

2023-10-30 Thread John H Palmieri


On Monday, October 30, 2023 at 12:28:18 PM UTC-7 Dima Pasechnik wrote:

On Mon, Oct 30, 2023 at 5:04 PM John H Palmieri  
wrote: 
> 
> Are endomorphisms better to work with? I might be able to extend my map 
to an endomorphism of the larger ring, if that would make the computation 
easier. Probably just send xi1 -> xi1, xi2 -> xi2, etc. 

these are "already there", as if phi is an endomorphism then ker(phi) 
is generated by a-phi(a) - so 
whenever phi(a)=a this reduces to 0. 



I don't understand this. Define phi: k[x,y,z] -> k[x,y,z] by

x -> y
y -> z
z -> 0

Then x - phi(x) = x - y  is not in the kernel. What do you mean by 
"ker(phi) is generated by a-phi(a)"?



> 
> On Monday, October 30, 2023 at 7:14:16 AM UTC-7 Dima Pasechnik wrote: 
>> 
>> On Mon, Oct 30, 2023 at 12:54 PM Kwankyu  wrote: 
>> > 
>> > Isn't this what you want? 
>> > 
>> > sage: R. = QQ[] 
>> > sage: phi = R.hom([x,x]) 
>> > sage: phi 
>> > Ring endomorphism of Multivariate Polynomial Ring in x, y over 
Rational Field 
>> > Defn: x |--> x 
>> > y |--> x 
>> > sage: phi.kernel() 
>> > Ideal (x - y) of Multivariate Polynomial Ring in x, y over Rational 
Field 
>> 
>> that's the kernel of the endomorphism phi of R. 
>> John's question is a bit different, and it will require 
>> finding the intersection of such an ideal with the domain of his map. 
>> His R=F_2[h20,...,h50,xi1,...,xi5] and phi induces an endomorphism of 
>> R with the kernel . 
>> Then phi is injective iff the intersection of this ideal with 
>> F_2[h20,...,h50]={0}. 
>> And this needs a Grobner basis computation. 
>> 
>> By the way, using 
>> h30 |--> h20*xi1^4 + h21*xi1 + h30 
>> h31 |--> h21*xi1^8 + h31 
>> 
>> one can split the problem into cases 
>> 1) xi1=0 
>> 2) h21=h20=0 
>> (but perhaps it's only specific to this particular example) 
>> 
>> > 
>> > On Monday, October 30, 2023 at 6:08:16 PM UTC+9 Dima Pasechnik wrote: 
>> >> 
>> >> 
>> >> 
>> >> On Mon, 30 Oct 2023, 05:57 John H Palmieri,  
wrote: 
>> >>> 
>> >>> Does anyone have any tips for how to compute the kernel of a map 
between polynomial algebras, or for checking whether the map is injective? 
I have families of such maps involving algebras with many generators. I'm 
working over GF(2), if that matters. In one example I defined the map phi: 
R -> S where R has 12 generators, S has 19 generators, and did 
>> >>> 
>> >>> sage: phi.is_injective() 
>> >>> 
>> >>> After about 30 hours, Sage quit on me, perhaps running out of memory 
("Killed: 9"). An example of the sort of map I'm interested in: 
>> >>> 
>> >>> sage: phi 
>> >>> Ring morphism: 
>> >>> From: Multivariate Polynomial Ring in h20, h21, h30, h31, h40, h41, 
h50 over Finite Field of size 2 
>> >>> To: Multivariate Polynomial Ring in h20, h21, h30, h31, h40, h41, 
h50, xi1, xi2, xi3, xi4, xi5 over Finite Field of size 2 
>> >>> Defn: h20 |--> h20 
>> >>> h21 |--> h21 
>> >>> h30 |--> h20*xi1^4 + h21*xi1 + h30 
>> >>> h31 |--> h21*xi1^8 + h31 
>> >>> h40 |--> h21*xi1^9 + h30*xi1^8 + h20*xi2^4 + h31*xi1 
>> >>> h41 |--> h31*xi1^16 + h21*xi2^8 
>> >>> h50 |--> h31*xi1^17 + h21*xi1*xi2^8 + h30*xi2^8 + h20*xi3^4 
>> >>> 
>> >>> Any suggestions? 
>> >> 
>> >> 
>> >> The standard way to find the kernel of a map 
>> >> phi: A->B is to take the 
>> >> ring R generated by the gens of A and B and compute the Gröbner basis 
of the ideal I generated by {a-phi(a)|a in gens(A)}, and then 
>> >> take the intersection of I with A. 
>> >> (for the latter you have to take R with an appropriate order) 
>> >> 
>> >> The Gröbner basis would be done by Singular. 
>> >> Better Gröbner basis routines are available in the msolve spkg. 
>> >> 
>> >> I'd try using msolve. There are also options such as computing I 
w.r.t. to an "easier" order and then chaniging the order (so-called Gröbner 
walk), they might work better here (it's all more of art than science here) 
>> >> 
>> >> 
>> >> 
>> >> HTH 
>> >> Dima 
>> >> 
>> >>> 
>> >>> -- 
>> >>> John 
>> >>> 
>> >>> 
>> >>> -- 
>&g

Re: [sage-support] Computing the kernel of a map between polynomial algebras

2023-10-30 Thread John H Palmieri
Are endomorphisms better to work with? I might be able to extend my map to 
an endomorphism of the larger ring, if that would make the computation 
easier. Probably just send xi1 -> xi1, xi2 -> xi2, etc.

On Monday, October 30, 2023 at 7:14:16 AM UTC-7 Dima Pasechnik wrote:

> On Mon, Oct 30, 2023 at 12:54 PM Kwankyu  wrote:
> >
> > Isn't this what you want?
> >
> > sage: R. = QQ[]
> > sage: phi = R.hom([x,x])
> > sage: phi
> > Ring endomorphism of Multivariate Polynomial Ring in x, y over Rational 
> Field
> > Defn: x |--> x
> > y |--> x
> > sage: phi.kernel()
> > Ideal (x - y) of Multivariate Polynomial Ring in x, y over Rational Field
>
> that's the kernel of the endomorphism phi of R.
> John's question is a bit different, and it will require
> finding the intersection of such an ideal with the domain of his map.
> His R=F_2[h20,...,h50,xi1,...,xi5] and phi induces an endomorphism of
> R with the kernel .
> Then phi is injective iff the intersection of this ideal with
> F_2[h20,...,h50]={0}.
> And this needs a Grobner basis computation.
>
> By the way, using
> h30 |--> h20*xi1^4 + h21*xi1 + h30
> h31 |--> h21*xi1^8 + h31
>
> one can split the problem into cases
> 1) xi1=0
> 2) h21=h20=0
> (but perhaps it's only specific to this particular example)
>
> >
> > On Monday, October 30, 2023 at 6:08:16 PM UTC+9 Dima Pasechnik wrote:
> >>
> >>
> >>
> >> On Mon, 30 Oct 2023, 05:57 John H Palmieri,  
> wrote:
> >>>
> >>> Does anyone have any tips for how to compute the kernel of a map 
> between polynomial algebras, or for checking whether the map is injective? 
> I have families of such maps involving algebras with many generators. I'm 
> working over GF(2), if that matters. In one example I defined the map phi: 
> R -> S where R has 12 generators, S has 19 generators, and did
> >>>
> >>> sage: phi.is_injective()
> >>>
> >>> After about 30 hours, Sage quit on me, perhaps running out of memory 
> ("Killed: 9"). An example of the sort of map I'm interested in:
> >>>
> >>> sage: phi
> >>> Ring morphism:
> >>> From: Multivariate Polynomial Ring in h20, h21, h30, h31, h40, h41, 
> h50 over Finite Field of size 2
> >>> To: Multivariate Polynomial Ring in h20, h21, h30, h31, h40, h41, h50, 
> xi1, xi2, xi3, xi4, xi5 over Finite Field of size 2
> >>> Defn: h20 |--> h20
> >>> h21 |--> h21
> >>> h30 |--> h20*xi1^4 + h21*xi1 + h30
> >>> h31 |--> h21*xi1^8 + h31
> >>> h40 |--> h21*xi1^9 + h30*xi1^8 + h20*xi2^4 + h31*xi1
> >>> h41 |--> h31*xi1^16 + h21*xi2^8
> >>> h50 |--> h31*xi1^17 + h21*xi1*xi2^8 + h30*xi2^8 + h20*xi3^4
> >>>
> >>> Any suggestions?
> >>
> >>
> >> The standard way to find the kernel of a map
> >> phi: A->B is to take the
> >> ring R generated by the gens of A and B and compute the Gröbner basis 
> of the ideal I generated by {a-phi(a)|a in gens(A)}, and then
> >> take the intersection of I with A.
> >> (for the latter you have to take R with an appropriate order)
> >>
> >> The Gröbner basis would be done by Singular.
> >> Better Gröbner basis routines are available in the msolve spkg.
> >>
> >> I'd try using msolve. There are also options such as computing I w.r.t. 
> to an "easier" order and then chaniging the order (so-called Gröbner walk), 
> they might work better here (it's all more of art than science here)
> >>
> >>
> >>
> >> HTH
> >> Dima
> >>
> >>>
> >>> --
> >>> John
> >>>
> >>>
> >>> --
> >>> You received this message because you are subscribed to the Google 
> Groups "sage-support" group.
> >>> To unsubscribe from this group and stop receiving emails from it, send 
> an email to sage-support...@googlegroups.com.
> >>> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/sage-support/97318b8e-f4c9-4af3-a8ff-b901a4f2c971n%40googlegroups.com
> .
> >
> > --
> > You received this message because you are subscribed to the Google 
> Groups "sage-support" group.
> > To unsubscribe from this group and stop receiving emails from it, send 
> an email to sage-support...@googlegroups.com.
> > To view this discussion on the web visit 
> https://groups.google.com/d/msgid/sage-support/487bf189-fce6-4b6b-9752-178602ff9808n%40googlegroups.com
> .
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/0ddf54b3-1778-4fca-932c-bb5521963db2n%40googlegroups.com.


Re: [sage-support] Computing the kernel of a map between polynomial algebras

2023-10-30 Thread John H Palmieri
So Sage doesn't already use Gröbner bases when computing kernels of such 
maps? Okay, I'll try that.

Now that I've looked at the code a little bit, I see that 
`phi.is_injective()` just calls `phi.kernel()` and checks whether it's 
zero. I was hoping that there was something more clever: if I want to know 
whether something is injective, I only care whether the kernel is zero, not 
precisely what the kernel is. 

By the way, this struck me as odd:

sage: phi
Ring morphism:
  From: Multivariate Polynomial Ring in h20, h21, h30, h31, h40, h41 over 
Finite Field of size 2
  To:   Multivariate Polynomial Ring in h20, h21, h30, h31, xi1, xi2, xi3, 
xi4 over Finite Field of size 2
  Defn: h20 |--> h20
h21 |--> h21
h30 |--> h20*xi1^4 + h21*xi1 + h30
h31 |--> h21*xi1^8 + h31
h40 |--> h21*xi1^9 + h30*xi1^8 + h20*xi2^4 + h31*xi1
h41 |--> h31*xi1^16 + h21*xi2^8
sage: %time phi.is_injective()
CPU times: user 7.32 s, sys: 58.7 ms, total: 7.38 s
Wall time: 7.44 s
True

Note that phi doesn't do anything very interesting with h20 and h21: it 
sends each of those to itself. If I remove them from the domain (I need to 
keep them in the codomain because they're involved in other terms), the 
computation is slower:

sage: phi
Ring morphism:
  From: Multivariate Polynomial Ring in h30, h31, h40, h41 over Finite 
Field of size 2
  To:   Multivariate Polynomial Ring in h20, h21, h30, h31, xi1, xi2, xi3, 
xi4 over Finite Field of size 2
  Defn: h30 |--> h20*xi1^4 + h21*xi1 + h30
h31 |--> h21*xi1^8 + h31
h40 |--> h21*xi1^9 + h30*xi1^8 + h20*xi2^4 + h31*xi1
h41 |--> h31*xi1^16 + h21*xi2^8
sage: %time phi.is_injective()
CPU times: user 15.7 s, sys: 101 ms, total: 15.8 s
Wall time: 15.9 s
True

I've seen this on two different machines: roughly double the time to do the 
second computation.

On Monday, October 30, 2023 at 7:14:16 AM UTC-7 Dima Pasechnik wrote:

> On Mon, Oct 30, 2023 at 12:54 PM Kwankyu  wrote:
> >
> > Isn't this what you want?
> >
> > sage: R. = QQ[]
> > sage: phi = R.hom([x,x])
> > sage: phi
> > Ring endomorphism of Multivariate Polynomial Ring in x, y over Rational 
> Field
> > Defn: x |--> x
> > y |--> x
> > sage: phi.kernel()
> > Ideal (x - y) of Multivariate Polynomial Ring in x, y over Rational Field
>
> that's the kernel of the endomorphism phi of R.
> John's question is a bit different, and it will require
> finding the intersection of such an ideal with the domain of his map.
> His R=F_2[h20,...,h50,xi1,...,xi5] and phi induces an endomorphism of
> R with the kernel .
> Then phi is injective iff the intersection of this ideal with
> F_2[h20,...,h50]={0}.
> And this needs a Grobner basis computation.
>
> By the way, using
> h30 |--> h20*xi1^4 + h21*xi1 + h30
> h31 |--> h21*xi1^8 + h31
>
> one can split the problem into cases
> 1) xi1=0
> 2) h21=h20=0
> (but perhaps it's only specific to this particular example)
>
> >
> > On Monday, October 30, 2023 at 6:08:16 PM UTC+9 Dima Pasechnik wrote:
> >>
> >>
> >>
> >> On Mon, 30 Oct 2023, 05:57 John H Palmieri,  
> wrote:
> >>>
> >>> Does anyone have any tips for how to compute the kernel of a map 
> between polynomial algebras, or for checking whether the map is injective? 
> I have families of such maps involving algebras with many generators. I'm 
> working over GF(2), if that matters. In one example I defined the map phi: 
> R -> S where R has 12 generators, S has 19 generators, and did
> >>>
> >>> sage: phi.is_injective()
> >>>
> >>> After about 30 hours, Sage quit on me, perhaps running out of memory 
> ("Killed: 9"). An example of the sort of map I'm interested in:
> >>>
> >>> sage: phi
> >>> Ring morphism:
> >>> From: Multivariate Polynomial Ring in h20, h21, h30, h31, h40, h41, 
> h50 over Finite Field of size 2
> >>> To: Multivariate Polynomial Ring in h20, h21, h30, h31, h40, h41, h50, 
> xi1, xi2, xi3, xi4, xi5 over Finite Field of size 2
> >>> Defn: h20 |--> h20
> >>> h21 |--> h21
> >>> h30 |--> h20*xi1^4 + h21*xi1 + h30
> >>> h31 |--> h21*xi1^8 + h31
> >>> h40 |--> h21*xi1^9 + h30*xi1^8 + h20*xi2^4 + h31*xi1
> >>> h41 |--> h31*xi1^16 + h21*xi2^8
> >>> h50 |--> h31*xi1^17 + h21*xi1*xi2^8 + h30*xi2^8 + h20*xi3^4
> >>>
> >>> Any suggestions?
> >>
> >>
> >> The standard way to find the kernel of a map
> >> phi: A->B is to take the
> >> ring R generated by the gens of A and B and compute the Gröbner basis 
> of the ideal I generat

[sage-support] Computing the kernel of a map between polynomial algebras

2023-10-29 Thread John H Palmieri
Does anyone have any tips for how to compute the kernel of a map between 
polynomial algebras, or for checking whether the map is injective? I have 
families of such maps involving algebras with many generators. I'm working 
over GF(2), if that matters. In one example I defined the map phi: R -> S 
where R has 12 generators, S has 19 generators, and did

sage: phi.is_injective()

After about 30 hours, Sage quit on me, perhaps running out of memory 
("Killed: 9"). An example of the sort of map I'm interested in:

sage: phi
Ring morphism:
  From: Multivariate Polynomial Ring in h20, h21, h30, h31, h40, h41, h50 
over Finite Field of size 2
  To:   Multivariate Polynomial Ring in h20, h21, h30, h31, h40, h41, h50, 
xi1, xi2, xi3, xi4, xi5 over Finite Field of size 2
  Defn: h20 |--> h20
h21 |--> h21
h30 |--> h20*xi1^4 + h21*xi1 + h30
h31 |--> h21*xi1^8 + h31
h40 |--> h21*xi1^9 + h30*xi1^8 + h20*xi2^4 + h31*xi1
h41 |--> h31*xi1^16 + h21*xi2^8
h50 |--> h31*xi1^17 + h21*xi1*xi2^8 + h30*xi2^8 + h20*xi3^4

Any suggestions?

-- 
John


-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/97318b8e-f4c9-4af3-a8ff-b901a4f2c971n%40googlegroups.com.


Re: [sage-support] Re: Canonical divisor help

2023-10-28 Thread John H Palmieri
Nils, thanks to you, too, for your responses.

On Saturday, October 28, 2023 at 11:16:39 AM UTC-7 Nils Bruin wrote:

> On Saturday, 28 October 2023 at 05:39:26 UTC-7 Kwankyu wrote:
>
> I looked the Magma code in ask.sagemath. There's no problem in computing a 
> canonical divisor for the curve (through the attached function field). 
> Computing a basis of the Riemann-Roch space is no problem as well. Actually 
> the hard part is to construct the morphism from C to P2 from the basis. 
> Magma does this seamlessly. But Sage lacks this functionality (perhaps 
> because I did not implement it). I think, the gist of the matter is to 
> convert an element of the function field to a rational function of the 
> coordinate ring of P2.
>
>
> That's actually trivially simple: if [f1,f2,f3] is the basis of your 
> Riemann-Roch space, you just consider the map defined by [f1:f2:f3]. So you 
> lift f1,f2,f3 to rational functions on the affine space that contains your 
> curve: you just take the rational function representation and forget the 
> algebraic relations between the variables. You now have rational functions 
> in a rational function field, so you can clear denominators there. Now you 
> have a rational map (described by polynomials) A^2->P^r under which the 
> rational image of your curve C in A^2 is the corresponding projective 
> image. Computing that image is the usual groebner-basis operation for 
> finding images of rational maps, so that's potentially quite expensive.
>
> In practice, you know something about the denominators of the 
> representations of f1,f2,f3, so you can probably do a little better.
>
> At its core, that is what the magma code does too, although perhaps it has 
> some smart tricks here and there to try and keep degrees in check a bit.
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/9449eaa0-6470-4cd2-91a5-6780f1faab86n%40googlegroups.com.


Re: [sage-support] Re: Canonical divisor help

2023-10-28 Thread John H Palmieri
Thanks for all of your posts, Kwankyu. Helpful and informative.

  John


On Saturday, October 28, 2023 at 6:19:48 AM UTC-7 Kwankyu wrote:

> To answer John's question:
>
> sage: P2. = ProjectiveSpace(QQ, 2)
> sage: f = 2*x^5 - 4*x^3*y*z + x^2*y*z^2 + 2*x*y^3*z + 2*x*y^2*z^2+ y^5
> sage: C = P2.curve(f)
> sage: F = C.function_field()
> sage: z, = F.gens()
> sage: K = z.differential().divisor()  # canonical divisor
> sage: (-K).dimension()
> 3
> sage: f1, f2, f3 = (-K).basis_function_space()
> sage: phi = C.hom(P2, [f1,f2,f3]). <--- does not work
> sage: phi.image()  # will work
>
> On Saturday, October 28, 2023 at 9:59:58 PM UTC+9 Kwankyu wrote:
>
>> Let me mention also the related PR 
>>
>> https://github.com/sagemath/sage/pull/35467
>>
>> which implements Jacobian groups of curves (again via function field), 
>> referencing Nils' old code. The PR is long sleeping in draft state. If 
>> anyone finds it useful, I may wake it up. 
>>
>> On Saturday, October 28, 2023 at 9:39:26 PM UTC+9 Kwankyu wrote:
>>
>>> Hi,
>>>
>>> I replied to Dima's comment in 
>>> https://github.com/sagemath/sage/commit/977ace651af9b99689f7b6507f91f8b4e2588ae9#r131138149
>>> . 
>>>
>>> Note that the "divisor" method of a curve had existed long before I 
>>> added function field machinery and attached function fields to curves. 
>>> Hence actually there are two systems of "divisors" of curves in Sage. 
>>>
>>> The old system was implemented by William Stein, David Kohel, and Volker 
>>> Braun. In the old system, a divisor is a formal sum of rational points with 
>>> multiplicities. It is mainly implemented in 
>>> `src/sage/schemes/generic/divisor.py`. Overall it is very rudimentary. Dima 
>>> and John is attempting to use this system.
>>>
>>> The new system was implemented by me. Here a divisor is a formal sum of 
>>> places of a function field with multiplicities. This system is available 
>>> via the function field attached to a curve. This is much more powerful than 
>>> the old system. You can compute the Riemann-Roch space of a divisor. Nils 
>>> is using this system.
>>>
>>> I never attempted to combine the two systems, being afraid of breaking 
>>> the old system (or just being lazy :-) There are similarly two systems in 
>>> Magma too. But in Magma, the two systems are integrated tightly and 
>>> seamlessly. I did some integration in Sage too but far from complete 
>>> compared with Magma.
>>>
>>> I looked the Magma code in ask.sagemath. There's no problem in computing 
>>> a canonical divisor for the curve (through the attached function field). 
>>> Computing a basis of the Riemann-Roch space is no problem as well. Actually 
>>> the hard part is to construct the morphism from C to P2 from the basis. 
>>> Magma does this seamlessly. But Sage lacks this functionality (perhaps 
>>> because I did not implement it). I think, the gist of the matter is to 
>>> convert an element of the function field to a rational function of the 
>>> coordinate ring of P2. I have no idea how to do this now... Once you 
>>> construct the morphism, Sage can also compute the image of the morphism 
>>> (perhaps I implemented this). Hence unfortunately the Magma code cannot be 
>>> line by line converted to Sage code at present.
>>>
>>> On Saturday, October 28, 2023 at 8:27:07 AM UTC+9 Dima Pasechnik wrote:
>>>
>>>> On Sat, Oct 28, 2023 at 1:02 AM John H Palmieri  
>>>> wrote: 
>>>>
>>>> > Yes, I noticed that, too. It also fails to provide any information 
>>>> about what ``v`` should be (beyond saying that it should be a "valid 
>>>> object"): there is no INPUT block. 
>>>>
>>>> I've left a comment here: 
>>>>
>>>> https://github.com/sagemath/sage/commit/977ace651af9b99689f7b6507f91f8b4e2588ae9#r131117132
>>>>  
>>>>
>>>> fortunately, the author, @kwankyu is active 
>>>>
>>>> I can't locate the ticket, but it was merged in 9.0.beta9 
>>>>
>>>>
>>>> > 
>>>> > 
>>>> > On Friday, October 27, 2023 at 3:51:10 PM UTC-7 Dima Pasechnik wrote: 
>>>> >> 
>>>> >> By the way, the docstring of divisor() misses an example, it's 
>>>> >> 
>>>> >> def divisor(self, v, base_ring=None, check=True, reduce=True): 
>>>>

Re: [sage-support] Re: Canonical divisor help

2023-10-27 Thread John H Palmieri
Hi Dima,

Yes, I noticed that, too. It also fails to provide any information about 
what ``v`` should be (beyond saying that it should be a "valid object"): 
there is no INPUT block.


On Friday, October 27, 2023 at 3:51:10 PM UTC-7 Dima Pasechnik wrote:

> By the way, the docstring of divisor() misses an example, it's
>
> def divisor(self, v, base_ring=None, check=True, reduce=True):
> r"""
> Return the divisor specified by ``v``.
>
> .. WARNING::
>
> The coefficients of the divisor must be in the base ring
> and the terms must be reduced. If you set ``check=False``
> and/or ``reduce=False`` it is your responsibility to pass
> a valid object ``v``.
>
> EXAMPLES::
>
> sage: x,y,z = PolynomialRing(QQ, 3, names='x,y,z').gens()
> sage: C = Curve(y^2*z - x^3 - 17*x*z^2 + y*z^2)
>
> """
>
> Is there an issue for this?
>
> On Sat, Oct 28, 2023 at 12:42 AM Nils Bruin  wrote:
> >
> > A canonical divisor is the divisor of any differential on C so the 
> following does the trick:
> >
> > sage: kC=C.function_field()
> > sage: kC(kC.base_field().gen(0)).differential().divisor()
> >
> > It doesn't look like we quite have computation of Riemann-Roch spaces 
> natively in sage yet, so finding effective representatives requires a 
> little more work. In the RiemannSurface code this is done using singular's 
> adjoint ideal code (or by Baker's theorem in cases where it applies). For 
> this curve the canonical class is of degree -2, so there are no effective 
> representatives in this case.
> >
> > On Friday, 27 October 2023 at 15:14:00 UTC-7 John H Palmieri wrote:
> >>
> >> If anyone here knows anything about canonical divisors and their 
> implementation in Sage, please see 
> https://ask.sagemath.org/question/74034/converting-algebraic-geometry-magmas-code-to-sage/.
>  
> The setup:
> >>
> >> sage: P2. = ProjectiveSpace(QQ, 2)
> >> sage: f = 2*x^5 - 4*x^3*y*z + x^2*y*z^2 + 2*x*y^3*z + 2*x*y^2*z^2+ y^5
> >> sage: C = P2.curve(f)
> >>
> >> How do you get the canonical divisor for C?
> >>
> >> (I encourage you to post answers directly to ask.sagemath.org, if 
> you're willing.)
> >>
> >> --
> >> John
> >>
> > --
> > You received this message because you are subscribed to the Google 
> Groups "sage-support" group.
> > To unsubscribe from this group and stop receiving emails from it, send 
> an email to sage-support...@googlegroups.com.
> > To view this discussion on the web visit 
> https://groups.google.com/d/msgid/sage-support/91b14570-b83e-4dbf-8bca-0a2eff538a50n%40googlegroups.com
> .
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/391d8ee7-0329-4a15-bc88-4b84973389abn%40googlegroups.com.


[sage-support] Canonical divisor help

2023-10-27 Thread John H Palmieri
If anyone here knows anything about canonical divisors and their 
implementation in Sage, please see 
https://ask.sagemath.org/question/74034/converting-algebraic-geometry-magmas-code-to-sage/.
 
The setup:

sage: P2. = ProjectiveSpace(QQ, 2)
sage: f = 2*x^5 - 4*x^3*y*z + x^2*y*z^2 + 2*x*y^3*z + 2*x*y^2*z^2+ y^5
sage: C = P2.curve(f)

How do you get the canonical divisor for C?

(I encourage you to post answers directly to ask.sagemath.org, if you're 
willing.)

-- 
John

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/47f02ff1-8125-4328-a2db-0db270e8eed8n%40googlegroups.com.


[sage-support] Re: How to define module multiplication?

2023-09-20 Thread John H Palmieri
Very good, thank you. The "_acted_upon_" method was what I was missing.

  John

On Wednesday, September 20, 2023 at 2:11:52 AM UTC-7 Kwankyu wrote:

> sage.rings.function_field.differential defines the space of differentials 
> of a function field, which is a left module over the function field. You 
> may consult the code there.
>
> On Wednesday, September 20, 2023 at 6:08:15 PM UTC+9 Kwankyu wrote:
>
>> Is you element in the cohomology ring an instance of ModuleElement?
>>
>> On Wednesday, September 20, 2023 at 8:34:05 AM UTC+9 John H Palmieri 
>> wrote:
>>
>>> The mod 2 cohomology of a simplicial complex has the structure of a 
>>> module over the mod 2 Steenrod algebra. I would like to be able to do this 
>>> in Sage:
>>>
>>> sage: x  = (some element in a cohomology ring)
>>> sage: a = (some element of SteenrodAlgebra(2))
>>> sage: a * x
>>>
>>> I have tried telling Sage that instances of CohomologyRing should be 
>>> left modules over the Steenrod algebra (using the category framework) and 
>>> then defining _mul_, _rmul_, _lmul_. I have had no luck: I just get
>>>
>>> TypeError: unsupported operand parent(s) for *: 'mod 2 Steenrod 
>>> algebra, milnor basis' and 'Cohomology ring of RP^6 over Finite Field of 
>>> size 2'
>>>
>>> What should I be doing instead?
>>>
>>> -- 
>>> John
>>>
>>>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/d1dbb8e1-f42c-408f-a466-836571debbc9n%40googlegroups.com.


[sage-support] How to define module multiplication?

2023-09-19 Thread John H Palmieri
The mod 2 cohomology of a simplicial complex has the structure of a module 
over the mod 2 Steenrod algebra. I would like to be able to do this in Sage:

sage: x  = (some element in a cohomology ring)
sage: a = (some element of SteenrodAlgebra(2))
sage: a * x

I have tried telling Sage that instances of CohomologyRing should be left 
modules over the Steenrod algebra (using the category framework) and then 
defining _mul_, _rmul_, _lmul_. I have had no luck: I just get

TypeError: unsupported operand parent(s) for *: 'mod 2 Steenrod 
algebra, milnor basis' and 'Cohomology ring of RP^6 over Finite Field of 
size 2'

What should I be doing instead?

-- 
John

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/8e7da4f8-3c33-4e64-a872-76a163725be5n%40googlegroups.com.


Re: [sage-support] what am I missing?

2023-04-13 Thread John H Palmieri
This looks like the issue reported at 
https://github.com/sagemath/sage/issues/34233.

-- 
John


On Thursday, April 13, 2023 at 2:13:44 PM UTC-7 Fernando Gouvea wrote:

> That seems right. Plotting x^6/(1-x)^7 shows the error, but x^5/(1-x)^6 
> does not. And
>
> .9^6/.1^7 = 5.314411e6
>
> .9^5/.1^6 = 590490.1
>
> So it seems that there should be a 1e6 label that is somehow not appearing.
>
> Fernando
> On 4/13/2023 4:33 PM, William Stein wrote:
>
> I tried "plot(g(x),(0.8,0.9))" and it says "1e10" in the upper left of the 
> plot, suggesting it is labeling the y axis with the labels divided by 1e10, 
> and maybe somehow that 1e10 gets cut off in your example. See below.  The 
> default plotting in Sage got implemented as follows: In 2006 I said to Alex 
> Clemesha (who had just got his undergrad degree), "implement 2d plotting 
> for Sage that has the same API and look as mathematica, but translated to 
> be pythonic", and he did that.  So whatever is happening here with the 
> labels changing, might be just copying what "Mathematica in 2006" did...
>
> [image: image.png]
>
> On Thu, Apr 13, 2023 at 1:22 PM Fernando Gouvea  wrote:
>
>> I get the same results in 9.2 and 9.6.
>>
>> Fernando
>> On 4/13/2023 4:17 PM, William Stein wrote:
>>
>> Hi,
>>
>> I think I randomly ran into this same thing with sage-9.8 this week too.  
>> My guess is that there is some sort of overflow bug in the computation of 
>> the y-axis labels.  It's probably one of the most severe bugs in sage ever, 
>> since it is so likely to be randomly misleading...
>>
>> On Thu, Apr 13, 2023 at 1:15 PM Fernando Gouvea  
>> wrote:
>>
>>> I must be missing something here...
>>>
>>> sage: g(x)=x^10/(1-x)^11
>>> sage: plot(g(x),(0,0.9))
>>>
>>> sage: g(0.7)
>>> 15945.8104850773 <(810)%20485-0773>
>>>
>>> What's wrong?
>>>
>>> Fernando
>>>
>>> -- 
>>> =
>>> Fernando Q. Gouvea http://www.colby.edu/~fqgouvea
>>> Carter Professor of Mathematics
>>> Dept. of Mathematics
>>> Colby College  
>>> 5836 Mayflower Hill
>>> Waterville, ME 04901   
>>>
>>> Further Pronunciation Advice
>>>
>>> That math whiz Euler (Leonhard)
>>> Had a great mind, but a peon heart.
>>> His life was spare and frugal,
>>> His sex life strictly conjugal.
>>>
>>>   -- John Derbyshire
>>>
>>>
>>> -- 
>>> You received this message because you are subscribed to the Google 
>>> Groups "sage-support" group.
>>> To unsubscribe from this group and stop receiving emails from it, send 
>>> an email to sage-support...@googlegroups.com.
>>> To view this discussion on the web visit 
>>> https://groups.google.com/d/msgid/sage-support/57352ea7-2214-50af-9944-1eed986c9442%40colby.edu
>>>  
>>> 
>>> .
>>>
>>
>>
>> -- 
>> William (http://wstein.org)
>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "sage-support" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to sage-support...@googlegroups.com.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/sage-support/CACLE5GAxv0ZTFs6_NHpwV5BQL6%3Diw%3DRZz3dGER1i3R_nLZF9Bw%40mail.gmail.com
>>  
>> 
>> .
>>
>> -- 
>> =
>> Fernando Q. Gouvea http://www.colby.edu/~fqgouvea
>> Carter Professor of Mathematics
>> Dept. of Mathematics
>> Colby College  
>> 5836 Mayflower Hill
>> Waterville, ME 04901   
>>
>> Flagrant breaches of good breeding, like singing in the streets
>> or any other gross misconduct, are easily apparent and do not
>> call especially for admonition and instruction.
>>   -- Cicero, De Oficiis
>>
>>
>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "sage-support" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to sage-support...@googlegroups.com.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/sage-support/27cf8e83-3d66-ad8f-2030-74753af22650%40colby.edu
>>  
>> 
>> .
>>
>
>
> -- 
> William (http://wstein.org)
> -- 
> You received this message because you are subscribed to the Google Groups 
> "sage-support" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to sage-support...@googlegroups.com.
>
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/sage-support/CACLE5GBx%3DCupGqqPJkDTDfv3KZ3aKsQ5gWE46aeE-ETezrLRuQ%40mail.gmail.com
>  
> 

Re: [sage-support] Testing forked branches

2023-04-08 Thread John H Palmieri
I have found the instructions at 
https://github.com/sagemath/trac-to-github/blob/master/docs/Migration-Trac-to-Github.md
 
useful for me, as someone used to the old trac interface.


On Saturday, April 8, 2023 at 1:23:06 PM UTC-7 G. M.-S. wrote:

>
> Thanks Dima and Drew.
>
> I had the very same question, but zero ways for doing it, so I did not 
> dare ask…
>
> Guillermo
>
> On Sat, 8 Apr 2023 at 22:14, Dima Pasechnik  wrote:
>
>>
>> On Sat, 8 Apr 2023, 20:24 Drew Shotwell,  wrote:
>>
>>> I'm looking into working on an issue in git, and I'm wondering how to 
>>> properly go about testing someone else's branch. Let's take for instance 
>>> https://github.com/sagemath/sage/pull/35414. 
>>
>>
>> suppose you have remote foo set to
>> https://github.com/sagemath/sage 
>> 
>>
>> then
>>
>> git fetch foo pull/35414 
>> /head:pr35414
>>
>> will create the branch named pr35414 you want
>>
>>
>> Essentially what I want to do is get the code changes from the forked 
>>> branch videlec:complex-root-of-to-algebraic into my repository so I can 
>>> test them in parallel with the develop branch. My own research has opened 
>>> an overwhelming number of different ways for doing this, so I figured I'd 
>>> ask here to get the most straight forward answer. Thank you.
>>
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/04a58ebe-6365-4439-904a-2f8827dd2a47n%40googlegroups.com.


[sage-support] Re: Error building 9.8 on Ubuntu 23.04

2023-04-07 Thread John H Palmieri
Some recent versions of Singular don't seem to work with Sage. You could 
try "make distclean" (to start over) and "./configure 
--with-system-singular=no" to force Sage to build its own Singular. Then 
"make".

On Friday, April 7, 2023 at 2:22:20 PM UTC-7 Eric Majzoub wrote:

> Following the procedure outlined on the Sage install page for Ubuntu.
>
> make fails showing:
> Error building Sage. 
>
> The following package(s) may have failed to build (not necessarily 
> during this run of 'make all-start'): 
>
> * package: sagelib-9.8 
>  last build time: Apr 7 15:48 
>  log file:/home/packages/SOURCE/sage/logs/pkgs/sagelib-9.8.log
>
> The log file is attached. It shows that gcc exits with status 1, but 
> doesn't give any specific error output from gcc itself. It fails on 
> building multi_polynomial_libsingular.
>
> Any help is appreciated.
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/089983a8-73a3-473c-a7d1-0c7be2e2a5c1n%40googlegroups.com.


Re: [sage-support] How to use Gap interface for permutation groups?

2023-04-04 Thread John H Palmieri
In lengthy code, you could start with a line like

OnSets = libgap.OnSets

and then in the rest of the code, you could do `g.Stabilizer([1,2], 
OnSets)`. That is, predefine whatever you want from libgap, giving each 
item a meaningful name, and then use that name in the rest of the code.

On Tuesday, April 4, 2023 at 10:08:02 AM UTC-7 Hongyi Zhao wrote:

> On Friday, March 31, 2023 at 1:38:47 AM UTC+8 Dima Pasechnik wrote:
>
>
>
> On Thu, 30 Mar 2023, 18:25 'Peter Mueller' via sage-support, <
> sage-s...@googlegroups.com> wrote:
>
> When working with finite permutation groups, it seems to me that one has 
> the choice to either use the groups as sage objects like 
> `SymmetricGroup(4)`, or as a Gap object via `libgap.SymmetricGroup(4)`. The 
> former has rather limited functionality (and quite a few bugs as reported 
> earlier), so the advise was to use the latter concept.
>
> So after setting `g = libgap.SymmetricGroup(4)`, things like 
> `g.Stabilizer(1)` work as expected. However, I have difficulties to figure 
> out how for instance the equivalent of the Gap code `Stabilizer(g, [1,2], 
> OnSets)` would look like. Something like `g. Stabilizer([1, 2], 'OnSets')` 
> raises a GapError.
>
>
> it is
>
> g. Stabilizer([1, 2], libgap.OnSets)
>
>
> In lengthy code, calling too many keywords such as "libgap" is not elegant 
> in my opinion.
>
> Zhao
>  
>
>
> (which makes sense, as in GAP you also don't pass a string to Stabilizer, 
> but you pass a GAP action)
>
>
>
> Are these things documented somewhere? I couldn't find anything.
>
>
> all we have is 
> https://doc.sagemath.org/html/en/reference/libs/sage/libs/gap/libgap.html
> (and source code, eg in src/sage/graphs/)
>
>  - pull requests welcome 
>
>  
> Dima
>
>
>
> -- Peter Mueller
>
> -- 
> You received this message because you are subscribed to the Google Groups 
> "sage-support" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to sage-support...@googlegroups.com.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/sage-support/9702a206-d4d9-4d05-95eb-3a2b729ec4c5n%40googlegroups.com
>  
> 
> .
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/970530fa-c390-41e9-8ded-992add677c5bn%40googlegroups.com.


Re: [sage-support] computig all possible determinants of submatrices of a given matrix

2023-03-21 Thread John H Palmieri
>From the ask.sagemath.org answers:

[m.minors(k) for k in range(5)]

is pretty close to what you want: you just have to flatten the list.

On Monday, March 20, 2023 at 3:09:07 PM UTC-7 William Stein wrote:

> This is
>
>
> https://ask.sagemath.org/question/41136/how-to-find-all-the-sub-square-matrices-of-an-4x4-matrix-and-all-their-determinants/
>
>  -- William
>
> PS: For fun, I also asked a robot from the future and it said to use the 
> following code, but unfortunately "submatrix_iterator" doesn't exist yet:
>
> F = FiniteField(17) 
> A = matrix(F, 4, [1,2,3,4, 5,6,7,8, 9,10,11,12, 13,14,15,16]) # replace 
> the elements of the matrix with your desired matrix
>
> dets = []
> for i in range(1,5):
> for submatrix in A.submatrix_iterator(i):
> if submatrix.is_square():
> dets.append(submatrix.det())
>
> print(dets)
>
>
> On Mon, Mar 20, 2023 at 2:36 PM GUSTAVO TERRA BASTOS  
> wrote:
>
>> Hi all.
>>
>> Is there any specific comand to compute the determinants of all square 
>> submatrices of a given 4x4 - matrix over finite fields?
>>
>> best regards
>>
>> Gustavo
>>
>>
>>
>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "sage-support" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to sage-support...@googlegroups.com.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/sage-support/97ff54ff-8569-497a-9100-05ff2ae2cf9an%40googlegroups.com
>>  
>> 
>> .
>>
>
>
> -- 
> William (http://wstein.org)
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/99c17f96-9deb-4b83-bf9d-c5183ec6eaafn%40googlegroups.com.


Re: [sage-support] Equivalent System Packages command for homebrew?

2023-03-14 Thread John H Palmieri
See also the installation manual: 
https://doc.sagemath.org/html/en/installation/source.html#macos-package-installation.


On Tuesday, March 14, 2023 at 3:45:17 AM UTC-7 Dima Pasechnik wrote:

> Assuming you are on macOS with homebrew installed, get Sage source and run
> ./bootstrap
>
> and then
>
> ./configure
>
> The latter will print brew command(s) to run in the end.
>
> HTH
> Dima
>
> On Tue, Mar 14, 2023 at 10:38 AM Rishitha Madhavaram
>  wrote:
> >
> >
> > --
> > You received this message because you are subscribed to the Google 
> Groups "sage-support" group.
> > To unsubscribe from this group and stop receiving emails from it, send 
> an email to sage-support...@googlegroups.com.
> > To view this discussion on the web visit 
> https://groups.google.com/d/msgid/sage-support/8a812f6b-a521-44c5-941f-6faf54c5d590n%40googlegroups.com
> .
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/5bfbf661-11db-467f-9db8-7250d54732f8n%40googlegroups.com.


Re: [sage-support] sagemathlib only building single-threaded

2023-02-12 Thread John H Palmieri
I have been setting MAKE and MAKEFLAGS for a long time, and I have not seen 
any difference in the behavior of "make build". If I unset MAKE and 
MAKEFLAGS, then it takes longer to build sagelib, as it should.

On Saturday, February 11, 2023 at 11:44:43 AM UTC-8 Nils Bruin wrote:

> On Saturday, 11 February 2023 at 01:51:47 UTC-8 Dima Pasechnik wrote:
> >
> >make -j8 normaliz pynormaliz
> >
> > "sage -i"  is obsolete - at least in my mind :-)
> OK -- thanks! so what used to be "spkg"s are now makefile targets. That 
> reduces the possibility of having "third party" spkgs -- I guess that means 
> they should be packaged as "pip" packages instead.
>
> Also for this, sage itself actually instructed me to install it with `sage 
> -i`, so if "make" is now preferred, we should change docs on that. I think 
> it even suggested something like "!sage -i normaliz" which is difficult to 
> find a make analogue of.
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/ae28def1-4eb6-4c44-b2a2-8ab0fdee9863n%40googlegroups.com.


Re: [sage-support] Sagemath binary is old and fails to install properly on Ubuntu 20.04.5 LTS

2023-02-08 Thread John H Palmieri
For what it's worth, every now and then I create a virtual linux machine 
and build Sage from source using the instructions in the installation 
guide, including installing the recommended prerequisite software. It 
typically goes smoothly, and it's definitely worth trying on Ubuntu. (I've 
done this with Ubuntu 22.04.1 LTS.)

On Wednesday, February 8, 2023 at 3:27:23 AM UTC-8 dim...@gmail.com wrote:

> Hi Dave,
>
> On Wed, Feb 8, 2023 at 11:12 AM David Kirkby  wrote:
> >
> > Some of you may remember me - I did a fair amount of work porting Sage 
> to Solaris SPARC.
> >
> > I wanted to try sage, and could not be bothered to build from source, so 
> thought I'd just install a binary onto a Dell 7920 tower workstation (2 x 
> 26-core 2.0 GHz CPUs with 384 GB RAM) running Ubuntu 20.04.5 LTS.
> >
> > 1) First sage is not installed, and never has been on this system.
> > drkirkby@canary:~/Desktop$ sage
> >
> > Command 'sage' not found, but can be installed with:
> >
> > sudo apt install sagemath-common
>
> We aren't maintaining Ubuntu/Debian packages, so this report should
> not have gone here. :-)
> Some years/releases Debian packaging of Sage is in good shape, some
> years it's falling behind,
> but we are trying to be helpful. (Debian is permanently short on
> hands, and also slowed down
> by their rather slow workflow...)
> Not sure about Ubuntu, what they use and how they maintain their Sage
> packages, they never showed up here.
> (typically Ubuntu just uses Debian packages, but not always)
>
> >
> > 2) I try to install Sage - this gives a number of error messages.
> > drkirkby@canary:~/Desktop$ sudo apt install sagemath-common
> > [sudo] password for drkirkby:
> > Reading package lists... Done
> > Building dependency tree
> > Reading state information... Done
> > The following packages were automatically installed and are no longer 
> required:
> > chromium-codecs-ffmpeg-extra gstreamer1.0-vaapi guile-2.2
> > libalgorithm-c3-perl libaqbanking-data libaqbanking44
> > libb-hooks-endofscope-perl libb-hooks-op-check-perl libcgi-fast-perl
> > libcgi-pm-perl libclass-c3-perl libclass-c3-xs-perl
> > libclass-data-inheritable-perl libclass-inspector-perl
> > libclass-method-modifiers-perl libclass-singleton-perl
> > libclass-xsaccessor-perl libcommon-sense-perl libdata-optlist-perl
> > libdate-manip-perl libdatetime-format-strptime-perl 
> libdatetime-locale-perl
> > libdatetime-perl libdatetime-timezone-perl libdbi1 
> libdevel-callchecker-perl
> > libdevel-caller-perl libdevel-lexalias-perl libdevel-stacktrace-perl
> > libdynaloader-functions-perl libeval-closure-perl libexception-class-perl
> > libfcgi-perl libfile-sharedir-perl libfinance-quote-perl libfwupdplugin1
> > libgstreamer-plugins-bad1.0-0 libgwengui-gtk3-0 libgwenhywfar-data
> > libgwenhywfar79 libhtml-tableextract-perl libjson-parse-perl libjson-perl
> > libjson-xs-perl libllvm11 libmodule-implementation-perl
> > libmodule-runtime-perl libmro-compat-perl libnamespace-autoclean-perl
> > libnamespace-clean-perl libofx7 libosp5 libpackage-stash-perl
> > libpackage-stash-xs-perl libpadwalker-perl libparams-classify-perl
> > libparams-util-perl libparams-validationcompiler-perl libreadonly-perl
> > libref-util-perl libref-util-xs-perl librole-tiny-perl libspecio-perl
> > libsub-exporter-perl libsub-exporter-progressive-perl 
> libsub-identify-perl
> > libsub-install-perl libsub-quote-perl libtext-template-perl
> > libtypes-serialiser-perl libva-wayland2 libvariable-magic-perl libxmlb1
> > libxstring-perl shim
> > Use 'sudo apt autoremove' to remove them.
> > The following NEW packages will be installed
> > sagemath-common
> > 0 to upgrade, 1 to newly install, 0 to remove and 39 not to upgrade.
> > Need to get 16.2 MB of archives.
> > After this operation, 205 MB of additional disk space will be used.
> > Get:1 http://gb.archive.ubuntu.com/ubuntu focal/universe amd64 
> sagemath-common all 9.0-1ubuntu4 [16.2 MB]
> > Fetched 16.2 MB in 1s (11.0 MB/s)
> > Selecting previously unselected package sagemath-common.
> > (Reading database ... 382458 files and directories currently installed.)
> > Preparing to unpack .../sagemath-common_9.0-1ubuntu4_all.deb ...
> > Unpacking sagemath-common (9.0-1ubuntu4) ...
> > Setting up sagemath-common (9.0-1ubuntu4) ...
> > 
> /usr/lib/python3/dist-packages/sage/combinat/root_system/branching_rules.py:1753
> > : SyntaxWarning: "is not" with a literal. Did you mean "!="?
> > if len(stypes) is not 2:
> > /usr/lib/python3/dist-packages/sage/graphs/graph_latex.py:1159: 
> SyntaxWarning: '
> > str' object is not callable; perhaps you missed a comma?
> > raise TypeError('%s option must be a dictionary, not %s' (name, value))
> > /usr/lib/python3/dist-packages/sage/graphs/graph_latex.py:1168: 
> SyntaxWarning: '
> > str' object is not callable; perhaps you missed a comma?
> > raise TypeError('%s option must be a dictionary, not %s' (name, value))
> > /usr/lib/python3/dist-packages/sage/graphs/graph_latex.py:1175: 
> 

[sage-support] Re: mathematica_console() command not working

2023-01-20 Thread John H Palmieri
All of the *_console commands should be fixed by ticket #34547.


On Thursday, January 19, 2023 at 11:45:59 PM UTC-8 trevor...@gmail.com 
wrote:

> Something similar seems to happen with `gap_console()` and `gap.console()`.
>
> On Thursday, January 19, 2023 at 5:22:23 PM UTC-6 John H Palmieri wrote:
>
>> "mathematica_console()" is available (or at least it should be) when 
>> using Sage from the command-line but not from the notebook. There was a 
>> bug, now fixed in https://trac.sagemath.org/ticket/34547, that meant 
>> that this command was not available when it should have been.
>>
>>
>> On Thursday, January 19, 2023 at 2:28:38 PM UTC-8 pvit...@gmail.com 
>> wrote:
>>
>>> Ups, sorry about that. 
>>>
>>> El jueves, 19 de enero de 2023 a las 22:37:16 UTC+1, Emmanuel 
>>> Charpentier escribió:
>>>
>>>> mathematica_console() does not indeed exist. but mathematica.console() 
>>>> does (and so does mathematica.interact(), which might be what you are 
>>>> really searching…).
>>>> ​
>>>> Le jeudi 19 janvier 2023 à 11:13:28 UTC+1, pvit...@gmail.com a écrit :
>>>>
>>>>> Using Sage 9.7 installed in Arch Linux over WSL2 in Windows 10.
>>>>> The interface to mathematica works, but the mathematica_console() does 
>>>>> not, with this error:
>>>>>
>>>>> NameError Traceback (most recent call 
>>>>> last)
>>>>> Cell In[16], line 1
>>>>> > 1 mathematica_console()
>>>>>
>>>>> NameError: name 'mathematica_console' is not defined
>>>>>
>>>>> Is this command not available anymore?
>>>>>
>>>>> Thanks a lot
>>>>> Pablo
>>>>>
>>>>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/36ec8531-0b9d-4501-ad56-da7d961137f6n%40googlegroups.com.


[sage-support] Re: mathematica_console() command not working

2023-01-19 Thread John H Palmieri
"mathematica_console()" is available (or at least it should be) when using 
Sage from the command-line but not from the notebook. There was a bug, now 
fixed in https://trac.sagemath.org/ticket/34547, that meant that this 
command was not available when it should have been.


On Thursday, January 19, 2023 at 2:28:38 PM UTC-8 pvit...@gmail.com wrote:

> Ups, sorry about that. 
>
> El jueves, 19 de enero de 2023 a las 22:37:16 UTC+1, Emmanuel Charpentier 
> escribió:
>
>> mathematica_console() does not indeed exist. but mathematica.console() 
>> does (and so does mathematica.interact(), which might be what you are 
>> really searching…).
>> ​
>> Le jeudi 19 janvier 2023 à 11:13:28 UTC+1, pvit...@gmail.com a écrit :
>>
>>> Using Sage 9.7 installed in Arch Linux over WSL2 in Windows 10.
>>> The interface to mathematica works, but the mathematica_console() does 
>>> not, with this error:
>>>
>>> NameError Traceback (most recent call 
>>> last)
>>> Cell In[16], line 1
>>> > 1 mathematica_console()
>>>
>>> NameError: name 'mathematica_console' is not defined
>>>
>>> Is this command not available anymore?
>>>
>>> Thanks a lot
>>> Pablo
>>>
>>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/c6adb046-ed02-4019-b68a-4df8a2123fc4n%40googlegroups.com.


[sage-support] Re: Cannot build 9.7 on Debian Sid

2023-01-13 Thread John H Palmieri
It may be (as pointed out on a similar thread in the group sage-devel) that 
some of the Debian packages have versions that are too new to be used with 
Sage. You could tell Sage to build its own Python, its own Gap, perhaps its 
own Singular (if the system one is causing problems):

./configure --with-system-python3=no --with-system-gap=no 
--with-system-singular=no



On Friday, January 13, 2023 at 6:54:37 AM UTC-8 Luis Finotti wrote:

> After some more updated came to Sid, I tried again.  Still does not 
> compile, but breaks much sooner.  Here is the new log: 
> https://web.math.utk.edu/~finotti/tmp/install-2.log
>
> Sid's own packaged version of Sage also cannot be installed at the moment:
>
> # apt install sagemath 
> Reading package lists... Done 
> Building dependency tree... Done 
> Reading state information... Done 
> Some packages could not be installed. This may mean that you have 
> requested an impossible situation or if you are using the unstable 
> distribution that some required packages have not yet been created 
> or been moved out of Incoming. 
> The following information may help to resolve the situation: 
>
> The following packages have unmet dependencies: 
> python3-sage : Depends: python3 (< 3.11) but 3.11.1-1 is to be installed 
>Depends: libgap7 (>= 4.11.0-1) but it is not installable 
> E: Unable to correct problems, you have held broken packages.
>
> Any help would be greatly appreciated.
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/1b2e26e6-d41e-457b-800d-82d7d3201d5fn%40googlegroups.com.


[sage-support] Re: Matrix_generic_dense.det() is quite slow compared to Numpy

2023-01-08 Thread John H Palmieri
I am not at all an expert in numerical linear algebra, but (a) certainly 
parts of Sage can be improved and (b) contributions are welcome. Others can 
speak more knowledgeably about this particular issue.

On Sunday, January 8, 2023 at 11:45:00 AM UTC-8 ivana...@gmail.com wrote:

> Is there any space to improve the computation of MPFR which is used by 
> RealField?
>
> John H Palmieri 在 2023年1月6日 星期五凌晨3:01:37 [UTC+8] 的信中寫道:
>
>> One way to speed it up might be to work with RDF or QQ or RLF. The 
>> documentation for the generic determinant method says, "Note that for 
>> matrices over most rings, more sophisticated algorithms can be used." 
>>
>> sage: %time ones_matrix(RDF, 600, 600).determinant()
>> CPU times: user 78.6 ms, sys: 7.6 ms, total: 86.2 ms
>> Wall time: 77.9 ms
>> 0.0
>> sage: %time ones_matrix(QQ, 600, 600).determinant()
>> CPU times: user 280 ms, sys: 36.3 ms, total: 317 ms
>> Wall time: 325 ms
>> 0
>> sage: %time ones_matrix(RLF, 600, 600).determinant()
>> CPU times: user 32.7 s, sys: 183 ms, total: 32.9 s
>> Wall time: 40.3 s
>> 0
>>
>>
>> On Thursday, January 5, 2023 at 1:26:12 AM UTC-8 ivana...@gmail.com 
>> wrote:
>>
>>> I am doing a numerical analysis which needs to calculate many 
>>> determinants of "huge" dense matrices. The sizes of the matrix are less 
>>> than 100*100.
>>>
>>> I found the computation of the determinant is quite slow with 
>>> Matrix_generic_dense. I followed the method on What is the time 
>>> complexity of numpy.linalg.det? 
>>> <https://stackoverflow.com/questions/72206172/what-is-the-time-complexity-of-numpy-linalg-det>
>>>  
>>> and made minor modifications to the script to benchmark for Sagemath.
>>> 1. np.arange(1,10001, 100) => np.arange(1, 292, 10) because the speed is 
>>> too slow, I have to reduce the testing range to make the script finish 
>>> within a reasonable time.
>>> 2. np.ones((size, size))  => ones_matrix(RR, size, size)
>>> 3. timeit('np.linalg.det(A)', globals={'np':np, 'A':A}, number=1) => 
>>> timeit('A.det(algorithm="df")', globals={'A': A}, number=1)
>>>
>>> Here is the full script I used.
>>>
>>> from timeit import timeit
>>>
>>> import matplotlib.pyplot as plt
>>> import numpy as np
>>> from sage.rings.real_mpfr import RR
>>> from sklearn.linear_model import LinearRegression
>>> from sklearn.preprocessing import PolynomialFeatures
>>>
>>> sizes = np.arange(1, 292, 10)
>>> times = []
>>>
>>> for size in sizes:
>>> A = ones_matrix(RR, size, size)
>>> time = timeit('A.det(algorithm="df")', globals={'A': A}, number=1)
>>> times.append(time)
>>> print(size, time)
>>>
>>> sizes = sizes.reshape(-1, 1)
>>> times = np.array(times).reshape(-1, 1)
>>>
>>> quad_sizes = PolynomialFeatures(degree=2).fit_transform(sizes)
>>> quad_times = LinearRegression().fit(quad_sizes, 
>>> times).predict(quad_sizes)
>>> cubic_sizes = PolynomialFeatures(degree=3).fit_transform(sizes)
>>> cubic_times = LinearRegression().fit(cubic_sizes, 
>>> times).predict(cubic_sizes)
>>> quartic_sizes = PolynomialFeatures(degree=4).fit_transform(sizes)
>>> quartic_times = LinearRegression().fit(quartic_sizes,
>>>times).predict(quartic_sizes)
>>>
>>> plt.scatter(sizes, times, label='Data', color='k', alpha=0.5)
>>> plt.plot(sizes, quad_times, label='Quadratic', color='r')
>>> plt.plot(sizes, cubic_times, label='Cubic', color='g')
>>> plt.plot(sizes, quartic_times, label='Quartic', color='b')
>>> plt.xlabel('Matrix Dimension n')
>>> plt.ylabel('Time (seconds)')
>>> plt.legend()
>>> plt.show()
>>>
>>> This is the time complexity diagram on the linked post. The data from 
>>> the testing with Numpy. It only took about 20 seconds to calculate a 
>>> 1*1 matrix.
>>> [image: numpy.png]This is the testing with matrix(RR) with the df 
>>> algorithm.
>>> [image: df.png]
>>> I also tested with the "hessenberg" algorithm which got worse.
>>> [image: df.png]
>>> Compared to Numpy, Sagemath spent 800 seconds calculating a 300*300 
>>> matrix. It seems that Sagemath still runs the algorithm under O(n^3) (the 
>>> curves of the cubic model and the quartic model overlap) but with a large 
>>> constant. Why Sagemath is so slow? Is it possible to speed up?
>>>
>>>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/8b81830e-d76f-4554-b4cd-7f62a47ba32fn%40googlegroups.com.


[sage-support] Re: Matrix_generic_dense.det() is quite slow compared to Numpy

2023-01-05 Thread John H Palmieri
One way to speed it up might be to work with RDF or QQ or RLF. The 
documentation for the generic determinant method says, "Note that for 
matrices over most rings, more sophisticated algorithms can be used." 

sage: %time ones_matrix(RDF, 600, 600).determinant()
CPU times: user 78.6 ms, sys: 7.6 ms, total: 86.2 ms
Wall time: 77.9 ms
0.0
sage: %time ones_matrix(QQ, 600, 600).determinant()
CPU times: user 280 ms, sys: 36.3 ms, total: 317 ms
Wall time: 325 ms
0
sage: %time ones_matrix(RLF, 600, 600).determinant()
CPU times: user 32.7 s, sys: 183 ms, total: 32.9 s
Wall time: 40.3 s
0


On Thursday, January 5, 2023 at 1:26:12 AM UTC-8 ivana...@gmail.com wrote:

> I am doing a numerical analysis which needs to calculate many determinants 
> of "huge" dense matrices. The sizes of the matrix are less than 100*100.
>
> I found the computation of the determinant is quite slow with 
> Matrix_generic_dense. I followed the method on What is the time 
> complexity of numpy.linalg.det? 
> 
>  
> and made minor modifications to the script to benchmark for Sagemath.
> 1. np.arange(1,10001, 100) => np.arange(1, 292, 10) because the speed is 
> too slow, I have to reduce the testing range to make the script finish 
> within a reasonable time.
> 2. np.ones((size, size))  => ones_matrix(RR, size, size)
> 3. timeit('np.linalg.det(A)', globals={'np':np, 'A':A}, number=1) => 
> timeit('A.det(algorithm="df")', globals={'A': A}, number=1)
>
> Here is the full script I used.
>
> from timeit import timeit
>
> import matplotlib.pyplot as plt
> import numpy as np
> from sage.rings.real_mpfr import RR
> from sklearn.linear_model import LinearRegression
> from sklearn.preprocessing import PolynomialFeatures
>
> sizes = np.arange(1, 292, 10)
> times = []
>
> for size in sizes:
> A = ones_matrix(RR, size, size)
> time = timeit('A.det(algorithm="df")', globals={'A': A}, number=1)
> times.append(time)
> print(size, time)
>
> sizes = sizes.reshape(-1, 1)
> times = np.array(times).reshape(-1, 1)
>
> quad_sizes = PolynomialFeatures(degree=2).fit_transform(sizes)
> quad_times = LinearRegression().fit(quad_sizes, times).predict(quad_sizes)
> cubic_sizes = PolynomialFeatures(degree=3).fit_transform(sizes)
> cubic_times = LinearRegression().fit(cubic_sizes, 
> times).predict(cubic_sizes)
> quartic_sizes = PolynomialFeatures(degree=4).fit_transform(sizes)
> quartic_times = LinearRegression().fit(quartic_sizes,
>times).predict(quartic_sizes)
>
> plt.scatter(sizes, times, label='Data', color='k', alpha=0.5)
> plt.plot(sizes, quad_times, label='Quadratic', color='r')
> plt.plot(sizes, cubic_times, label='Cubic', color='g')
> plt.plot(sizes, quartic_times, label='Quartic', color='b')
> plt.xlabel('Matrix Dimension n')
> plt.ylabel('Time (seconds)')
> plt.legend()
> plt.show()
>
> This is the time complexity diagram on the linked post. The data from the 
> testing with Numpy. It only took about 20 seconds to calculate a 
> 1*1 matrix.
> [image: numpy.png]This is the testing with matrix(RR) with the df 
> algorithm.
> [image: df.png]
> I also tested with the "hessenberg" algorithm which got worse.
> [image: df.png]
> Compared to Numpy, Sagemath spent 800 seconds calculating a 300*300 
> matrix. It seems that Sagemath still runs the algorithm under O(n^3) (the 
> curves of the cubic model and the quartic model overlap) but with a large 
> constant. Why Sagemath is so slow? Is it possible to speed up?
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/6c5c2d95-7521-4548-8335-2a3064e180ben%40googlegroups.com.


[sage-support] Re: Sage 9.8 build error

2023-01-04 Thread John H Palmieri
Some observations:

- It's showing a different error now.
- I find it unusual that more packages haven't been built before it tries 
to build sagelib. You could try "make" again and see how far it gets.
- config.log says 

Invocation command line was

  $ ./configure 
PKG_CONFIG_PATH=/opt/homebrew/opt/sqlite/lib/pkgconfig:/opt/homebrew/opt/readline/lib/pkgconfig:/opt/homebrew/opt/openblas/lib/pkgconfig:/opt/homebrew/lib/pkgconfig:
 
--no-create --no-recursion

Did you pass these arguments to ./configure?

- Did you "source .homebrew-build-env" before running "./configure" and 
"make"?


On Wednesday, January 4, 2023 at 2:59:01 PM UTC-8 alexcha...@gmail.com 
wrote:

> After following all of the suggestions, I am still getting the error
>
> """
> Error building Sage.
>
> The following package(s) may have failed to build (not necessarily
> during this run of 'make all-start'):
>
> * package: sagelib-9.8.beta6
>   last build time: Jan 4 14:45
>   log file:   
>  /Users/alexchandler/Documents/GitHub/sage/logs/pkgs/sagelib-9.8.beta6.log
>
> It is safe to delete any log files and build directories, but they
> contain information that is helpful for debugging build problems.
> WARNING: If you now run 'make' again, the build directory of the
> same version of the package will, by default, be deleted. Set the
> environment variable SAGE_KEEP_BUILT_SPKGS=yes to prevent this.
>
> make[1]: *** [all-start] Error 1
> make: *** [all] Error 2
> """
>
> This time there are only four packages with errors pointed out when I run
>
> grep -li "^Error" logs/pkgs/*
>
> so this is an improvement, but I am still unable to proceed. Any idea how 
> to fix the issue? I have attached logs, config.log, and a text file with 
> the 4 packages with errors.
>
> Thank you!
> Alex
>
> On Wednesday, January 4, 2023 at 11:35:39 AM UTC-8 John H Palmieri wrote:
>
>> Many of the errors are discussed at 
>> https://trac.sagemath.org/ticket/34838. You can probably avoid those by 
>> running "make typing_extensions" before running "make".
>>
>> The most recent error seems to be for sagelib:
>>
>> ld: library not found for -lopenblas
>>
>> I assume that you followed the directions at the end of ./configure? It 
>> is possible that some homebrew package got updated after running 
>> ./configure, and now Sage is looking for the old one and can't find it. 
>> Maybe you need to start over by running "make distclean"? Re-run 
>> "./configure", then "make typing_extension", then "make".
>>
>>
>> On Tuesday, January 3, 2023 at 10:56:01 PM UTC-8 alexcha...@gmail.com 
>> wrote:
>>
>>> Hello,
>>>
>>> I am trying to build Sage 9.8 from source on a 2021 Apple M1 laptop. I 
>>> have attached the logs for each attempt and also the packages with errors 
>>> as indicated by running 
>>>
>>> grep -li "^Error" logs/pkgs/*
>>>
>>> Thank you,
>>> Alex
>>>
>>>
>>>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/be9c7509-cba6-4fa2-9619-173161896767n%40googlegroups.com.


[sage-support] Re: Sage 9.8 build error

2023-01-04 Thread John H Palmieri
Maybe you also need to do "make flit_core" before "make typing_extension".

On Wednesday, January 4, 2023 at 11:35:39 AM UTC-8 John H Palmieri wrote:

> Many of the errors are discussed at https://trac.sagemath.org/ticket/34838. 
> You can probably avoid those by running "make typing_extensions" before 
> running "make".
>
> The most recent error seems to be for sagelib:
>
> ld: library not found for -lopenblas
>
> I assume that you followed the directions at the end of ./configure? It is 
> possible that some homebrew package got updated after running ./configure, 
> and now Sage is looking for the old one and can't find it. Maybe you need 
> to start over by running "make distclean"? Re-run "./configure", then "make 
> typing_extension", then "make".
>
>
> On Tuesday, January 3, 2023 at 10:56:01 PM UTC-8 alexcha...@gmail.com 
> wrote:
>
>> Hello,
>>
>> I am trying to build Sage 9.8 from source on a 2021 Apple M1 laptop. I 
>> have attached the logs for each attempt and also the packages with errors 
>> as indicated by running 
>>
>> grep -li "^Error" logs/pkgs/*
>>
>> Thank you,
>> Alex
>>
>>
>>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/02f5700b-bf0c-429e-a304-3e7ea8dac33bn%40googlegroups.com.


[sage-support] Re: Sage 9.8 build error

2023-01-04 Thread John H Palmieri
Many of the errors are discussed at https://trac.sagemath.org/ticket/34838. 
You can probably avoid those by running "make typing_extensions" before 
running "make".

The most recent error seems to be for sagelib:

ld: library not found for -lopenblas

I assume that you followed the directions at the end of ./configure? It is 
possible that some homebrew package got updated after running ./configure, 
and now Sage is looking for the old one and can't find it. Maybe you need 
to start over by running "make distclean"? Re-run "./configure", then "make 
typing_extension", then "make".


On Tuesday, January 3, 2023 at 10:56:01 PM UTC-8 alexcha...@gmail.com wrote:

> Hello,
>
> I am trying to build Sage 9.8 from source on a 2021 Apple M1 laptop. I 
> have attached the logs for each attempt and also the packages with errors 
> as indicated by running 
>
> grep -li "^Error" logs/pkgs/*
>
> Thank you,
> Alex
>
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/5c58d060-cfda-4518-a4ff-cfeef5c06bcen%40googlegroups.com.


Re: [sage-support] Re: Listing elements of a finite ring.

2022-11-20 Thread John H Palmieri
You can also do `list(S)`, or depending on what you're doing it might be 
better to iterate over its elements, as Emmanuel wrote: `for u in S...`


On Sunday, November 20, 2022 at 8:54:25 AM UTC-8 gauri...@gmail.com wrote:

> Oh wow! That was easy! 
>
> Thanks so much! 
> G
>
> On Sun, Nov 20, 2022 at 3:12 PM Emmanuel Charpentier <
> emanuel.c...@gmail.com> wrote:
>
>> No predefined method, but listing S’s elements seems easy :
>>
>> sage: R1.=GF(97)[]
>> sage: p=lambda x:x^2+2
>> sage: S=R1.quotient(p(t),'a')
>> sage: L=[u for u in S]
>> sage: len(L)
>> 9409
>>
>> HTH,
>> ​
>> Le dimanche 20 novembre 2022 à 07:39:27 UTC+1, gauri...@gmail.com a 
>> écrit :
>>
>>> I am afraid I cannot seem to find the answer to the following question 
>>> in the docs. 
>>>
>>> Suppose I have finite ring? How do I list all its elements? e.g.
>>>
>>> ```
>>> R = PolynomialRing(GF(97),'x')
>>> x = R.gen()
>>>
>>> p = lambda x: x^2+2
>>> S = R.quotient(p(x), 'a')
>>> ```
>>>
>>> I would like to list all the elements of the quotient ring S. Is there a 
>>> function/method that allows listing elements of S?
>>>
>>>  
>>>
>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "sage-support" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to sage-support...@googlegroups.com.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/sage-support/5288658d-8d36-454f-9f07-8a6cadf056edn%40googlegroups.com
>>  
>> 
>> .
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/d1d641f6-894b-4026-b37a-efb528786779n%40googlegroups.com.


Re: [sage-support] Subalgebra membership in a polynomial algebra

2022-09-06 Thread John H Palmieri
Thanks, Dima, that's helpful. I will open a ticket; I hope this will be an 
easy thing for people familiar with the Singular interfaces.

-- 
John

On Tuesday, September 6, 2022 at 3:31:08 PM UTC-7 dim...@gmail.com wrote:

> On Tue, Sep 6, 2022 at 10:32 PM John H Palmieri  
> wrote:
> >
> > Let R = k[x_1, x_2, ..., x_n] be a polynomial ring over a field k of 
> characteristic p. Given elements a_1, a_2, ..., a_m and b in R, I would 
> like to know if b is in the subalgebra generated by a_1, ..., a_m.My 
> impression from a superficial skim of the literature (Shannon and Sweedler, 
> https://www.sciencedirect.com/science/article/pii/S0747717188800476, for 
> example) is that this problem has been solved using Grobner bases. Is there 
> something already in Sage that can easily perform this test? I couldn't 
> find any method "in_subalgebra" or "in_subring" or any obviously relevant 
> "__contains__", or even a method for constructing a subalgebra of a 
> polynomial ring, but maybe I'm missing something obvious.
>
> in Singular it is available:
> https://www.singular.uni-kl.de/Manual/4-3-1/sing_1247.htm#SEC1328
> So the question is to make an interface.
>
> >
> > (I don't actually care about representing b inside the subalgebra, I 
> just want to know if it's there, in case that helps.)
> >
> > --
> > John
> >
> > --
> > You received this message because you are subscribed to the Google 
> Groups "sage-support" group.
> > To unsubscribe from this group and stop receiving emails from it, send 
> an email to sage-support...@googlegroups.com.
> > To view this discussion on the web visit 
> https://groups.google.com/d/msgid/sage-support/e69e3952-57bf-4d8e-b213-16a691d4n%40googlegroups.com
> .
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/25a3294a-15bb-4a05-a081-bb9407176d59n%40googlegroups.com.


[sage-support] Subalgebra membership in a polynomial algebra

2022-09-06 Thread John H Palmieri
Let R = k[x_1, x_2, ..., x_n] be a polynomial ring over a field k of 
characteristic p. Given elements a_1, a_2, ..., a_m and b in R, I would 
like to know if b is in the subalgebra generated by a_1, ..., a_m.My 
impression from a superficial skim of the literature (Shannon and Sweedler, 
https://www.sciencedirect.com/science/article/pii/S0747717188800476, for 
example) is that this problem has been solved using Grobner bases. Is there 
something already in Sage that can easily perform this test? I couldn't 
find any method "in_subalgebra" or "in_subring" or any obviously relevant 
"__contains__", or even a method for constructing a subalgebra of a 
polynomial ring, but maybe I'm missing something obvious.

(I don't actually care about representing b inside the subalgebra, I just 
want to know if it's there, in case that helps.)

-- 
John

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/e69e3952-57bf-4d8e-b213-16a691d4n%40googlegroups.com.


Re: [sage-support] Re: PATH in OS X Jupyter notebook

2022-08-29 Thread John H Palmieri
I'm reviving this discussion because of another ask.sagemath.org post 
(https://ask.sagemath.org/question/63845/how-reach-octave-or-macaulay2-from-sage-notebook/):
 
someone who had installed octave and macaulay 2, but the app wasn't finding 
them because of its minimal setting for PATH. This makes me think that a 
preference panel to set the PATH would be a good idea. As far as I can 
tell, the app still reads $HOME/.sage/init.sage, so people can use that 
instead of modifying an IPython profile function, right? But a small 
preference panel might be nice.

-- 
John

On Friday, June 24, 2022 at 8:38:22 PM UTC-7 Marc Culler wrote:

> I should have mentioned that it is always possible to run the main 
> executable of a macOS app from the command line.  E.g.
>
> $ /Applications/SageMath.app/Contents/MacOS/SageMath
>
> When you do that, the process  that is launched is almost identical to the 
> one that is launched when you click on the icon, the difference being that 
> it does have a stdout and stderr.  So if you launch the app that way from 
> your terminal then you will be able to see any messages that are being 
> written to stderr.  (This is one of those situations for which a terminal 
> is an optimal tool.)
>
> - Marc
>
>
>
> On Fri, Jun 24, 2022 at 10:28 PM Marc Culler  wrote:
>
>> Hi John,
>>
>> A macOS app launched from an icon has no stdout or stderr.  Apple's NSLog 
>> command will write to stderr if it exists, and to a log file if it does not 
>> exist.  But simply writing to stderr as most unix programs do has no effect 
>> if stderr does not exist.  When using the terminal as the input for the 
>> sage app any stderr output generated by sage will go to the terminal.  But 
>> there is no place for such error messages to go if they are generated 
>> before sage is launched.  The /usr/local/bin/sage command is available as 
>> long as you install the recommended extra package, and anyone who is 
>> debugging should use it whenever necessary, as you did.
>>
>> I don't see any value in working hard to try to arrange that every 
>> possible thing can be done without ever using a terminal.  There is nothing 
>> wrong with using a terminal.  There are many tasks for which a terminal is 
>> the optimal tool.  So be it.
>>
>> - Marc
>>
>> On Fri, Jun 24, 2022 at 10:01 PM John H Palmieri  
>> wrote:
>>
>>> Hi Marc,
>>>
>>> Very good question. I think that allowing users to modify the standard 
>>> config files is the right thing to do, but I'm really not sure. I worry 
>>> that the next person will want to modify a different setting, and you don't 
>>> want to get dragged into recreating IPython/Jupyter preferences. For 
>>> debugging, would it be worth providing a warning if a config file is found, 
>>> or if a config file is found with any nonstandard settings? (The default 
>>> config file is entirely commented out.)
>>>
>>> By the way, I debugged Samuel's suggestion by running "./sage -n" with a 
>>> local installation: it printed error messages in the terminal where I ran 
>>> it that let me know that something was wrong. I figured out that I had to 
>>> use quotes, as in
>>>
>>>   c.InteractiveShellApp.exec_lines = ['import sys; ...']
>>>
>>> rather than
>>>
>>>   c.InteractiveShellApp.exec_lines = [import sys; ...]
>>>
>>> I don't know where to view the corresponding error messages for the OS X 
>>> app.
>>>
>>> A question for both of you: I think the standard situation is to not 
>>> have a profile directory, you have to run "sage --ipython profile create". 
>>> Is there a good way to do this instead from a Jupyter notebook? Then 
>>> someone could create a profile directory without having to use the 
>>> terminal, although they would need to use a text editor to modify it.
>>>
>>> -- 
>>> John
>>>
>>> On Friday, June 24, 2022 at 3:12:52 PM UTC-7 Marc Culler wrote:
>>>
>>>> Thank you for figuring that out Samuel.  Now here is a question for 
>>>> both of you.  The macOS app intentionally sets a minimal environment when 
>>>> it starts sage.  It is intentionally minimal because it would be 
>>>> dangerous, 
>>>> in terms of security, but more importantly in terms of the potential for 
>>>> creating hard-to-debug crashes of the app, to simply accept whatever weird 
>>>> stuff the user happens to have in their environment.  The decision to set 
>>>> a 
>>>> specific minimal envi

Re: [sage-support] Compute equalizer of maps between polynomial rings?

2022-08-25 Thread John H Palmieri
One issue is that f-id is not a ring homomorphism. So do I restrict to a 
range of degrees, convert to vector spaces, and compute the kernel? I'm not 
sure of the right approach.

On Thursday, August 25, 2022 at 3:11:12 AM UTC-7 pedrito...@gmail.com wrote:

> Dear John,
> Wouldn’t be of some help to consider the kernel of  f-Id (with Id the 
> identity map)?
> Best,
> Pedro
>
> El El jue, 25 ago 2022 a las 8:22, Dima Pasechnik  
> escribió:
>
>>
>>
>> On Thu, 25 Aug 2022, 00:38 John H Palmieri,  wrote:
>>
>>> I have a polynomial ring R = k[x1, x2, ..., xn] and a ring homomorphism 
>>> f: R -> R. In case it matters, k=GF(2). I would like to find the subring of 
>>> elements x satisfying f(x) = x: that is, I want to find the equalizer of 
>>> the pair of maps (f, 1). Is there anything in Sage that will compute this? 
>>> The more polynomial generators this can handle, the better.
>>>
>>
>> Is this subring finitely generated? Invariant theory in positive 
>> characteristic is full of surprises...
>>
>>
>>> -- 
>>> John
>>>
>>> -- 
>>> You received this message because you are subscribed to the Google 
>>> Groups "sage-support" group.
>>> To unsubscribe from this group and stop receiving emails from it, send 
>>> an email to sage-support...@googlegroups.com.
>>> To view this discussion on the web visit 
>>> https://groups.google.com/d/msgid/sage-support/6b028ddf-d0b7-4156-adad-7315cc6220a1n%40googlegroups.com
>>>  
>>> <https://groups.google.com/d/msgid/sage-support/6b028ddf-d0b7-4156-adad-7315cc6220a1n%40googlegroups.com?utm_medium=email_source=footer>
>>> .
>>>
>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "sage-support" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to sage-support...@googlegroups.com.
>>
> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/sage-support/CAAWYfq3d%3DLMGOoXUyPhqRgzWfcMvrc%3DWZrxOTN7rfBg71VL06Q%40mail.gmail.com
>>  
>> <https://groups.google.com/d/msgid/sage-support/CAAWYfq3d%3DLMGOoXUyPhqRgzWfcMvrc%3DWZrxOTN7rfBg71VL06Q%40mail.gmail.com?utm_medium=email_source=footer>
>> .
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/8def5bf5-9526-49ee-b280-3203e2dd4949n%40googlegroups.com.


Re: [sage-support] Compute equalizer of maps between polynomial rings?

2022-08-25 Thread John H Palmieri
Good question, and I don't whether the subring is finitely generated. I 
want to compute examples — what's the subring in a range of degrees — to 
see what's going on.

On Wednesday, August 24, 2022 at 11:22:31 PM UTC-7 dim...@gmail.com wrote:

>
>
> On Thu, 25 Aug 2022, 00:38 John H Palmieri,  wrote:
>
>> I have a polynomial ring R = k[x1, x2, ..., xn] and a ring homomorphism 
>> f: R -> R. In case it matters, k=GF(2). I would like to find the subring of 
>> elements x satisfying f(x) = x: that is, I want to find the equalizer of 
>> the pair of maps (f, 1). Is there anything in Sage that will compute this? 
>> The more polynomial generators this can handle, the better.
>>
>
> Is this subring finitely generated? Invariant theory in positive 
> characteristic is full of surprises...
>
>
>> -- 
>> John
>>
>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "sage-support" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to sage-support...@googlegroups.com.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/sage-support/6b028ddf-d0b7-4156-adad-7315cc6220a1n%40googlegroups.com
>>  
>> <https://groups.google.com/d/msgid/sage-support/6b028ddf-d0b7-4156-adad-7315cc6220a1n%40googlegroups.com?utm_medium=email_source=footer>
>> .
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/1864e476-7668-43ce-8089-ecb66b1e66e6n%40googlegroups.com.


[sage-support] Compute equalizer of maps between polynomial rings?

2022-08-24 Thread John H Palmieri
I have a polynomial ring R = k[x1, x2, ..., xn] and a ring homomorphism f: 
R -> R. In case it matters, k=GF(2). I would like to find the subring of 
elements x satisfying f(x) = x: that is, I want to find the equalizer of 
the pair of maps (f, 1). Is there anything in Sage that will compute this? 
The more polynomial generators this can handle, the better.

-- 
John

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/6b028ddf-d0b7-4156-adad-7315cc6220a1n%40googlegroups.com.


[sage-support] Re: Find the matrix representations corresponding to complex numbers and quaternions.

2022-07-01 Thread John H Palmieri
Is this the sort of thing you're looking for?

def matrix_rep(z):
"""
INPUT: complex number z = a + bi
OUTPUT: the matrix
   [a -b]
   [b  a]
"""
a = z.real_part()
b = z.imag_part()
return matrix(RR, [[a, -b], [b, a]])

On Friday, July 1, 2022 at 3:04:40 AM UTC-7 hongy...@gmail.com wrote:

> How can I find the matrix representations corresponding to complex numbers 
> and quaternions with the help of SageMath , 
> i.e., the ring isomorphism 
>  from the field of 
> complex numbers and quaternions to the rings of corresponding matrices, 
> respectively, as described here 
> 
>  
> and here 
> ?
>
> Regards,
> HZ
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/143f4daf-9e77-4b1b-92f4-ab8cde91a1bbn%40googlegroups.com.


[sage-support] Re: "Inappropriate ioctl for device" when displaying number in Jupyter notebook

2022-06-30 Thread John H Palmieri
This might be fixed by the change at 
https://trac.sagemath.org/ticket/33996. That will presumably be merged in 
the next beta release, since the ticket was just closed two days ago.


On Thursday, June 30, 2022 at 11:30:11 AM UTC-7 Richard Stanton wrote:

> I've just installed Sagemath 9.6 (Release Date: 2022-05-15) on my Mac 
> running macOS 12.4. If I create a new Sagemath Jupyter notebook starting 
> from Sagemath, everything seems to work fine. However, I'd like to start by 
> just running "jupyter notebook" at the command line.  When I do this and 
> create a new notebook, selecting Sagemath 9.6 as the kernel, the kernel 
> starts up fine and I can run code. However, while `print(2)` correctly 
> displays the number 2, just typing `2` results in the error message shown 
> in the title. Any suggestions? Thanks!
>
> Here's the full error dump:
>
> {{{
>
> --
> OSError   Traceback (most recent call last)
> /var/folders/z_/x5g7y7vd6wqd2kzfnmfdqjjhgn/T/ipykernel_14807/1798176506.py
>  
> in 
> > 1 Integer(2)
>
> /private/var/tmp/sage-9.6-current/local/var/lib/sage/venv-python3.10.3/lib/python3.10/site-packages/IPython/core/displayhook.py
>  
> in __call__(self, result)
> 260 self.start_displayhook()
> 261 self.write_output_prompt()
> --> 262 format_dict, md_dict = self.compute_format_data(result)
> 263 self.update_user_ns(result)
> 264 self.fill_exec_result(result)
>
> /private/var/tmp/sage-9.6-current/local/var/lib/sage/venv-python3.10.3/lib/python3.10/site-packages/IPython/core/displayhook.py
>  
> in compute_format_data(self, result)
> 149 
> 150 """
> --> 151 return self.shell.display_formatter.format(result)
> 152 
> 153 # This can be set to True by the write_output_prompt method in 
> a subclass
>
> /private/var/tmp/sage-9.6-current/local/var/lib/sage/venv-python3.10.3/lib/python3.10/site-packages/sage/repl/display/formatter.py
>  
> in format(self, obj, include, exclude)
> 186 I am repper
> 187 """
> --> 188 sage_format, sage_metadata = self.dm.displayhook(obj)
> 189 assert PLAIN_TEXT in sage_format, 'plain text is always 
> present'
> 190 
>
> /private/var/tmp/sage-9.6-current/local/var/lib/sage/venv-python3.10.3/lib/python3.10/site-packages/sage/repl/rich_output/display_manager.py
>  
> in displayhook(self, obj)
> 825 return
> 826 self._backend.set_underscore_variable(obj)
> --> 827 plain_text, rich_output = self._rich_output_formatter(obj, 
> dict())
> 828 return self._backend.displayhook(plain_text, rich_output)
> 829 
>
> /private/var/tmp/sage-9.6-current/local/var/lib/sage/venv-python3.10.3/lib/python3.10/site-packages/sage/repl/rich_output/display_manager.py
>  
> in _rich_output_formatter(self, obj, rich_repr_kwds)
> 652 plain_text = self._backend.plain_text_formatter(obj, 
> **rich_repr_kwds)
> 653 if rich_output is None:
> --> 654 rich_output = self._preferred_text_formatter(
> 655 obj, plain_text=plain_text, **rich_repr_kwds)
> 656 # promote output container types to backend-specific 
> containers
>
> /private/var/tmp/sage-9.6-current/local/var/lib/sage/venv-python3.10.3/lib/python3.10/site-packages/sage/repl/rich_output/display_manager.py
>  
> in _preferred_text_formatter(self, obj, plain_text, **kwds)
> 550 return out
> 551 if want == 'unicode_art' and OutputUnicodeArt in supported:
> --> 552 out = self._backend.unicode_art_formatter(obj, **kwds)
> 553 if type(out) is not OutputUnicodeArt:
> 554 raise OutputTypeException('backend returned wrong 
> output type, require UnicodeArt')
>
> /private/var/tmp/sage-9.6-current/local/var/lib/sage/venv-python3.10.3/lib/python3.10/site-packages/sage/repl/rich_output/backend_base.py
>  
> in unicode_art_formatter(self, obj, **kwds)
> 425 result = unicode_art(obj)
> 426 from sage.repl.rich_output.output_basic import 
> OutputUnicodeArt
> --> 427 return OutputUnicodeArt(str(result))
> 428 
> 429 def latex_formatter(self, obj, **kwds):
>
> /private/var/tmp/sage-9.6-current/local/var/lib/sage/venv-python3.10.3/lib/python3.10/site-packages/sage/structure/sage_object.pyx
>  
> in sage.structure.sage_object.SageObject.__repr__ 
> (build/cythonized/sage/structure/sage_object.c:2558)()
> 192 except AttributeError:
> 193 return super().__repr__()
> --> 194 result = reprfunc()
> 195 if isinstance(result, str):
> 196 return result
>
> /private/var/tmp/sage-9.6-current/local/var/lib/sage/venv-python3.10.3/lib/python3.10/site-packages/sage/typeset/character_art.py
>  
> in 

[sage-support] Re: PATH in OS X Jupyter notebook

2022-06-24 Thread John H Palmieri
Hi Marc,

Very good question. I think that allowing users to modify the standard 
config files is the right thing to do, but I'm really not sure. I worry 
that the next person will want to modify a different setting, and you don't 
want to get dragged into recreating IPython/Jupyter preferences. For 
debugging, would it be worth providing a warning if a config file is found, 
or if a config file is found with any nonstandard settings? (The default 
config file is entirely commented out.)

By the way, I debugged Samuel's suggestion by running "./sage -n" with a 
local installation: it printed error messages in the terminal where I ran 
it that let me know that something was wrong. I figured out that I had to 
use quotes, as in

  c.InteractiveShellApp.exec_lines = ['import sys; ...']

rather than

  c.InteractiveShellApp.exec_lines = [import sys; ...]

I don't know where to view the corresponding error messages for the OS X 
app.

A question for both of you: I think the standard situation is to not have a 
profile directory, you have to run "sage --ipython profile create". Is 
there a good way to do this instead from a Jupyter notebook? Then someone 
could create a profile directory without having to use the terminal, 
although they would need to use a text editor to modify it.

-- 
John

On Friday, June 24, 2022 at 3:12:52 PM UTC-7 Marc Culler wrote:

> Thank you for figuring that out Samuel.  Now here is a question for both 
> of you.  The macOS app intentionally sets a minimal environment when it 
> starts sage.  It is intentionally minimal because it would be dangerous, in 
> terms of security, but more importantly in terms of the potential for 
> creating hard-to-debug crashes of the app, to simply accept whatever weird 
> stuff the user happens to have in their environment.  The decision to set a 
> specific minimal environment for the app was made after such a crash, which 
> was related to traces of an obsolete Sage installation left in a user's 
> .bashrc file.
>
> But dangerous should not necessarily mean impossible.  It would be 
> feasible to add a preferences panel to the app which could include a PATH 
> string to be appended to the minimal default PATH at startup.  Being forced 
> to type that string into a preferences dialog would at least alert the user 
> to the possibility that the next weird crash might be their own fault.  But 
> Samuel's answer indicates that expert users can actually do this using a 
> completely orthogonal preferences setting (one of millions, I suspect) 
> namely editing an IPython config file hidden in the user's .sage 
> directory.  His answer shows that it is not impossible, just difficult.
>
> My question is whether Samuel's approach is better than providing a simple 
> way to modify the PATH, and thereby inviing an unsophisticated user to make 
> a big mess which could cripple the app.  The esoteric knowledge needed to 
> find and edit that config file provides a pretty good filter for ensuring 
> that people who do this know what they are doing, or at least know that 
> they are responsible for the consequences of making a mistake while doing 
> it.  Also, it is unclear to me how many users would actually want to use 
> such a feature.  Adding features that almost no one needs is not my idea of 
> a good design approach.
>
> What do the two of you think?
>
> - Marc
>
> On Friday, June 24, 2022 at 2:08:17 PM UTC-5 John H Palmieri wrote:
>
>> Hi Samuel,
>>
>> Thank you for this. One thing: I made a mistake in my comments on 
>> ask.sagemath.org. Changing sys.path changes the Python path, not the 
>> path for executables. One option is to use
>>
>> import os; os.environ["PATH"] += ":/usr/local/bin"
>>
>> Any better ways to do this? Your pointer on how to include this into 
>> IPython config files works, as long as the lines are in quotes:
>>
>> c.InteractiveShellApp.exec_lines = [
>> 'import os; os.environ["PATH"] += ":/usr/local/bin" ']
>>
>>
>>
>> On Friday, June 24, 2022 at 10:09:39 AM UTC-7 slelievre wrote:
>>
>>> 2022-06-22 16:37:11 UTC, John H Palmieri:
>>> >
>>> > How do I set the PATH in the OS X Jupyter notebook,
>>> > if I'm using the 3-manifolds binary app? I mean, I know
>>> > how to do it in an individual notebook, but how do I set
>>> > the default PATH for every notebook? For example,
>>> > how do I add /usr/local/bin so that it's in the PATH
>>> > every time I open a new notebook?
>>>
>>> Hi John,
>>>
>>> Good job with your comments at
>>>
>>> - Ask Sage question 62873
>>>   https://ask.sagemath.org/question/628

[sage-support] Re: PATH in OS X Jupyter notebook

2022-06-24 Thread John H Palmieri
Hi Samuel,

Thank you for this. One thing: I made a mistake in my comments on 
ask.sagemath.org. Changing sys.path changes the Python path, not the path 
for executables. One option is to use

import os; os.environ["PATH"] += ":/usr/local/bin"

Any better ways to do this? Your pointer on how to include this into 
IPython config files works, as long as the lines are in quotes:

c.InteractiveShellApp.exec_lines = [
'import os; os.environ["PATH"] += ":/usr/local/bin" ']



On Friday, June 24, 2022 at 10:09:39 AM UTC-7 slelievre wrote:

> 2022-06-22 16:37:11 UTC, John H Palmieri:
> >
> > How do I set the PATH in the OS X Jupyter notebook,
> > if I'm using the 3-manifolds binary app? I mean, I know
> > how to do it in an individual notebook, but how do I set
> > the default PATH for every notebook? For example,
> > how do I add /usr/local/bin so that it's in the PATH
> > every time I open a new notebook?
>
> Hi John,
>
> Good job with your comments at
>
> - Ask Sage question 62873
>   https://ask.sagemath.org/question/62873
>   Animating plots in Jupyter/Sagemath
>
> Here is a possibility for the missing bit, after reading
>
> - discussion at [Stack Overflow question 34976803](
> https://stackoverflow.com/q/34976803)
> - [Lucy Park: When Python imports but IPython does not](
> https://www.lucypark.kr/blog/2013/02/10/when-python-imports-and-ipython-does-not/
> )
>
> To define some code to be run at the start of each
> Sage session, and/or each time the Sage Jupyter
> kernel starts, edit one or both of the files
>
> - `$HOME/.sage/ipython-5.0.0/profile_default/ipython_config.py`
> - `$HOME/.sage/ipython-5.0.0/profile_default/ipython_kernel_config.py`
>
> in which you should find a section like this:
>
> ## lines of code to run at IPython startup.
> #  Default: []
> # c.InteractiveShellApp.exec_lines = []
>
> Uncomment the last line in that section and add
> any code to run. For example:
>
> ## lines of code to run at IPython startup.
> #  Default: []
> c.InteractiveShellApp.exec_lines = [
> import sys; sys.path.append('/usr/local/bin')
> ]
>  
> Feel free to consolidate your comments and this idea
> into an answer to the Ask Sage question.   --Samuel
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/b25491b0-c599-46cf-99d2-02627b368104n%40googlegroups.com.


[sage-support] PATH in OS X Jupyter notebook

2022-06-22 Thread John H Palmieri
How do I set the PATH in the OS X Jupyter notebook, if I'm using the 
3-manifolds binary app? I mean, I know how to do it in an individual 
notebook, but how do I set the default PATH for every notebook? For 
example, how do I add /usr/local/bin so that it's in the PATH every time I 
open a new notebook?

(See 
https://ask.sagemath.org/question/62873/animating-plots-in-jupytersagemath/.)

-- 
John

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/ffd2ef6b-74df-4c87-ac81-9cfab215cec7n%40googlegroups.com.


Re: [sage-support] Re: Crystals won't view in jupiter notebook

2022-06-04 Thread John H Palmieri
Can you please post that LaTeX file? I get a file which is missing 
"\usepackage{tkz-graph}" and hence fails to compile. If I add that line, it 
produces the same LaTeX error that I've been seeing all along.

And yes, the LaTeX file is hidden — it's temporary and is removed when Sage 
quits. You don't want to produce permanent LaTeX and PDF files every time 
you run a "view" command, so these are temporary by design. 

On Saturday, June 4, 2022 at 10:38:07 AM UTC-7 raymond@gmail.com wrote:

> Well, I found a usable .tex file :)  My interpretation is that the "real" 
> .tex file is hidden.  Presumably that can be fixed?
> Code:
> -
>
>
> B = crystals.Tableaux(['A',2], shape=[2,1])
> G = B.digraph()
>
> fn = tmp_filename(ext='.tex')
> B.latex_file(fn)
> #show(B.latex_file)
> view(G)
> print(B)
> print(G)
> -
> fn
> -
>
> '/home/rrogers/.sage/temp/rrogers-desktop/103238/tmp_j8izjh3_.tex'
> --
> ~/.sage/temp/rrogers-desktop/103238: pdflatex tmp_j*texq
> blah...blah
> output written on tmp_j8izjh3_.pdf (1 page, 11580 bytes)
> --
> Which displays; although it's not horribly happy :)   (But latex is seldom 
> 'horribly happy' in my experience)
> --
>
>
> On 6/4/22 12:37, John H Palmieri wrote:
>
> For any Sage object, the code for "view" first constructs a LaTeX version 
> and then runs pdflatex (or similar) on it. For crystals, the code to 
> produce the LaTeX is this:
>
> G = self.digraph()
> G.set_latex_options(**options)
> return G._latex_()
>
> (from sage.categories.crystals). So view(B) converts B to a digraph and 
> then turns that into LaTeX. So it's essentially equivalent to your 
> suggestion:
>
> B = crystals.Tableaux(...)
> G = B.digraph()
> view(G)
>
> I see the same error with either view(B) or view(G) at this point. I can 
> get a picture using "G.plot()" or "B.plot()", but it's not coming from 
> LaTeX.
>
> On Saturday, June 4, 2022 at 5:49:19 AM UTC-7 raymond@gmail.com wrote:
>
>> I think I have it; "view" expects  a "digraph"  not a "crystal"
>> Try
>> -
>> #%%Latex
>>
>>
>> B = crystals.Tableaux(['A',2], shape=[2,1])
>> G = B.digraph()
>>
>> view(G)
>> print(B)
>> print(G)
>> ---
>>
>> Returns popup graph and inpage text
>> -
>> The crystal of tableaux of type ['A', 2] and shape(s) [[2, 1]]
>> Digraph on 8 vertices
>> -
>> Although there is a Latex (digraph ?) error 
>> Try
>> -
>> %%latex
>>
>>
>> B = crystals.Tableaux(['A',2], shape=[2,1])
>> G = B.digraph()
>>
>> view(G)
>> print(B)
>> print(G)
>> --
>>
>> Gives inpage; and nothing else
>> --B = crystals.Tableaux(['A',2], shape=[2,1]) G = B.digraph() view(G) 
>> print(B) print(G)
>> -
>>
>> rrogers
>>
>>
>>
>>
>>
>> On 6/4/22 00:03, John H Palmieri wrote:
>>
>> Here is a workaround, or at least it works for me. The LaTeX code for the 
>> labels seems to be the issue.
>>
>> sage: B = crystals.Tableaux(['A',2], shape=[2,1])
>> sage: G = B.digraph()
>> sage: G.set_latex_options(vertex_labels_math=False)
>> sage: view(G)
>>
>> On Thursday, June 2, 2022 at 4:06:26 PM UTC-7 John H Palmieri wrote:
>>
>>> I've opened https://trac.sagemath.org/ticket/33947 to trac this problem.
>>>
>>> On Thursday, June 2, 2022 at 3:30:49 PM UTC-7 John H Palmieri wrote:
>>>
>>>> For me, `show(G)` works, but not `view(G)`. `show(G)` does not use 
>>>> LaTeX, and the problem is the LaTeX code produced by `view(G)`. You can 
>>>> also see that code with `latex(G)` or `latex(B)`.
>>>>
>>>> I'm not sure what you're referring to in your first sentence, "Well, 
>>>> that didn't work for me."
>>>>
>>>> On Thursday, June 2, 2022 at 2:11:33 PM UTC-7 raymond@gmail.com 
>>>> wrote:
>>>>
>>>>> Well, that didn't work for me.
>>>>> But changing "view" to "show" produced a script that I can tell is 
>>>>> targeted for something, not pdflatex.  Let me know if you know; maybe 
>>>>> graphviz converter?  Loading doc2tex didn't help.
>>>>> Anyhow,  here is a "hack" that pops a popup that is correct.  A 
>>>>> wrapper could be built around it.
>>>>>
>>>>> B = crystals.Tableaux(['A',2], s

Re: [sage-support] Re: Crystals won't view in jupiter notebook

2022-06-04 Thread John H Palmieri
For any Sage object, the code for "view" first constructs a LaTeX version 
and then runs pdflatex (or similar) on it. For crystals, the code to 
produce the LaTeX is this:

G = self.digraph()
G.set_latex_options(**options)
return G._latex_()

(from sage.categories.crystals). So view(B) converts B to a digraph and 
then turns that into LaTeX. So it's essentially equivalent to your 
suggestion:

B = crystals.Tableaux(...)
G = B.digraph()
view(G)

I see the same error with either view(B) or view(G) at this point. I can 
get a picture using "G.plot()" or "B.plot()", but it's not coming from 
LaTeX.

On Saturday, June 4, 2022 at 5:49:19 AM UTC-7 raymond@gmail.com wrote:

> I think I have it; "view" expects  a "digraph"  not a "crystal"
> Try
> -
> #%%Latex
>
>
> B = crystals.Tableaux(['A',2], shape=[2,1])
> G = B.digraph()
>
> view(G)
> print(B)
> print(G)
> ---
>
> Returns popup graph and inpage text
> -
> The crystal of tableaux of type ['A', 2] and shape(s) [[2, 1]]
> Digraph on 8 vertices
> -
> Although there is a Latex (digraph ?) error 
> Try
> -
> %%latex
>
>
> B = crystals.Tableaux(['A',2], shape=[2,1])
> G = B.digraph()
>
> view(G)
> print(B)
> print(G)
> --
>
> Gives inpage; and nothing else
> --B = crystals.Tableaux(['A',2], shape=[2,1]) G = B.digraph() view(G) 
> print(B) print(G)
> -
>
> rrogers
>
>
>
>
>
> On 6/4/22 00:03, John H Palmieri wrote:
>
> Here is a workaround, or at least it works for me. The LaTeX code for the 
> labels seems to be the issue.
>
> sage: B = crystals.Tableaux(['A',2], shape=[2,1])
> sage: G = B.digraph()
> sage: G.set_latex_options(vertex_labels_math=False)
> sage: view(G)
>
> On Thursday, June 2, 2022 at 4:06:26 PM UTC-7 John H Palmieri wrote:
>
>> I've opened https://trac.sagemath.org/ticket/33947 to trac this problem.
>>
>> On Thursday, June 2, 2022 at 3:30:49 PM UTC-7 John H Palmieri wrote:
>>
>>> For me, `show(G)` works, but not `view(G)`. `show(G)` does not use 
>>> LaTeX, and the problem is the LaTeX code produced by `view(G)`. You can 
>>> also see that code with `latex(G)` or `latex(B)`.
>>>
>>> I'm not sure what you're referring to in your first sentence, "Well, 
>>> that didn't work for me."
>>>
>>> On Thursday, June 2, 2022 at 2:11:33 PM UTC-7 raymond@gmail.com 
>>> wrote:
>>>
>>>> Well, that didn't work for me.
>>>> But changing "view" to "show" produced a script that I can tell is 
>>>> targeted for something, not pdflatex.  Let me know if you know; maybe 
>>>> graphviz converter?  Loading doc2tex didn't help.
>>>> Anyhow,  here is a "hack" that pops a popup that is correct.  A wrapper 
>>>> could be built around it.
>>>>
>>>> B = crystals.Tableaux(['A',2], shape=[2,1])
>>>> G = B.digraph()
>>>> G.set_latex_options(color_by_label = {1:"red", 2:"yellow"})
>>>> view(G, tightpage=True) # optional - dot2tex graphviz, not tested 
>>>> (opens external window)
>>>>
>>>> This is from: 
>>>> https://doc.sagemath.org/html/en/thematic_tutorials/lie/crystals.html.
>>>> The file is labeled sage.pdf, but is hidden.  Since the PDF viewer is 
>>>> popped, you can save it where you want; manually.
>>>>
>>>> I am sure that 
>>>> https://doc.sagemath.org/html/en/reference/graphs/sage/graphs/generic_graph.html
>>>> has the key to saving the .PDF programmatically where you want; but I 
>>>> am going cross-eyed.
>>>>
>>>> rrogers
>>>> On 6/2/22 13:01, John H Palmieri wrote:
>>>>
>>>> It's bad LaTeX, but I'm not sure what's producing it. If you run 
>>>> "view(crystals.Tableaux("A3",shape=[2,1]), debug=True)", then it will 
>>>> first 
>>>> print the LaTeX code, and if you paste that into a file, it will fail to 
>>>> compile.
>>>>
>>>> On Thursday, June 2, 2022 at 6:42:51 AM UTC-7 HG wrote:
>>>>
>>>>> Some time ago, on the list they said it's better to keep to sage-9.2, 
>>>>> at least I changed 9.3 to 9.2 because latex didn't work.
>>>>> Le 02/06/2022 à 14:08, Eric Gourgoulhon a écrit :
>>>>>
>>>>> I got the same error from the console of Sage 9.7.beta1 running on 
>>>>> Ubuntu 20.04. 
>>>&g

Re: [sage-support] Re: Crystals won't view in jupiter notebook

2022-06-03 Thread John H Palmieri
Here is a workaround, or at least it works for me. The LaTeX code for the 
labels seems to be the issue.

sage: B = crystals.Tableaux(['A',2], shape=[2,1])
sage: G = B.digraph()
sage: G.set_latex_options(vertex_labels_math=False)
sage: view(G)

On Thursday, June 2, 2022 at 4:06:26 PM UTC-7 John H Palmieri wrote:

> I've opened https://trac.sagemath.org/ticket/33947 to trac this problem.
>
> On Thursday, June 2, 2022 at 3:30:49 PM UTC-7 John H Palmieri wrote:
>
>> For me, `show(G)` works, but not `view(G)`. `show(G)` does not use LaTeX, 
>> and the problem is the LaTeX code produced by `view(G)`. You can also see 
>> that code with `latex(G)` or `latex(B)`.
>>
>> I'm not sure what you're referring to in your first sentence, "Well, that 
>> didn't work for me."
>>
>> On Thursday, June 2, 2022 at 2:11:33 PM UTC-7 raymond@gmail.com 
>> wrote:
>>
>>> Well, that didn't work for me.
>>> But changing "view" to "show" produced a script that I can tell is 
>>> targeted for something, not pdflatex.  Let me know if you know; maybe 
>>> graphviz converter?  Loading doc2tex didn't help.
>>> Anyhow,  here is a "hack" that pops a popup that is correct.  A wrapper 
>>> could be built around it.
>>>
>>> B = crystals.Tableaux(['A',2], shape=[2,1])
>>> G = B.digraph()
>>> G.set_latex_options(color_by_label = {1:"red", 2:"yellow"})
>>> view(G, tightpage=True) # optional - dot2tex graphviz, not tested (opens 
>>> external window)
>>>
>>> This is from: 
>>> https://doc.sagemath.org/html/en/thematic_tutorials/lie/crystals.html.
>>> The file is labeled sage.pdf, but is hidden.  Since the PDF viewer is 
>>> popped, you can save it where you want; manually.
>>>
>>> I am sure that 
>>> https://doc.sagemath.org/html/en/reference/graphs/sage/graphs/generic_graph.html
>>> has the key to saving the .PDF programmatically where you want; but I am 
>>> going cross-eyed.
>>>
>>> rrogers
>>> On 6/2/22 13:01, John H Palmieri wrote:
>>>
>>> It's bad LaTeX, but I'm not sure what's producing it. If you run 
>>> "view(crystals.Tableaux("A3",shape=[2,1]), debug=True)", then it will first 
>>> print the LaTeX code, and if you paste that into a file, it will fail to 
>>> compile.
>>>
>>> On Thursday, June 2, 2022 at 6:42:51 AM UTC-7 HG wrote:
>>>
>>>> Some time ago, on the list they said it's better to keep to sage-9.2, 
>>>> at least I changed 9.3 to 9.2 because latex didn't work.
>>>> Le 02/06/2022 à 14:08, Eric Gourgoulhon a écrit :
>>>>
>>>> I got the same error from the console of Sage 9.7.beta1 running on 
>>>> Ubuntu 20.04. 
>>>> So it is not specific to Sage 9.3, nor to Windows...
>>>>
>>>>
>>>>
>>>> Le mercredi 1 juin 2022 à 23:00:05 UTC+2, dbis...@gmail.com a écrit :
>>>>
>>>> I have installed Sagemath 9.3 on my windows 10 computer and have run 
>>>>> the following code: 
>>>>> view(crystals.Tableaux("A3",shape=[2,1]))
>>>>>
>>>>> I end up getting this long error: 
>>>>>
>>>>> An error occurred. This is pdfTeX, Version 3.141592653-2.6-1.40.24 
>>>>> (MiKTeX 22.3) (preloaded format=pdflatex 2022.6.1) 1 JUN 2022 21:54 
>>>>> entering extended mode restricted \write18 enabled. %&-line parsing 
>>>>> enabled. **\nonstopmode \input{sage.tex} (sage.tex 
>>>>> (C:\Users\dbisa\AppData\Local\Programs\MiKTeX\tex/latex/base\article.cls 
>>>>> Document Class: article 2021/10/04 v1.4n Standard LaTeX document class 
>>>>> (C:\Users\dbisa\AppData\Local\Programs\MiKTeX\tex/latex/base\size10.clo 
>>>>> File: size10.clo 2021/10/04 v1.4n Standard LaTeX file (size option) ) 
>>>>> \c@part=\count185 \c@section=\count186 \c@subsection=\count187 
>>>>> \c@subsubsection=\count188 \c@paragraph=\count189 
>>>>> \c@subparagraph=\count190 
>>>>> \c@figure=\count191 \c@table=\count192 \abovecaptionskip=\skip47 
>>>>> \belowcaptionskip=\skip48 \bibindent=\dimen138 ) 
>>>>> (C:\Users\dbisa\AppData\Local\Programs\MiKTeX\tex/latex/amsmath\amsmath.sty
>>>>>  
>>>>> Package: amsmath 2021/10/15 v2.17l AMS math features \@mathmargin=\skip49 
>>>>> For additional information on amsmath, use the `?' option. 
>>>>> (C:\Users\

Re: [sage-support] Re: Crystals won't view in jupiter notebook

2022-06-02 Thread John H Palmieri
I've opened https://trac.sagemath.org/ticket/33947 to trac this problem.

On Thursday, June 2, 2022 at 3:30:49 PM UTC-7 John H Palmieri wrote:

> For me, `show(G)` works, but not `view(G)`. `show(G)` does not use LaTeX, 
> and the problem is the LaTeX code produced by `view(G)`. You can also see 
> that code with `latex(G)` or `latex(B)`.
>
> I'm not sure what you're referring to in your first sentence, "Well, that 
> didn't work for me."
>
> On Thursday, June 2, 2022 at 2:11:33 PM UTC-7 raymond@gmail.com wrote:
>
>> Well, that didn't work for me.
>> But changing "view" to "show" produced a script that I can tell is 
>> targeted for something, not pdflatex.  Let me know if you know; maybe 
>> graphviz converter?  Loading doc2tex didn't help.
>> Anyhow,  here is a "hack" that pops a popup that is correct.  A wrapper 
>> could be built around it.
>>
>> B = crystals.Tableaux(['A',2], shape=[2,1])
>> G = B.digraph()
>> G.set_latex_options(color_by_label = {1:"red", 2:"yellow"})
>> view(G, tightpage=True) # optional - dot2tex graphviz, not tested (opens 
>> external window)
>>
>> This is from: 
>> https://doc.sagemath.org/html/en/thematic_tutorials/lie/crystals.html.
>> The file is labeled sage.pdf, but is hidden.  Since the PDF viewer is 
>> popped, you can save it where you want; manually.
>>
>> I am sure that 
>> https://doc.sagemath.org/html/en/reference/graphs/sage/graphs/generic_graph.html
>> has the key to saving the .PDF programmatically where you want; but I am 
>> going cross-eyed.
>>
>> rrogers
>> On 6/2/22 13:01, John H Palmieri wrote:
>>
>> It's bad LaTeX, but I'm not sure what's producing it. If you run 
>> "view(crystals.Tableaux("A3",shape=[2,1]), debug=True)", then it will first 
>> print the LaTeX code, and if you paste that into a file, it will fail to 
>> compile.
>>
>> On Thursday, June 2, 2022 at 6:42:51 AM UTC-7 HG wrote:
>>
>>> Some time ago, on the list they said it's better to keep to sage-9.2, at 
>>> least I changed 9.3 to 9.2 because latex didn't work.
>>> Le 02/06/2022 à 14:08, Eric Gourgoulhon a écrit :
>>>
>>> I got the same error from the console of Sage 9.7.beta1 running on 
>>> Ubuntu 20.04. 
>>> So it is not specific to Sage 9.3, nor to Windows...
>>>
>>>
>>>
>>> Le mercredi 1 juin 2022 à 23:00:05 UTC+2, dbis...@gmail.com a écrit :
>>>
>>> I have installed Sagemath 9.3 on my windows 10 computer and have run the 
>>>> following code: 
>>>> view(crystals.Tableaux("A3",shape=[2,1]))
>>>>
>>>> I end up getting this long error: 
>>>>
>>>> An error occurred. This is pdfTeX, Version 3.141592653-2.6-1.40.24 
>>>> (MiKTeX 22.3) (preloaded format=pdflatex 2022.6.1) 1 JUN 2022 21:54 
>>>> entering extended mode restricted \write18 enabled. %&-line parsing 
>>>> enabled. **\nonstopmode \input{sage.tex} (sage.tex 
>>>> (C:\Users\dbisa\AppData\Local\Programs\MiKTeX\tex/latex/base\article.cls 
>>>> Document Class: article 2021/10/04 v1.4n Standard LaTeX document class 
>>>> (C:\Users\dbisa\AppData\Local\Programs\MiKTeX\tex/latex/base\size10.clo 
>>>> File: size10.clo 2021/10/04 v1.4n Standard LaTeX file (size option) ) 
>>>> \c@part=\count185 \c@section=\count186 \c@subsection=\count187 
>>>> \c@subsubsection=\count188 \c@paragraph=\count189 
>>>> \c@subparagraph=\count190 
>>>> \c@figure=\count191 \c@table=\count192 \abovecaptionskip=\skip47 
>>>> \belowcaptionskip=\skip48 \bibindent=\dimen138 ) 
>>>> (C:\Users\dbisa\AppData\Local\Programs\MiKTeX\tex/latex/amsmath\amsmath.sty
>>>>  
>>>> Package: amsmath 2021/10/15 v2.17l AMS math features \@mathmargin=\skip49 
>>>> For additional information on amsmath, use the `?' option. 
>>>> (C:\Users\dbisa\AppData\Local\Programs\MiKTeX\tex/latex/amsmath\amstext.sty
>>>>  
>>>> Package: amstext 2021/08/26 v2.01 AMS text 
>>>> (C:\Users\dbisa\AppData\Local\Programs\MiKTeX\tex/latex/amsmath\amsgen.sty 
>>>> File: amsgen.sty 1999/11/30 v2.0 generic functions \@emptytoks=\toks16 
>>>> \ex@=\dimen139 )) 
>>>> (C:\Users\dbisa\AppData\Local\Programs\MiKTeX\tex/latex/amsmath\amsbsy.sty 
>>>> Package: amsbsy 1999/11/29 v1.2d Bold Symbols \pmbraise@=\dimen140 ) 
>>>> (C:\Users\dbisa\AppData\Local\Programs\MiKTeX\tex/latex/amsmath\amsopn.sty 
>>>&g

Re: [sage-support] Re: Crystals won't view in jupiter notebook

2022-06-02 Thread John H Palmieri
For me, `show(G)` works, but not `view(G)`. `show(G)` does not use LaTeX, 
and the problem is the LaTeX code produced by `view(G)`. You can also see 
that code with `latex(G)` or `latex(B)`.

I'm not sure what you're referring to in your first sentence, "Well, that 
didn't work for me."

On Thursday, June 2, 2022 at 2:11:33 PM UTC-7 raymond@gmail.com wrote:

> Well, that didn't work for me.
> But changing "view" to "show" produced a script that I can tell is 
> targeted for something, not pdflatex.  Let me know if you know; maybe 
> graphviz converter?  Loading doc2tex didn't help.
> Anyhow,  here is a "hack" that pops a popup that is correct.  A wrapper 
> could be built around it.
>
> B = crystals.Tableaux(['A',2], shape=[2,1])
> G = B.digraph()
> G.set_latex_options(color_by_label = {1:"red", 2:"yellow"})
> view(G, tightpage=True) # optional - dot2tex graphviz, not tested (opens 
> external window)
>
> This is from: 
> https://doc.sagemath.org/html/en/thematic_tutorials/lie/crystals.html.
> The file is labeled sage.pdf, but is hidden.  Since the PDF viewer is 
> popped, you can save it where you want; manually.
>
> I am sure that 
> https://doc.sagemath.org/html/en/reference/graphs/sage/graphs/generic_graph.html
> has the key to saving the .PDF programmatically where you want; but I am 
> going cross-eyed.
>
> rrogers
> On 6/2/22 13:01, John H Palmieri wrote:
>
> It's bad LaTeX, but I'm not sure what's producing it. If you run 
> "view(crystals.Tableaux("A3",shape=[2,1]), debug=True)", then it will first 
> print the LaTeX code, and if you paste that into a file, it will fail to 
> compile.
>
> On Thursday, June 2, 2022 at 6:42:51 AM UTC-7 HG wrote:
>
>> Some time ago, on the list they said it's better to keep to sage-9.2, at 
>> least I changed 9.3 to 9.2 because latex didn't work.
>> Le 02/06/2022 à 14:08, Eric Gourgoulhon a écrit :
>>
>> I got the same error from the console of Sage 9.7.beta1 running on Ubuntu 
>> 20.04. 
>> So it is not specific to Sage 9.3, nor to Windows...
>>
>>
>>
>> Le mercredi 1 juin 2022 à 23:00:05 UTC+2, dbis...@gmail.com a écrit :
>>
>> I have installed Sagemath 9.3 on my windows 10 computer and have run the 
>>> following code: 
>>> view(crystals.Tableaux("A3",shape=[2,1]))
>>>
>>> I end up getting this long error: 
>>>
>>> An error occurred. This is pdfTeX, Version 3.141592653-2.6-1.40.24 
>>> (MiKTeX 22.3) (preloaded format=pdflatex 2022.6.1) 1 JUN 2022 21:54 
>>> entering extended mode restricted \write18 enabled. %&-line parsing 
>>> enabled. **\nonstopmode \input{sage.tex} (sage.tex 
>>> (C:\Users\dbisa\AppData\Local\Programs\MiKTeX\tex/latex/base\article.cls 
>>> Document Class: article 2021/10/04 v1.4n Standard LaTeX document class 
>>> (C:\Users\dbisa\AppData\Local\Programs\MiKTeX\tex/latex/base\size10.clo 
>>> File: size10.clo 2021/10/04 v1.4n Standard LaTeX file (size option) ) 
>>> \c@part=\count185 \c@section=\count186 \c@subsection=\count187 
>>> \c@subsubsection=\count188 \c@paragraph=\count189 \c@subparagraph=\count190 
>>> \c@figure=\count191 \c@table=\count192 \abovecaptionskip=\skip47 
>>> \belowcaptionskip=\skip48 \bibindent=\dimen138 ) 
>>> (C:\Users\dbisa\AppData\Local\Programs\MiKTeX\tex/latex/amsmath\amsmath.sty 
>>> Package: amsmath 2021/10/15 v2.17l AMS math features \@mathmargin=\skip49 
>>> For additional information on amsmath, use the `?' option. 
>>> (C:\Users\dbisa\AppData\Local\Programs\MiKTeX\tex/latex/amsmath\amstext.sty 
>>> Package: amstext 2021/08/26 v2.01 AMS text 
>>> (C:\Users\dbisa\AppData\Local\Programs\MiKTeX\tex/latex/amsmath\amsgen.sty 
>>> File: amsgen.sty 1999/11/30 v2.0 generic functions \@emptytoks=\toks16 
>>> \ex@=\dimen139 )) 
>>> (C:\Users\dbisa\AppData\Local\Programs\MiKTeX\tex/latex/amsmath\amsbsy.sty 
>>> Package: amsbsy 1999/11/29 v1.2d Bold Symbols \pmbraise@=\dimen140 ) 
>>> (C:\Users\dbisa\AppData\Local\Programs\MiKTeX\tex/latex/amsmath\amsopn.sty 
>>> Package: amsopn 2021/08/26 v2.02 operator names ) \inf@bad=\count193 LaTeX 
>>> Info: Redefining \frac on input line 234. \uproot@=\count194 
>>> \leftroot@=\count195 LaTeX Info: Redefining \overline on input line 399. 
>>> \classnum@=\count196 \DOTSCASE@=\count197 LaTeX Info: Redefining \ldots on 
>>> input line 496. LaTeX Info: Redefining \dots on input line 499. LaTeX Info: 
>>> Redefining \cdots on input line 620. \Mathstrutbox@=\box50 
>>> \strutbox@=\box51 \big@size=\dimen141

Re: [sage-support] Re: Crystals won't view in jupiter notebook

2022-06-02 Thread John H Palmieri
It's bad LaTeX, but I'm not sure what's producing it. If you run 
"view(crystals.Tableaux("A3",shape=[2,1]), debug=True)", then it will first 
print the LaTeX code, and if you paste that into a file, it will fail to 
compile.

On Thursday, June 2, 2022 at 6:42:51 AM UTC-7 HG wrote:

> Some time ago, on the list they said it's better to keep to sage-9.2, at 
> least I changed 9.3 to 9.2 because latex didn't work.
> Le 02/06/2022 à 14:08, Eric Gourgoulhon a écrit :
>
> I got the same error from the console of Sage 9.7.beta1 running on Ubuntu 
> 20.04. 
> So it is not specific to Sage 9.3, nor to Windows...
>
>
>
> Le mercredi 1 juin 2022 à 23:00:05 UTC+2, dbis...@gmail.com a écrit :
>
> I have installed Sagemath 9.3 on my windows 10 computer and have run the 
>> following code: 
>> view(crystals.Tableaux("A3",shape=[2,1]))
>>
>> I end up getting this long error: 
>>
>> An error occurred. This is pdfTeX, Version 3.141592653-2.6-1.40.24 
>> (MiKTeX 22.3) (preloaded format=pdflatex 2022.6.1) 1 JUN 2022 21:54 
>> entering extended mode restricted \write18 enabled. %&-line parsing 
>> enabled. **\nonstopmode \input{sage.tex} (sage.tex 
>> (C:\Users\dbisa\AppData\Local\Programs\MiKTeX\tex/latex/base\article.cls 
>> Document Class: article 2021/10/04 v1.4n Standard LaTeX document class 
>> (C:\Users\dbisa\AppData\Local\Programs\MiKTeX\tex/latex/base\size10.clo 
>> File: size10.clo 2021/10/04 v1.4n Standard LaTeX file (size option) ) 
>> \c@part=\count185 \c@section=\count186 \c@subsection=\count187 
>> \c@subsubsection=\count188 \c@paragraph=\count189 \c@subparagraph=\count190 
>> \c@figure=\count191 \c@table=\count192 \abovecaptionskip=\skip47 
>> \belowcaptionskip=\skip48 \bibindent=\dimen138 ) 
>> (C:\Users\dbisa\AppData\Local\Programs\MiKTeX\tex/latex/amsmath\amsmath.sty 
>> Package: amsmath 2021/10/15 v2.17l AMS math features \@mathmargin=\skip49 
>> For additional information on amsmath, use the `?' option. 
>> (C:\Users\dbisa\AppData\Local\Programs\MiKTeX\tex/latex/amsmath\amstext.sty 
>> Package: amstext 2021/08/26 v2.01 AMS text 
>> (C:\Users\dbisa\AppData\Local\Programs\MiKTeX\tex/latex/amsmath\amsgen.sty 
>> File: amsgen.sty 1999/11/30 v2.0 generic functions \@emptytoks=\toks16 
>> \ex@=\dimen139 )) 
>> (C:\Users\dbisa\AppData\Local\Programs\MiKTeX\tex/latex/amsmath\amsbsy.sty 
>> Package: amsbsy 1999/11/29 v1.2d Bold Symbols \pmbraise@=\dimen140 ) 
>> (C:\Users\dbisa\AppData\Local\Programs\MiKTeX\tex/latex/amsmath\amsopn.sty 
>> Package: amsopn 2021/08/26 v2.02 operator names ) \inf@bad=\count193 LaTeX 
>> Info: Redefining \frac on input line 234. \uproot@=\count194 
>> \leftroot@=\count195 LaTeX Info: Redefining \overline on input line 399. 
>> \classnum@=\count196 \DOTSCASE@=\count197 LaTeX Info: Redefining \ldots on 
>> input line 496. LaTeX Info: Redefining \dots on input line 499. LaTeX Info: 
>> Redefining \cdots on input line 620. \Mathstrutbox@=\box50 
>> \strutbox@=\box51 \big@size=\dimen141 LaTeX Font Info: Redeclaring font 
>> encoding OML on input line 743. LaTeX Font Info: Redeclaring font encoding 
>> OMS on input line 744. \macc@depth=\count198 \c@MaxMatrixCols=\count199 
>> \dotsspace@=\muskip16 \c@parentequation=\count266 \dspbrk@lvl=\count267 
>> \tag@help=\toks17 \row@=\count268 \column@=\count269 \maxfields@=\count270 
>> \andhelp@=\toks18 \eqnshift@=\dimen142 \alignsep@=\dimen143 
>> \tagshift@=\dimen144 \tagwidth@=\dimen145 \totwidth@=\dimen146 
>> \lineht@=\dimen147 \@envbody=\toks19 \multlinegap=\skip50 
>> \multlinetaggap=\skip51 \mathdisplay@stack=\toks20 LaTeX Info: Redefining 
>> \[ on input line 2938. LaTeX Info: Redefining \] on input line 2939. ) 
>> (C:\Users\dbisa\AppData\Local\Programs\MiKTeX\tex/latex/amsfonts\amssymb.sty 
>> Package: amssymb 2013/01/14 v3.01 AMS font symbols 
>> (C:\Users\dbisa\AppData\Local\Programs\MiKTeX\tex/latex/amsfonts\amsfonts.sty
>>  
>> Package: amsfonts 2013/01/14 v3.01 Basic AMSFonts support 
>> \symAMSa=\mathgroup4 \symAMSb=\mathgroup5 LaTeX Font Info: Redeclaring math 
>> symbol \hbar on input line 98. LaTeX Font Info: Overwriting math alphabet 
>> `\mathfrak' in version `bold' (Font) U/euf/m/n --> U/euf/b/n on input line 
>> 106. )) (C:\Users\dbisa\AppData\Local\Programs\MiKTeX\tex/latex/graphics\
>> graphicx.st y Package: graphicx 2021/09/16 v1.2d Enhanced LaTeX Graphics 
>> (DPC,SPQR) 
>> (C:\Users\dbisa\AppData\Local\Programs\MiKTeX\tex/latex/graphics\keyval.sty 
>> Package: keyval 2014/10/28 v1.15 key=value parser (DPC) \KV@toks@=\toks21 ) 
>> (C:\Users\dbisa\AppData\Local\Programs\MiKTeX\tex/latex/graphics\graphics.sty
>>  
>> Package: graphics 2021/03/04 v1.4d Standard LaTeX Graphics (DPC,SPQR) 
>> (C:\Users\dbisa\AppData\Local\Programs\MiKTeX\tex/latex/graphics\trig.sty 
>> Package: trig 2021/08/11 v1.11 sin cos tan (DPC) ) 
>> (C:\Users\dbisa\AppData\Local\Programs\MiKTeX\tex/latex/graphics-cfg\graphics.c
>>  
>> fg File: graphics.cfg 2016/06/04 v1.11 sample graphics configuration ) 
>> Package graphics Info: Driver file: 

[sage-support] Re: OS X 12.3 intel: scipy fails to build

2022-03-17 Thread John H Palmieri
"./sage -pip install -U pythran" seems to have worked. I checked Sage's 
pythran log and didn't see anything suspicious, for what that's worth.

On Thursday, March 17, 2022 at 2:34:56 PM UTC-7 Matthias Koeppe wrote:

> It would be worth checking whether "./sage -pip install -U pythran" or 
> "./sage -pip install -U git+https://github.com/serge-sans-paille/pythran; 
> fixes this issue
>
> On Thursday, March 17, 2022 at 2:01:49 PM UTC-7 John H Palmieri wrote:
>
>> Since upgrading to OS X 12.3 a few days ago, along with the corresponding 
>> Xcode and command line tools, I have been unable to build scipy. The end of 
>> the log file says
>>
>>   Building wheel for scipy (pyproject.toml): finished with status 'error'
>>   ERROR: Failed building wheel for scipy
>>
>> A little before that:
>>
>>   
>> /Users/palmieri/Desktop/Sage/sage_builds/TESTING/sage-9.6.beta5/local/var/lib/sage/venv-python3.10.2/lib/python3.10/site-packages/pythran/pythonic/types/str.hpp:417:12:
>>  
>> error: no matching constructor for initialization of 'typename 
>> str::reverse_iterator' (aka 'reverse_iterator<(anonymous 
>> namespace)::pythonic::types::string_iterator>')
>>   return {data->rend()};
>>  ^~
>>
>> Log files attached. I've tried this using all of my installed homebrew 
>> packages and also using (as you can see in config.log) 
>> "--with-system-python3=no", same result either way. Any suggestions?
>>
>> -- 
>> John
>>
>>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/ab5310b6-e8ce-41dd-8b20-0124dd99092dn%40googlegroups.com.


Re: [sage-support] Re: Basic Stats deprecated?

2022-02-28 Thread John H Palmieri
Should there be a small list of functions which we import automatically? 
For example in sage.all we could do: "from numpy import mean, median". It 
seems strange to not have a top-level "mean" or "median" function, given 
all of the other esoteric top-level functions.


On Friday, February 25, 2022 at 10:28:17 PM UTC-8 Matthias Koeppe wrote:

> On Friday, February 25, 2022 at 8:32:39 PM UTC-8 wst...@gmail.com wrote:
>
>> Also, if you want to argue that users should explicitly import 
>> everything...
>
>
> No, that's not what I'm arguing. 
>
> The deprecation of the basic_stats module happened because Sage has 
> nothing to offer in this area;
> it's a module with 5 functions that hasn't seen development since 2009. 
> Underdeveloped modules like this reflect poorly on the rest of Sage.
>
> It's a disservice to learners to offer these facilities of Sage as the 
> standard vocabulary of doing basic stats on the computer.
> They will be better off with virtually any other solution: With the 
> built-in stats module of Python; with Numpy/SciPy; with Pandas; with R.
>
>
>
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/ad50aa77-c5fc-4b6d-8b2b-c364518b83bcn%40googlegroups.com.


[sage-support] Re: Tensor Multiprocessing broken. SageMath 9.5 on Apple Mac OSX 12.1 . SageMath-9.5_x86_64

2022-01-25 Thread John H Palmieri
Are you using OS X? Could this possibly be due to how Python handles 
multiprocessing on OS X vs. other platforms? (See 
https://docs.python.org/3/library/multiprocessing.html#contexts-and-start-methods,
 
in particular the comment "On macOS, the *spawn* start method is now the 
default" and https://bugs.python.org/issue33725.)



On Tuesday, January 25, 2022 at 12:34:07 PM UTC-8 alan_thoma...@yahoo.co.uk 
wrote:

> Process SpawnPoolWorker-1: Traceback (most recent call last): File 
> "/private/var/tmp/sage-9.5-current/local/var/lib/sage/venv-python3.9.9/lib/python3.9/multiprocessing/process.py",
>  
> line 315, in _bootstrap self.run() File 
> "/private/var/tmp/sage-9.5-current/local/var/lib/sage/venv-python3.9.9/lib/python3.9/multiprocessing/process.py",
>  
> line 108, in run self._target(*self._args, **self._kwargs) File 
> "/private/var/tmp/sage-9.5-current/local/var/lib/sage/venv-python3.9.9/lib/python3.9/multiprocessing/pool.py",
>  
> line 114, in worker task = get() File 
> "/private/var/tmp/sage-9.5-current/local/var/lib/sage/venv-python3.9.9/lib/python3.9/multiprocessing/queues.py",
>  
> line 368, in get return _ForkingPickler.loads(res) File 
> "/private/var/tmp/sage-9.5-current/local/var/lib/sage/venv-python3.9.9/lib/python3.9/site-packages/sage/manifolds/differentiable/chart.py",
>  
> line 36, in 
> On Tuesday, January 25, 2022 at 8:13:20 PM UTC egourg...@gmail.com wrote:
>
>> Hi,
>>
>> Le mardi 25 janvier 2022 à 12:54:57 UTC+1, alan_thoma...@yahoo.co.uk a 
>> écrit :
>>
>>> I get errors in this notebook if I set the variable tpar to any value 
>>> greater than one. (Number of Tensor processing cores.)
>>>
>>> *http://alan.atstafford.co.uk/Sage9.5Problem.ipynb 
>>> *
>>>
>>
>> Your notebook works well with tpar=4 on my Ubuntu computer running Sage 
>> 9.5.rc4.
>> What kind of error do you get?
>>
>> Eric.
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/4e5362fc-05b2-48ac-9783-66e6e70d6f21n%40googlegroups.com.


[sage-support] Re: LatexExpr

2021-11-29 Thread John H Palmieri
Or if you need single and double quotes, delimit the string with """ or ''' 
(three double-quotes or three single-quotes):

r"""here is "some" 'text' """

On Monday, November 29, 2021 at 11:07:21 AM UTC-8 slelievre wrote:

> 2021-11-29 18:05:58 UTC+1, Cyrille Piatecki:
> >
> > I often use LatexExpr(r'\text{blabla} x_i =') encapsulated
> > in show(). It's very easy to use but not if I need single quotes
> > as in "it's". Is there a way to escape the quotes?
>
> LatexExpr(r"\text{there's a way} x_i =")
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/ce3ddb95-05d2-46ae-9bfa-e4253527a997n%40googlegroups.com.


Re: [sage-support] Using SageMath app online and saving worksheets?

2021-11-10 Thread John H Palmieri
The default behavior, at least if you start Sage from a terminal window 
with "sage -n", is to store the notebooks in the current directory. If you 
want to change this, then: after you download Sage, from a terminal you 
should run "sage --jupyter notebook --generate-config". This will print a 
message like

Writing default config to: 
/Users/jpalmier/.sage//jupyter-4.1/jupyter_notebook_config.py

Within the named file, there are lines

## The directory to use for notebooks and kernels.
#  Default: ''
# c.NotebookApp.notebook_dir = ''

You can change the last line to

c.NotebookApp.notebook_dir = '/Users/my_user_id/any/directory/I/want/'

and Sage will store your notebooks in that directory.

On Tuesday, November 9, 2021 at 8:34:23 PM UTC-8 cyrille piatecki wrote:

> For Mac I don't know where the system keep the files. I have tried to find 
> it because some of my student use a Mac, but without success. Sorry
>
> --
> *De: *"LouP" 
> *À: *"sage-support" 
> *Envoyé: *Mardi 9 Novembre 2021 23:35:46
> *Objet: *Re: [sage-support] Using SageMath app online and saving 
> worksheets?
>
> Thank you Mr. Piatecki.  I should have mentioned I am using a Mac.  Sorry. 
> But it does sound like the files are local.  -- Lou Pecora
> On Tuesday, November 9, 2021 at 12:48:21 PM UTC-5 cyrille piatecki wrote:
>
>> You can install Sagemath on your computer if you download the good file (
>> https://www.sagemath.org/download.html).
>> Under Windows your files are stored into c:\user\yourname\...
>>
>> --
>> *De: *"LouP" 
>> *À: *"sage-support" 
>> *Envoyé: *Mardi 9 Novembre 2021 14:59:00
>> *Objet: *[sage-support] Using SageMath app online and saving worksheets?
>>
>> After Googling and checking the resources suggested I have not found 
>> answers to two simple questions about SageMath:
>> (1) Can I run this offline?
>> (2) Where are my worksheets stored and can I back them up?
>>
>> Thanks for any hints.
>>
>>  -- Lou Pecora
>>
>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "sage-support" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to sage-support...@googlegroups.com.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/sage-support/4ad6d585-cfda-4336-b7cc-91f3a3fd7b05n%40googlegroups.com
>>  
>> 
>> .
>>
> -- 
> You received this message because you are subscribed to the Google Groups 
> "sage-support" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to sage-support...@googlegroups.com.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/sage-support/cc0827e6-3af8-45ea-8dc9-c06a3b726fb7n%40googlegroups.com
>  
> 
> .
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/76b099ae-6099-4f6f-9fd3-e53c7d21c16en%40googlegroups.com.


Re: [sage-support] Re: trouble displaying 3D graphics

2021-11-09 Thread John H Palmieri
Is there a way for users to redefine SAGE_TMP (without editing Sage source 
code) so that these graphics files would be produced elsewhere?

On Tuesday, November 9, 2021 at 4:06:34 AM UTC-8 dim...@gmail.com wrote:

> Right, one can see more of these "Chromium cannot open hidden 
> files/directories" posts
> elsewhere, cf. e.g.
>
> https://askubuntu.com/questions/1312932/cant-browse-access-hidden-files-and-folders-with-chromium
>
> I don't see a good and quick way out, rather than renaming ~/.sage/ to 
> something without leading '.'.
>
>  
>
>
>
>
> On Tue, Nov 9, 2021 at 10:23 AM Eric Gourgoulhon  
> wrote:
>
>> Le mardi 9 novembre 2021 à 10:38:29 UTC+1, dim...@gmail.com a écrit :
>>
>>> I wonder if 'file:///' must be present in the URL for the script source 
>>> for Chrome/Chromium to load it.
>>>
>>> This does not seem to be an issue with 'file:///' in the URL since 
>> Chromium refuses to open any hidden directory while browsing directories in 
>> the window opened after CTRL+O.  
>>
>> -- 
>>
> You received this message because you are subscribed to the Google Groups 
>> "sage-support" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to sage-support...@googlegroups.com.
>>
> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/sage-support/dd62df2d-4a09-4475-bdf6-62af5a3249e3n%40googlegroups.com
>>  
>> 
>> .
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/616a26f8-ff7c-48a4-be91-7b2ed52e094en%40googlegroups.com.


[sage-support] Re: Sage 9.4_20.04 Ubuntu: error relocate-once.py

2021-09-03 Thread John H Palmieri
Also addressed in https://github.com/sagemath/binary-pkg/pull/29


On Friday, September 3, 2021 at 10:15:02 AM UTC-7 Matthias Koeppe wrote:

> Thanks, I've noted this in 
> https://wiki.sagemath.org/ReleaseTours/sage-9.4#Availability_as_binaries_and_in_distributions
>
> On Friday, September 3, 2021 at 3:02:47 AM UTC-7 Rolandb wrote:
>
>> Hi,
>>
>> Running the file 'relocate-once.py', I got an error: directory 'python' 
>> not recognized.
>> Changing the line #!.. python into #!.. python3 solved the problem.
>>
>> Roland  
>>
>>
>>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/3db75689-efd7-4e45-a59f-c8d2f92fb479n%40googlegroups.com.


Re: [sage-support] Other mailing lists

2021-08-24 Thread John H Palmieri
I believe that most of the traffic these days is on sage-support and 
sage-devel, rather than the more specialized groups. Feel free to post 
questions about Sage's algebra capabilities here.

On Monday, August 23, 2021 at 8:03:33 PM UTC-7 H wrote:

> On August 23, 2021 7:18:16 PM EDT, David Joyner  wrote:
> >On Mon, Aug 23, 2021 at 7:13 PM H  wrote:
> >
> >> I just joined this list a few days ago but also tried to join
> >> sage-algebra, that list however seems dead. The moderator has after
> >almost
> >> a week not approved my membership and the last Google group posting
> >seems
> >> to be from 2018...
> >>
> >> Are there any other mailing lists/groups? I should also mention that
> >the
> >> rss feeds mentioned on the sage site have
> >
> >
> >Some are listed here:
> >https://www.sagemath.org/help-groups.html
> >and others are here
> >https://www.sagemath.org/development-groups.html
> >
> >defective links... Is the software dying or am I missing something?
> >>
> >> --
> >> You received this message because you are subscribed to the Google
> >Groups
> >> "sage-support" group.
> >> To unsubscribe from this group and stop receiving emails from it,
> >send an
> >> email to sage-support...@googlegroups.com.
> >> To view this discussion on the web visit
> >>
> >
> https://groups.google.com/d/msgid/sage-support/FA4ECD7D-AC30-4982-8B7F-A6BEDBF1BD91%40meddatainc.com
> >> .
> >>
>
> Yes, that's the page with the dead sage-algebra group and the non-working 
> rss feeds...
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/bd9058fe-52c9-4096-be88-cedf76cfd6f6n%40googlegroups.com.


[sage-support] Re: loading large file

2021-04-02 Thread John H Palmieri
Another option might have been to preparse separately (using "sage 
-preparse matp11n2.sage" at the shell prompt) and then load the resulting 
Python file.

  John

On Friday, April 2, 2021 at 12:02:38 PM UTC-7 Luis Finotti wrote:

> The solution I found was to increase the recursion limit: I did 
>
> sys.setrecursionlimit(4500)
>
> It was enough for this.
> On Friday, April 2, 2021 at 7:51:42 AM UTC-4 Luis Finotti wrote:
>
>> I produced a very large text file (139MB) containing some input for Sage.
>>
>> The problem is that when I try to load it, I get:
>>
>>
>> sage: load('matp11n2.sage') 
>>
>> --- 
>> RecursionErrorTraceback (most recent call 
>> last) 
>>  in  
>> > 1 load('matp11n2.sage') 
>>
>> ~/src/sage-9.2/local/lib/python3.8/site-packages/sage/misc/persist.pyx 
>> in sage.misc.persist.load (build/cythonized/sage/misc/persis
>> t.c:2558)() 
>>141 
>>142 if sage.repl.load.is_loadable_filename(filename): 
>> --> 143 sage.repl.load.load(filename, globals()) 
>>144 return 
>>145 
>>
>> ~/src/sage-9.2/local/lib/python3.8/site-packages/sage/repl/load.py in 
>> load(filename, globals, attach) 
>>270 add_attached_file(fpath) 
>>271 with open(fpath) as f: 
>> --> 272 exec(preparse_file(f.read()) + "\n", globals) 
>>273 elif ext == '.spyx' or ext == '.pyx': 
>>274 if attach: 
>>
>> RecursionError: maximum recursion depth exceeded during compilation
>>
>> Any ideas on how I could load such file?
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/ae9d3d68-6318-4aea-8cf2-ce29ef2687a3n%40googlegroups.com.


[sage-support] Re: Cannot install Sage 9.2 on macOS 10.15.7 Catalina

2021-03-28 Thread John H Palmieri
What happens if you install into another location, for example the Desktop?

On Sunday, March 28, 2021 at 9:26:28 AM UTC-7 Anscari wrote:

> I installed the app you suggested but when I open jupyter I find too many 
> bugs. I am not even able to access the jupyter folder created using 
> previous versions. :(
>
> El sábado, 27 de marzo de 2021 a las 19:01:55 UTC+1, Nathan Dunfield 
> escribió:
>
>> Suggest you try the version in development here:
>>
>> https://github.com/3-manifolds/Sage_macOS/releases/tag/v1.0-beta
>>
>> To be clear, it's the same Sage 9.2 as you are trying to install, the 
>> "beta" refers to the packaging method.
>>
>> Nathan
>>
>> On Saturday, March 27, 2021 at 11:58:38 AM UTC-5 Anscari wrote:
>>
>>> I downloaded the binary sage-9.2-OSX_10.15.7_x86_64.app.dmg in order to 
>>> install SageMath 9.2 as an app on my MacBook Pro (Intel Core i7, 2015) 
>>> running macOS Catalina 10.15.7. I already have SageMath 8.0 as an app, 
>>> which I installed with no problem some time ago, but since I don't know of 
>>> a better way to upgrade I am just trying to install the SageMath 9.2 app.
>>>
>>> The download works fine and when I open the dmg and drag the app to 
>>> 'Applications' the app starts copying just fine, but after a few minutes I 
>>> get an error message saying 'The operation can't be completed because you 
>>> don't have permission to access "SageMath-9.2".' and the process stops.
>>>
>>> [image: Screenshot 2021-03-26 at 13.18.03.png]
>>> Copying normally ^
>>>
>>>
>>> [image: Screenshot 2021-03-26 at 13.21.53.png]
>>>
>>> After some minutes this happens ^
>>>
>>>
>>> Do you have any suggestions as to why this might be happening and how to 
>>> solve it?
>>>
>>> Thank you very much!
>>>
>>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/0674bbe0-9142-4329-ad6c-dcfcff007578n%40googlegroups.com.


Re: [sage-support] Re: Install of sage on macOS

2020-12-23 Thread John H Palmieri
The short answer is that Sage is designed for (among others) research 
mathematicians, who may not have the interest or inclination to learn how 
to install lots of system packages. So from the beginning it included as 
many components as possible. Years ago the presence of MacPorts and other 
similar systems would actually break the Sage build process, so the build 
process may attempt to disable them. Whether it tried to disable them, for 
a long time Sage refused to use any system packages and just built 
everything itself (with a few exceptions, like gcc).

This has been changing recently, and now Sage can use many system packages. 
This is restricted to systems (OS + package manager) used by Sage 
developers, and apparently no developer uses MacPorts, or at least not 
enough to spend time getting Sage to work with it. Homebrew is pretty well 
integrated with the Sage build process.

On Wednesday, December 23, 2020 at 6:11:32 AM UTC-8 u...@ll.mit.edu wrote:

> I looked into build/pgks/* (1.5 GB) and it appears that Sage is trying to 
> be a package manager, in addition to what people probably want it for. 
>
> I guess at version 9.2 it's rather late to ask why it isn't good enough to 
> just list in the README a set of packages that Sage requires to run, and 
> have a minimal config that would check for their presence at install time? 
> Letting user to worry about, e.g., where and how to install OpenSSL-1.1.x 
> or python38?
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/06787647-8d63-4e0b-912b-3ddefc516833n%40googlegroups.com.


[sage-support] Re: The pip ssl mess on Mac OS X: ways forwards

2020-11-22 Thread John H Palmieri
Is it possible to create a binary distribution that relies on a system 
Python 3? Those may already be built with ssl support.

On Sunday, November 22, 2020 at 11:24:45 AM UTC-8 watso...@gmail.com wrote:

>
> Right now pip doesn't work in the binary distributions due to the absence 
> of the ssl module. This is apparently due to licensing restrictions, thanks 
> to the terrible license of OpenSSL.
>
> My suggestion is that we hack together  a build curl+NSS, which is freely 
> redistributable. Then as part of the post-install fixup the curl grabs 
> OpenSSL and the ssl python module, and we run a hacky install of the local 
> copy with pip.  Better options highly welcome.
>
> Sincerely,
> Watson Ladd
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/03af83f0-3419-474f-8ef1-e78166b8d793n%40googlegroups.com.


Re: [sage-support] The best practices for using SageNB in SagaMath 9.1?

2020-11-18 Thread John H Palmieri
I was hoping that it might be missing dependencies when building sagenb, 
but when I tried this, it didn't help. Maybe something this will work:

./configure --with-python=2 --enable-sagenb=yes 
--enable-flask_autoindex=yes --enable-flask_babel=yes --enable-flask=yes 
--enable-flask_oldsessions=yes --enable-flask_openid=yes 
--enable-flask_silk=yes --enable-twisted=yes --enable-speaklater=yes

followed by

make

(When we switched to Python 3, we made various packages optional, some of 
which are necessary for sagenb. We didn't record them as dependencies of 
sagenb, so "--enable-sagenb=yes" is not sufficient to build them.)



On Wednesday, November 18, 2020 at 4:52:14 AM UTC-8 Xie wrote:

> Yes. If one people  edit the notebook  then the other's browser will auto 
> refresh.  Not a very good experience, just works.
>
>
> 在2020年11月18日星期三 UTC+8 下午5:04:02 写道:
>
>> On Wed, Nov 18, 2020 at 2:42 AM Xie  wrote:
>>
>>> Thanks, but jupyterhub  does not supoort  real-time collaboration now 
>>> though  roadmap  contains  this.
>>
>> there was no RTC (2+ people working on the same sheet in real time) in 
>> sageNB either, if I recall right.
>> The jupyter roadmap is via jupyterlab, I think.
>>
>>
>>
>>>
>>>
>>>
>>> 在2020年11月18日星期三 UTC+8 上午2:07:29 写道:
>>>
 On Tue, Nov 17, 2020 at 2:50 PM Xie  wrote:

> Yes.  I use  *Jupyter* *Notebook*   myself. But  I need share with 
> other people sometimes.  And  *Jupyter* Notebook*  does not* provide 
> a server mode to make the others register an  account.  


 what you need is 
 https://jupyterhub.readthedocs.io/en/latest/

 Here are SageMath-specific instructions: 
 https://opendreamkit.org/2018/10/17/jupyterhub-docker/
 see also 
 https://discourse.jupyter.org/t/trouble-getting-sagemath-up-and-running-solved/1354
 (there conda is recommended, and perhaps it is indeed the quickest way 
 to get everything set up)

 The SageMath docs on this are not complete, but there is work being 
 done on it:
 https://trac.sagemath.org/ticket/30476


  

> Most students use Windows, which is not very friendly to SageMath.   I 
> also tried Cocalc in  Docker. Its UI   is a bit complicated for 
> *newbie*.
> In addition, Ubuntu 18.04 and Archlinux can run SageMath 8.9 without 
> problems.  Now I use  SageMath 8.9 on 
> a Ubuntu 18.04   server to run SageNB.
> 在2020年11月17日星期二 UTC+8 下午9:44:53 写道:
>
>> Hi,
>> SageMath never supported SageNB on Python3, it did not "drop" such a 
>> support.
>> SageNB has been *retired *since SageMath stopped supporting Python2 
>> in version 9.2, and it is high time to switch to
>> another notebook solution, while converters from SageNB are readily 
>> available.
>> This should not be a surprise, as a deprecation notice for SageNB has 
>> been up since Sage 8.5 (i.e. in 2018), I think,
>> see https://github.com/sagemath/sagenb/pull/451 and 
>> https://trac.sagemath.org/ticket/25852
>>
>> Having said that, I could also point out that the latest Arch, as 
>> well as the latest update of Ubuntu 18.04 have been released after Sage 
>> 9.1, so there is absolutely no guarantee that 9.1 would work on them, 
>> with 
>> Python 2 or 3.
>>
>> HTH
>> Dima
>>
>> On Tue, Nov 17, 2020 at 1:07 PM 漂  wrote:
>> >
>> > Hi,  I maintain a  SageNB server since 2011. But as you know, 
>> SageMath has droped the support of SageNB on Python3. Now I want to run 
>> SageNB in SagaMath 9.1. But I failed many times. 
>> >
>> > I follows the codes  by Samuel Lelièvre given  in
>> >  
>> https://ask.sagemath.org/question/53501/get-the-error-nameerror-name-_interact_-is-not-defined-when-run-sagenb/
>>  
>> .
>> >
>> > make configure 
>> > ./configure --with-python=2 --enable-sagenb=yes
>> >  make -s V=0
>> >
>> > I have tried the source "sage-9.1.tar.gz" and  the tag9.1 source in 
>>  github. I test on Archl linux and Ubuntu 18.04.  I always get the 
>> following error. 
>> >
>> > Traceback (most recent call last): File "", line 1, in 
>>  File "_sage_input_6.py", line 8, in  
>> _interact_.SAGE_CELL_ID=1 NameError: name '_interact_' is not defined
>> >
>> >
>> > This problem may be caused by the codes in 
>> sage/local/lib/python2.7/site-packages/sagenb-1.1.3-py2.7.egg/sagenb/notebook/worksheet.py.
>>   
>> In the line ~3145.
>> >
>> > def initialize_sage(self):
>> >   S = self.__sage 
>> >try: 
>> >from . import misc
>> > cmd = '''import base64 
>> > import sagenb.misc.support as _support_ 
>> > import sagenb.notebook.interact as _interact_ 
>> > # for setting current cell id  ''' 
>> > S.execute(cmd)
>> >
>> > I think 'cmd' is not be executed. If I put some error code in 
>> 'cmd', 

Re: [sage-support] SageMath-9.2 does not start with Jupyter on macOS 10.15.7

2020-11-04 Thread John H Palmieri
By way of comparison, I am using the system's version of all of these 
(/usr/bin/...), not homebrew's. Sage builds fine for me.


On Wednesday, November 4, 2020 at 2:39:58 PM UTC-8, Isuru Fernando wrote:
>
> Looks to me like you are using gcc,g++ from the system and ar, ranlib from 
> homebrew. Can you try switching all to system or all to homebrew?
>
> Isuru
>
> On Wed, Nov 4, 2020 at 3:09 PM phiparis19 > 
> wrote:
>
>> /usr/bin/gcc
>>
>> /usr/bin/g++
>>
>> /usr/local/bin/ar
>>
>> /usr/local/bin/ranlib
>>
>>
>> /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld
>>
>> /Applications/sage-9.2/local/var/tmp/sage/build/gf2x-1.3.0/.libs/libtuneup-s1.a:
>>  
>> cannot open 
>> `/Applications/sage-9.2/local/var/tmp/sage/build/gf2x-1.3.0/.libs/libtuneup-s1.a'
>>  
>> (No such file or directory)
>>
>> Philippe
>>
>> Le mercredi 4 novembre 2020 à 21:45:52 UTC+1, isu...@gmail.com a écrit :
>>
>>> What do you get for each of the commands?
>>>
>>> which gcc
>>> which g++
>>> which ar
>>> which ranlib
>>> gcc -print-prog-name=ld
>>> file 
>>> /Applications/sage-9.2/local/var/tmp/sage/build/gf2x-1.3.0/.libs/libtuneup-s1.a
>>>
>>> Isuru
>>>
>>> On Wed, Nov 4, 2020 at 2:30 PM phiparis19  wrote:
>>>
>>>> Here is the file
>>>> Thank you
>>>>
>>>> Le mercredi 4 novembre 2020 à 21:04:09 UTC+1, isu...@gmail.com a 
>>>> écrit :
>>>>
>>>>> > I get ld: warning: ignoring file ./.libs/libtuneup-s1.a, building 
>>>>> for macOS-x86_64 but attempting to link with file built for 
>>>>> unknown-unsupported file format ( 0x21 0x3C 0x61 0x72 0x63 0x68 0x3E 0x0A 
>>>>> 0x2F 0x20 0x20 0x20 0x20 0x20 0x20 0x20 )
>>>>>
>>>>> Can you send `gf2x`'s `config.log`?
>>>>>
>>>>> This happens when you are using a linker without LTO support.
>>>>>
>>>>> Isuru
>>>>>
>>>>> On Wed, Nov 4, 2020 at 1:53 PM phiparis19  wrote:
>>>>>
>>>>>>
>>>>>> Thank you for helping me.
>>>>>>
>>>>>> I followed the instructions at the end of ./configure output  (brew 
>>>>>> install ...)
>>>>>>
>>>>>> I get ld: warning: ignoring file ./.libs/libtuneup-s1.a, building for 
>>>>>> macOS-x86_64 but attempting to link with file built for 
>>>>>> unknown-unsupported 
>>>>>> file format ( 0x21 0x3C 0x61 0x72 0x63 0x68 0x3E 0x0A 0x2F 0x20 0x20 
>>>>>> 0x20 
>>>>>> 0x20 0x20 0x20 0x20 )
>>>>>>
>>>>>> Error installing package gf2x-1.3.0
>>>>>>
>>>>>> I have also tried to compile sage-9.2 on another partition of my mac 
>>>>>> : il fails after 4h of compilation for the same reason for one of the 
>>>>>> last 
>>>>>> packages.
>>>>>> Le mercredi 4 novembre 2020 à 18:18:41 UTC+1, John H Palmieri a 
>>>>>> écrit :
>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> On Tuesday, November 3, 2020 at 11:30:54 PM UTC-8, Dima Pasechnik 
>>>>>>> wrote:
>>>>>>>>
>>>>>>>> As far as building from source is concerned, I'd recommend using 
>>>>>>>> Homebrew, instead of trying 
>>>>>>>> to build most packages from scratch (as it is the case if you don't 
>>>>>>>> use it). 
>>>>>>>> Please pay attention that you need to run 
>>>>>>>>
>>>>>>>> source .homebrew-build-env 
>>>>>>>>
>>>>>>>>
>>>>>>>> and to the list of packages you'd install printed out by 
>>>>>>>> ./configure 
>>>>>>>> (at the end of its run) 
>>>>>>>>
>>>>>>>
>>>>>>> And after installing new system packages, it's a good idea to run 
>>>>>>> 'make distclean' and then rerun './configure' (with whatever options 
>>>>>>> you 
>>>>>>> want to pass to it).
>>>>>>>  
>>>>>>>
>>>>>>>>
>>>>>>

Re: [sage-support] SageMath-9.2 does not start with Jupyter on macOS 10.15.7

2020-11-04 Thread John H Palmieri


On Tuesday, November 3, 2020 at 11:30:54 PM UTC-8, Dima Pasechnik wrote:
>
> As far as building from source is concerned, I'd recommend using 
> Homebrew, instead of trying 
> to build most packages from scratch (as it is the case if you don't use 
> it). 
> Please pay attention that you need to run 
>
> source .homebrew-build-env 
>
>
> and to the list of packages you'd install printed out by ./configure 
> (at the end of its run) 
>

And after installing new system packages, it's a good idea to run 'make 
distclean' and then rerun './configure' (with whatever options you want to 
pass to it).
 

>
> On Wed, Nov 4, 2020 at 6:18 AM phiparis19 > 
> wrote: 
> > 
> > Hello, 
> > 
> > After upgrading from SageMath-9.1 to SageMath-9.2, 
> > 
> > ./sage -n jupyter fails 
> > 
> > ModuleNotFoundError: No module named '_ssl' 
> > 
> > The Jupyter notebook requires ssl, even if you do not use https. Install 
> the openssl development packages in your system and then rebuild Python 
> (sage -f python3). 
> > 
> > Unfortunately,  openssl installation has failed : 
> > 
> > [openssl-1.1.1g] Undefined symbols for architecture x86_64: 
> > 
> >  
> > 
> > [openssl-1.1.1g] ld: symbol(s) not found for architecture x86_64 
> > 
> > [openssl-1.1.1g] clang: error: linker command failed with exit code 1 
> (use -v to see invocation) 
> > 
> > Same issue when recompiling sage from sage-9.2.tar.gz 
> > 
> > ./configure --enable-openssl=yes 
> > 
> > make 
> > 
> > [patch-2.7.5] ld: symbol(s) not found for architecture x86_64 
> > 
> > 
> > I have macports and hombres installed 
> > 
> > So I dit 
> > 
> >  sudo mv /opt/local /opt/local_old 
> > 
> > sudo mv /usr/local/Homebrew /usr/local/Homebrew_old 
>
> Unless you use a non-standard installaI don't think you achieve much 
> by the latter, as Homebrew installs several packages directly into 
> /usr/local (i.e. /usr/local/bin, etc), so this is more or less just 
> breaks Homebrew, but is very far from uninstalling it. 
>
>
> > 
> > before typing make for sage 
> > 
> > See file enclose for configure output 
> > 
> > Thank you for helping 
> > 
> > -- 
> > You received this message because you are subscribed to the Google 
> Groups "sage-support" group. 
> > To unsubscribe from this group and stop receiving emails from it, send 
> an email to sage-s...@googlegroups.com . 
> > To view this discussion on the web visit 
> https://groups.google.com/d/msgid/sage-support/d13b96e9-92ec-4128-b219-92384d3e3110n%40googlegroups.com.
>  
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/08d1fcf0-45de-4d61-9101-21da54768c29o%40googlegroups.com.


[sage-support] Re: persistent homology?

2020-10-15 Thread John H Palmieri
No, I do not believe so.


On Thursday, October 15, 2020 at 10:22:36 AM UTC-7, Linden Disney wrote:
>
> I am just starting a project involving persistent homology, did anything 
> end up happening with this? 
>
> On Wednesday, September 13, 2017 at 1:55:30 AM UTC+1 slelievre wrote:
>
>> Tue 2017-09-12 07:25:20 UTC, Pierre:
>>
>> > I tried to follow the instructions, in a brand new cocalc project.
>> > This failed, with [...]
>>
>> There have been major CoCalc changes since the successful
>> installation I reported three weeks ago. Notably, CoCalc projects
>> now run under Ubuntu 16.04.3 (vs previously 15.10).
>>
>> Trying again in this new setting, I get the same failure as you.
>> This Bash Jupyter notebook shows the failure:
>>
>>
>> https://cocalc.com/projects/57b64f7e-e45e-4171-a0f0-bb53ab8befb1/files/install-gudhi.ipynb
>>
>> The CoCalc developers are looking into this.
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/2b0f84ed-aebf-4b5d-a4da-8e11a26962afo%40googlegroups.com.


Re: [sage-support] Re: problem compiling sage-9.2.rc0 on big sur, xcode 12.01

2020-10-07 Thread John H Palmieri
I think you should report this at #30651, including details of which 
homebrew packages you've installed. It was suggested at 
https://trac.sagemath.org/ticket/30494#comment:92 that homebrew's gfortran 
may not work with Big Sur, so you might want to install Sage's version of 
that, too.

On Wednesday, October 7, 2020 at 12:55:50 PM UTC-7, David Joyner wrote:
>
>
>
> On Wed, Oct 7, 2020 at 1:06 PM John H Palmieri  > wrote:
>
>> Building Sage on Big Sur is being tracked at 
>> https://trac.sagemath.org/ticket/30651; see also 
>> https://trac.sagemath.org/ticket/30494. Do you have homebrew installed, 
>> and if so, which packages? You could try forcing Sage to build its own 
>> zlib, for example, to try to get Sage's Python to find it.
>>
>>
> Yes, homebrew's installed and I used it to install python3 and readline, 
> but the compiler can't find either one.
>  
> Following your suggestion, I ran sage -f zlib, which seemed to work fine, 
> but 
> said openblas wasn't able to compile. I ran sage -f openblas. Here's the 
> tail of that:
>
> [openblas-0.3.9] gfortran -O2 -m128bit-long-double -Wall -frecursive 
> -fno-optimize-sibling-calls -m64 -fPIC 
> -L/Users/wdj/sagefiles/sage-9.2.rc0/local/lib 
> -Wl,-rpath,/Users/wdj/sagefiles/sage-9.2.rc0/local/lib  -all_load 
> -headerpad_max_install_names -install_name 
> "/Users/wdj/sagefiles/sage-9.2.rc0/local/var/tmp/sage/build/openblas-0.3.9/src/exports/../libopenblas.0.dylib"
>  
> -dynamiclib -o ../libopenblas_atomp-r0.3.9.dylib 
> ../libopenblas_atomp-r0.3.9.a -Wl,-exported_symbols_list,osx.def  
> -L/Users/wdj/sagefiles/sage-9.2.rc0/local/lib 
> -L/usr/local/Cellar/gcc/9.2.0_1/lib/gcc/9/gcc/x86_64-apple-darwin19/9.2.0 
> -L/usr/local/Cellar/gcc/9.2.0_1/lib/gcc/9/gcc/x86_64-apple-darwin19/9.2.0/../../..
>  
> -L/Users/wdj/sagefiles/sage-9.2.rc0/local/lib 
> -L/usr/local/Cellar/gcc/9.2.0_1/lib/gcc/9/gcc/x86_64-apple-darwin19/9.2.0 
> -L/usr/local/Cellar/gcc/9.2.0_1/lib/gcc/9/gcc/x86_64-apple-darwin19/9.2.0/../../..
>   
> -lgfortran -lSystem -lquadmath -lm -lSystem -lgfortran -lSystem -lquadmath 
> -lm -lSystem -lSystem  
>
> [openblas-0.3.9] ld: library not found for -lSystem
>
> [openblas-0.3.9] collect2: error: ld returned 1 exit status
>
> [openblas-0.3.9] make[4]: *** [libopenblas_atomp-r0.3.9.dylib] Error 1
>
> [openblas-0.3.9] make[3]: *** [shared] Error 2
>
> [openblas-0.3.9] 
> 
>
> [openblas-0.3.9] Error building openblas-0.3.9
>
> [openblas-0.3.9] 
> 
>
> [openblas-0.3.9] 
>
> [openblas-0.3.9] real 10m21.321s
>
> [openblas-0.3.9] user 55m3.304s
>
> [openblas-0.3.9] sys 14m23.198s
>
> [openblas-0.3.9] 
> 
>
> [openblas-0.3.9] Error installing package openblas-0.3.9
>
> [openblas-0.3.9] 
> 
>
> [openblas-0.3.9] Please email sage-devel (
> http://groups.google.com/group/sage-devel)
>
> [openblas-0.3.9] explaining the problem and including the log file
>
> [openblas-0.3.9]   
> /Users/wdj/sagefiles/sage-9.2.rc0/logs/pkgs/openblas-0.3.9.log
>
> [openblas-0.3.9] Describe your computer, operating system, etc.
>
> [openblas-0.3.9] If you want to try to fix the problem yourself, *don't* 
> just cd to
>
> [openblas-0.3.9] 
> /Users/wdj/sagefiles/sage-9.2.rc0/local/var/tmp/sage/build/openblas-0.3.9 
> and type 'make' or whatever is appropriate.
>
> [openblas-0.3.9] Instead, the following commands setup all environment 
> variables
>
> [openblas-0.3.9] correctly and load a subshell for you to debug the error:
>
> [openblas-0.3.9]   (cd 
> '/Users/wdj/sagefiles/sage-9.2.rc0/local/var/tmp/sage/build/openblas-0.3.9' 
> && '/Users/wdj/sagefiles/sage-9.2.rc0/sage' --buildsh)
>
> [openblas-0.3.9] When you are done debugging, you can type "exit" to leave 
> the subshell.
>
> [openblas-0.3.9] 
> 
>
> make[2]: *** [openblas-no-deps] Error 1
>
> make[1]: *** 
> [/Users/wdj/sagefiles/sage-9.2.rc0/local/var/lib/sage/installed/openblas-0.3.9]
>  
> Error 2
>
>
> real 10m32.344s
>
> user 55m7.812s
>
> sys 14m30.548s
>
> ***
>
> Error building Sage.
>
>
> The following package(s) may have failed to build (not necessarily
>
> during this run of 'make openblas'):
>
>
> * package: openblas-0.3.9
>
>   l

[sage-support] Re: problem compiling sage-9.2.rc0 on big sur, xcode 12.01

2020-10-07 Thread John H Palmieri
Building Sage on Big Sur is being tracked at 
https://trac.sagemath.org/ticket/30651; see also 
https://trac.sagemath.org/ticket/30494. Do you have homebrew installed, and 
if so, which packages? You could try forcing Sage to build its own zlib, 
for example, to try to get Sage's Python to find it.


On Wednesday, October 7, 2020 at 7:39:59 AM UTC-7, David Joyner wrote:
>
> Hi:
>
> The compiler still can't find installed python3:
>
> wdj@jeeves sage-9.2.rc0 % which python3
>
> /Library/Frameworks/Python.framework/Versions/3.7/bin/python3
>
>
>
> The log python3-3.8.5.log says
> "Package 'python3' is currently not installed"
>
> Here's the tail after running configure then make -k:
>
> [yasm-1.3.0.p0] Finished installing yasm-1.3.0.p0
>
> make[3]: Target `all-sage' not remade because of errors.
>
> make[2]: *** [all-start] Error 2
>
>
> real 940m12.196s
>
> user 113m42.845s
>
> sys 15m52.978s
>
> ***
>
> Error building Sage.
>
>
> The following package(s) may have failed to build (not necessarily
>
> during this run of 'make all-start'):
>
>
> * package: python3-3.8.5
>
>   last build time: Oct 6 18:49
>
>   log file:
> /Users/wdj/sagefiles/sage-9.2.rc0/logs/pkgs/python3-3.8.5.log
>
>   build directory: 
> /Users/wdj/sagefiles/sage-9.2.rc0/local/var/tmp/sage/build/python3-3.8.5
>
>
> It is safe to delete any log files and build directories, but they
>
> contain information that is helpful for debugging build problems.
>
> WARNING: If you now run 'make' again, the build directory of the
>
> same version of the package will, by default, be deleted. Set the
>
> environment variable SAGE_KEEP_BUILT_SPKGS=yes to prevent this.
>
>
> make[1]: *** [all-start] Error 1
>
> make: *** [all] Error 2
>
> make: Target `default' not remade because of errors.
>
>
> - David Joyner
>
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/5fc19ba6-1e77-4250-adcc-1d78f65a8507o%40googlegroups.com.


Re: [sage-support] compiling fails with 'boost/preprocessor/cat.hpp' file not found

2020-09-04 Thread John H Palmieri


On Friday, September 4, 2020 at 9:23:30 AM UTC-7, Dima Pasechnik wrote:
>
> On Fri, Sep 4, 2020 at 4:31 PM John H Palmieri  > wrote: 
> > 
> > 
> > 
> > On Friday, September 4, 2020 at 7:14:24 AM UTC-7, Dima Pasechnik wrote: 
> >> 
> >> 
> >> 
> >> On Fri, Sep 4, 2020 at 12:55 PM Szabolcs Horvát  
> wrote: 
> >> 
> >> > Thanks for the response. I do have boost installed in 
> /opt/local/include, through MacPorts, but I remove MacPorts from the PATH 
> before building Sage (otherwise Sage complains). Therefore, I assumed that 
> this boost installation would not be detected. It appears that it might be 
> sometimes detected and sometimes not? The contents of config.log are a bit 
> unclear to me. I copy the relevant part below. Do you have any suggestion 
> for what I might try, based on this? 
> >> 
> >> 
> >> various Sage  packages have many ways to detect external software, and 
> it's not uncommon to  see loops over 
> >> /usr/include, /usr/local/include/, /opt/include, /opt/local/include in 
> their configuration scripts. 
> >> Perhaps you are hit by one of these issues. 
> >> Or perhaps you left an environment variable set, pointing at 
> /opt/local/include, e.g. CFLAGS or CXXFLAGS or CPPFLAGS... 
> >> At least it would explain why your log says 
> >> 
> >> > configure:13392: g++ -std=gnu++11 -c -g -O2 -I/opt/local/include 
> conftest.cpp >&5 
> >> 
> >> which contains -I/opt/local/include 
> >> 
> >> As a workaround, please rename your /opt/local 
> >> while building Sage. 
> > 
> > 
> > Or if you think that the system boost being broken is the only problem, 
> you could do 
> > 
> > make distclean 
> > ./configure --with-system-boost_cropped=no 
> > make 
> > 
> > 
> > to force Sage to build its own boost. 
>
> Sage does build its own boost here - the problem is that a broken 
> (from Sage's point of view) systemwide 
> install of boost interferes with the build of brial. 
>

Sage was using the system installation of the standard package 
"boost_cropped" ("configure:13558: will use system package and not install 
SPKG boost_cropped"). It would indeed have built its own version of the 
optional package "boost" if that had been requested, but that's not part of 
the standard build process. Somehow the configure file recognized that 
boost was broken but not boost_cropped. That should probably be addressed.
 

>
> > 
> >> 
> >> 
> >> > 
> >> > ## -- ## 
> >> > ## Checking whether SageMath should install SPKG boost_cropped... ## 
> >> > ## -- ## 
> >> > configure:13360: checking for boostlib >= 1.66.0 (106600) 
> >> > configure:13392: g++ -std=gnu++11 -c -g -O2 -I/opt/local/include 
> conftest.cpp >&5 
> >> > configure:13392: $? = 0 
> >> > configure:13394: result: yes 
> >> > configure:13558: will use system package and not install SPKG 
> boost_cropped 
> >> > ## -- ## 
> >> > ## Checking whether SageMath should install SPKG boost... ## 
> >> > ## -- ## 
> >> > configure:13658: checking whether any of boost_cropped is installed 
> as or will be installed as SPKG 
> >> > configure:13667: result: no 
> >> > configure:13691: g++ -std=gnu++11 -o conftest -g -O2 conftest.cpp -lm 
> >&5 
> >> > conftest.cpp:24:12: fatal error: 'boost/program_options/errors.hpp' 
> file not found 
> >> > #include  
> >> > ^~ 
> >> > 1 error generated. 
> >> > configure:13691: $? = 1 
> >> > configure: program exited with status 1 
> >> > configure: failed program was: 
> >> > | /* confdefs.h */ 
> >> > | #define PACKAGE_NAME "Sage" 
> >> > | #define PACKAGE_TARNAME "sage" 
> >> > | #define PACKAGE_VERSION "9.1" 
> >> > | #define PACKAGE_STRING "Sage 9.1" 
> >> > | #define PACKAGE_BUGREPORT "sage-...@googlegroups.com" 
> >> > | #define PACKAGE_URL "" 
> >> > | #define PACKAGE "sage" 
> >> > | #define VERSION "9.1" 
> >> > | #define STDC_HEADERS 1 
> >> > | #define HAVE_SYS_

Re: [sage-support] compiling fails with 'boost/preprocessor/cat.hpp' file not found

2020-09-04 Thread John H Palmieri


On Friday, September 4, 2020 at 7:14:24 AM UTC-7, Dima Pasechnik wrote:
>
>
>
> On Fri, Sep 4, 2020 at 12:55 PM Szabolcs Horvát  > wrote:
>
> > Thanks for the response. I do have boost installed in 
> /opt/local/include, through MacPorts, but I remove MacPorts from the PATH 
> before building Sage (otherwise Sage complains). Therefore, I assumed that 
> this boost installation would not be detected. It appears that it might be 
> sometimes detected and sometimes not? The contents of config.log are a bit 
> unclear to me. I copy the relevant part below. Do you have any suggestion 
> for what I might try, based on this?
>
>
> various Sage  packages have many ways to detect external software, and 
> it's not uncommon to  see loops over
> /usr/include, /usr/local/include/, /opt/include, /opt/local/include in 
> their configuration scripts.
> Perhaps you are hit by one of these issues.
> Or perhaps you left an environment variable set, pointing at 
> /opt/local/include, e.g. CFLAGS or CXXFLAGS or CPPFLAGS...
> At least it would explain why your log says
>
> > configure:13392: g++ -std=gnu++11 -c -g -O2 -I/opt/local/include 
> conftest.cpp >&5
>
> which contains -I/opt/local/include
>
> As a workaround, please rename your /opt/local 
> while building Sage. 
>

Or if you think that the system boost being broken is the only problem, you 
could do

make distclean
./configure --with-system-boost_cropped=no
make


to force Sage to build its own boost.
 

>
> >
> > ## -- ##
> > ## Checking whether SageMath should install SPKG boost_cropped... ##
> > ## -- ##
> > configure:13360: checking for boostlib >= 1.66.0 (106600)
> > configure:13392: g++ -std=gnu++11 -c -g -O2 -I/opt/local/include 
> conftest.cpp >&5
> > configure:13392: $? = 0
> > configure:13394: result: yes
> > configure:13558: will use system package and not install SPKG 
> boost_cropped
> > ## -- ##
> > ## Checking whether SageMath should install SPKG boost... ##
> > ## -- ##
> > configure:13658: checking whether any of boost_cropped is installed as 
> or will be installed as SPKG
> > configure:13667: result: no
> > configure:13691: g++ -std=gnu++11 -o conftest -g -O2 conftest.cpp -lm >&5
> > conftest.cpp:24:12: fatal error: 'boost/program_options/errors.hpp' file 
> not found
> > #include 
> > ^~
> > 1 error generated.
> > configure:13691: $? = 1
> > configure: program exited with status 1
> > configure: failed program was:
> > | /* confdefs.h */
> > | #define PACKAGE_NAME "Sage"
> > | #define PACKAGE_TARNAME "sage"
> > | #define PACKAGE_VERSION "9.1"
> > | #define PACKAGE_STRING "Sage 9.1"
> > | #define PACKAGE_BUGREPORT "sage-...@googlegroups.com "
> > | #define PACKAGE_URL ""
> > | #define PACKAGE "sage"
> > | #define VERSION "9.1"
> > | #define STDC_HEADERS 1
> > | #define HAVE_SYS_TYPES_H 1
> > | #define HAVE_SYS_STAT_H 1
> > | #define HAVE_STDLIB_H 1
> > | #define HAVE_STRING_H 1
> > | #define HAVE_MEMORY_H 1
> > | #define HAVE_STRINGS_H 1
> > | #define HAVE_INTTYPES_H 1
> > | #define HAVE_STDINT_H 1
> > | #define HAVE_UNISTD_H 1
> > | #define HAVE_LIBM 1
> > | #define HAVE_CXX11 1
> > | #define HAVE_BOOST /**/
> > | /* end confdefs.h. */
> > | #include 
> > |
> > | int
> > | main ()
> > | {
> > |
> > | boost::program_options::error err("Error message");
> > | return 0;
> > |
> > | ;
> > | return 0;
> > | }
> > configure:13719: no suitable system package found for SPKG boost
> >
> > On Fri, 4 Sep 2020 at 13:04, Dima Pasechnik  > wrote:
> >>
> >> On Fri, Sep 4, 2020 at 11:12 AM Szabolcs Horvát  > wrote:
> >> >
> >> >
> >> > Hello everyone,
> >> >
> >> > I am trying to compile Sage on macOS 10.14.
> >> >
> >> > The package brial-1.2.5 fails to compile.
> >> >
> >> > The error is:
> >> >
> >> > ../../libbrial/include/polybori/common/traits.h:26:10: fatal error: 
> 'boost/preprocessor/cat.hpp' file not found
> >> > #include 
> >> > ^~~~
> >> > 1 error generated.
> >> >
> >> > Did anyone succeed to compile Sage on macOS 10.14? Is a separate, 
> manual installation of Boost necessary to compile? Sage does appear to 
> include (or auto-download?) Boost, so I assume this is not the case.
> >>
> >> it should work. Sage tries to detect an system-wide installation of
> >> boost, and if it fails it installs a package boost-cropped,
> >> otherwise it uses what's available on the system.
> >>
> >> Have a look at the top level config.log to see what happens for you.
> >> E.g. here is a place in config.log where system boost is detected:
> >>
> >> []
> >> # Checking whether SageMath should install SPKG boost_cropped... ##
> >> ## -- ##
> >> configure:13366: checking for boostlib >= 1.66.0 (106600)
> >> configure:13398: 

Re: [sage-support] compile problem for sage 9.2.b9 on mac 11.0 big sur

2020-09-02 Thread John H Palmieri
With a system Python and "make -k", the following packages fail:

gf2x
ecm
symmetrica
rubiks
ecl
scipy

On Tuesday, September 1, 2020 at 10:29:52 PM UTC-7 Matthias Koeppe wrote:

> These lines:
>
> configure:17396: checking build system compiler gcc
>
> etc.
> might indicate that the configure script is confused about cross compiling 
> to a different architecture.
>
>
> On Tuesday, September 1, 2020 at 9:59:59 PM UTC-7, John H Palmieri wrote:
>>
>>
>>
>> On Tuesday, September 1, 2020 at 9:52:37 PM UTC-7 Matthias Koeppe wrote:
>>
>>> On Tuesday, September 1, 2020 at 8:59:14 PM UTC-7, John H Palmieri wrote:
>>>
>>>> If I do install Python 3.7, then gf2x and ecm both fail to build. The 
>>>> gf2x log file says "configure: error: Cannot find a build system compiler
>>>> ". The ecm log file says "checking if globals are prefixed by 
>>>> underscore... configure: error: Test program links neither with nor 
>>>> without 
>>>> underscore."
>>>>
>>>>>
>>>>>>
>>> gf2x was just upgraded in https://trac.sagemath.org/ticket/30412 - 
>>> merged in 9.2.beta11. Did you test with this beta or an earlier one?
>>>
>>
>> I tried with 9.2.beta10, and just now I tried with this new version of 
>> gf2x. Same error either way. Here is the gf2x config.log. 
>>
>>>
>>>  
>>>
>>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/ba86f66e-ed79-4329-bd09-53138a1dd559n%40googlegroups.com.


Re: [sage-support] compile problem for sage 9.2.b9 on mac 11.0 big sur

2020-09-01 Thread John H Palmieri


On Tuesday, September 1, 2020 at 9:52:37 PM UTC-7 Matthias Koeppe wrote:

> On Tuesday, September 1, 2020 at 8:59:14 PM UTC-7, John H Palmieri wrote:
>
>> If I do install Python 3.7, then gf2x and ecm both fail to build. The 
>> gf2x log file says "configure: error: Cannot find a build system compiler
>> ". The ecm log file says "checking if globals are prefixed by 
>> underscore... configure: error: Test program links neither with nor without 
>> underscore."
>>
>>>
>>>>
> gf2x was just upgraded in https://trac.sagemath.org/ticket/30412 - merged 
> in 9.2.beta11. Did you test with this beta or an earlier one?
>

I tried with 9.2.beta10, and just now I tried with this new version of 
gf2x. Same error either way. Here is the gf2x config.log. 

>
>  
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/b0fbaff1-916e-4d15-95a5-268077b8b08dn%40googlegroups.com.
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.

It was created by gf2x configure 1.3.0, which was
generated by GNU Autoconf 2.69.  Invocation command line was

  $ ./configure --prefix=/Users/palmieri/Sage/sage-9.2.beta10/local 
--libdir=/Users/palmieri/Sage/sage-9.2.beta10/local/lib

## - ##
## Platform. ##
## - ##

hostname = johnpalierisair.lan
uname -m = x86_64
uname -r = 20.0.0
uname -s = Darwin
uname -v = Darwin Kernel Version 20.0.0: Fri Aug 14 00:25:13 PDT 2020; 
root:xnu-7195.40.44.151.1~4/RELEASE_X86_64

/usr/bin/uname -p = i386
/bin/uname -X = unknown

/bin/arch  = unknown
/usr/bin/arch -k   = unknown
/usr/convex/getsysinfo = unknown
/usr/bin/hostinfo  = Mach kernel version:
 Darwin Kernel Version 20.0.0: Fri Aug 14 00:25:13 PDT 2020; 
root:xnu-7195.40.44.151.1~4/RELEASE_X86_64
Kernel configured for up to 4 processors.
2 processors are physically available.
4 processors are logically available.
Processor type: x86_64h (Intel x86-64h Haswell)
Processors active: 0 1 2 3
Primary memory available: 8.00 gigabytes
Default processor set: 474 tasks, 1601 threads, 4 processors
Load average: 66.11, Mach factor: 0.09
/bin/machine   = unknown
/usr/bin/oslevel   = unknown
/bin/universe  = unknown

PATH: /Users/palmieri/Sage/sage-9.2.beta10/build/bin
PATH: /Users/palmieri/Sage/sage-9.2.beta10/src/bin
PATH: /Users/palmieri/Sage/sage-9.2.beta10/local/bin
PATH: /Users/palmieri/Sage/sage-9.2.beta10/build/bin
PATH: /Users/palmieri/Sage/sage-9.2.beta10/src/bin
PATH: /Users/palmieri/Sage/sage-9.2.beta10/local/bin
PATH: /usr/local/opt/python@3.7/bin
PATH: /usr/local/opt/gettext/bin
PATH: /Users/palmieri/.local/bin
PATH: /Users/palmieri/Dropbox/bin
PATH: /Users/palmieri/bin
PATH: /usr/local/bin
PATH: /usr/bin
PATH: /bin
PATH: /usr/sbin
PATH: /sbin
PATH: /Library/TeX/texbin
PATH: /Library/Apple/usr/bin


## --- ##
## Core tests. ##
## --- ##

configure:2621: checking build system type
configure:2635: result: x86_64-apple-darwin20.0.0
configure:2655: checking host system type
configure:2668: result: x86_64-apple-darwin20.0.0
configure:2688: checking target system type
configure:2701: result: x86_64-apple-darwin20.0.0
configure:2786: checking for gcc
configure:2813: result: gcc
configure:3042: checking for C compiler version
configure:3051: gcc --version >&5
Apple clang version 12.0.0 (clang-1200.0.31.1)
Target: x86_64-apple-darwin20.0.0
Thread model: posix
InstalledDir: /Library/Developer/CommandLineTools/usr/bin
Configured with: --prefix=/Library/Developer/CommandLineTools/usr 
--with-gxx-include-dir=/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/c++/4.2.1
configure:3062: $? = 0
configure:3051: gcc -v >&5
Configured with: --prefix=/Library/Developer/CommandLineTools/usr 
--with-gxx-include-dir=/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/c++/4.2.1
Apple clang version 12.0.0 (clang-1200.0.31.1)
Target: x86_64-apple-darwin20.0.0
Thread model: posix
InstalledDir: /Library/Developer/CommandLineTools/usr/bin
configure:3062: $? = 0
configure:3051: gcc -V >&5
clang: error: argument to '-V' is missing (expected 1 value)
clang: error: no input files
configure:3062: $? = 1
configure:3051: gcc -qversion >&5
clang: error: unknown argument '-qversion'; did you mean '--version'?
clang: error: no input files
configure:3062: $? = 1
configure:3082: checking whether the C compiler works
configure:3104: gcc -O2 -g   -L/Users/palmieri/Sage/sage-9.2.beta10/local/lib 
-Wl,-rpath,/Users/palmieri/Sage/sage-9.2.beta10/local/lib  conftest.c  >&5
configure:3108: $? = 0
configure:31

Re: [sage-support] compile problem for sage 9.2.b9 on mac 11.0 big sur

2020-09-01 Thread John H Palmieri
If I do install Python 3.7, then gf2x and ecm both fail to build. The gf2x 
log file says "configure: error: Cannot find a build system compiler
". The ecm log file says "checking if globals are prefixed by underscore... 
configure: error: Test program links neither with nor without underscore."

On Tuesday, September 1, 2020 at 8:38:47 PM UTC-7 John H Palmieri wrote:

> I've been trying to build on Big Sur, too. I removed the 
> MACOSX_DEPLOYMENT_TARGET lines from sage-env, but the Python build still 
> fails. The log file is attached. Any suggestions (besides installing a 
> different system version of Python)?
>
>   John
>
> On Saturday, August 22, 2020 at 3:44:01 PM UTC-7 dim...@gmail.com wrote:
>
>> On Sat, Aug 22, 2020 at 11:23 PM David Joyner  wrote:
>> >
>> >
>> >
>> > On Sat, Aug 22, 2020 at 6:02 PM Dima Pasechnik  
>> wrote:
>> >>
>> >> On Sat, Aug 22, 2020 at 10:51 PM David Joyner  
>> wrote:
>> >> >
>> >> >
>> >> >
>> >> > On Sat, Aug 22, 2020 at 4:52 PM Dima Pasechnik  
>> wrote:
>> >> >>
>> >> >> On Sat, Aug 22, 2020 at 8:28 PM Dima Pasechnik  
>> wrote:
>> >> >> >
>> >> >> > note: 'utimensat' has been marked as being introduced in macOS 
>> 10.13
>> >> >> > here, but the deployment target is macOS 10.9.0
>> >> >> >
>> >> >> > seems to indicate that one has to properly set 
>> MACOS_DEPLOYMENT_TARGET
>> >> >> > (or a suchlike thing) to 10.13 or even bigger.
>> >> >>
>> >> >> indeed, in src/bin/sage-env on has
>> >> >>
>> >> >> MACOSX_DEPLOYMENT_TARGET=10.9
>> >> >>
>> >> >> which is the reason for that error, I guess.
>> >> >
>> >> >
>> >> > Shouldn't it be 11.0?
>> >> >
>> >> > I changed it then tried to recompile but it stopped at the same 
>> place.
>> >> > I can't install a system python3 using homebrew since it's broken
>> >> > https://github.com/Homebrew/brew/issues/7803
>> >>
>> >> you can install a binary python3.7 from python.org - this is known to
>> >> be possible to use in Sage on macOS 10.15 and earlier versions.
>> >>
>> >
>> > I installed both python 3.8.5 (the latest) and when that failed 3.7.9.
>> >
>> > The end of the output of configure is this seeming contradictory info:
>> >
>> > configure: notice: the following SPKGs did not find equivalent system 
>> packages: brial cbc cddlib cliquer coxeter3 eclib ecm fflas_ffpack flintqs 
>> fplll gf2x gfan givaro glpk gp2c gsl iconv iml lcalc libatomic_ops 
>> libbraiding libsemigroups lrcalc m4ri m4rie nauty ninja_build openblas palp 
>> pandoc pari pari_elldata pari_galdata pari_galpol pari_nftables 
>> pari_seadata pari_seadata_small pcre perl_cpan_polymake_prereq 
>> perl_term_readline_gnu planarity ppl python3 r rw suitesparse symmetrica 
>> sympow tachyon yasm zeromq zn_poly
>>
>> This notice is more about ./configure being confused whether there is
>> Homebrew or Conda installed.
>>
>> The interesting line of ./configure output is above that notice:
>>
>> python3-3.7.3.p1: using system package;
>> SPKG will not be installed
>>
>> - if it's there then system Python will be used.
>> Otherwise, look in config.log for more details.
>>
>> HTH
>> Dima
>>
>>
>> >
>> > checking for the package system in use... unknown
>> >
>> > wdj@jeeves sage-9.2.beta9 % which python3
>> >
>> > /usr/local/bin/python3
>> >
>> > wdj@jeeves sage-9.2.beta9 % python3 --version
>> >
>> > Python 3.7.9
>> >
>> > There isn't a python3 system package but there is?
>> >
>> >>
>> >> >
>> >> >
>> >> >>
>> >> >>
>> >> >> >
>> >> >> > On Sat, Aug 22, 2020 at 8:06 PM David Joyner  
>> wrote:
>> >> >> > >
>> >> >> > > Hi:
>> >> >> > >
>> >> >> > > I don't know if this has been discussed yet but
>> >> >> > > I just upgraded to mac os 11.0. I downloaded
>> >> >> > > sage 9.2.b9 and ran make. I got a "you must
>> >> >> > > run ./configure fir

Re: [sage-support] compile problem for sage 9.2.b9 on mac 11.0 big sur

2020-09-01 Thread John H Palmieri
I've been trying to build on Big Sur, too. I removed the 
MACOSX_DEPLOYMENT_TARGET lines from sage-env, but the Python build still 
fails. The log file is attached. Any suggestions (besides installing a 
different system version of Python)?

  John

On Saturday, August 22, 2020 at 3:44:01 PM UTC-7 dim...@gmail.com wrote:

> On Sat, Aug 22, 2020 at 11:23 PM David Joyner  wrote:
> >
> >
> >
> > On Sat, Aug 22, 2020 at 6:02 PM Dima Pasechnik  wrote:
> >>
> >> On Sat, Aug 22, 2020 at 10:51 PM David Joyner  
> wrote:
> >> >
> >> >
> >> >
> >> > On Sat, Aug 22, 2020 at 4:52 PM Dima Pasechnik  
> wrote:
> >> >>
> >> >> On Sat, Aug 22, 2020 at 8:28 PM Dima Pasechnik  
> wrote:
> >> >> >
> >> >> > note: 'utimensat' has been marked as being introduced in macOS 
> 10.13
> >> >> > here, but the deployment target is macOS 10.9.0
> >> >> >
> >> >> > seems to indicate that one has to properly set 
> MACOS_DEPLOYMENT_TARGET
> >> >> > (or a suchlike thing) to 10.13 or even bigger.
> >> >>
> >> >> indeed, in src/bin/sage-env on has
> >> >>
> >> >> MACOSX_DEPLOYMENT_TARGET=10.9
> >> >>
> >> >> which is the reason for that error, I guess.
> >> >
> >> >
> >> > Shouldn't it be 11.0?
> >> >
> >> > I changed it then tried to recompile but it stopped at the same place.
> >> > I can't install a system python3 using homebrew since it's broken
> >> > https://github.com/Homebrew/brew/issues/7803
> >>
> >> you can install a binary python3.7 from python.org - this is known to
> >> be possible to use in Sage on macOS 10.15 and earlier versions.
> >>
> >
> > I installed both python 3.8.5 (the latest) and when that failed 3.7.9.
> >
> > The end of the output of configure is this seeming contradictory info:
> >
> > configure: notice: the following SPKGs did not find equivalent system 
> packages: brial cbc cddlib cliquer coxeter3 eclib ecm fflas_ffpack flintqs 
> fplll gf2x gfan givaro glpk gp2c gsl iconv iml lcalc libatomic_ops 
> libbraiding libsemigroups lrcalc m4ri m4rie nauty ninja_build openblas palp 
> pandoc pari pari_elldata pari_galdata pari_galpol pari_nftables 
> pari_seadata pari_seadata_small pcre perl_cpan_polymake_prereq 
> perl_term_readline_gnu planarity ppl python3 r rw suitesparse symmetrica 
> sympow tachyon yasm zeromq zn_poly
>
> This notice is more about ./configure being confused whether there is
> Homebrew or Conda installed.
>
> The interesting line of ./configure output is above that notice:
>
> python3-3.7.3.p1: using system package;
> SPKG will not be installed
>
> - if it's there then system Python will be used.
> Otherwise, look in config.log for more details.
>
> HTH
> Dima
>
>
> >
> > checking for the package system in use... unknown
> >
> > wdj@jeeves sage-9.2.beta9 % which python3
> >
> > /usr/local/bin/python3
> >
> > wdj@jeeves sage-9.2.beta9 % python3 --version
> >
> > Python 3.7.9
> >
> > There isn't a python3 system package but there is?
> >
> >>
> >> >
> >> >
> >> >>
> >> >>
> >> >> >
> >> >> > On Sat, Aug 22, 2020 at 8:06 PM David Joyner  
> wrote:
> >> >> > >
> >> >> > > Hi:
> >> >> > >
> >> >> > > I don't know if this has been discussed yet but
> >> >> > > I just upgraded to mac os 11.0. I downloaded
> >> >> > > sage 9.2.b9 and ran make. I got a "you must
> >> >> > > run ./configure first message, which I did.
> >> >> > > Then I ran make and the compilation stopped while
> >> >> > > compiling python 3. The log is attached.
> >> >> > >
> >> >> > > - David Joyner
> >> >> > >
> >> >> > >
> >> >> > > --
> >> >> > > You received this message because you are subscribed to the 
> Google Groups "sage-support" group.
> >> >> > > To unsubscribe from this group and stop receiving emails from 
> it, send an email to sage-support...@googlegroups.com.
> >> >> > > To view this discussion on the web visit 
> https://groups.google.com/d/msgid/sage-support/CAEQuuAVjRasvOnj7NKQGfXxjL2g9XPfi8WFXdO-6A3mZ_XedHg%40mail.gmail.com
> .
> >> >>
> >> >> --
> >> >> You received this message because you are subscribed to the Google 
> Groups "sage-support" group.
> >> >> To unsubscribe from this group and stop receiving emails from it, 
> send an email to sage-support...@googlegroups.com.
> >> >> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/sage-support/CAAWYfq2AU24nTFsL2eq3%3DPYgj5320t2LyQJV%2BRFon%2BhrzLJseA%40mail.gmail.com
> .
> >> >
> >> > --
> >> > You received this message because you are subscribed to the Google 
> Groups "sage-support" group.
> >> > To unsubscribe from this group and stop receiving emails from it, 
> send an email to sage-support...@googlegroups.com.
> >> > To view this discussion on the web visit 
> https://groups.google.com/d/msgid/sage-support/CAEQuuAUnZEypSLGc%3DJu8jfZdkSCB6LN4xCg8%2B9A7Fa%3DTnYAuAQ%40mail.gmail.com
> .
> >>
> >> --
> >> You received this message because you are subscribed to the Google 
> Groups "sage-support" group.
> >> To unsubscribe from this group and stop receiving emails from it, send 
> an email to sage-support...@googlegroups.com.
> >> 

[sage-support] Is our toric varieties documentation misleading and/or wrong?

2020-08-27 Thread John H Palmieri
See 
https://math.stackexchange.com/questions/3802874/does-isomorphic-mathbb-q-cohomology-implies-isomorphic-mathbb-z-cohomology/3803623#3803623

Can someone who knows the mathematics decide whether this is an issue that 
needs to be fixed, or whether the documentation could be clarified?

-- 
John

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/8036ed13-c0a6-4271-bd89-ca7f83732925o%40googlegroups.com.


[sage-support] Re: Question about a deprecation warning

2020-07-10 Thread John H Palmieri
Does IPython have a preparser?


On Thursday, July 9, 2020 at 11:43:36 PM UTC-7, Kwankyu wrote:
>
> Because of the preparser?
>
> On Thursday, July 2, 2020 at 9:19:58 AM UTC+9 John H Palmieri wrote:
>
>>
>>
>> On Wednesday, July 1, 2020 at 4:39:12 PM UTC-7, John H Palmieri wrote:
>>>
>>>
>>>
>>> On Wednesday, July 1, 2020 at 2:22:49 PM UTC-7, Antonio Rojas wrote:
>>>>
>>>>
>>>>
>>>> El miércoles, 1 de julio de 2020, 21:06:43 (UTC+2), John H Palmieri 
>>>> escribió:
>>>>>
>>>>>
>>>>> Why so many deprecation warnings? I think they're coming from plain 
>>>>> Python; why doesn't Python print the warnings?
>>>>>
>>>>>
>>>>>
>>>> Because python ignores deprecation warnings, 
>>>> https://docs.python.org/3/library/warnings.html#default-warning-filter 
>>>>
>>>
>>> Thanks, that's helpful. But why does Sage print the warning so many 
>>> times? If I turn on Python's deprecation warnings, I just see one warning 
>>> message, not six of them.
>>>
>>>
>> I guess this is in turn an IPython thing, although I don't know why 
>> IPython prints the warning 6 times, and also repeats my original command. 
>> With warnings enabled, I evaluated '\i' once:
>>
>> % PYTHONWARNINGS=always sage --ipython
>> ...
>> IPython 5.8.0 -- An enhanced Interactive Python.
>> ? -> Introduction and overview of IPython's features.
>> %quickref -> Quick reference.
>> help  -> Python's own help system.
>> object?   -> Details about 'object', use 'object??' for extra details.
>>
>> In [1]: '\i':1: DeprecationWarning: invalid escape sequence \i
>> :1: DeprecationWarning: invalid escape sequence \i
>> :1: DeprecationWarning: invalid escape sequence \i
>> In [1]: '\i'
>>
>> :1: DeprecationWarning: invalid escape sequence \i
>> :1: DeprecationWarning: invalid escape sequence \i
>> :1: DeprecationWarning: invalid escape sequence \i
>> :1: DeprecationWarning: invalid escape 
>> sequence \i
>>   '\i'
>> Out[1]: '\\i'
>>
>>
>>
>>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/81516c8f-1161-4507-b5a1-5c7198ffa49ao%40googlegroups.com.


[sage-support] Re: Question about a deprecation warning

2020-07-01 Thread John H Palmieri


On Wednesday, July 1, 2020 at 4:39:12 PM UTC-7, John H Palmieri wrote:
>
>
>
> On Wednesday, July 1, 2020 at 2:22:49 PM UTC-7, Antonio Rojas wrote:
>>
>>
>>
>> El miércoles, 1 de julio de 2020, 21:06:43 (UTC+2), John H Palmieri 
>> escribió:
>>>
>>>
>>> Why so many deprecation warnings? I think they're coming from plain 
>>> Python; why doesn't Python print the warnings?
>>>
>>>
>>>
>> Because python ignores deprecation warnings, 
>> https://docs.python.org/3/library/warnings.html#default-warning-filter 
>>
>
> Thanks, that's helpful. But why does Sage print the warning so many times? 
> If I turn on Python's deprecation warnings, I just see one warning message, 
> not six of them.
>
>
I guess this is in turn an IPython thing, although I don't know why IPython 
prints the warning 6 times, and also repeats my original command. With 
warnings enabled, I evaluated '\i' once:

% PYTHONWARNINGS=always sage --ipython
...
IPython 5.8.0 -- An enhanced Interactive Python.
? -> Introduction and overview of IPython's features.
%quickref -> Quick reference.
help  -> Python's own help system.
object?   -> Details about 'object', use 'object??' for extra details.

In [1]: '\i':1: DeprecationWarning: invalid escape sequence \i
:1: DeprecationWarning: invalid escape sequence \i
:1: DeprecationWarning: invalid escape sequence \i
In [1]: '\i'
:1: DeprecationWarning: invalid escape sequence \i
:1: DeprecationWarning: invalid escape sequence \i
:1: DeprecationWarning: invalid escape sequence \i
:1: DeprecationWarning: invalid escape 
sequence \i
  '\i'
Out[1]: '\\i'



-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/15f4bfab-8605-4099-a3e6-c35f10f6942fo%40googlegroups.com.


[sage-support] Re: Question about a deprecation warning

2020-07-01 Thread John H Palmieri


On Wednesday, July 1, 2020 at 2:22:49 PM UTC-7, Antonio Rojas wrote:
>
>
>
> El miércoles, 1 de julio de 2020, 21:06:43 (UTC+2), John H Palmieri 
> escribió:
>>
>>
>> Why so many deprecation warnings? I think they're coming from plain 
>> Python; why doesn't Python print the warnings?
>>
>>
>>
> Because python ignores deprecation warnings, 
> https://docs.python.org/3/library/warnings.html#default-warning-filter 
>

Thanks, that's helpful. But why does Sage print the warning so many times? 
If I turn on Python's deprecation warnings, I just see one warning message, 
not six of them.

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/b753e544-c3f5-4289-946f-4c2e63df007bo%40googlegroups.com.


[sage-support] Question about a deprecation warning

2020-07-01 Thread John H Palmieri
This puzzles me: evaluating '\i' in Python 3 just gives '\i'. Same with 
IPython. Evaluating it in Sage prints many warning messages: the following 
is from a fresh Sage session, and I only evaluated '\i' once, despite the 
appearance:


% sage
┌┐
│ SageMath version 9.2.beta2, Release Date: 2020-06-26   │
│ Using Python 3.7.7. Type "help()" for help.│
└┘
┏┓
┃ Warning: this is a prerelease version, and it may be unstable. ┃
┗┛
sage: '\i':1: DeprecationWarning: invalid escape sequence \i
:1: DeprecationWarning: invalid escape sequence \i
:1: DeprecationWarning: invalid escape sequence \i
sage: '\i'
:1: DeprecationWarning: invalid escape sequence \i
:1: DeprecationWarning: invalid escape sequence \i
:1: DeprecationWarning: invalid escape sequence \i
:1: DeprecationWarning: invalid escape 
sequence \i
  '\i'
'\\i'
sage: 


Why so many deprecation warnings? I think they're coming from plain Python; 
why doesn't Python print the warnings?

-- 
John

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/0a45ea8f-0062-4aad-b4d9-0b12a175daf9o%40googlegroups.com.


[sage-support] Re: bug in CirculantGraph(10,[2,4])?

2020-06-29 Thread John H Palmieri
According to wikipedia, graphs.CirculantGraph(n, [j_1, j_2, ...]) is 
connected if and only if gcd(n, j_1, j_2, ...) = 1. In this case, the gcd 
is 2. If Sage's definition is correct, it's defined as having 10 vertices, 
and vertex i is connected to vertices i+2, i-2, i+4, i-4, then even 
vertices will only be connected to other even vertices, so it should have 
two connected components.

(I'm not a graph theorist, and wikipedia is wikipedia, so take this with a 
grain of salt.)

  John


On Monday, June 29, 2020 at 10:25:26 AM UTC-7 wdjo...@gmail.com wrote:

> Hi: 
>
> In SageMath version 9.1.beta3, I get
>
> sage: Gamma1 = graphs.CirculantGraph(*10*,[*2*,*4*])
>
> sage: Gamma1.is_connected()
>
> False
>
>
> My understanding is that all circulant graphs are connected. 
>
> Is this a bug?
>
> - David
>
>
>
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/f76cc4fa-4406-40ef-bf1b-7b285407f4d0n%40googlegroups.com.


[sage-support] Conda install: docs?

2020-06-14 Thread John H Palmieri
When I follow the directions at 
https://doc.sagemath.org/html/en/installation/conda.html#sec-installation-conda 
for installing via conda, it seems that the Sage documentation is not 
built, and furthermore, it is not clear to me how to build it. Am I missing 
something?

See also 
https://ask.sagemath.org/question/51915/installing-from-conda-forge/.

-- 
John

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/1b23a734-ef3b-4690-bcb5-d59e9a9c923do%40googlegroups.com.


Re: [sage-support] How to use notebook in sage 9.0?

2020-05-06 Thread John H Palmieri
Silly question, but are you sure you are starting up Sage 9.0 when you do 
all of this ("sage --notebook" or "sage --sh")? If you give an explicit 
path to the Sage 9.0 version, does that help? Do you have any Sage-related 
environment variables which could be interfering with things?


On Wednesday, May 6, 2020 at 12:54:16 PM UTC-7, Szabolcs Horvát wrote:
>
> Thanks for the help Dima, but sadly, even this did not work :-( Is there a 
> simple way to set up the kernel manually?
>
> On Wed, 6 May 2020 at 20:32, Dima Pasechnik  > wrote:
>
>> this looks like a conflict between two versions of Sage (more
>> precisely, of jupyter).
>>
>> Not sure how this can happen, though. You migh try to start "sage -sh"
>> of your Sage 9.0 and at its
>> prompt start
>>
>> jupyter-notebook
>>
>> it should give you an option to open URL of the shape
>> http://localhost:/?token=
>>
>> where you should ge the correct jupyter kernel (hopefully)
>>
>>
>> On Wed, May 6, 2020 at 7:19 PM Szabolcs Horvát > > wrote:
>> >
>> >
>> >
>> > On Wednesday, 6 May 2020 20:11:50 UTC+2, Dima Pasechnik wrote:
>> >>
>> >> On Wed, May 6, 2020 at 6:58 PM Szabolcs Horvát  
>> wrote:
>> >> >
>> >> > I use sage 9.0 and sage 8.9 on macOS. I compiled them myself so I 
>> would gain access to other ILP solvers than GLPK.
>> >> >
>> >> > They work fine in command line mode. But if I start Sage 9.0 as sage 
>> --notebook, it gives me an interface to create a new notebook, which only 
>> has the kernel "Sage 8.9".  How can I get the Sage 9.0 kernel?
>> >>
>> >>  sage -notebook=jupyter
>> >>
>> >> should give you jupyter notebook.
>> >>
>> >> sagenb would only work with Python2 Sage (by default Sage 9.0 is built
>> >> with Python3, not 2)
>> >>
>> >
>> > Yes, I do get a Jupyter page in the browser, but not a notebook. In 
>> order to create a notebook, one must click "New" and choose the Jupyter 
>> kernel to use. There is no Sage 9.0 kernel there. There are some of the 
>> Python kernels I use independently of Sage, and there is Sage 8.9. How can 
>> I install the Sage 9.0 kernel? Is there documentation on this?
>> >
>> > --
>> > You received this message because you are subscribed to the Google 
>> Groups "sage-support" group.
>> > To unsubscribe from this group and stop receiving emails from it, send 
>> an email to sage-s...@googlegroups.com .
>> > To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/sage-support/4feab8f6-c3dc-450d-92c3-95039aa1d7e2%40googlegroups.com
>> .
>>
>> -- 
>> You received this message because you are subscribed to a topic in the 
>> Google Groups "sage-support" group.
>> To unsubscribe from this topic, visit 
>> https://groups.google.com/d/topic/sage-support/X5sXp3a-TmA/unsubscribe.
>> To unsubscribe from this group and all its topics, send an email to 
>> sage-s...@googlegroups.com .
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/sage-support/CAAWYfq1viv3gEHKxfPCRqLBmvFc9gOsCKJiu1c_s_yQoDF8XWg%40mail.gmail.com
>> .
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/124d3fe3-1b3a-4c5e-aee5-f2a44bb446cd%40googlegroups.com.


[sage-support] Re: Extended Operations on Symbols

2020-04-26 Thread John H Palmieri
sage: var('q')
q
sage: (q+q^(-1))^(1/2)
sqrt(q + 1/q)

(By the way, I'm not sure I would call using a fraction field "naive".)


On Sunday, April 26, 2020 at 9:01:35 AM UTC-7, Jin Guu wrote:
>
> I am writing a calculator for various 'q' quantities, and often find that 
> I need to manipulate symbols more flexibly. For example, I have to deal 
> with the expression
>
> ( q + q^(-1) ) ^ (1/2) -- (*)
>
> But currently I could not find any way to achieve this. A naive attempt 
> gives a failure:
>
> sage: q = Frac(ZZ['q']).gen()
> sage: q ^ (1/2)
> ---> ValueError: not a 2nd power
> sage: power(q, 1/2)
> NotImplementedError: non-integral exponents not supported
>
> Leave alone the expression I need! Indeed, one might have to define a 
> larger parent for the expression (*) to live in. So this might require 
> implementing a new algebraic structure. If that's the case, I'm willing to 
> write it. The problem is that implementing a new structure seems a bit 
> complicated to me.. I might take some time, and need some guides. Thank you 
> so much!
>
> PS. Weirdly enough, exp(sin(q)) is already implemented as in the class 
> . Perhaps what I need might 
> not be too hard to implement?
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/ade75123-de8c-4c93-a81b-ba244057c72a%40googlegroups.com.


[sage-support] Re: How to modify the index of a matrix

2020-04-20 Thread John H Palmieri


On Monday, April 20, 2020 at 1:01:24 PM UTC-7, Emmanuel Zuñiga wrote:
>
> Hello, i would like to know how to modify the index of a matrix in 
> sagemath. As an example, we all know that every object begins in 0, m[0] 
> and that kind of things.
> Now, i need to modify this. to add one to the index, not beggining in 0, i 
> want it that the matrix index begin in 1 for rows and columns. I will 
> appreciate your answer. 
> Thanks!
>

It might help if you let us know what you're hoping to accomplish. For 
example, would it be good enough to, instead of work with 3x3 matrices, 
work with 4x4 matrices with zeroes in the 0th row and column? Then all of 
the potential nonzero entries will start in row 1, column 1.

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/55681950-7b26-431f-a833-914b4b78b319%40googlegroups.com.


Re: [sage-support] simple desolve_tides_mpfr crash, even for SageMath Cell Server

2020-04-16 Thread John H Palmieri
Maybe SageCell doesn't have the optional package "tides" installed. This is 
the same error I see on my own computer without "tides".



On Thursday, April 16, 2020 at 9:26:21 AM UTC-7, slelievre wrote:
>
> Here is the error after executing the original poster's code in SageCell.
>
> ---CalledProcessError
> Traceback (most recent call 
> last) in ()  8 z0 = Integer(27) 
>  9 T = 
> RealNumber('15.586522107161747275678702092126960705284805489972439358895215783190198756258880854355851082660142374')--->
>  10 sol = desolve_tides_mpfr(f, [x0, y0, z0],Integer(0) , T, T, 
> RealNumber('1e-100'), RealNumber('1e-100'), Integer(100)) # optional - tides  
>11 print(sol)
> /home/sc_serv/sage/local/lib/python3.7/site-packages/sage/calculus/desolvers.py
>  in desolve_tides_mpfr(f, ics, initial, final, delta, tolrel, tolabs, digits) 
>   1887   + os.path.join('-L$SAGE_LOCAL','lib ') + 
> '-lmpfr -lgmp -lm  -O2 -w ' +   1888   
> os.path.join('-I$SAGE_LOCAL','include ') ,-> 1889   
> shell=True,  stdout=subprocess.PIPE, stderr=subprocess.PIPE)   1890 
> subprocess.check_call(os.path.join(tempdir, 'runme'), shell=True,  
> stdout=subprocess.PIPE, stderr=subprocess.PIPE)   1891 outfile = 
> open(fileoutput)
> /home/sc_serv/sage/local/lib/python3.7/subprocess.py in 
> check_call(*popenargs, **kwargs)345 if cmd is None:346
>  cmd = popenargs[0]--> 347 raise CalledProcessError(retcode, cmd) 
>348 return 0349 
> CalledProcessError: Command 'gcc -o 
> /home/sc_work/.sage/temp/sc-2B/23183/dir_rwnrlkk7/runme 
> /home/sc_work/.sage/temp/sc-2B/23183/dir_rwnrlkk7/*.c 
> $SAGE_LOCAL/lib/libTIDES.a $LDFLAGS -L$SAGE_LOCAL/lib -lmpfr -lgmp -lm  -O2 
> -w -I$SAGE_LOCAL/include ' returned non-zero exit status 1.
>
>  
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/18706f73-8228-4646-9989-82fc2795414e%40googlegroups.com.


Re: [sage-support] Sage Crash report

2020-04-09 Thread John H Palmieri
Did you look at the file "README.md"? It suggests building in parallel to 
speed things up. Have you tried that?


On Thursday, April 9, 2020 at 12:35:58 PM UTC-7, hbetx9 wrote:
>
> I htink I know what I did, somehow I change the prefix to a directory that 
> didn't exist. I'm recompiling to see if the error is fixed. 
>
> Boy does this compile take a LONG time, is that the same for everyone? 
>
>
>
> On Thursday, April 9, 2020 at 2:26:48 PM UTC-5, hbetx9 wrote:
>>
>> Okay, I did something apparently odd. 
>>
>> For context, I first unpacked in a directory, ran make (took a long time) 
>> and would close with an error concerning R as above. Sage would work on 
>> command line by running the copy in this directory. However, something I 
>> did broke this install, and I'm wondering if I should just erase and start 
>> over. 
>>
>> Now make finishes with 
>>
>> Makefile:31: recipe for target 'base-toolchain' failed
>> make: *** [base-toolchain] Error 1
>>
>> and when running I get only the following message 
>>
>> 
>> It seems that you are attempting to run Sage from an unpacked source
>> tarball, but you have not compiled it yet (or maybe the build has not
>> finished). You should run `make` in the Sage root directory first.
>> If you did not intend to build Sage from source, you should download
>> a binary tarball instead. Read README.txt for more information.
>> 
>>
>> Should I just start over or is there an easy way to repair this issue? 
>>
>> On Wednesday, April 8, 2020 at 11:12:19 PM UTC-5, Matthias Koeppe wrote:
>>>
>>> On Wednesday, April 8, 2020 at 8:01:38 PM UTC-7, hbetx9 wrote:

 No, I just want all users to have this at default. Where should I put 
 the SAGE_ROOT directory? /usr/local? 

>>>
>>> Use "./configure --prefix=/usr/local/opt/sage-9.0" to set the 
>>> installation prefix (SAGE_LOCAL).
>>>
>>>
>>>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/aef99461-ab90-41a7-a198-9585503996e8%40googlegroups.com.


Re: [sage-support] Building on Catalina

2020-04-08 Thread John H Palmieri
When I have had problems with libpng, it has helped to do "brew install 
pkg-config". If you happened to start building Sage and then upgraded 
Homebrew and/or Xcode in the middle of that, or if you've installed any new 
Homebrew packages,  you should probably start over with "make distclean" 
followed by "make".


On Wednesday, April 8, 2020 at 7:58:38 PM UTC-7, David Einstein wrote:
>
> Here is the config.log.
>
> On Wednesday, April 8, 2020 at 10:32:51 PM UTC-4, Dima Pasechnik wrote:
>>
>> Hi David, 
>> It might help if you posted the top-level config.log, thanks. 
>>
>> Dima 
>>
>> On Thu, Apr 9, 2020 at 9:58 AM David Einstein  wrote: 
>> > 
>> > I am trying to build on OSX Catalina, and everything seems to go well 
>> until it builds sagelib, and I get a libpng not found. 
>> > 
>> > Everything built nicely a few weeks ago.  I am tempted to blame the 
>> upgrade to catalina, but I also upgraded hombrew and XCode. 
>> > 
>> > Any ideas? 
>> > 
>> > Here is the final output from the terminal. 
>> > 
>> > if [ -z "$SAGE_INSTALL_FETCH_ONLY" ]; then \ 
>> > 
>> > cd /Users/davideinstein/projects/sage/src && source bin/sage-env && 
>> source /Users/davideinstein/projects/sage/build/bin/sage-build-env-config 
>> && \ 
>> > 
>> > sage-logger -p 'time make sage' 
>> '/Users/davideinstein/projects/sage/logs/pkgs/sagelib-9.1.beta9.log'; \ 
>> > 
>> > fi 
>> > 
>> > [sagelib-9.1.beta9] cd . && export\ 
>> > 
>> > [sagelib-9.1.beta9] SAGE_ROOT=/doesnotexist 
>>   \ 
>> > 
>> > [sagelib-9.1.beta9] SAGE_SRC=/doesnotexist 
>>\ 
>> > 
>> > [sagelib-9.1.beta9] SAGE_SRC_ROOT=/doesnotexist 
>>   \ 
>> > 
>> > [sagelib-9.1.beta9] SAGE_DOC_SRC=/doesnotexist 
>>\ 
>> > 
>> > [sagelib-9.1.beta9] SAGE_BUILD_DIR=/doesnotexist   
>>\ 
>> > 
>> > [sagelib-9.1.beta9] 
>> SAGE_PKGS=/Users/davideinstein/projects/sage/build/pkgs\ 
>> > 
>> > [sagelib-9.1.beta9] && sage-python -u setup.py --no-user-cfg build 
>> install 
>> > 
>> > [sagelib-9.1.beta9] 
>> /Users/davideinstein/projects/sage/src/bin/sage-env: line 130: cd: 
>> /doesnotexist: No such file or directory 
>> > 
>> > [sagelib-9.1.beta9] Warning: overwriting SAGE_ROOT environment 
>> variable: 
>> > 
>> > [sagelib-9.1.beta9] Old SAGE_ROOT=/doesnotexist 
>> > 
>> > [sagelib-9.1.beta9] New SAGE_ROOT= 
>> > 
>> > [sagelib-9.1.beta9] 
>>  
>> > 
>> > [sagelib-9.1.beta9] Traceback (most recent call last): 
>> > 
>> > [sagelib-9.1.beta9]   File "setup.py", line 72, in  
>> > 
>> > [sagelib-9.1.beta9] from module_list import ext_modules, 
>> library_order 
>> > 
>> > [sagelib-9.1.beta9]   File 
>> "/Users/davideinstein/projects/sage/src/module_list.py", line 36, in 
>>  
>> > 
>> > [sagelib-9.1.beta9] png_pc = pkgconfig.parse('libpng') 
>> > 
>> > [sagelib-9.1.beta9]   File 
>> "/Users/davideinstein/projects/sage/local/lib/python3.7/site-packages/pkgconfig/pkgconfig.py",
>>  
>> line 248, in parse 
>> > 
>> > [sagelib-9.1.beta9] _raise_if_not_exists(package) 
>> > 
>> > [sagelib-9.1.beta9]   File 
>> "/Users/davideinstein/projects/sage/local/lib/python3.7/site-packages/pkgconfig/pkgconfig.py",
>>  
>> line 103, in _raise_if_not_exists 
>> > 
>> > [sagelib-9.1.beta9] raise PackageNotFoundError(package) 
>> > 
>> > [sagelib-9.1.beta9] pkgconfig.pkgconfig.PackageNotFoundError: libpng 
>> not found 
>> > 
>> > [sagelib-9.1.beta9] 
>>  
>> > 
>> > [sagelib-9.1.beta9] Error building the Sage library 
>> > 
>> > [sagelib-9.1.beta9] 
>>  
>> > 
>> > [sagelib-9.1.beta9] Please email sage-devel (
>> http://groups.google.com/group/sage-devel) 
>> > 
>> > [sagelib-9.1.beta9] explaining the problem and including the relevant 
>> part of the log file 
>> > 
>> > [sagelib-9.1.beta9]   
>> /Users/davideinstein/projects/sage/logs/pkgs/sagelib-9.1.beta9.log 
>> > 
>> > [sagelib-9.1.beta9] Describe your computer, operating system, etc. 
>> > 
>> > [sagelib-9.1.beta9] 
>>  
>> > 
>> > [sagelib-9.1.beta9] make[4]: *** [sage] Error 1 
>> > 
>> > [sagelib-9.1.beta9] 
>> > 
>> > [sagelib-9.1.beta9] real 0m0.612s 
>> > 
>> > [sagelib-9.1.beta9] user 0m0.193s 
>> > 
>> > [sagelib-9.1.beta9] sys 0m0.133s 
>> > 
>> > make[3]: *** [sagelib] Error 2 
>> > 
>> > make[2]: *** [all-start] Error 2 
>> > 
>> > 
>> > real 212m28.552s 
>> > 
>> > user 151m29.195s 
>> > 
>> > sys 26m1.334s 
>> > 
>> > *** 
>> > 
>> > Error building Sage. 
>> > 
>> > 
>> > The following package(s) may have failed to build (not necessarily 
>> > 
>> > during this run of 

[sage-support] Re: deprecation warning about "`\QQ`" and "\*"

2020-03-29 Thread John H Palmieri
On Sunday, March 29, 2020 at 12:24:38 AM UTC-7, rana-aere wrote:
>
> Thank you for clear instructions.
> I used the codes to compare how doctoring of the method _macaulay2_init_ 
> is displayed. 
>
> sage-8.9 (command line and jupyter)
>
> ```
> Init docstring: x.__init__(...) initializes x; see help(type(x)) for 
> signature
> File:   
> /Applications/SageMath-8.9.app/Contents/Resources/sage/local/lib/python2.7/site-packages/sage/structure/sage_object.pyx
> Type:   builtin_function_or_method
> ```
>
> sage-9.0 (command line and jupyter )
>
> ```
> Signature:  S._macaulay2_init_(macaulay2=None)
> Docstring: 
>EXAMPLES:
>
>Quotients of multivariate polynomial rings over QQ, ZZ and a
>finite field:
> ```
>
> sage-9.1 (command line and jupyter)
>
> ```
> Signature:  S._macaulay2_init_(macaulay2=None)
> Docstring: 
>EXAMPLES:
>
>Quotients of multivariate polynomial rings over \QQ, \ZZ and a
>finite field:
> ```
>
> All three have different behaviors.
>

The difference between Sage 8.9 and 9.0 is probably due to the switch from 
Python 2 to Python 3.
 

>
> I think true and meaningful difference should be observed in conversion to 
> tutorial, wiki or manual
>

I don't consider these differences meaningful. What are you concerned about?
 

> If someone knows how to test it, please tell me the result.
>

Test what, exactly?
 

> I will find a way to make a ticket for it.
>
> For now I proceed to check issues on "sqrt?"
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/0d0dcb1d-84bb-41ad-b247-8aa7a296922c%40googlegroups.com.


[sage-support] Re: deprecation warning about "`\QQ`" and "\*"

2020-03-28 Thread John H Palmieri


On Saturday, March 28, 2020 at 7:07:53 AM UTC-7, rana-aere wrote:
>
>
>
> I am compiling binary-pkg and encountered a deprecation warning.
> The warning appeared when I invoked sage from command line.
> (Technically, it was after messages of patching.)
>
> The warning reads
>
> ```
> .../quotient_ring.py:1350: DeprecationWarning: invalid escape sequence \Q
> ```
>
> I read the file quotient_ring.py located at 
> SageMath-9.1.beta8.app/Contents/Resources/sage/local/lib/python3.7/site-packages/sage/rings.
>
> The description (line 1300--1350) of _macaulay2_init contains a line
>
> ```
> Quotients of multivariate polynomial rings over `\QQ`, `\ZZ` and
> ```
>
> So, I inserted 'r' before """ on line 1300. (""" -> r""").
>
> After reinvocation of sage, the previous warning is gone.
> Unfortunately, I cannot test the effect of the change on description.
> I tried typing "_macaulay2_init_?". This did not work.
>

It's a method, not a function. You have to call it on an appropriate object.

R. = PolynomialRing(QQ)
I = R.ideal([x^2-y])
S = R.quotient_ring(I)
S._macaulay2_init_?

 

>
> How can I test it? (Question 1.)
>

Adding the "r" is certainly the right thing to do.
 

>
> I thought  function name with "?" might not be the right syntax.
> So, I tested "sqrt?". It gave me a series of deprecation warnings like
>
> ```
> .../sessions.py:565: DeprecationWarning: invalid escape sequence \*
> ```
>
> They make the screen to scroll one page.
>
> These warnings for sessions.py are also descriptions of functions enclosed 
> by """...""" pair inserted of r"""...""".
> Yes, the recommended style was r"""..."" for description containing latex 
> expressions.
> The warnings for sessions.py might be regular expressions intended to be 
> displayed by "function_name?"
> or may be "*" are really escaped so that enclosing by r"""...""" and 
> changing "\*" with "*" might help.
> I do not have knowledge to distinguish these two.
>
> (Question 2.) Is there any body who can tell which correction is suitable 
> for sessions.py?
> Option 1. """...""" -> r"""..."""
> Option ". """... \*...""" -> r"""... *..."""
>

There is no file "sessions.py" in the Sage library. This may be referring 
to a file in some package like "requests", but that's not a file that the 
Sage developers control. Once you identify which package the file comes 
from, talk to its developers about what to do.

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/16d54cd1-d52b-4fa3-a1c8-5d36d48aee53%40googlegroups.com.


Re: [sage-support] sage with python3, mpmath

2020-01-14 Thread John H Palmieri
On line 158, in the function "numerical_python", I see

A, B = divmod(n, base**half)






On Tuesday, January 14, 2020 at 11:54:21 AM UTC-8, Александр Ватузов wrote:
>
> and what is on mpmath file, analog of 
> "/SageMath/local/lib/python3.7/site-packages/mpmath/libmp/libintmath.py", 
> line 161 ? Just interesting :)
>
> вторник, 14 января 2020 г., 21:20:05 UTC+3 пользователь John H Palmieri 
> написал:
>>
>> Sorry, I meant Sage *9.1.beta0*.
>>
>> On Tuesday, January 14, 2020 at 10:18:41 AM UTC-8, John H Palmieri wrote:
>>>
>>> Just to confirm: everything works with Sage 9.0.beta1, built with Python 
>>> 2. Fails with Sage built with Python 3.
>>>
>>>
>>> On Tuesday, January 14, 2020 at 5:55:51 AM UTC-8, Александр Ватузов 
>>> wrote:
>>>>
>>>> https://trac.sagemath.org/ticket/29009#ticket
>>>>
>>>> вторник, 14 января 2020 г., 16:36:27 UTC+3 пользователь Александр 
>>>> Ватузов написал:
>>>>>
>>>>> Now I constantly know, that problem was in using
>>>>>
>>>>> divmod(n, base**half)
>>>>>
>>>>> instead of
>>>>>
>>>>> n // (base**half), n % (base**half)
>>>>>
>>>>> on File 
>>>>> "/home/nouret/SageMath/local/lib/python3.7/site-packages/mpmath/libmp/libintmath.py",
>>>>>  
>>>>> line 161, in numeral_python
>>>>>
>>>>> вторник, 14 января 2020 г., 15:42:17 UTC+3 пользователь Dima Pasechnik 
>>>>> написал:
>>>>>>
>>>>>> On Tue, Jan 14, 2020 at 12:37 PM Александр Ватузов  
>>>>>> wrote: 
>>>>>> > 
>>>>>> > I haven-fount where report bug on that site... 
>>>>>> > 
>>>>>> you open a new ticket: https://trac.sagemath.org/newticket 
>>>>>> - you'd need either a Guthub account, or a local account (long time 
>>>>>> to 
>>>>>> get sometimes) to authenticate. 
>>>>>>
>>>>>>
>>>>>> > Now I will try to repair smth: 
>>>>>> > 
>>>>>> > I have 2 dirs: 
>>>>>> > SageMath/local/lib/python3.7/site-packages/mpmath 
>>>>>> > .local/lib/python3.6/site-packages/mpmath 
>>>>>> > 
>>>>>> > I think there are sima chenges here 
>>>>>> > 
>>>>>> > вторник, 14 января 2020 г., 14:57:31 UTC+3 пользователь Dima 
>>>>>> Pasechnik написал: 
>>>>>> >> 
>>>>>> >> On Tue, Jan 14, 2020 at 11:53 AM Александр Ватузов <
>>>>>> amva...@gmail.com> wrote: 
>>>>>> >> > 
>>>>>> >> > Will you open issue here? https://trac.sagemath.org/ 
>>>>>> >> 
>>>>>> >> I can't reproduce the issue with a system python 3.7.3, so it 
>>>>>> deserves 
>>>>>> >> a trac ticket. 
>>>>>> >> Can you open one? 
>>>>>> >> 
>>>>>> >> > 
>>>>>> >> > Or I can try to do something 
>>>>>> >> > 
>>>>>> >> > вторник, 14 января 2020 г., 14:08:08 UTC+3 пользователь Dima 
>>>>>> Pasechnik написал: 
>>>>>> >> >> 
>>>>>> >> >> I have opened 
>>>>>> https://github.com/fredrik-johansson/mpmath/issues/503 
>>>>>> >> >> to report this. 
>>>>>> >> >> 
>>>>>> >> >> On Tue, Jan 14, 2020 at 10:59 AM Eric Gourgoulhon 
>>>>>> >> >>  wrote: 
>>>>>> >> >> > 
>>>>>> >> >> > PS: a similar error has been reported on ask.sagemath: 
>>>>>> https://ask.sagemath.org/question/49534/error-with-mpmathfindroot-on-89/ 
>>>>>> >> >> > 
>>>>>> >> >> > Le mardi 14 janvier 2020 11:55:08 UTC+1, Eric Gourgoulhon a 
>>>>>> écrit : 
>>>>>> >> >> >> 
>>>>>> >> >> >> Le mardi 14 janvier 2020 11:36:44 UTC+1, Dima Pasechnik a 
>>>>>> écrit : 
>>>>>> >> >> >>> 
>>>>>> >> >

Re: [sage-support] sage with python3, mpmath

2020-01-14 Thread John H Palmieri
Sorry, I meant Sage *9.1.beta0*.

On Tuesday, January 14, 2020 at 10:18:41 AM UTC-8, John H Palmieri wrote:
>
> Just to confirm: everything works with Sage 9.0.beta1, built with Python 
> 2. Fails with Sage built with Python 3.
>
>
> On Tuesday, January 14, 2020 at 5:55:51 AM UTC-8, Александр Ватузов wrote:
>>
>> https://trac.sagemath.org/ticket/29009#ticket
>>
>> вторник, 14 января 2020 г., 16:36:27 UTC+3 пользователь Александр Ватузов 
>> написал:
>>>
>>> Now I constantly know, that problem was in using
>>>
>>> divmod(n, base**half)
>>>
>>> instead of
>>>
>>> n // (base**half), n % (base**half)
>>>
>>> on File 
>>> "/home/nouret/SageMath/local/lib/python3.7/site-packages/mpmath/libmp/libintmath.py",
>>>  
>>> line 161, in numeral_python
>>>
>>> вторник, 14 января 2020 г., 15:42:17 UTC+3 пользователь Dima Pasechnik 
>>> написал:
>>>>
>>>> On Tue, Jan 14, 2020 at 12:37 PM Александр Ватузов  
>>>> wrote: 
>>>> > 
>>>> > I haven-fount where report bug on that site... 
>>>> > 
>>>> you open a new ticket: https://trac.sagemath.org/newticket 
>>>> - you'd need either a Guthub account, or a local account (long time to 
>>>> get sometimes) to authenticate. 
>>>>
>>>>
>>>> > Now I will try to repair smth: 
>>>> > 
>>>> > I have 2 dirs: 
>>>> > SageMath/local/lib/python3.7/site-packages/mpmath 
>>>> > .local/lib/python3.6/site-packages/mpmath 
>>>> > 
>>>> > I think there are sima chenges here 
>>>> > 
>>>> > вторник, 14 января 2020 г., 14:57:31 UTC+3 пользователь Dima 
>>>> Pasechnik написал: 
>>>> >> 
>>>> >> On Tue, Jan 14, 2020 at 11:53 AM Александр Ватузов <
>>>> amva...@gmail.com> wrote: 
>>>> >> > 
>>>> >> > Will you open issue here? https://trac.sagemath.org/ 
>>>> >> 
>>>> >> I can't reproduce the issue with a system python 3.7.3, so it 
>>>> deserves 
>>>> >> a trac ticket. 
>>>> >> Can you open one? 
>>>> >> 
>>>> >> > 
>>>> >> > Or I can try to do something 
>>>> >> > 
>>>> >> > вторник, 14 января 2020 г., 14:08:08 UTC+3 пользователь Dima 
>>>> Pasechnik написал: 
>>>> >> >> 
>>>> >> >> I have opened 
>>>> https://github.com/fredrik-johansson/mpmath/issues/503 
>>>> >> >> to report this. 
>>>> >> >> 
>>>> >> >> On Tue, Jan 14, 2020 at 10:59 AM Eric Gourgoulhon 
>>>> >> >>  wrote: 
>>>> >> >> > 
>>>> >> >> > PS: a similar error has been reported on ask.sagemath: 
>>>> https://ask.sagemath.org/question/49534/error-with-mpmathfindroot-on-89/ 
>>>> >> >> > 
>>>> >> >> > Le mardi 14 janvier 2020 11:55:08 UTC+1, Eric Gourgoulhon a 
>>>> écrit : 
>>>> >> >> >> 
>>>> >> >> >> Le mardi 14 janvier 2020 11:36:44 UTC+1, Dima Pasechnik a 
>>>> écrit : 
>>>> >> >> >>> 
>>>> >> >> >>> 
>>>> >> >> >>> mpmath version on Sage 8.6 is 1.0.0, and later and now it is 
>>>> 1.1.0 
>>>> >> >> >>> 
>>>> >> >> >>> This might explain the problem, which maybe should be 
>>>> reported upstream: 
>>>> >> >> >>> 
>>>> >> >> >>> https://github.com/fredrik-johansson/mpmath 
>>>> >> >> >>> 
>>>> >> >> >> 
>>>> >> >> >> 
>>>> >> >> >> It's OK with Sage 8.9, which has already mpmath 1.1.0. So the 
>>>> problem is not due to the version of mpmath. Maybe a Python 2 / Python 3 
>>>> issue? 
>>>> >> >> >> Another data point: the issue is there in Sage 9.0.beta5 
>>>> (Python 3). 
>>>> >> >> >> 
>>>> >> >> >> Eric. 
>>>> >> >> >> 
>>>> >> >> > 
>>>> >> >> > -- 
>>>> >> >> > You received this message because you are subscribed to the 
>>>> Google Groups "sage-support" group. 
>>>> >> >> > To unsubscribe from this group and stop receiving emails from 
>>>> it, send an email to sage-s...@googlegroups.com. 
>>>> >> >> > To view this discussion on the web visit 
>>>> https://groups.google.com/d/msgid/sage-support/5a7d5bb4-c406-4b8f-a757-370578307ed1%40googlegroups.com.
>>>>  
>>>>
>>>> >> > 
>>>> >> > -- 
>>>> >> > You received this message because you are subscribed to the Google 
>>>> Groups "sage-support" group. 
>>>> >> > To unsubscribe from this group and stop receiving emails from it, 
>>>> send an email to sage-s...@googlegroups.com. 
>>>> >> > To view this discussion on the web visit 
>>>> https://groups.google.com/d/msgid/sage-support/2e9eea57-3558-426b-9dec-76c22a6547ea%40googlegroups.com.
>>>>  
>>>>
>>>> > 
>>>> > -- 
>>>> > You received this message because you are subscribed to the Google 
>>>> Groups "sage-support" group. 
>>>> > To unsubscribe from this group and stop receiving emails from it, 
>>>> send an email to sage-s...@googlegroups.com. 
>>>> > To view this discussion on the web visit 
>>>> https://groups.google.com/d/msgid/sage-support/e9324849-4998-4c91-a384-f3314f59ae46%40googlegroups.com.
>>>>  
>>>>
>>>>
>>>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/516f1a46-e931-4a5a-9a6e-bcbd590cfedc%40googlegroups.com.


Re: [sage-support] sage with python3, mpmath

2020-01-14 Thread John H Palmieri
Just to confirm: everything works with Sage 9.0.beta1, built with Python 2. 
Fails with Sage built with Python 3.


On Tuesday, January 14, 2020 at 5:55:51 AM UTC-8, Александр Ватузов wrote:
>
> https://trac.sagemath.org/ticket/29009#ticket
>
> вторник, 14 января 2020 г., 16:36:27 UTC+3 пользователь Александр Ватузов 
> написал:
>>
>> Now I constantly know, that problem was in using
>>
>> divmod(n, base**half)
>>
>> instead of
>>
>> n // (base**half), n % (base**half)
>>
>> on File 
>> "/home/nouret/SageMath/local/lib/python3.7/site-packages/mpmath/libmp/libintmath.py",
>>  
>> line 161, in numeral_python
>>
>> вторник, 14 января 2020 г., 15:42:17 UTC+3 пользователь Dima Pasechnik 
>> написал:
>>>
>>> On Tue, Jan 14, 2020 at 12:37 PM Александр Ватузов  
>>> wrote: 
>>> > 
>>> > I haven-fount where report bug on that site... 
>>> > 
>>> you open a new ticket: https://trac.sagemath.org/newticket 
>>> - you'd need either a Guthub account, or a local account (long time to 
>>> get sometimes) to authenticate. 
>>>
>>>
>>> > Now I will try to repair smth: 
>>> > 
>>> > I have 2 dirs: 
>>> > SageMath/local/lib/python3.7/site-packages/mpmath 
>>> > .local/lib/python3.6/site-packages/mpmath 
>>> > 
>>> > I think there are sima chenges here 
>>> > 
>>> > вторник, 14 января 2020 г., 14:57:31 UTC+3 пользователь Dima Pasechnik 
>>> написал: 
>>> >> 
>>> >> On Tue, Jan 14, 2020 at 11:53 AM Александр Ватузов  
>>> wrote: 
>>> >> > 
>>> >> > Will you open issue here? https://trac.sagemath.org/ 
>>> >> 
>>> >> I can't reproduce the issue with a system python 3.7.3, so it 
>>> deserves 
>>> >> a trac ticket. 
>>> >> Can you open one? 
>>> >> 
>>> >> > 
>>> >> > Or I can try to do something 
>>> >> > 
>>> >> > вторник, 14 января 2020 г., 14:08:08 UTC+3 пользователь Dima 
>>> Pasechnik написал: 
>>> >> >> 
>>> >> >> I have opened 
>>> https://github.com/fredrik-johansson/mpmath/issues/503 
>>> >> >> to report this. 
>>> >> >> 
>>> >> >> On Tue, Jan 14, 2020 at 10:59 AM Eric Gourgoulhon 
>>> >> >>  wrote: 
>>> >> >> > 
>>> >> >> > PS: a similar error has been reported on ask.sagemath: 
>>> https://ask.sagemath.org/question/49534/error-with-mpmathfindroot-on-89/ 
>>> >> >> > 
>>> >> >> > Le mardi 14 janvier 2020 11:55:08 UTC+1, Eric Gourgoulhon a 
>>> écrit : 
>>> >> >> >> 
>>> >> >> >> Le mardi 14 janvier 2020 11:36:44 UTC+1, Dima Pasechnik a écrit 
>>> : 
>>> >> >> >>> 
>>> >> >> >>> 
>>> >> >> >>> mpmath version on Sage 8.6 is 1.0.0, and later and now it is 
>>> 1.1.0 
>>> >> >> >>> 
>>> >> >> >>> This might explain the problem, which maybe should be reported 
>>> upstream: 
>>> >> >> >>> 
>>> >> >> >>> https://github.com/fredrik-johansson/mpmath 
>>> >> >> >>> 
>>> >> >> >> 
>>> >> >> >> 
>>> >> >> >> It's OK with Sage 8.9, which has already mpmath 1.1.0. So the 
>>> problem is not due to the version of mpmath. Maybe a Python 2 / Python 3 
>>> issue? 
>>> >> >> >> Another data point: the issue is there in Sage 9.0.beta5 
>>> (Python 3). 
>>> >> >> >> 
>>> >> >> >> Eric. 
>>> >> >> >> 
>>> >> >> > 
>>> >> >> > -- 
>>> >> >> > You received this message because you are subscribed to the 
>>> Google Groups "sage-support" group. 
>>> >> >> > To unsubscribe from this group and stop receiving emails from 
>>> it, send an email to sage-s...@googlegroups.com. 
>>> >> >> > To view this discussion on the web visit 
>>> https://groups.google.com/d/msgid/sage-support/5a7d5bb4-c406-4b8f-a757-370578307ed1%40googlegroups.com.
>>>  
>>>
>>> >> > 
>>> >> > -- 
>>> >> > You received this message because you are subscribed to the Google 
>>> Groups "sage-support" group. 
>>> >> > To unsubscribe from this group and stop receiving emails from it, 
>>> send an email to sage-s...@googlegroups.com. 
>>> >> > To view this discussion on the web visit 
>>> https://groups.google.com/d/msgid/sage-support/2e9eea57-3558-426b-9dec-76c22a6547ea%40googlegroups.com.
>>>  
>>>
>>> > 
>>> > -- 
>>> > You received this message because you are subscribed to the Google 
>>> Groups "sage-support" group. 
>>> > To unsubscribe from this group and stop receiving emails from it, send 
>>> an email to sage-s...@googlegroups.com. 
>>> > To view this discussion on the web visit 
>>> https://groups.google.com/d/msgid/sage-support/e9324849-4998-4c91-a384-f3314f59ae46%40googlegroups.com.
>>>  
>>>
>>>
>>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/32ead3e3-0459-410b-b421-117e1d8ddec1%40googlegroups.com.


[sage-support] Re: Problems Compiling 9.0

2020-01-03 Thread John H Palmieri


On Friday, January 3, 2020 at 11:54:04 AM UTC-8, finotti wrote:
>
> I'm trying to build version 9.0 from source under Linux (Debian 
> Unstable/Sid).  The machine has Intel Core i7-8700 CPU and 48GB of RAM.
>
> Below is the end of the compilation:
>
> [snip]
>
> [twisted-16.3.0.p0] Finished installing twisted-16.3.0.p0.spkg
>
> make[3]: Leaving directory '/home/finotti/src/sage-9.0/build/make'
>
> make[2]: *** [Makefile:1830: all-start] Error 2
>
> make[2]: Leaving directory '/home/finotti/src/sage-9.0/build/make'
>
>
>
> real21m22.729s
>
> user92m46.651s
>
> sys 9m10.370s
>
> ***
>
> Error building Sage.
>
>
>
> The following package(s) may have failed to build (not necessarily
>
> during this run of 'make all-start'):
>
>
>
> * package: openblas-0.3.6.p0
>
>   log file: /home/finotti/src/sage-9.0/logs/pkgs/openblas-0.3.6.p0.log
>
>   build directory: /home/finotti/src/sage-9.0/local/var/tmp/sage/build/
> openblas-0.3.6.p0
>
>
>
> The build directory may contain configuration files and other potentially
>
> helpful information. WARNING: if you now run 'make' again, the build
>
> directory will, by default, be deleted. Set the environment variable
>
> SAGE_KEEP_BUILT_SPKGS to 'yes' to prevent this.
>
>
>
> make[1]: *** [Makefile:33: all-start] Error 1
>
> make[1]: Leaving directory '/home/finotti/src/sage-9.0'
>
> make: *** [Makefile:13: all] Error 2
>
> The openblas-0.3.6.p0 directory did not seem to have any useful log file.
>

What about the log file listed:

log file: /home/finotti/src/sage-9.0/logs/pkgs/openblas-0.3.6.p0.log

?

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/a40275a0-148f-4302-a27a-9e0a6551d259%40googlegroups.com.


Re: [sage-support] Re: sage building with python3

2019-11-04 Thread John H Palmieri
If you want to build Sage for use with Python 3, you should do

$ make distclean
$ ./configure --with-python=3
$ make

Where does this fail for you?



On Monday, November 4, 2019 at 8:21:04 AM UTC-8, Александр Ватузов wrote:
>
> No, I am building sage only for using it with python3. So I need to 
> install ipython and prompt_toolkit
>
> понедельник, 4 ноября 2019 г., 18:56:00 UTC+3 пользователь Dima Pasechnik 
> написал:
>>
>> Well, it is not clear what you are trying to do. Yes, if you want to use 
>> more recent than used in Sage (for compatibility with Python2 reasons) 
>> packages, then various things need to be adjusted. It has to be done in a 
>> systematic way.
>>
>>
>>
>> On Mon, 4 Nov 2019, 15:44 Александр Ватузов,  wrote:
>>
>>> Another error:
>>>
>>> jupyter-console 6.0.0 has requirement prompt-toolkit<2.1.0,>=2.0.0, but 
>>> you'll have prompt-toolkit 1.0.15 which is incompatible.
>>> ipython 7.9.0 has requirement prompt-toolkit<2.1.0,>=2.0.0, but you'll 
>>> have prompt-toolkit 1.0.15 which is incompatible.
>>>
>>> понедельник, 4 ноября 2019 г., 17:37:54 UTC+3 пользователь Dima 
>>> Pasechnik написал:

 looks like you have a bad mix of python packages in a number of 
 locations.

 certainly you can try something like

 ./sage --pip install prompt_toolkit


 On Mon, 4 Nov 2019, 13:05 Александр Ватузов,  wrote:

> next error:
>
> when I try:
> import prompt_toolkit
>
> ImportError: cannot import name 'AsyncGeneratorItem' from 
> 'prompt_toolkit.eventloop' 
> (/home/nouret/SageMath_3/local/lib/python3.7/site-packages/prompt_toolkit/eventloop/__init__.py)
>
> AsyncGeneratorItem is defined in 
> ./local/lib/python3.7/site-packages/prompt_toolkit/eventloop/async_generator.py
>
> /home/nouret/SageMath_3/local/lib/python3.7/site-packages/prompt_toolkit/eventloop/__init__.py
>  
> is empty
>
> понедельник, 4 ноября 2019 г., 14:56:35 UTC+3 пользователь Dima 
> Pasechnik написал:
>>
>> try 
>>
>> ./sage -f ipython 
>>
>> followed by 
>>
>> make build 
>>
>>
>> On Mon, Nov 4, 2019 at 11:47 AM Александр Ватузов  
>> wrote: 
>> > 
>> > sage building is sucsess now. But running sage makes error 
>> > 
>> > cannot import name '_baseclass_reprs' from 'IPython.lib.pretty' 
>> > 
>> > it looks like new libreary, but don't undestend, which one 
>> > 
>> > понедельник, 4 ноября 2019 г., 12:51:24 UTC+3 пользователь Dima 
>> Pasechnik написал: 
>> >> 
>> >> 
>> >> 
>> >> On Mon, 4 Nov 2019, 09:47 Александр Ватузов,  
>> wrote: 
>> >>> 
>> >>> it builds cython lib? 
>> >> 
>> >> yes 
>> >>> 
>> >>> 
>> >>> понедельник, 4 ноября 2019 г., 12:35:17 UTC+3 пользователь Dima 
>> Pasechnik написал: 
>>  
>>  
>>  
>>  On Mon, 4 Nov 2019, 09:27 Александр Ватузов,  
>> wrote: 
>> > 
>> > "./sage -pip install cython" installs cython for python3: 
>> Requirement already satisfied: cython in 
>> ./local/lib/python3.7/site-packages (0.29.14); and 
>> > "Requirement already satisfied: gmpy2 in 
>> ./local/lib/python3.7/site-packages (2.0.8)" 
>> > 
>> > So I think that, may be, cython need gmpy2 installed in other 
>> way? I still have na error: 
>>  
>>  try 
>>  
>>  ./sage -f gmpy2 
>>  
>> > 
>> > [sagelib-8.9] cimport gmpy2 
>> > [sagelib-8.9]^ 
>> > [sagelib-8.9] 
>>  
>> > [sagelib-8.9] 
>> > [sagelib-8.9] sage/rings/complex_double.pyx:110:8: 'gmpy2.pxd' 
>> not found 
>> > 
>> > 
>> > 
>> > 
>> > воскресенье, 3 ноября 2019 г., 23:52:01 UTC+3 пользователь 
>> Simon King написал: 
>> >> 
>> >> Hi Dima, 
>> >> 
>> >> On 2019-11-02, Dima Pasechnik  wrote: 
>> >> > There "python" is Sage's Python, "pip" manages its modules, 
>> etc. 
>> >> 
>> >> IIRC, that's not true for Sage's py-3 version. Namely, if one 
>> opens a 
>> >> sage-with-py-3 shell, then "python" still means "python2". So, 
>> if you 
>> >> really want Sage-with-py-3's Python installation, you should 
>> either do 
>> >> "sage -python" or (in a Sage shell) "python3". And I think the 
>> same 
>> >> holds for pip. 
>> >> 
>> >> Best regards, 
>> >> Simon 
>> >> 
>> > -- 
>> > You received this message because you are subscribed to the 
>> Google Groups "sage-support" group. 
>> > To unsubscribe from this group and stop receiving emails from 
>> it, send an email to sage-s...@googlegroups.com. 
>> > To view this discussion on the web visit 

Re: [sage-support] Re: sage building with python3

2019-11-03 Thread John H Palmieri
Since trac #28426 (merged pretty recently), when building with Python 3, we 
do not build Python 2. Before that, we always built both.


On Sunday, November 3, 2019 at 12:57:02 PM UTC-8, Dima Pasechnik wrote:
>
> I am surprised we still even build python2 by default. Isn't it an 
> optional package?
>
> On Sun, 3 Nov 2019, 20:52 Simon King, > 
> wrote:
>
>> Hi Dima,
>>
>> On 2019-11-02, Dima Pasechnik > wrote:
>> > There "python" is Sage's Python, "pip" manages its modules, etc.
>>
>> IIRC, that's not true for Sage's py-3 version. Namely, if one opens a
>> sage-with-py-3 shell, then "python" still means "python2". So, if you
>> really want Sage-with-py-3's Python installation, you should either do
>> "sage -python" or (in a Sage shell) "python3". And I think the same
>> holds for pip.
>>
>> Best regards,
>> Simon
>>
>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "sage-support" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to sage-s...@googlegroups.com .
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/sage-support/qpnel6%24itu%241%40blaine.gmane.org
>> .
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/45d0a564-549e-4fea-addf-dc2e30cc4001%40googlegroups.com.


[sage-support] Re: failure to re-install ipython

2019-10-25 Thread John H Palmieri


On Friday, October 25, 2019 at 2:59:36 AM UTC-7, Dima Pasechnik wrote:
>
> in the Sage 9.0.beta2 I get 
>  
> [ipython-5.8.0] Successfully installed ipython-5.8.0 
> [ipython-5.8.0] Cleaning up... 
> [ipython-5.8.0] Removed build tracker '/tmp/pip-req-tracker-h6h22jg5' 
> [ipython-5.8.0] 
> [ipython-5.8.0] real 0m2.424s 
> [ipython-5.8.0] user 0m2.136s 
> [ipython-5.8.0] sys 0m0.398s 
> [ipython-5.8.0] Copying package files from temporary location 
> /mnt/opt/Sage/sage-dev/local/var/tmp/sage/build/ipython-5.8.0/inst to 
> /mnt/opt/Sage/sage-dev/local 
> [ipython-5.8.0] cp: not writing through dangling symlink 
> '/mnt/opt/Sage/sage-dev/local/./bin/ipython' 
> [ipython-5.8.0] 
>  
> [ipython-5.8.0] Error copying files for ipython-5.8.0. 
>
>  
>
> I had to apply 
>
> diff --git a/build/pkgs/ipython/spkg-install 
> b/build/pkgs/ipython/spkg-install 
> index 07a28f951c..dd2fcdc698 100644 
> --- a/build/pkgs/ipython/spkg-install 
> +++ b/build/pkgs/ipython/spkg-install 
> @@ -4,6 +4,7 @@ if [ "$SAGE_LOCAL" = "" ]; then 
> exit 1 
>  fi 
>
> +rm -f "$SAGE_LOCAL"/bin/ipython* 
>  cd src 
>
>  sdh_pip_install . 
> @@ -12,10 +13,3 @@ if [ $? -ne 0 ]; then 
>  echo >&2 "Error installing IPython" 
>  exit 1 
>  fi 
> - 
> -# add symlink if we are running on python3 
> -if python -c 'import sys; sys.exit(sys.version_info.major != 3)'; then 
> -cd "$SAGE_LOCAL"/bin 
> -rm -f ipython 
> -ln -s ipython3 ipython 
> -fi 
>
> to make it build. In particular the last chunk removed by this patch 
> looks as something outdated. 
>
> Any ideas? 
>

I just saw this problem today, too. I agree that the last chunk looks 
outdated. 

Just curious: what platform is this? 

-- 
John

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/b0be0cf0-7d8d-4d4b-b03a-e4a1db92611e%40googlegroups.com.


Re: [sage-support] SageMath installation in macOS Catalina

2019-10-09 Thread John H Palmieri


On Wednesday, October 9, 2019 at 4:51:48 AM UTC-7, David Joyner wrote:
>
>
>
> On Wed, Oct 9, 2019 at 7:42 AM Dima Pasechnik  > wrote:
>
>>
>>
>> On Wed, Oct 9, 2019 at 6:34 AM David Joyner > > wrote:
>>
>>>
>>>
>>> On Wed, Oct 9, 2019 at 7:14 AM Dima Pasechnik >> > wrote:
>>>
 Hi,

 On Wed, Oct 9, 2019 at 6:03 AM George > 
 wrote:

> Hi David,
>
> Thanks for the update and information.
>
> building from source should still work.
 Did you try this ?

>>>
>>> I did. It chokes on the gfortran build:
>>>
>>> ...
>>>
>>> [gfortran-7.4.0] make[7]: *** [gets-chk.lo] Error 1
>>>
>>> [gfortran-7.4.0] make[6]: *** [all] Error 2
>>>
>>> [gfortran-7.4.0] make[5]: *** [all-target-libssp] Error 2
>>>
>>> [gfortran-7.4.0] make[4]: *** [all] Error 2
>>>
>>> [gfortran-7.4.0] 
>>> 
>>>
>>> [gfortran-7.4.0] Error building gfortran-7.4.0
>>>
>>> [gfortran-7.4.0] 
>>> 
>>>
>>>
>>>  
>>>
>> is there Homebrew for  Catalina?
>> Then one can use its gfortran.
>>
>>
> I googled around. Apparently the answer is no
> (or not as of a few days ago anyway).
>

On a recent beta release of Catalina, I used homebrew to install gfortran, 
and it went fine, allowing me to build Sage from scratch. I haven't yet 
tried with the actual release of Catalina, but I will soon.

  John

 

>  
>
>>
>>
 Dima

> G
>
> On Wednesday, October 9, 2019 at 1:00:37 PM UTC+2, David Joyner wrote:
>>
>>
>>
>> On Wed, Oct 9, 2019 at 6:45 AM George  wrote:
>>
>>> Hi,
>>>
>>> I upgraded to the new macOS Catalina and SageMath won't install. I 
>>> get errors like "python2.7 cannot be opened because the developer 
>>> cannot be 
>>> verified" and for numerous other components as well. 
>>>
>>> Is anyone having the same problem? Any tips, advice or ideas on what 
>>> is going on and how to fix this?
>>>
>>>
>> I can confirm this issue. The problem is also discussed in the thread
>>
>> https://groups.google.com/forum/?utm_medium=email_source=footer#!msg/sage-support/4dUg8mbiDYw/u5o-U9QBCAAJ
>> That's all I know.
>>  
>>
>>> Thanks a lot,
>>> G
>>>
>>> -- 
>>> You received this message because you are subscribed to the Google 
>>> Groups "sage-support" group.
>>> To unsubscribe from this group and stop receiving emails from it, 
>>> send an email to sage-s...@googlegroups.com.
>>> To view this discussion on the web visit 
>>> https://groups.google.com/d/msgid/sage-support/e69a4235-ec1b-465e-98da-635ed8be1b23%40googlegroups.com
>>>  
>>> 
>>> .
>>>
>> -- 
> You received this message because you are subscribed to the Google 
> Groups "sage-support" group.
> To unsubscribe from this group and stop receiving emails from it, send 
> an email to sage-s...@googlegroups.com .
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/sage-support/1cd586e5-35af-4e39-9322-8e055c144601%40googlegroups.com
>  
> 
> .
>
 -- 
 You received this message because you are subscribed to the Google 
 Groups "sage-support" group.
 To unsubscribe from this group and stop receiving emails from it, send 
 an email to sage-s...@googlegroups.com .
 To view this discussion on the web visit 
 https://groups.google.com/d/msgid/sage-support/CAAWYfq0ZBO74cNDnkb33ywH7KkGUNci%3DMxXm5Dsoq5ak-mWb9Q%40mail.gmail.com
  
 
 .

>>> -- 
>>> You received this message because you are subscribed to the Google 
>>> Groups "sage-support" group.
>>> To unsubscribe from this group and stop receiving emails from it, send 
>>> an email to sage-s...@googlegroups.com .
>>> To view this discussion on the web visit 
>>> https://groups.google.com/d/msgid/sage-support/CAEQuuAWOOuPVgzgGdysYwz3oJ%3DxxV%3DNvj-ePKH__CYTe3x0p%2Bg%40mail.gmail.com
>>>  
>>> 
>>> .
>>>
>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "sage-support" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to sage-s...@googlegroups.com .
>> To view this discussion on the web visit 
>> 

[sage-support] debian virtual machine numerical noise

2019-08-09 Thread John H Palmieri
In order to try to track down the problem with Python 3 and 
polynomial_rational_flint.pyx on Debian (see 
https://trac.sagemath.org/ticket/28334 — help wanted!), I installed 
VirtualBox and a Debian 10 virtual machine on my iMac. Most doctests pass, 
but I am getting some numerical noise. Did I misconfigure something? Is 
this to be expected? Any advice?

For example:

File "src/sage/calculus/interpolators.pyx", line 191, in 
sage.calculus.interpolators.complex_cubic_spline
Failed example:
cs.derivative(2)
Expected:
(-0.0497765406583...+0.151095006434...j)
Got:
(-0.04977602323949545+0.15109527580806253j)


File "src/sage/calculus/riemann.pyx", line 173, in 
sage.calculus.riemann.Riemann_Map
Failed example:
print("error = {}".format(m.inverse_riemann_map(m.riemann_map(x)) - 
x))  # long time
Expected:
error = (-0.000...+0.0016...j)
Got:
error = (0.0006698241837047592+0.0003692515183057285j)
**
File "src/sage/calculus/riemann.pyx", line 422, in 
sage.calculus.riemann.Riemann_Map.get_szego
Failed example:
s(3*pi / 4)
Expected:
0.0012158...
Got:
0.0012508938619074255
**



There are a few more worrisome failures:

File "src/sage/matrix/matrix_double_dense.pyx", line 629, in 
sage.matrix.matrix_double_dense.Matrix_double_dense.condition
Failed example:
A.condition()  # tol 2e-4
Expected:
16332197709146.014
Got:
5.908570618719731e+19
Tolerance exceeded:
16332197709146.014 vs 5.908570618719731e+19, tolerance 4e6 > 2e-4
**

sage -t --long src/sage/matrix/matrix_integer_dense.pyx
**
File "src/sage/matrix/matrix_integer_dense.pyx", line 3717, in 
sage.matrix.matrix_integer_dense.Matrix_integer_dense.determinant
Failed example:
A.determinant(algorithm='linbox',proof=False) == d
Expected:
True
Got:
False
**

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/9313fca4-b61a-45c4-b869-206bbacf98f8%40googlegroups.com.


Re: [sage-support] Is there a binary version of SageMath .app.dmg compatiable with Mac OS X ver. 10.14.6

2019-07-26 Thread John H Palmieri


On Friday, July 26, 2019 at 9:33:25 AM UTC-7, John H Palmieri wrote:
>
>
>
> On Friday, July 26, 2019 at 12:32:06 AM UTC-7, Dima Pasechnik wrote:
>>
>>
>>
>> On Fri, 26 Jul 2019 at 06:26, Samuel Dupree  wrote:
>>
>>>
>>>
>>> I'm attempting to update SageMath-8.7.app on an iMacPro running Mac OS X 
>>> ver. 10.14.6 tp SageMath-8.8.app. The problem for the moment occurs when I 
>>> decompress sage-8.8-OSX_10.14.5-x86_64.app.dmg, the operation crashes my 
>>> iMacPro with the message captured in the attached file.
>>>
>>
>> there is no OSX-10.14 compatible app version available, for there are 
>> changes needed to be done, and someone with knowledge of OSX (err, Mac OS) 
>> frontend programming needs to step forward and do the needed work...
>>
>
>
> What about 
> http://mirrors.xmission.com/sage/osx/intel/sage-8.8-OSX_10.14.5-x86_64.app.dmg?
>  
> This works for me with OS X 10.14.6, although I haven't yet tried on an 
> iMac Pro. 
>

It works on my iMac Pro, too. Try downloading the file again, maybe from a 
different mirror.



>   John
>
>
>> HTH,
>> Dima
>>
>>
>>> Any suggestions?
>>>
>>>
>>> Sam Dupree.
>>>
>>> -- 
>>> You received this message because you are subscribed to the Google 
>>> Groups "sage-support" group.
>>> To unsubscribe from this group and stop receiving emails from it, send 
>>> an email to sage-s...@googlegroups.com.
>>> To view this discussion on the web visit 
>>> https://groups.google.com/d/msgid/sage-support/1cd574a4-4709-4156-bd95-d2c9ac162132%40googlegroups.com
>>>  
>>> <https://groups.google.com/d/msgid/sage-support/1cd574a4-4709-4156-bd95-d2c9ac162132%40googlegroups.com?utm_medium=email_source=footer>
>>> .
>>>
>>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/5f1610f5-c8a7-4b27-bce7-d5326a9d7d55%40googlegroups.com.


  1   2   3   4   5   >