[sage-support] Error building sage packages ppl and brial

2022-06-09 Thread Daniel Lima
Hi, I'm having problems building Sagemath 9.6 in my Ubuntu 20.04 CPU 
= Intel® Core™ i7-7500U CPU @ 2.70GHz × 4. After running ./configure and 
make I get the following error 
Error building Sage.

The following package(s) may have failed to build (not necessarily
during this run of 'make all-start'):

* package: brial-1.2.8
  last build time: jun 9 15:07
  log file:    /home/daniel/sage/logs/pkgs/brial-1.2.8.log
  build directory: /home/daniel/sage/local/var/tmp/sage/build/brial-1.2.8

* package: ppl-1.2.p1
  last build time: jun 9 15:17
  log file:    /home/daniel/sage/logs/pkgs/ppl-1.2.p1.log
  build directory: /home/daniel/sage/local/var/tmp/sage/build/ppl-1.2.p1

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]: *** [Makefile:39: all-start] Erro 1
make[1]: Saindo do diretório '/home/daniel/sage'
make: *** [Makefile:13: all] Erro 2

-- 
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/441543b5-047b-4608-ad40-a59e60abdce2n%40googlegroups.com.


[sage-support] TIDES ode solver with vector dependent variable

2021-12-18 Thread Daniel Friedan
I am trying to solve some first order linear odes
 dy/dt = A(t) y
where y is an N vector and A(t) an NxN matrix with real entries.  N varies.

I need arbitrary precision arithmetic, so I'm trying to use
 sage.calculus.desolvers.desolve_tides_mpfr(f, ics, initial, final, 
delta, tolrel=1e-16,
tolabs=1e-16, digits=50)

desolve_tides_mpfr() requires the ode to be described by f which is a 
symbolic function f(t,y_1,...,y_N) of N+1 variables which returns a list of 
derivatives [dy_1/dt, ..., dy_N/dt]

My problem is that N varies.  I can write a symbolic expression of the form
  f(t,y) = A(t)*y
with two arguments, t a real number and y a vector, returning a vector.

But that is not acceptable to desolve_tides_mpfr().

Is there any way of avoiding writing a separate  f for each value of N?  
e.g.,
f(x,y_1,y_2) = list(A(t)*vector[y_1,y_2]))

thanks,
Daniel Friedan

-- 
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/473ca93f-481f-4c30-9c7c-307f9649457cn%40googlegroups.com.


Re: [sage-support] another "how to simplify" question

2021-12-09 Thread 'Daniel Volinski' via sage-support
 Hi All,
In Maxima (embedded in SageMath) you can use:
expand(trigrat(integrate(integrate(sin(x^2),x,y,1),y,0,1)));

in order to get exactly the same result in both cases.
Daniel


En miércoles, 8 de diciembre de 2021 23:02:00 GMT+2, Fernando Q. Gouvea 
 escribió:  
 
  
I see. So the difference between this and, say, 1+1==2 (which returns True) is 
that 1+1 and 2 are numbers, not symbolic things.
 
Fernando
 
 On 12/8/2021 3:37 PM, William Stein wrote:
  
 
 
  
  On Wed, Dec 8, 2021 at 12:22 PM Fernando Q. Gouvea  wrote:
  
  
Thank you, that works. What is strange is that this does not:
 sage: right=integrate(integrate(sin(x^2),y,0,x),x,0,1)
sage: wrong=integrate(integrate(sin(x^2),x,y,1),y,0,1)
sage: real(wrong)==right
-1/2*cos(1) + 1/2 == -1/2*cos(1) + 1/2 
Is Sage seeing a difference there that I don't? 
  
 
  
 
 
 
I think I don't understand the difference between real(wrong)==right and 
bool(real(wrong)==right).
  
 In Sage "[symbol thing] == [symbolic thing]" is a constructor for a symbolic 
equation. 
  sage: SR(2) == SR(2) 2 == 2  sage: parent(SR(2) == SR(2)) Symbolic Ring sage: 
bool(SR(2) == SR(2)) True # only because Sage can *prove* they are equal -- 
it's false if it can't prove they are equal, even if they are equal... 
  
  https://cocalc.com/wstein/support/gouvea-equals
  
  
    
  
Fernando
 
 On 12/8/2021 1:23 PM, William Stein wrote:
  
 You can compare the real and imaginary parts directly. 
  https://cocalc.com/wstein/support/2021-12-08-gouvea
  
  sage: bool(wrong.real() == right) True sage: wrong.imag() 0  
  On Wed, Dec 8, 2021 at 10:07 AM Fernando Q. Gouvea  wrote:
  
  
I was showing my students a famous calculus example of an integral that can be 
computed in one order of the variables but not in the other. Knowing that 
SageMath can compute anything, the students suggested trying the integral the 
"wrong" way.
 
The "right" way is
 sage: integrate(integrate(sin(x^2),y,0,x),x,0,1) -1/2*cos(1) + 1/2 
The "wrong" way is
 sage: integrate(integrate(sin(x^2),x,y,1),y,0,1)

-1/16*(-1)^(3/4)*((sqrt(2) + 4*(-1)^(1/4))*e^I - sqrt(-I)*((I + 
1)*sqrt(2)*(-1)^(1/4)*e^(2*I) - (I + 1)*sqrt(2)*(-1)^(1/4)*e^I) + 
I*sqrt(2)*e^I - 2*(-1)^(1/4)*e^(2*I) - (I + 1)*sqrt(2) - 
2*(-1)^(1/4))*e^(-I) 
Is there any way to get Sage to check that these are equal? 
 
 
The obvious thing does not seem to work:
 sage: -1/16*(-1)^(3/4)*((sqrt(2) + 4*(-1)^(1/4))*e^I - sqrt(-I)*((I + 
1)*sqrt(2)
: *(-1)^(1/4)*e^(2*I) - (I + 1)*sqrt(2)*(-1)^(1/4)*e^I) + I*sqrt(2)*e^I - 2*
: (-1)^(1/4)*e^(2*I) - (I + 1)*sqrt(2) - 2*(-1)^(1/4))*e^(-I) == -1/2*cos(1)
: +1/2

-1/16*(-1)^(3/4)*((sqrt(2) + 4*(-1)^(1/4))*e^I - sqrt(-I)*((I + 
1)*sqrt(2)*(-1)^(1/4)*e^(2*I) 
- (I + 1)*sqrt(2)*(-1)^(1/4)*e^I) + I*sqrt(2)*e^I - 2*(-1)^(1/4)*e^(2*I) - (I + 
1)*sqrt(2) 
- 2*(-1)^(1/4))*e^(-I) == -1/2*cos(1) + 1/2
 
Thanks,
 
Fernando
 
 -- 
==
Fernando Q. Gouvea
Carter Professor of Mathematics  
Colby College
Mayflower Hill 5836
Waterville, ME 04901   
fqgou...@colby.edu http://www.colby.edu/~fqgouvea

I have had a perfectly wonderful evening, but this wasn't it.
  --Groucho Marx

  -- 
 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/9557c1a9-bd1c-69e1-358f-4ab02a058c3a%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+unsubscr...@googlegroups.com.
 To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/CACLE5GC6SNZuSsJ13iRFbO72Udn80Yy5OavR1SFwv03gjaQxvw%40mail.gmail.com.
 
 -- 
==
Fernando Q. Gouvea
Carter Professor of Mathematics  
Colby College
Mayflower Hill 5836
Waterville, ME 04901   
fqgou...@colby.edu http://www.colby.edu/~fqgouvea

What is socialism?

The painful transition from capitalism to capitalism.

  -- 
 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/5ea4d847-d5a5-1053-cc98-e071382cf49f%40colby.edu.
 
  
 
  -- 
 William (http://wstein.org)  -- 
 You received this message because you are subscribed to the Google 

Re: [sage-support] Using Cadabra2

2021-04-14 Thread 'Daniel Volinski' via sage-support
Hi All,

Has this been resolved? Can I use Cadabra2 on a SageMath installation on 
Windows 10?

Thanks,

Daniel Volinski


On Sunday, March 14, 2021 at 10:55:48 PM UTC+2 dim...@gmail.com wrote:

> On Sun, Mar 14, 2021 at 7:29 PM Kasper Peeters  
> wrote:
> >
> > Run cmake as
> >
> > cmake -DCMAKE_INSTALL_PREFIX=/local
> >
> > and do not set `DESTDIR`. The `DESTDIR` variable is meant for package 
> creation, not to set the final installation location; see 
> https://www.gnu.org/prep/standards/html_node/DESTDIR.html for more 
> details.
>
> Thanks. I forgot that cmake-speak for parameters is "variables".
>
> >
> > On Saturday, 13 March 2021 at 16:19:59 UTC dim...@gmail.com wrote:
> >>
> >> On Sat, Mar 13, 2021 at 3:34 PM Kasper Peeters  
> wrote:
> >> >
> >> > I am happy to stand corrected, but shouldn't you in that case set 
> `CMAKE_INSTALL_PREFIX` to the empty string? Things get installed into 
> `${DESTDIR}${CMAKE_INSTALL_PREFIX}`. If you do not set 
> `CMAKE_INSTALL_PREFIX`, it defaults to `/usr/local`.
> >>
> >> Right, but I don't understand at what point CMAKE_INSTALL_PREFIX has
> >> to be set, and how.
> >> CMAKE_INSTALL_PREFIX is a "cmake-variable", as opposed to DESTDIR,
> >> which is an environment
> >> variable used in cmake-produced makefiles.
> >> (As I said, I have little understanding of cmake...)
> >>
> >> Dima
> >>
> >> >
> >> > Kasper
> >> >
> >> > On Saturday, 13 March 2021 at 13:47:43 UTC dim...@gmail.com wrote:
> >> >>
> >> >> On Fri, Mar 12, 2021 at 10:51 PM Kasper Peeters
> >> >>  wrote:
> >> >> >
> >> >> > Cadabra author here. On Unix, the Cadabra build/install process 
> installs a Jupyter kernel, which works with SageMath installed from the 
> binary distribution (may need some PYTHONPATH setting, but nothing more).
> >> >>
> >> >> It seems that the Jupyter part of Cadabra appends /usr/local to
> >> >> cmake's DESTDIR for a reason I don't understand.
> >> >> A Cadabra bug, maybe? (I don't know enough of cmake to be certain).
> >> >> It least that's what I got when I tried installing Cadabra into 
> SageMath's venv,
> >> >> which has the convention that the install prefix is /local
> >> >> (with SAGE_ROOT the location of the
> >> >> root of SageMath install); I've set DESTDIR=/local and got
> >> >> (some parts of) Cadabra installed into DESTDIR/usr/local - which is
> >> >> not what's needed.
> >> >>
> >> >> Dima
> >> >>
> >> >> > On Windows, the build process using Visual Studio is relatively 
> simple, but getting everything to see all required libraries is a 
> never-ending horror story. Maybe someone on the SageMath team responsible 
> for the Windows port can help out; I have no resources to properly support 
> Windows.
> >> >> >
> >> >> > The alternative is to run the lot in WSL and then install a binary 
> distribution of Cadabra; that is known to work from first-hand experience 
> using a non-SageMath Jupyter installation, but I have no doubt it can be 
> made to work with the one supplied by SageMath. You can still connect to 
> the Jupyter kernel from your Windows browser that way.
> >> >> >
> >> >> > On Monday, 8 March 2021 at 14:22:57 UTC dim...@gmail.com wrote:
> >> >> >>
> >> >> >> On Mon, Mar 8, 2021 at 7:28 AM 'Daniel Volinski' via sage-support
> >> >> >>  wrote:
> >> >> >> >
> >> >> >> > Hi Dima,
> >> >> >> >
> >> >> >> > This is a page in the Cadabra site: Cadabra: use with Jupyter
> >> >> >> >
> >> >> >> > I just want to calculate some General relativity stuff using 
> Cadabra on a Jupyter Notebook as shown in their picture.
> >> >> >>
> >> >> >> I'm able to build Cadabra2 in SageMath environment (at sage 
> --buildsh
> >> >> >> prompt, that is)
> >> >> >> on Debian Linux. This way it should be possible to use it with 
> Sage's
> >> >> >> Jupyter notebook.
> >> >> >>
> >> >> >> But on Windows, well, probably much harder...
> >> >> >>
>

Re: [sage-support] Using Cadabra2

2021-03-13 Thread 'Daniel Volinski' via sage-support
 Hi All,
Is it possible to "translate" all that to Windows 10?
Thanks,
Daniel Volinski
En sábado, 13 de marzo de 2021 09:04:30 GMT+2, Henri Girard 
 escribió:  
 
  
Thank you very much, I am using next month ubuntu 21.04 an working with sage 
5.2, just install sudo apt install cadabra2 start sage in jupyter notebook and 
to display latex at the beginning write only once  in a cell 
 
 
%display latex
 
from cadabra2 import *
 
 
from IPython.display import display, Math, Latex
 
For example :
 
%display latex
 ex=Ex(r"A_{m n} B^{m n}");ex
 

  
and voila ! lol
 
 Le 12/03/2021 à 23:51, Kasper Peeters a écrit :
  
 
Cadabra author here. On Unix, the Cadabra build/install process installs a 
Jupyter kernel, which works with SageMath installed from the binary 
distribution (may need some PYTHONPATH setting, but nothing more). On Windows, 
the build process using Visual Studio is relatively simple, but getting 
everything to see all required libraries is a never-ending horror story. Maybe 
someone on the SageMath team responsible for the Windows port can help out; I 
have no resources to properly support Windows.
  
  The alternative is to run the lot in WSL and then install a binary 
distribution of Cadabra; that is known to work from first-hand experience using 
a non-SageMath Jupyter installation, but I have no doubt it can be made to work 
with the one supplied by SageMath. You can still connect to the Jupyter kernel 
from your Windows browser that way.
  
  On Monday, 8 March 2021 at 14:22:57 UTC dim...@gmail.com wrote:
  
On Mon, Mar 8, 2021 at 7:28 AM 'Daniel Volinski' via sage-support 
  wrote: 
 > 
 > Hi Dima, 
 > 
 > This is a page in the Cadabra site: Cadabra: use with Jupyter 
 > 
 > I just want to calculate some General relativity stuff using Cadabra on a 
 > Jupyter Notebook as shown in their picture. 
 
 I'm able to build Cadabra2 in SageMath environment (at sage --buildsh 
 prompt, that is) 
 on Debian Linux. This way it should be possible to use it with Sage's 
 Jupyter notebook. 
 
 But on Windows, well, probably much harder... 
 
 
 > 
 > Thanks, 
 > 
 > Daniel Volinski 
 > 
 > 
 > 
 > 
 > En domingo, 7 de marzo de 2021 11:54:22 GMT+2, Dima Pasechnik 
 >  escribió: 
 > 
 > 
 > I must say I don't understand what you mean by "use Cadabra2 on a Jupyter 
 > Notebook", is it even possible? 
 > The following does not read like it's supported by Cadabra2: 
 > https://github.com/kpeeters/cadabra2/tree/master/frontend/web 
 > 
 > They have https://github.com/kpeeters/cadabra2/tree/master/jupyterkernel 
 > but it's not clear how to use it, whether it's working at all etc. 
 > Do they have a working Jupyter kernel, which can be used in a system Jupyter 
 > notebook? 
 > 
 > In principle, Sage can use system Jupyter notebook (although whether it's 
 > try on Windows, I don't know) 
 > So if this is all working there should be no issue. 
 > 
 > 
 > On Sunday, March 7, 2021 at 9:10:54 AM UTC Daniel Volinski wrote: 
 > 
 > Hi Dima, 
 > 
 > I asked the same question on the Cadabra support site, they don't know 
 > either. 
 > 
 > Daniel Volinski 
 > 
 > 
 > 
 > En sábado, 6 de marzo de 2021 16:57:24 GMT+2, 'Daniel Volinski' via 
 > sage-support  escribió: 
 > 
 > 
 > Thank you Dima. 
 > 
 > Daniel Volinski 
 > 
 > 
 > En sábado, 6 de marzo de 2021 12:30:27 GMT+2, Dima Pasechnik 
 >  escribió: 
 > 
 > 
 > 
 > 
 > On Sat, 6 Mar 2021, 10:23 'Daniel Volinski' via sage-support, 
 >  wrote: 
 > 
 > Hi Dima, 
 > 
 > Thank you for your reply. 
 > 
 > I already have a Python3 installation provided by the SageMath installation, 
 > I can run Python3 programs without adding anything else. 
 > I already have a LaTeX installation (MikTex) that I use with other programs. 
 > How do I proceed from here? 
 > 
 > 
 > We don't know how to install Cadabra2. 
 > 
 > IMHO this is a question for Cadabra2 people: "I have a Python3 installation, 
 > and I want to run Cadabra2 on top of it". 
 > 
 > 
 > Thanks, 
 > 
 > Daniel Volinski 
 > 
 > 
 > 
 > 
 > En viernes, 5 de marzo de 2021 22:49:40 GMT+2, Dima Pasechnik 
 >  escribió: 
 > 
 > 
 > On Fri, Mar 5, 2021 at 8:42 PM 'Daniel Volinski' via sage-support 
 >  wrote: 
 > > 
 > > Hi All, 
 > > 
 > > I'm using SageMath 9.2 on Windows 10 Native with Jupyter Notebook. 
 > > 
 > > My question, is there any way to use Cadabra2 on a Jupyter Notebook after 
 > > installing SageMath? 
 > > 
 > > I do not want to install conda or anaconda or miniconda, I just want to 
 > > use Cadabra2 in the Jupyter Notebook provide

Re: [sage-support] Using Cadabra2

2021-03-07 Thread 'Daniel Volinski' via sage-support
 Hi Dima,
This is a page in the Cadabra site: Cadabra: use with Jupyter
I just want to calculate some General relativity stuff using Cadabra on a 
Jupyter Notebook as shown in their picture.
Thanks,
Daniel Volinski



En domingo, 7 de marzo de 2021 11:54:22 GMT+2, Dima Pasechnik 
 escribió:  
 
 I must say I don't understand what you mean by "use Cadabra2 on a Jupyter 
Notebook", is it even possible?The following does not read like it's supported 
by Cadabra2:https://github.com/kpeeters/cadabra2/tree/master/frontend/web
They have https://github.com/kpeeters/cadabra2/tree/master/jupyterkernelbut 
it's not clear how to use it, whether it's working at all etc.Do they have a 
working Jupyter kernel, which can be used in a system Jupyter notebook?
In principle, Sage can use system Jupyter notebook (although whether it's try 
on Windows, I don't know)So if this is all working there should be no issue. 

On Sunday, March 7, 2021 at 9:10:54 AM UTC Daniel Volinski wrote:

 Hi Dima,
I asked the same question on the Cadabra support site, they don't know either.
Daniel Volinski


En sábado, 6 de marzo de 2021 16:57:24 GMT+2, 'Daniel Volinski' via 
sage-support  escribió:  
 
  Thank you Dima.
Daniel Volinski

En sábado, 6 de marzo de 2021 12:30:27 GMT+2, Dima Pasechnik 
 escribió:  
 
 

On Sat, 6 Mar 2021, 10:23 'Daniel Volinski' via sage-support, 
 wrote:

 Hi Dima,
Thank you for your reply.
I already have a Python3 installation provided by the SageMath installation, I 
can run Python3 programs without adding anything else.I already have a LaTeX 
installation (MikTex) that I use with other programs. How do I proceed from 
here?

We don't know how to install Cadabra2.
IMHO this is a question for Cadabra2 people: "I have a Python3 installation, 
and I want to run Cadabra2 on top of it".


Thanks,
Daniel Volinski



En viernes, 5 de marzo de 2021 22:49:40 GMT+2, Dima Pasechnik 
 escribió:  
 
 On Fri, Mar 5, 2021 at 8:42 PM 'Daniel Volinski' via sage-support
 wrote:
>
> Hi All,
>
> I'm using SageMath 9.2 on Windows 10 Native with Jupyter Notebook.
>
> My question, is there any way to use Cadabra2 on a Jupyter Notebook after 
> installing SageMath?
>
> I do not want to install conda or anaconda or miniconda, I just want to use 
> Cadabra2 in the Jupyter Notebook provided by the SageMath installation and 
> may be with minimal installation of some software.

>From https://cadabra.science/download.html:
Windows 10
You will need a Python3 installation from Anaconda (64-bits, Python
3.8) and a LaTeX installation (tested with MikTeX, others may work
too) in order for this to work. Install those first if you do not have
them already. The Windows port and this binary installer are in beta
right now, please report any problems. Many thanks to Dominic Price
for making this become reality.

It seems it mixes well with conda, so why not?

Otherwise, I don't think anyone here has any idea whether Cadabra2 and
Sage will work together, and if yes, how.

>
> Thanks,
>
> Daniel Volinski
>
>
> --
> 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+unsub...@googlegroups.com.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/sage-support/14557094.2027036.1614975004314%40mail.yahoo.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+unsub...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/CAAWYfq2ZFE2vViOxPf0CZiUW_hUc3yj--2ZxQkwJwRLUt-VHcg%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/1467251413.81492.1615008723279%40mail.yahoo.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/CAAWYfq3Oy3u5E1oVqqapD1DPHds93huU%3D3yftpr3r1rAzoRJTA%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 thi

Re: [sage-support] Using Cadabra2

2021-03-07 Thread 'Daniel Volinski' via sage-support
 Hi Dima,
I asked the same question on the Cadabra support site, they don't know either.
Daniel Volinski


En sábado, 6 de marzo de 2021 16:57:24 GMT+2, 'Daniel Volinski' via 
sage-support  escribió:  
 
  Thank you Dima.
Daniel Volinski

En sábado, 6 de marzo de 2021 12:30:27 GMT+2, Dima Pasechnik 
 escribió:  
 
 

On Sat, 6 Mar 2021, 10:23 'Daniel Volinski' via sage-support, 
 wrote:

 Hi Dima,
Thank you for your reply.
I already have a Python3 installation provided by the SageMath installation, I 
can run Python3 programs without adding anything else.I already have a LaTeX 
installation (MikTex) that I use with other programs. How do I proceed from 
here?

We don't know how to install Cadabra2.
IMHO this is a question for Cadabra2 people: "I have a Python3 installation, 
and I want to run Cadabra2 on top of it".


Thanks,
Daniel Volinski



En viernes, 5 de marzo de 2021 22:49:40 GMT+2, Dima Pasechnik 
 escribió:  
 
 On Fri, Mar 5, 2021 at 8:42 PM 'Daniel Volinski' via sage-support
 wrote:
>
> Hi All,
>
> I'm using SageMath 9.2 on Windows 10 Native with Jupyter Notebook.
>
> My question, is there any way to use Cadabra2 on a Jupyter Notebook after 
> installing SageMath?
>
> I do not want to install conda or anaconda or miniconda, I just want to use 
> Cadabra2 in the Jupyter Notebook provided by the SageMath installation and 
> may be with minimal installation of some software.

>From https://cadabra.science/download.html:
Windows 10
You will need a Python3 installation from Anaconda (64-bits, Python
3.8) and a LaTeX installation (tested with MikTeX, others may work
too) in order for this to work. Install those first if you do not have
them already. The Windows port and this binary installer are in beta
right now, please report any problems. Many thanks to Dominic Price
for making this become reality.

It seems it mixes well with conda, so why not?

Otherwise, I don't think anyone here has any idea whether Cadabra2 and
Sage will work together, and if yes, how.

>
> Thanks,
>
> Daniel Volinski
>
>
> --
> 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/14557094.2027036.1614975004314%40mail.yahoo.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/CAAWYfq2ZFE2vViOxPf0CZiUW_hUc3yj--2ZxQkwJwRLUt-VHcg%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/1467251413.81492.1615008723279%40mail.yahoo.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/CAAWYfq3Oy3u5E1oVqqapD1DPHds93huU%3D3yftpr3r1rAzoRJTA%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/1120506566.220323.1615040040658%40mail.yahoo.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/2098685955.415820.1615096724266%40mail.yahoo.com.


Re: [sage-support] Using Cadabra2

2021-03-06 Thread 'Daniel Volinski' via sage-support
 Thank you Dima.
Daniel Volinski

En sábado, 6 de marzo de 2021 12:30:27 GMT+2, Dima Pasechnik 
 escribió:  
 
 

On Sat, 6 Mar 2021, 10:23 'Daniel Volinski' via sage-support, 
 wrote:

 Hi Dima,
Thank you for your reply.
I already have a Python3 installation provided by the SageMath installation, I 
can run Python3 programs without adding anything else.I already have a LaTeX 
installation (MikTex) that I use with other programs. How do I proceed from 
here?

We don't know how to install Cadabra2.
IMHO this is a question for Cadabra2 people: "I have a Python3 installation, 
and I want to run Cadabra2 on top of it".


Thanks,
Daniel Volinski



En viernes, 5 de marzo de 2021 22:49:40 GMT+2, Dima Pasechnik 
 escribió:  
 
 On Fri, Mar 5, 2021 at 8:42 PM 'Daniel Volinski' via sage-support
 wrote:
>
> Hi All,
>
> I'm using SageMath 9.2 on Windows 10 Native with Jupyter Notebook.
>
> My question, is there any way to use Cadabra2 on a Jupyter Notebook after 
> installing SageMath?
>
> I do not want to install conda or anaconda or miniconda, I just want to use 
> Cadabra2 in the Jupyter Notebook provided by the SageMath installation and 
> may be with minimal installation of some software.

>From https://cadabra.science/download.html:
Windows 10
You will need a Python3 installation from Anaconda (64-bits, Python
3.8) and a LaTeX installation (tested with MikTeX, others may work
too) in order for this to work. Install those first if you do not have
them already. The Windows port and this binary installer are in beta
right now, please report any problems. Many thanks to Dominic Price
for making this become reality.

It seems it mixes well with conda, so why not?

Otherwise, I don't think anyone here has any idea whether Cadabra2 and
Sage will work together, and if yes, how.

>
> Thanks,
>
> Daniel Volinski
>
>
> --
> 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/14557094.2027036.1614975004314%40mail.yahoo.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/CAAWYfq2ZFE2vViOxPf0CZiUW_hUc3yj--2ZxQkwJwRLUt-VHcg%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/1467251413.81492.1615008723279%40mail.yahoo.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/CAAWYfq3Oy3u5E1oVqqapD1DPHds93huU%3D3yftpr3r1rAzoRJTA%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/1120506566.220323.1615040040658%40mail.yahoo.com.


Re: [sage-support] Using Cadabra2

2021-03-06 Thread 'Daniel Volinski' via sage-support
 Hi Dima,
Thank you for your reply.
I already have a Python3 installation provided by the SageMath installation, I 
can run Python3 programs without adding anything else.I already have a LaTeX 
installation (MikTex) that I use with other programs. How do I proceed from 
here?
Thanks,
Daniel Volinski



En viernes, 5 de marzo de 2021 22:49:40 GMT+2, Dima Pasechnik 
 escribió:  
 
 On Fri, Mar 5, 2021 at 8:42 PM 'Daniel Volinski' via sage-support
 wrote:
>
> Hi All,
>
> I'm using SageMath 9.2 on Windows 10 Native with Jupyter Notebook.
>
> My question, is there any way to use Cadabra2 on a Jupyter Notebook after 
> installing SageMath?
>
> I do not want to install conda or anaconda or miniconda, I just want to use 
> Cadabra2 in the Jupyter Notebook provided by the SageMath installation and 
> may be with minimal installation of some software.

>From https://cadabra.science/download.html:
Windows 10
You will need a Python3 installation from Anaconda (64-bits, Python
3.8) and a LaTeX installation (tested with MikTeX, others may work
too) in order for this to work. Install those first if you do not have
them already. The Windows port and this binary installer are in beta
right now, please report any problems. Many thanks to Dominic Price
for making this become reality.

It seems it mixes well with conda, so why not?

Otherwise, I don't think anyone here has any idea whether Cadabra2 and
Sage will work together, and if yes, how.

>
> Thanks,
>
> Daniel Volinski
>
>
> --
> 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/14557094.2027036.1614975004314%40mail.yahoo.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/CAAWYfq2ZFE2vViOxPf0CZiUW_hUc3yj--2ZxQkwJwRLUt-VHcg%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/1467251413.81492.1615008723279%40mail.yahoo.com.


[sage-support] Using Cadabra2

2021-03-05 Thread 'Daniel Volinski' via sage-support
Hi All,
I'm using SageMath 9.2 on Windows 10 Native with Jupyter Notebook.

My question, is there any way to use Cadabra2 on a Jupyter Notebook after 
installing SageMath?
I do not want to install conda or anaconda or miniconda, I just want to use 
Cadabra2 in the Jupyter Notebook provided by the SageMath installation and may 
be with minimal installation of some software.
Thanks,
Daniel Volinski

-- 
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/14557094.2027036.1614975004314%40mail.yahoo.com.


[sage-support] power series method pade(m,n) off by 1?

2020-11-25 Thread Daniel Friedan
For p a power series in x, p.pade(m,n) requires p to be given up through 
and including O(x^(m+n+1)).

Shouldn't this be O(x^(m+n)) ?

The Padé approximant  P_m(x)/Q_n(x) contains m+n+1 unknown coefficients.  
So p(x) should contain m+n+1 terms, x^0 ... x^(m+n).

Or am I missing something elementary?

Daniel

-- 
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/7293d6c9-a26b-4778-a7dc-c80fe46c6b1bn%40googlegroups.com.


[sage-support] Unavailable link in online documentation

2020-08-27 Thread 'Daniel Volinski' via sage-support


Hi All,

In https://doc.sagemath.org/pdf/en/refer... 
<https://doc.sagemath.org/pdf/en/reference/> Section "Geometry and 
Topology', the first link is * :doc:Euclidean Spaces and Vector 
Calculus which does not link to any file. Please fix this.

Thanks,

Daniel


-- 
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/656a07c2-9c34-4afc-beba-f82db2d5caa6n%40googlegroups.com.


Re: [sage-support] Re: Computing a Groebner Basis (singular algorithm) raises an error

2019-05-27 Thread Daniel Krenn
On 27.05.19 20:40, Tracy Hall wrote:
> If anyone is curious to see an example 
> [...]
> sage: for ii in range(1):
> :     alarm(10)
> :     try:
> :         if prod(P.gens())^2 in anideal:
> :             cancel_alarm()
> [...]
> :     except AlarmInterrupt:
> :         print('Timeout.')
> :         break

+1 for trying to get something like this to work in SageMath; it would
be very convenient.



-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/c7e1a8db-b468-083f-963b-93eeeb861be4%40aon.at.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] Re: Computing a Groebner Basis (singular algorithm) raises an error

2019-05-27 Thread Daniel Krenn
On 27.05.19 18:08, Jeroen Demeyer wrote:
> On 2019-05-27 16:11, Tracy Hall wrote:
>> in particular it seems to have undefined
>> behavior in subsequent calls after it has been interrupted by alarm().
> 
> This is simply a fact of life and not really considered to be a bug. You
> should not rely on the fact that interruptions (using either CTRL-C or
> alarm) work perfectly. Don't use alarm() for serious computations.

Still, this is kind of annoying (I agree with the original poster), and
it would be great to find an easy applicable solution.

@Jeron (or whoever): Isn't there anything we can do to make it work
somehow? (Unfortunately, I do not know enough about this part of SageMath.)

Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/5afc6bb6-22b1-ba32-ec8b-aa935da0f038%40aon.at.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] How to permute a list of elements in sage

2019-05-20 Thread Daniel Krenn
On 20.05.19 05:29, jianrong wrote:
> I am trying to write a function in sage to permute a list of elements.

An alternative might me something along the following:

|
Permutation("(1,2,3)(4,5)").action(['a', 'b', 'c', 'd', 'e'])
|

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/5d1bf88f-f9c0-53ff-bd4b-db4c77c8c834%40aon.at.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] Re: parent of permutation

2019-05-03 Thread Daniel Krenn
On 04.05.19 06:04, Andrew wrote:
> The `Permutation` function is more general. For example, the folllowing
> all work: [...]

Thank you. But sorry, this does not answer my question. Maybe I should
be more precise:

What is the idea behind
|
sage: Permutation([5,4,3,2,1]).parent()
Standard permutations
sage: Permutation('(1,5)(2,4)(3)').parent()
Standard permutations of 5
|
returning different parents? (I.e. why the diffent parent depending on
the input format?)

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] parent of permutation

2019-05-03 Thread Daniel Krenn
sage: Permutation([5,4,3,2,1]).parent()
Standard permutations
sage: Permutation('(1,5)(2,4)(3)').parent()
Standard permutations of 5

Why is the first not restricted to permutations of length 5?

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] Re: reconnect to remote sagemath jupyter notebook?

2019-04-22 Thread Daniel Friedan
I'm sorry if I came off as snarky.  I really am sad to be losing this 
functionality of the SageMath notebook.  It has served me well in several 
substantial (for me) calculations over the last 12 years or so.  Of course 
I understand that scarcity of support resources justifies switching 
SageMath to the Jupyter notebook.  I'll hope that the Jupyter project 
catches up with the SageMath noteboook in this respect before the latter 
becomes unusable.

Thank you for the discussion.

Daniel

On Monday, April 22, 2019 at 2:32:28 PM UTC-4, Nils Bruin wrote:
>
> On Monday, April 22, 2019 at 11:13:23 AM UTC-7, Daniel Friedan wrote:
>>
>> One of the advantages of SageMath over Mathematica is SageMath's ability 
>> to run a remote notebook without continuous network connection.  The 
>> Mathematica remote kernel requires continuous connection.  It's sad that 
>> SageMath is regressing to the level of Mathematica in this respect.
>>
>
> I guess providing a platform for people to vent frustration about the 
> state of third party components used in sage out of necessity due to 
> developer shortage is also a form of support so you're welcome :-).
>
> For future reference:
>
> This is an issue that tracks this problem in jupyterlab:
>
> https://github.com/jupyterlab/jupyterlab/issues/2833
>
> It refers to the following issue, which handles "real time collaboration" 
> in jupyterlab, and as a consequence will deal with the 
> output-loss-on-reconnection problem:
>
> https://github.com/jupyterlab/jupyterlab/issues/5382
>
> The latter is under active development (and there's a branch there that 
> supposedly has most of what is required), so perhaps we'll get this in the 
> not-too-distant future. Note this is for JupyterLab. I'm not so sure this 
> will be backported to jupyter notebook. I already regularly use JupyterLab 
> for sage, python, and magma, and it seems to be working fine.
>
> For maintainability in the future, we might want to make is even easier 
> still to provide sagemath as a kernel to globally installed jupyters, 
> rather than just a prepackaged one.
>

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] Re: reconnect to remote sagemath jupyter notebook?

2019-04-22 Thread Daniel Friedan
One of the advantages of SageMath over Mathematica is SageMath's ability to 
run a remote notebook without continuous network connection.  The 
Mathematica remote kernel requires continuous connection.  It's sad that 
SageMath is regressing to the level of Mathematica in this respect.

Writing output to disk during a long calculation is normal at the 
production stage.  My problems come from intermediate sized calculations 
and from the testing stage of big calculations.  One wants to to be able to 
go back to the notebook frequently to check the output.

I've investigated cocalc.  It requires the overhead of Docker.  Also, it 
uses a modified version of Jupyter.  This is apparently fine for allowing 
interrupted network connections.  But the interface is apparently not 
identical.  I'm trying to proselytize for SageMath over Mathematica to 
members of my center who are already using Jupyter for Python coding (for 
Machine Learning in high energy physics).  Two versions of Jupyter won't 
fly.  Also, they use Machine Learning libraries that are not present in 
cocalc.  They can be installed in the Docker image, but too much IT support 
is required for that.  Running cocalc on one's laptop in addition to the 
server requires Docker on the laptop.  Too much trouble.

Daniel



On Monday, April 22, 2019 at 1:59:49 PM UTC-4, Nils Bruin wrote:
>
> On Monday, April 22, 2019 at 5:56:42 AM UTC-7, Daniel Friedan wrote:
>>
>> The kernel is still running.  The problem is not the culling of idle 
>> notebooks.
>>
>> When I close the browser tab and then reopen the notebook, the kernel is 
>> still running but output is lost and output from ongoing calculations does 
>> not appear.  When the ongoing calculations are finished, I can interact 
>> with the notebook again.
>>
>> Google tells me that this is a long-standing deficiency of Jupyter.
>>
>
> Ouch, I see. I didn't know that. I've tried and can confirm the behaviour. 
>
> The (deprecated) SageMath notebook behaves properly on reconnecting, as if 
>> there was no interruption.
>>
>> This behavior is indispensable to me, so I can't switch to the Jupyter 
>> notebook until Jupyter behaves properly when reconnecting.
>>
>  
> This deficiency in Jupyter is not going to make the resources available to 
> maintain the sagenotebook, so I'm afraid the reality is going to be we're 
> going to have to do without it. You could take a look if cocalc does a 
> better job. It has its own notebook and I think they wrote/adapted their 
> own ipynb frontend too.
>
> Otherwise, a work-around would be to structure long-running computations a 
> little differently to write state to a separate file rather than depending 
> on logging into the notebook. The kernel doesn't seem to lose state; it's 
> just output, so once the process has completed (which you could then see 
> from the file), the notebook is ready for interaction again.
>
> Another workaround is to not close the browser but instead use something 
> like VNC or xpra to disconnect/reconnect (remotely) to your running browser.
>
> It's pretty obvious that different behaviour of Jupyter would be the 
> better solution, but if the deficiency has been around for a long time and 
> you don't have definite plans to fix it yourself (I wouldn't know how to), 
> the reality is that this will likely not change.
>

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] Re: reconnect to remote sagemath jupyter notebook?

2019-04-22 Thread Daniel Friedan
The kernel is still running.  The problem is not the culling of idle 
notebooks.

When I close the browser tab and then reopen the notebook, the kernel is 
still running but output is lost and output from ongoing calculations does 
not appear.  When the ongoing calculations are finished, I can interact 
with the notebook again.

Google tells me that this is a long-standing deficiency of Jupyter.

The (deprecated) SageMath notebook behaves properly on reconnecting, as if 
there was no interruption.

This behavior is indispensable to me, so I can't switch to the Jupyter 
notebook until Jupyter behaves properly when reconnecting.

Daniel

On Wednesday, April 10, 2019 at 7:35:18 PM UTC-4, Nils Bruin wrote:
>
> On Wednesday, April 10, 2019 at 11:19:22 AM UTC-7, Daniel Friedan wrote:
>>
>> However, disconnecting my browser from a remote jupyter notebook aborts 
>> the calculation.
>>
>> That shouldn't need to happen. Jupyter notebook has configuration options 
> for killing "idle" notebooks (for various form of "idle", including "not 
> having a connected browser"):
>
>
> https://jupyter-notebook.readthedocs.io/en/stable/config.html?highlight=idle
>
> In addition, JupyterHub probably has its own ways of culling inactive 
> servers, for various forms of "inactive".
>
> I suspect this is something you'll have to fix in the configuration of 
> JupyterHub, or perhaps in your own jupyter notebook settings.
>
>  
>
>> Is there any way to get reconnectability in the sagemath jupyter notebook?
>>
>> Or should I stick with the deprecated sagemath notebook?
>>
>> thanks,
>> Daniel
>>
>> Daniel Friedan
>>
>>
>>
>>

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] reconnect to remote sagemath jupyter notebook?

2019-04-10 Thread Daniel Friedan
Over the past dozen years or so, I've used the (now deprecated) sagemath 
notebook for some long calculations on a server in my department.  A big 
practical advantage has been the ability to disconnect my browser from the 
notebook and then reconnect later to see the results (or see the 
calculation continuing).

I'm presently contemplating another long calculation.  Seeing the 
"deprecated" notice on the sagemath notebook login page, I asked to have 
JupyterHub installed on the server.   Now I can use sagemath 8.7 in a 
remote jupyter notebook on the server.

However, disconnecting my browser from a remote jupyter notebook aborts the 
calculation.

Is there any way to get reconnectability in the sagemath jupyter notebook?

Or should I stick with the deprecated sagemath notebook?

thanks,
Daniel

Daniel Friedan



-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] surface normal vector of polyhedron face

2019-02-27 Thread Daniel Krenn
On 27.02.19 16:12, Daniel Krenn wrote:
> On 27.02.19 15:35, Dima Pasechnik wrote:
>> So you get your normal vectors in the subspace parallel to the affine hull 
>> of P.
> 
> Thank you, looks easy :) (I am now just using orthogonal=True in my
> case, as I do not want to get non-rational.)

FYI, orthogonal=True does not seem to result in normal vectors, however
the final result when using orthonormal=True seem still to be rational
(although intermediate results are not).

Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] surface normal vector of polyhedron face

2019-02-27 Thread Daniel Krenn
On 27.02.19 15:35, Dima Pasechnik wrote:
>> Yes, this is the interesting case. The problem then is going back from
>> the projection. I guess that orthogonality is ususally destroyed here...
> One can ensure it is orthonormal:
> 
> sage: P = polytopes.simplex(2)
> sage: 
> M=P.affine_hull(orthonormal=True,as_affine_map=True,extend=True)[0].matrix()
> sage: v=P.inequalities()[0].vector()[1:]
> sage: M*(v*M)
> (0.6667?, -0.3334?, -0.3334?)
> sage: v=P.inequalities()[1].vector()[1:]
> sage: M*(v*M)
> (-0.3334?, 0.6667?, -0.3334?)
> sage: v=P.inequalities()[2].vector()[1:]
> sage: M*(v*M)
> (-0.3334?, -0.3334?, 0.6667?)
> 
> So you get your normal vectors in the subspace parallel to the affine hull of 
> P.

Thank you, looks easy :) (I am now just using orthogonal=True in my
case, as I do not want to get non-rational.)

Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] surface normal vector of polyhedron face

2019-02-27 Thread Daniel Krenn
On 27.02.19 14:34, Dima Pasechnik wrote:
> On Wed, Feb 27, 2019 at 1:02 PM Daniel Krenn  wrote:
>> Is there an easy way in SageMath to compute the in- or outward surface
>> normal vector of these faces of P? (in contrast to doing it all from
>> scratch). If not, are there methods that might help, so that not
>> everything needs to be built from scratch?
>>
>> Note: What I search for, is a method that works for a general compact
>> polyghedron in any dimension and their faces of dimension-1.
> 
> 
> In the full-dimensional case, say, P=polytopes.cube()
> P.inequalities() is more or less what you need (as they correspond to
> the facets,
> a.k.a. faces of codimension 1)
> e.g. P.inequalities()[0].vector()[1:]
> (0, 0, -1)
> is one of the 6 normal vectors.

In the full-dimensional case this indeed is the result.

> I suppose in non-full-dimensional case you still can use
> P.inequalities() as above,
> projecting them on the affine hull of P.

Yes, this is the interesting case. The problem then is going back from
the projection. I guess that orthogonality is ususally destroyed here...

Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] surface normal vector of polyhedron face

2019-02-27 Thread Daniel Krenn
Say we have

sage: P = polytopes.simplex(2)
sage: P.faces(1)
(<0,1>, <0,2>, <1,2>)

Is there an easy way in SageMath to compute the in- or outward surface
normal vector of these faces of P? (in contrast to doing it all from
scratch). If not, are there methods that might help, so that not
everything needs to be built from scratch?

Note: What I search for, is a method that works for a general compact
polyghedron in any dimension and their faces of dimension-1.

Best

Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] polyhedron H-representation: variables determined by equations

2019-02-25 Thread Daniel Krenn
The H-representation consists of equations and inequalities and the
equations seem to be in some canonical form. Is there a method that
returns the non-free variables (or indices), i.e. that are the variables
completely determined by the equations meaning once a value for the
other variables is fixed, then one can compute them and no further
restrictions apply.

E.g. for

sage: polytopes.simplex(2).Hrepresentation()
(An equation (1, 1, 1) x - 1 == 0,
 An inequality (0, -1, -1) x + 1 >= 0,
 An inequality (0, 1, 0) x + 0 >= 0,
 An inequality (0, 0, 1) x + 0 >= 0)

I simply want to get the list of indices [0], as the first component is
only determined by (1, 1, 1) x - 1 and does not appear in any of the
inequalities.

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] groebner basis algorithm: intended way of calling (out of other method)

2019-02-20 Thread Daniel Krenn
On 2019-02-08 10:07, Daniel Krenn wrote:
> Let I be an ideal. Then I might want to compute something involving
> Groebner basis, e.g. computing I.variety().
> Now suppose one wants to select a particular algorithm for the
> computation of the Groebner basis. Then (due to caching) I use something
> along the lines of
> 
>   GB = I.groebner_basis(algorithm='libsingular:slimgb')
>   I.groebner_basis.set_cache(GB)
>   I.variety()
> 
> Is this the intended way of doing so?
> 
> (It somehow feels wrong that one needs quite some background on the
> implementation and technical understanding (caching in SageMath) to
> understand the behavior.)

This is now
  https://trac.sagemath.org/ticket/27328
which proposes to use what is cached if no algorithm is given. Needs review.

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] Polyhedron.integrate: non-full dimension

2019-02-13 Thread Daniel Krenn
On 2018-12-05 11:07, Dima Pasechnik wrote:
>>>> For integrating a polynomial over a polyhedron LattE is used but if the
>>>> dimension is not full, then it is not implemented, see
>>>>
>>>>  sage: x, y = polygens(QQ, 'x, y')
>>>>  sage: P = Polyhedron(vertices=[[0,0],[1,1]])
>>>>  sage: P.integrate(x*y)# optional - latte_int
>>>>  Traceback (most recent call last):
>>>>  ...
>>>>  NotImplementedError: The polytope must be full-dimensional.
>>>> [...]
>>>
>>> you need an orthonormal transformation, thus potentially square roots,
>>> if you just want to move over to
>>> P.affine_hull() and integrate there.
>> [...]
> I suppose that in fact everything needed is actually available in Sage
> already, just not connected together. Indeed,
> (A,b)=P.affine_hull(as_affine_map=True, orthogonal=True)
> gives the rational change of coordinates,
> and so all you need is to use (A,b) to construct a ring homomorphism from
> R[x,y] to R[t], apply it to the integrand, integrate the result over
> P.affine_hull(orthogonal=True) # hopefully it would use the same (A,b)
> and scale the result by something like the square root of det(AA^T).

Why is it of importance that the transformation is orthogonal? (or is it
just a technical restriction as otherwise no matrix is returned at the
moment?)

> I'd actually propose to add an option to P.affine_hull() to give the caller
> both A,b and the resulting polytope.

+1

> And perhaps there is a 1-line way to construct the ring homomorphism, too
> (there should be one like this, anyway).

Would be interesting to know if there is a shortcut for this.

Best, Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] Re: groebner basis algorithm: intended way of calling (out of other method)

2019-02-08 Thread Daniel Krenn
On 2019-02-08 10:33, Simon King wrote:
> On 2019-02-08, Daniel Krenn  wrote:
>> Let I be an ideal. Then I might want to compute something involving
>> Groebner basis, e.g. computing I.variety().
>> Now suppose one wants to select a particular algorithm for the
>> computation of the Groebner basis. Then (due to caching) I use something
>> along the lines of
>>
>>   GB = I.groebner_basis(algorithm='libsingular:slimgb')
>>   I.groebner_basis.set_cache(GB)
>>   I.variety()
>>
>> Is this the intended way of doing so?
> 
> I guess not. I would expect that I.groebner_basis uses caching
> regardless of the used algorithm. Are you sure that this is not the
> case?

Not the case; I've carefully checked the code.

> Or do you say that I.groebner_basis sets a cache item for each possible
> value of "algorithm" individually? That would probably be a bug (i.e.,
> please open a ticket).

Yes, this is what I am saying. And indeed my implied question is,
whether this is a bug.

> Why "probably"? *Reduced* Gröbner bases are unique, hence, they should
> be cached independently of the algorithm used to compute them. But some
> algorithms would only call *some* Gröbner basis, no *the* reduced
> Gröbner basis. So, in these cases it makes sense to not automatically
> cache the value.

And indeed again, this is why I didn't open a ticket up to now. On the
contrary, the one-line description says
  "Return the reduced Groebner basis of this ideal"
Therefore, the intended result is unique and therefore, we have a bug as
above).

Which algorithm does not return a *reduced* Gröbner basis?

Best, Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] groebner basis algorithm: intended way of calling (out of other method)

2019-02-08 Thread Daniel Krenn
Let I be an ideal. Then I might want to compute something involving
Groebner basis, e.g. computing I.variety().
Now suppose one wants to select a particular algorithm for the
computation of the Groebner basis. Then (due to caching) I use something
along the lines of

  GB = I.groebner_basis(algorithm='libsingular:slimgb')
  I.groebner_basis.set_cache(GB)
  I.variety()

Is this the intended way of doing so?

(It somehow feels wrong that one needs quite some background on the
implementation and technical understanding (caching in SageMath) to
understand the behavior.)

Details: A method using a Groebner basis calls self.groebner_basis(),
i.e. uses default arguments or whatever is cached.

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] Polyhedron.integrate: non-full dimension

2018-12-04 Thread Daniel Krenn
On 2018-12-04 15:36, Dima Pasechnik wrote:
> On Tue, Dec 4, 2018 at 1:47 PM Daniel Krenn  wrote:
>> [I might not be that familiar with integration over polyhedra, but
>> shouldn't that basically be a somehow "nice" transformation where some
>> Jacobi-determinant comes into play?
> 
> you need an orthonormal transformation, thus potentially square roots,

I am aware of square roots.

> if you just want to move over to
> P.affine_hull() and integrate there.

Ok, thank you for the explaination.

> But the restriction to full-dimensional isn't really hard to overcome
> with a generalisation of the method
> in LattE, and I see how to do this, I think.
> If anyone cares I could implement this.

I definitly need this, so I care :) I, for sure can help or review the
code then.

Best

Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] Polyhedron.integrate: non-full dimension

2018-12-04 Thread Daniel Krenn
For integrating a polynomial over a polyhedron LattE is used but if the
dimension is not full, then it is not implemented, see

sage: x, y = polygens(QQ, 'x, y')
sage: P = Polyhedron(vertices=[[0,0],[1,1]])
sage: P.integrate(x*y)# optional - latte_int
Traceback (most recent call last):
...
NotImplementedError: The polytope must be full-dimensional.

from

http://doc.sagemath.org/html/en/reference/discrete_geometry/sage/geometry/polyhedron/base.html#sage.geometry.polyhedron.base.Polyhedron_base.integrate

I wonder if there is a (simple) way to come around this?

[I might not be that familiar with integration over polyhedra, but
shouldn't that basically be a somehow "nice" transformation where some
Jacobi-determinant comes into play? Or are there other
mathematical/technical difficulties that arise?]

Best, Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] full_simplify() gets wrong answer

2018-11-13 Thread Daniel Krenn
On 2018-11-13 06:20, Michael Beeson wrote:
> def demo():
> var('N,x')
> test = ((N*(3*I*sqrt(3) + 9) + N*(3*I*sqrt(3) - 3)))*x
> print("test = ")
> print(test)
> print("test.full_simplify() = ")
> print(test.full_simplify())
> 
> Here is the output
> 
> sage: demo()
> 
> test = 
> 
> (N*(3*I*sqrt(3) + 9) + N*(3*I*sqrt(3) - 3))*x
> 
> test.full_simplify() = 
> 
> (36*I*sqrt(3)*N + 6)*x

I cannot repreduce this on 8.4:

sage: demo()
test =
-3*(N*(-I*sqrt(3) + 1) + N*(-I*sqrt(3) - 3))*x
test.full_simplify() =
-6*N*x*(-I*sqrt(3) - 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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] Blue on black text

2018-10-31 Thread Daniel Krenn
On 2018-10-31 12:21, deSitter wrote:
> My text terminal uses a black background. The default text is dark blue
> on jet black. This is not a winning start to 8.4. How do I change the
> text color. Seriously, this is the sort of little thing that is
> absolutely exasperating, to get a perfect build right out of the box and
> then find it unreadable and so unusable. What Sage really needs is
> someone to fix these usage issues and make the thing presentable and the
> syntax less brittle! I'm not busy at the moment. Contact me, believe me,
> I will fix this.

I know that here is

%colors linux

and similar.

HTH Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] group of roots of unity

2018-10-23 Thread Daniel Krenn
Is there an algebraic structure for the group of roots of unity in
SageMath?
To clearify: I think of something whose elements are all roots of unity
or all n-th root of unity for a given n and the group operation is
multiplication.

Best, Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] Re: No interact libraries

2018-04-29 Thread Daniel Santos
Hi

Im glad to help.

I'll keep on working with Jupyter notebook.


I really like sagemath, I'll use to teach basic math to my future students.

Thank you again.

-Santos

El dom., abr. 29, 2018 14:09, slelievre 
escribió:

> Sun 2018-04-29 08:16:14 UTC, Daniel Santos:
> >
> > Hi support team.
> >
> > I'm looking for information of the "interact command" in sage.
> >
> > https://wiki.sagemath.org/interact
> >
> > But there is not a manual for it, also when I clicked:
> >
> http://www.sagemath.org/doc/reference/sagenb/notebook/interact.html#sagenb.notebook.interact.interact
> >
> > There is 404 Error.
> >
> > Where i can find information about the Interact command?
>
> Thanks for your report! I edited the interact page
> of the Sage wiki, adding links to the documentation:
>
> - interacts in the Jupyter notebook
>
> http://doc.sagemath.org/html/en/reference/repl/sage/repl/ipython_kernel/interact.html
>
> - interacts in the legacy SageNB notebook
>
> http://doc.sagemath.org/html/en/reference/notebook/sagenb/notebook/interact.html
>
> > By the way I've been trying to work in the sage notebook()
> > but there is not Syntax Highlighting, I really like the Sage
> > notebook, it is most robust.
>
> It has its merits, but it is no longer developed;
> one could say it is in low maintenance mode.
>
> > Is there something i can do to have Syntax Highlighting?
>
> I don't know.
>
> > By the moment I'll start using Jupyter notebook,
> > it has the syntax highlighting.
>
> Good idea. All the notebook development effort now goes
> to the Jupyter notebook.
>
> --
> 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 post to this group, send email to sage-support@googlegroups.com.
> Visit this group at https://groups.google.com/group/sage-support.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] No interact libraries

2018-04-29 Thread Daniel Santos
Hi henry,

Thanks for the information. I was able to do what i wanted.

Best regards

Daniel Santos


El dom., abr. 29, 2018 8:26, Henri Girard  escribió:

> http://ipywidgets.readthedocs.io/en/latest/examples/Using%20Interact.html
>
> Any use ?
>
>
>
> Le 29/04/2018 à 06:25, Daniel S a écrit :
>
> Hi support team.
>
> I'm looking for information of the "interact command" in sage.
>
> https://wiki.sagemath.org/interact
>
> But there is not a manual for it, also when I clicked:
>
>
> http://www.sagemath.org/doc/reference/sagenb/notebook/interact.html#sagenb.notebook.interact.interact
>
> There is 404 Error.
>
> [image: interact 404 error]
>
> Where i can find information about the Interact command?
>
> By the way I've been trying to work in the sage notebook() but there is
> not Syntax Highlighting, I really like the Sage_notebook, it is most robust.
>
> [image: no syntax highlighting]
>
> Is there something i can do to have Syntax Highlighting?
>
> by the moment I'll start using Jupiter_notebook() it has the syntax
> highlighting.
>
> [image: Jupiter Notebook]
>
> Best regards
>
> Daniel Santos
>
>
>
>
> --
> 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 post to this group, send email to sage-support@googlegroups.com.
> Visit this group at https://groups.google.com/group/sage-support.
> For more options, visit https://groups.google.com/d/optout.
>
>
> --
> 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 post to this group, send email to sage-support@googlegroups.com.
> Visit this group at https://groups.google.com/group/sage-support.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] How do I use SageMath using my browser? (Windows)

2018-03-08 Thread Daniel
I have followed the installation procedure on the website but I am not able 
to access Sagemath using my web browser.
The manual tells me to navigate to localhost:8000 but I am getting "unable 
to connect."
I am using sagemath 8.1.ova. How can I use sagemath in the browser?

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] How to return exponents of a multivariable polynomial in Sage?

2017-10-22 Thread Daniel Krenn
On 2017-10-22 17:27, Jianrong Li wrote:
> Let $r=x_{1}^{4} + 2 \, x_{1}^{3} x_{2} + 4 \, x_{1}^{2} x_{2}^{2} + 2
> \, x_{1}
> x_{2}^{3} + x_{2}^{4} + 2 \, x_{1}^{3} x_{3} + 2 \, x_{2}^{3} x_{3} + 4
> \, x_{1}^{2} x_{3}^{2} + 4 \, x_{2}^{2} x_{3}^{2} + 2 \, x_{1} x_{3}^{3}
> + 2 \, x_{2} x_{3}^{3} + x_{3}^{4}$. 
> 
> 1. How to return the list of exponents of the monomials in $r$ in Sage? 
> 
> The result I want is $[(4,0,0), (3,1,0), \ldots]$.
> 
> 2. How to list of terms in Sage?
> 
> The result I want is $[x_{1}^{4}, 2 \, x_{1}^{3} x_{2}, \ldots]$. 
> 
> For Question 1, I used 
> 
> R. = PolynomialRing(QQbar, 3)
> 
> r.exponents() 

In SageMath 8.0 the following works:

sage: R. = PolynomialRing(QQbar, 3)
sage: r = x1*x2 + 2*x3
sage: r.exponents()
[(1, 1, 0), (0, 0, 1)]
sage: r.monomials()
[x1*x2, x3]
sage: list(r)
[(1, x1*x2), (2, x3)]

> This works. But when I tried to use op for Question 2. It is said that 
> 
> AttributeError: 'MPolynomial_polydict' object has no attribute 'op'

Can you copy/paste the code you type to reproduce this error?

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] Re: save/pickle data of cached_method (used in ideals and groebner_basis)

2017-08-12 Thread Daniel Krenn
On 2017-08-12 12:10, Daniel Krenn wrote:
> On 2017-08-12 11:14, Volker Braun wrote:
>> Caches from @cached_method are pickled by default, but the class can
>> opt-out of this. Sometimes this is necessary to make pickling work (not
>> every Cython object is pickle-able).
> 
> Hmmmshouldn't the below work then?
> 
> sage: class A(SageObject):
> : @cached_method
> : def a(self):
> : print('oo')
> : return 42
> :
> sage: a = A()
> sage: a.a()
> oo
> 42
> sage: a.a()
> 42
> sage: save(a, 'a.sobj')
> sage: b = load('a.sobj')
> sage: b.a()  # again "computes" 42
> oo
> 42
> 

Indeed there is
@cached_method(do_pickle=True)
...and this is used for Groebner basis in the ideal. So all my problems
are solved :)



-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] Re: save/pickle data of cached_method (used in ideals and groebner_basis)

2017-08-12 Thread Daniel Krenn
On 2017-08-12 11:14, Volker Braun wrote:
> Caches from @cached_method are pickled by default, but the class can
> opt-out of this. Sometimes this is necessary to make pickling work (not
> every Cython object is pickle-able).

Hmmmshouldn't the below work then?

sage: class A(SageObject):
: @cached_method
: def a(self):
: print('oo')
: return 42
:
sage: a = A()
sage: a.a()
oo
42
sage: a.a()
42
sage: save(a, 'a.sobj')
sage: b = load('a.sobj')
sage: b.a()  # again "computes" 42
oo
42

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] save/pickle data of cached_method (used in ideals and groebner_basis)

2017-08-12 Thread Daniel Krenn
I have an ideal and computed its Groebner basis (6 hours). Now I want to
store this result, which is not the problem itself, but when loading
this data, it seems not possible to reconstruct the ideal (meaning
create it with the original generators and "bootstrap" the groebner
basis found earlier).

As the Groebner basis is cached somewhere via cached_method: Is there an
option, so that the data stored by cached_method is saved as well when
saving e.g. the whole ideal?

Any ideas how to do this (nicely)?

[I ask for "nicely", as, of course, I can create the ideal of the
original generators, and then access the cache of groebner_basis
manually and push the stored data somehow into it.

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] guesing algebraic numbers from floats

2017-07-20 Thread Daniel Krenn
On 2017-07-20 16:34, Vincent Delecroix wrote:
> sage: algdep(RealField(20)(1.4142), 2)
> x^2 - 2
> 
> Note that you have to specify the maximal degree. Be careful about the
> input
> 
> sage: algdep(1.4142, 2)
> 5000*x - 7071
> 
> This is using the PARI/GP algdep command (whose algorithm is a LLL
> reduction).

Thank you.

Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] guesing algebraic numbers from floats

2017-07-20 Thread Daniel Krenn
Dear all,

I vaguely remember a discussion on this list some years ago about the
following: Given a floating point number, what is a good guess for the
simplest possible algebraic number that approximates this?

E.g. The input 1.4142 gives back sqrt(2) or x^2-2 and says that this is
approximates the input on the first four digits. (Of course much more
precise guesses would be possible, but a simple one should just do fine.)

(I am aware that this is not a Sage-specific question, but when I
remember correctly, there was some software mentioned in that thread
years ago, which can do this. Maybe I am completely wrong and it was
somewhere else; but maybe someone has an idea if such a program exists.)

Best wishes

Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] graphs: moving vertices by mouse

2017-04-28 Thread Daniel Krenn
On 2017-04-28 22:11, William Stein wrote:
> In SMC in a **Sage worksheet**, do
> 
> show(g)

Thanks. (I've tried g.show() in the SMC, and then one gets only the
usual static representation).

Best

Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] graphs: moving vertices by mouse

2017-04-28 Thread Daniel Krenn
Is there a way to click on a vertex of a SageMath-graph (in some
notebook, Jupyter or SMC-notebook) and drag it around, thus manually
positioning the vertices?

(I think there was a graph_editor in the old Sage Notebook which could
do this, but this does not seem to work in one of the new notebooks.)

Best

Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] .format of RR-element

2017-04-28 Thread Daniel Krenn
Shouldn't the following two both work?

sage: '%.2f' % (pi.n(),)
'3.14'

sage: '{:.2f}'.format(pi.n())
---
ValueErrorTraceback (most recent call last)
 in ()
> 1 '{:.2f}'.format(pi.n())

ValueError: Unknown format code 'f' for object of type 'str'


-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] Impossible to launch sage after downloading the .tar.bz

2017-03-04 Thread Daniel


Hello, 
I've just bougth a new laptop and after installing Xubuntu 16.10, I tried 
to install SageMath. So I downloaded the file, like explained on the 
website but when I try to launch it, I have this error message : 





Somebody has a clue ?

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] embedding of number field element encapseled in symbolic ring

2017-01-08 Thread Daniel Krenn
On 2017-01-07 11:09, Vincent Delecroix wrote:
> Le 05/01/2017 à 11:33, Daniel Krenn a écrit :
>> It seems like the embedding is simply ignored in some sense:
>>   sage: QQbar(QuadraticField(-1, 'I', embedding=-CC.gen()).gen())
>>   I
> 
> To my mind, this one should actually raise an error.

Ok.

> The proper way to
> declare an embedding in QQbar is via
> 
> sage: K = QuadraticField(-1, 'I', embedding=-QQbar(I))
> sage: K.0
> I
> sage: QQbar(K.0)
> -I
> 
> which works perfectly fine.

Is it possible to define one embedding from a number field into CC and
another into QQbar (at "the same time")?

Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] embedding of number field element encapseled in symbolic ring

2017-01-05 Thread Daniel Krenn
On 2017-01-05 11:29, Daniel Krenn wrote:
> On 2017-01-05 10:55, Daniel Krenn wrote:
>> as there is no *canonical* coercion as no embedding of the number field
>> is specified.
>>
>> How can I specify this embedding such that it is used e.g. for the
>> symbolic I?
> 
> This looks weird: I is defined in sage.libs.pynac.pynac via
> K = QuadraticField(-1, 'I', embedding=CC.gen(), latex_name='i')
> pynac_I = K.gen()
> so there is an embedding defined, but QQbar this seems to be not
> sufficient to recognize it as an embedding into QQbar.

It seems like the embedding is simply ignored in some sense:
  sage: QQbar(QuadraticField(-1, 'I', embedding=-CC.gen()).gen())
  I
whereas
  sage: CC(QuadraticField(-1, 'I', embedding=-CC.gen()).gen())
  -1.00*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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] embedding of number field element encapseled in symbolic ring

2017-01-05 Thread Daniel Krenn
On 2017-01-05 10:55, Daniel Krenn wrote:
> as there is no *canonical* coercion as no embedding of the number field
> is specified.
> 
> How can I specify this embedding such that it is used e.g. for the
> symbolic I?

This looks weird: I is defined in sage.libs.pynac.pynac via
K = QuadraticField(-1, 'I', embedding=CC.gen(), latex_name='i')
pynac_I = K.gen()
so there is an embedding defined, but QQbar this seems to be not
sufficient to recognize it as an embedding into QQbar.

How can this be fixed?

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] embedding of number field element encapseled in symbolic ring

2017-01-05 Thread Daniel Krenn
I want to take an number field element embedded in the symbolic ring
like the imaginary I and add it to an algebraic number:
  sage: I.pyobject() + QQbar(sqrt(2))
This results in
  TypeError: unsupported operand parent(s) for '+': 'Number Field in I
  with defining polynomial x^2 + 1' and 'Algebraic Field'
as there is no *canonical* coercion as no embedding of the number field
is specified.

How can I specify this embedding such that it is used e.g. for the
symbolic I?

I've tried
  sage: F = NumberField(x^2 + 1, 'i', embedding=QQbar(I))
which makes
  sage: F.0 + QQbar(sqrt(2))
  1.414213562373095? + 1*I
work. However,
  sage: SR(F.0)
  I
so it is converted to the existing I and the example at the top
  sage: SR(F.0).pyobject() + QQbar(sqrt(2))
fails again.

Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] Re: apply substitution only at specific summand

2016-12-12 Thread Daniel Krenn
On 2016-12-13 08:06, Ralf Stephan wrote:
> On Monday, December 12, 2016 at 10:55:32 AM UTC+1, Daniel Krenn wrote:
> and the source in src/sage/symbolic/integration/integral.py
> you must walk the expression tree and apply subs to the first operand of
> all instances of
> integrate which is a symbolic function (operator).

I figured this out (but didn't want to do it completely from scratch).

> To do such walks in
> Python you usually
> create a subclass of one of the classes
> in symbolic/expression_conversions.py
> An example can be seen at
> https://github.com/sagemath/sage/blob/master/src/sage/symbolic/expression.pyx#L5467
> where sums with all-numeric arguments inside an expression are expanded.
> The rest of
> the expression is just copied. Note the class is defined inside the
> function where it's used.

Nice, thank you. :)

Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] apply substitution only at specific summand

2016-12-12 Thread Daniel Krenn
Let f be a sum of symbolic expressions. One of the summands is

sage: a = ((z^3 - 10*z^2 + 17*z - 8)/(z^4 + z^3 + z^2 + z + 1)).integrate(z)
sage: a
integrate((z^3 - 10*z^2 + 17*z - 8)/(z^4 + z^3 + z^2 + z + 1), z)

which cannot be integrated. However, doing

sage: a.subs({z^4 + z^3 + z^2 + z + 1: (z^5-1)/(z-1)}).expand()

evaluates the integral.

How do I apply subs/expand only to the summands of f, which have
operator "integrate" and not to any other summand?

(I can only think of very complicated and long workarounds, so what is
the best way to do this?)

Best

Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] Development process

2016-12-07 Thread Daniel Krenn
On 2016-12-07 10:00, Dima Pasechnik wrote:
> I don't see how using git worktree would reduce recompilation, for the 
> merging workflow you recommend touches a lot of files, potentially.

In your SageMath root, assuming you are at branch develop:

git worktree add ../merge
cd ../merge
git trac checkout 9  # getting on an old branch t/9/something
git merge develop
cd ../sage-develop
git checkout t/9/something

No files touched (except the ones changed in the old branch of course)

> The workflow I recommend may be paired with git rebase to get rid of extra 
> commits, leaving a nicer history.

rebase is almost always a bad idea. (The history looks nicer, but noone
using the old branch can track the changes.)

FWIW, http://justinhileman.info/article/git-pretty/git-pretty.png

Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] Development process

2016-12-07 Thread Daniel Krenn
On 2016-12-07 08:58, Dima Pasechnik wrote:
> For the purposes of reviewing you do not care about history being
> clean in your local branches, and what I describe does not lead to
> much recompilation.

For reviewing (without any new commits) this works.

> Whereas in particular with old tickets, with branches based on old
> versions of Sage, in your approach sometimes one would need to
> rebuild Sage from scratch.

Or use a separate git repo for this merges or use "git worktree".

Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] Development process

2016-12-06 Thread Daniel Krenn
On 2016-12-06 22:02, Justin C. Walker wrote:
> I am starting in a new, empty directory, and 'git' seems to want a repository 
> specified.
> 
> I have a "global" .gitconfig file set up.
> 
> A couple of questions:
> 
> Should I check out the 'develop' branch first, and then incorporate (how?) 
> the branch on top,
> or should I check out the branch first, and then updated it (how?) to the 
> develop branch?

The latter,

git trac checkout 9

which basically does

git fetch trac u/blah/branch-name
git checkout -b u/myname/branch-name u/blah/branch-name

After that, merge in the latest development by

git merge develop

In this way, the history keeps clean (Thus, you do not want to use the
first method mentioned). Note, however, that this may cause some
recompilation.
There was a recent discussion here on some of the lists about this...

Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] Sage Crash Report

2016-08-29 Thread Daniel Gerstenlauer


-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.
***

IPython post-mortem report

{'commit_hash': u'f76401f',
 'commit_source': 'installation',
 'default_encoding': 'UTF-8',
 'ipython_path': '/opt/sage/local/lib/python2.7/site-packages/IPython',
 'ipython_version': '4.1.2',
 'os_name': 'posix',
 'platform': 'Linux-4.4.0-34-generic-x86_64-with-debian-jessie-sid',
 'sys_executable': '/opt/sage/local/bin/python',
 'sys_platform': 'linux2',
 'sys_version': '2.7.10 (default, May 16 2016, 05:06:16) \n[GCC 4.9.3]'}

***



***

Crash traceback:

---
---
IndexErrorPython 2.7.10: /opt/sage/local/bin/python
   Mon Aug 29 09:42:41 2016
A problem occurred executing Python code.  Here is the sequence of function
calls leading up to the error, with the most recent (innermost) call last.
/opt/sage/src/bin/sage-ipython in ()
  1 #!/usr/bin/env python
  2 # -*- coding: utf-8 -*-
  3 """
  4 Sage IPython startup script.
  5 """
  6 
  7 # Install extra readline commands before IPython initialization
  8 from sage.repl.readline_extra_commands import *
  9 
 10 from sage.repl.interpreter import SageTerminalApp
 11 
 12 app = SageTerminalApp.instance()
 13 app.initialize()
---> 14 app.start()
global app.start = >

/opt/sage/local/lib/python2.7/site-packages/IPython/terminal/ipapp.pyc in 
start(self=)
330 if self.log_level <= logging.INFO: print()
331 
332 def _pylab_changed(self, name, old, new):
333 """Replace --pylab='inline' with --pylab='auto'"""
334 if new == 'inline':
335 warn.warn("'inline' not available as pylab backend, "
336   "using 'auto' instead.")
337 self.pylab = 'auto'
338 
339 def start(self):
340 if self.subapp is not None:
341 return self.subapp.start()
342 # perform any prexec steps:
343 if self.interact:
344 self.log.debug("Starting IPython's mainloop...")
--> 345 self.shell.mainloop()
self.shell.mainloop = >
346 else:
347 self.log.debug("IPython not interactive...")
348 
349 def load_default_config(ipython_dir=None):
350 """Load the default config file from the default ipython_dir.
351 
352 This is useful for embedded shells.
353 """
354 if ipython_dir is None:
355 ipython_dir = get_ipython_dir()
356 
357 profile_dir = os.path.join(ipython_dir, 'profile_default')
358 
359 config = Config()
360 for cf in Application._load_config_files("ipython_config", 
path=profile_dir):

/opt/sage/local/lib/python2.7/site-packages/IPython/terminal/interactiveshell.pyc
 in mainloop(self=, 
display_banner=None)
533 
#-
534 # Mainloop and code execution logic
535 
#-
536 
537 def mainloop(self, display_banner=None):
538 """Start the mainloop.
539 
540 If an optional banner argument is given, it will override the
541 internally created default banner.
542 """
543 
544 with self.builtin_trap, self.display_trap:
545 
546 while 1:
547 try:
--> 548 self.interact(display_banner=display_banner)
self.interact = >
display_banner = None
549 #self.interact_with_readline()
550 # XXX for testing of a readline-decoupled repl 
loop, call
551 # interact_with_readline above
552 break
553 except KeyboardInterrupt:
554 # this should not be necessary, but 
KeyboardInterrupt
555 # handling seems rather unpredictable...
556 self.write("\nKeyboardInterrupt in interact()\n")
557 
558 def _replace_rlhist_multiline(self, source_raw, hlen_before_cell):
559 """S

[sage-support] tab-completion in new IPython-command line

2016-08-25 Thread Daniel Krenn
Pressing TAB after a dot on some object gives (in the recent 7.4.beta1)
this:

sage: M = Matrix([1])
sage: M.
  M.act_on_polynomial   M.anticommutator
  M.add_multiple_of_column  M.antitranspose
  M.add_multiple_of_row M.apply_map   >
  M.additive_order  M.apply_morphism
  M.adjoint M.as_bipartite_graph

This looks nice, but is it possible to see more/all methods at once?

When searching for something (a method) of some object (with many
methods) it is convenient to see the whole list at once. This also
allows (allowed) copying&grepping for some keywords.
So:
- Is there a way to display more at once?
- How to navigate back and forth easily?
(All this relates to the command line interface.)

Best

Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] Doing a discrete fourier transform in sage

2016-07-21 Thread Daniel Mulholland
I'd like to carry out a discrete fourier transformer on some data but 
attempts so far have not been successful.

I've been able to do an FFT in the following manner:

def mmag(a):
return sqrt(a[0]^2+a[1]^2)

a = FastFourierTransform(4)
a[0]=0.707
a[1]=-0.707
a[2]=-0.707
a[3]=0.707
print a
print a.forward_transform()
print [mmag(kk) for kk in a]


However I don't know how to do the magnitude properly (I tried abs, norm 
and was not able to get either to work).

However to sort out the DFT:

J = range(4)
B = [707/1000,-707/1000,-707/1000,707/1000]
A = [QQ(i) for i in B]
print A
s = IndexedSequence(A,J)
print s.dft()


This gives me:

[(0.707, 0.0), (-0.707, 0.0), (-0.707, 0.0), (0.707, 0.0)]

None

[0.0, 1.999697977195556, 0.0, 1.9996979771955563]

[707/1000, -707/1000, -707/1000, 707/1000]

Indexed sequence: [0, -707/500*zeta4 + 707/500, 0, 707/500*zeta4 + 707/500]

indexed by [0, 1, 2, 3]

Is this the expected result? I was not expecting the zeta4 multiplies and was 
hoping to get the same result as the FFT above.


regards

Dan
-- 

--
Private or confidential message? Public Key available here 

: 

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] tikzposter and sagetex fails

2016-06-27 Thread Daniel Krenn
The tex-lines

  \documentclass{tikzposter}

  \usepackage{sagetex}

  \begin{document}

  Bla.

  \end{document}

fail with

  ! Undefined control sequence.
  \@enddocumenthook ... \jobname .tex'}
  \fi \ST@wsf
  {_st_.endofdoc()}\@ifundef...
  l.5 \end{document}

Any ideas?

Best wishes

Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] Need handholding about Sage Git good practices.

2016-04-01 Thread Daniel Krenn
On 2016-04-01 21:31, Emmanuel Charpentier wrote:
>   * revert to by original patch against 7.1rc0, update it and push this
> to Trac for review ? Or
>   * push by jumbo patch ?

If the merge of 7.2.beta2 into your 7.1.rc0+whatever works without a
conflict, then there is no need to do this merge. If there is a
conflict, then you should merge 7.2.beta2 into your 7.1.rc0+whatever.
(Just to point this out: you should merge it in the way said and not the
other way round)

But, I have to admit, maybe I do not understand your problem completely
(because merging in 7.2.beta2 if not needed is possible as well; I do
not see why you call it jumbo patch).

Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] Re: Zombie processes when using sage0 interface

2016-02-27 Thread Daniel Lännström
Hello again! 

I think I have successfully migrated this by using waitpid to reap zombies. 
This is by trial and error so I am not sure if this works reliably. 
Example code here: 
https://github.com/neural99/sage-zombie-debug/blob/master/zombie_fix.sage

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] Cython spyx import problem

2016-02-22 Thread Daniel Krenn
On 2016-02-17 17:25, Dima Pasechnik wrote:
> it's not related to RIF, it seems. Compilation ends with
> 
> ImportError: cannot import name ZZ
> 
> and even the following does not work:
> 
> import sage.all
> from sage.all import *
> from sage.rings.integer_ring import ZZ
> print ZZ(1000)
> 
> --
> Broken spyx support, in general (on the latest 7.1 beta) ?!

Fails on 7.1.beta4, 7.0, 6.9 with
  ImportError: cannot import name ZZ
Fails on 6.8 as well, but with
  error: command 'gcc' failed with exit status 1

This is now
  http://trac.sagemath.org/ticket/20093

Best,

Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] Zombie processes when using sage0 interface

2016-02-18 Thread Daniel Lännström
I have noticed that when using the sage0 interface zombie processes remain 
even after running the sage.interfaces.quit.expect_quitall function.

Is this a bug? Is there some way to migrate this?

Here is an example of what I am talking about. Here is the content of the 
file zombie_test.sage 

import sage.interfaces.sage0
import sage.interfaces.quit

def create_new_instances():
s = sage.interfaces.sage0.Sage()
s('4')
del s

print "Create instances"
create_new_instances()
raw_input('continue?')
print "Run expect_quit"
sage.interfaces.quit.expect_quitall(verbose=True)
raw_input('continue?')

After running the create_new_instances() function the relevant part of the 
process tree looks like this.

  |   |   |   `-bash,7619 /usr/lib/sagemath/local/bin/sage-python 
zombie_test.sage.py
  |   |   |   |-python,7661 /usr/lib/sagemath/local/bin/sage-cleaner
  |   |   |   `-python,7663 zombie_test.sage.py
  |   |   |   |-python,7668 
/usr/lib/sagemath/local/bin/sage-ipython 
--HistoryManager.hist_file=:memory: ...
  |   |   |   `-(python,7669)

But process 7669 is a zombie!

  PID TTY  STAT   TIME COMMAND
 7669 pts/6Z  0:00 [python] 

Next running sage.interfaces.quit.expect_quitall outputs

Exiting Sage with PID 7668 running /usr/lib/sagemath/local/bin/sage-ipython 
--HistoryManager.hist_file=:memory: --colors=NoColor

Indeed process 7668 has been removed but process 7669 remains and the 
process tree looks like this:

  |   |   |   `-bash,7619 /usr/lib/sagemath/local/bin/sage-python 
zombie_test.sage.py
  |   |   |   |-python,7661 /usr/lib/sagemath/local/bin/sage-cleaner
  |   |   |   `-python,7663 zombie_test.sage.py
  |   |   |   |-(python,7668)
  |   |   |   |-(python,7669)
  |   |   |   `-python,7701 zombie_test.sage.py

In my work I'm running a long executing program and these zombie processes 
are annoying. 

Finally some info about my setup:
Sage Version 6.9, Release Date: 2015-10-10
Ubuntu MATE 15.10
Linux kernel 4.2.0-27-generic 



-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] Cython spyx import problem

2016-02-17 Thread Daniel Krenn
On 2016-02-17 10:16, Dima Pasechnik wrote:
> 
> 
> On Wednesday, February 17, 2016 at 7:26:18 AM UTC, Daniel Krenn wrote:
> 
> On 2016-02-17 08:05, Jeroen Demeyer wrote:
> > On 2016-02-17 07:33, Daniel Krenn wrote:
> >> Calling this in my working directory with
> >>sage problem.spyx
> >> fails with
> >>Traceback (most recent call last):
> >>...
> >>ImportError: cannot import name ZZ
> >>
> >> What can I do to make it work?
> >
> > import sage.all first.
> 
> problem.spyx
> 
> import sage.all
> from sage.rings.real_interval_field import RealIntervalField  # fails
> RealIntervalField(100)(4.2)
> 
> 
> does not work either (same error as before; in line 2)
> 
> 
> this does not work at sage: prompt either, for the simple reason that
> there is no such thing!
> 
> Here is what you can import (at sage prompt after import you  hit tab to
> get this)
> 
> sage: from sage.rings.real_interval_field import 
> RealIntervalFieldElement__reduce__RealIntervalFieldElement
> RealIntervalField_class is_RealIntervalField
> __reduce__RealIntervalField is_RealIntervalFieldElement

True...it seems i was a bit confused  :) ...and the error message did
not imply this at all...

However,

import sage.all
from sage.rings.real_mpfi import RealIntervalField
RealIntervalField(100)(4.2)

in problem.spyx does not work either. More ideas?

Best

Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] Cython spyx import problem

2016-02-16 Thread Daniel Krenn
On 2016-02-17 08:05, Jeroen Demeyer wrote:
> On 2016-02-17 07:33, Daniel Krenn wrote:
>> Calling this in my working directory with
>>sage problem.spyx
>> fails with
>>Traceback (most recent call last):
>>...
>>ImportError: cannot import name ZZ
>>
>> What can I do to make it work?
> 
> import sage.all first.

problem.spyx

import sage.all
from sage.rings.real_interval_field import RealIntervalField  # fails
RealIntervalField(100)(4.2)


does not work either (same error as before; in line 2)


-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] Cython spyx import problem

2016-02-16 Thread Daniel Krenn
My problem boils down to:

problem.spyx

from sage.rings.real_interval_field import RealIntervalField  # fails
RealIntervalField(100)(4.2)  # not needed in minimal non-working example


Calling this in my working directory with
  sage problem.spyx
fails with
  Traceback (most recent call last):
  ...
  ImportError: cannot import name ZZ

What can I do to make it work?

Best

Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] Same Matrix Construction gives two different results

2015-11-09 Thread Daniel Krenn
On 2015-11-09 08:06, P Purkayastha wrote:
> [...] so that everything gets coerced to Sage
> integers, irrespective of the input:
> 
> Q = Integer(q)

FYI, this is a conversion; use
  Q = ZZ.coerce(q)
instead.

Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] Re: plot a 3d polyhedron with transparent background?

2015-07-10 Thread Daniel Friedan


On Wednesday, July 8, 2015 at 2:37:59 PM UTC, kcrisman wrote:
>
> When I do the same for a 3d polyhedron, the background is white.
>>>
>>
>> Given that p3.show(whatever=15) does not raise an exception, I would say 
>> that 'transparent' is not supported for 3d plots and that your argument is 
>> ignored.
>>
>
> Yes, I believe that is the case.  There *is* the "opacity" keyword, e.g. 
> opacity=0.5, which might do what you are looking for - well, I'm not sure 
> what you are looking for exactly, but you can try it.
>

The "opacity" keyword controls the opacity of the polyhedron, not the 
background.

I was making an animation of the construction of a flat 1-cycle (a limit of 
1-cycles in R^3).The construction added tinier and tinier 1-cycles at 
each step.

I made the frames using Polyhedron.plot(), then .save(), then used 
os.system() to invoke ImageMagick to stitch the frames together as an 
animated gif.

I had to plot the entire 1-cycle for each frame.

It would have saved processing time and storage space if I could have saved 
only a plot of the 1-cycles added at each step of the construction, with a 
transparent background, then overlaid that plot on the previous plots using 
ImageMagick.  Overlaying doesn't work when the latest image has a white 
background.

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] plot a 3d polyhedron with transparent background?

2015-07-06 Thread Daniel Friedan
Is it possible to plot a 3d polyhedron with transparent background?

When I use .plot(transparent=True) on a 2d polyhedron, and save to a file, 
the background is transparent.

When I do the same for a 3d polyhedron, the background is white.

p2=Polyhedron(vertices=[[0,1],[1,0]])
p3=Polyhedron(vertices=[[0,1,1],[1,0,0]])
p2_plot = p2.plot(transparent=True)
p3_plot = p3.plot(transparent=True)
p2_plot.save(the_file2)   # saved image has transparent background
p3_plot.save(the_file3)   # saved image has white background

thanks,
Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] Re: ipython+show -> popup

2015-04-15 Thread Daniel Krenn
Am 2015-04-14 um 21:34 schrieb Volker Braun:
> Inline plots work in Sage now, you just need a sufficently new version.

In 6.6

show(x+1)

still shows the result externally, not inline.

Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] Re: AssertionError while setting assumption after creating Matplotlib figure

2015-04-14 Thread Daniel Ingraham
I forgot to attach the traceback. Added it to this post.

On Tuesday, April 14, 2015 at 11:36:22 AM UTC-4, Daniel Ingraham wrote:
>
> Hi Sage people!
>
> I've run into a strange problem with using Sage and Matplotlib: Sage 
> throws an AssertionError while making an assumption about a Sage variable, 
> but only after I create a Matplotlib figure. I've attached a short script 
> that trips the bug when I run it with the `sage` command from the terminal.
>
> My setup: up-to-date 64-bit Arch Linux with the sage-mathematics package 
> from the official Arch repositories (Sage Version 6.5, Release Date: 
> 2015-02-17).
>
> Thanks for any help you can give!
>
> Daniel
>

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


python_sage_matplotlib.stderr
Description: Binary data


[sage-support] AssertionError while setting assumption after creating Matplotlib figure

2015-04-14 Thread Daniel Ingraham
Hi Sage people!

I've run into a strange problem with using Sage and Matplotlib: Sage throws 
an AssertionError while making an assumption about a Sage variable, but 
only after I create a Matplotlib figure. I've attached a short script that 
trips the bug when I run it with the `sage` command from the terminal.

My setup: up-to-date 64-bit Arch Linux with the sage-mathematics package 
from the official Arch repositories (Sage Version 6.5, Release Date: 
2015-02-17).

Thanks for any help you can give!

Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


python_sage_matplotlib.sage
Description: Binary data


Re: [sage-support] Re: difference between SR.symbol and SR.var

2015-04-10 Thread Daniel Krenn
Am 2015-04-11 um 00:03 schrieb Volker Braun:
> Common confusion. See also: http://trac.sagemath.org/ticket/17958

Thanks.

Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] difference between SR.symbol and SR.var

2015-04-10 Thread Daniel Krenn
Am 2015-04-10 um 23:12 schrieb Michael Orlitzky:
> On 04/10/2015 05:09 PM, Daniel Krenn wrote:
>> Can someone explain me the difference between SR.symbol and SR.var ?
>>
>> (BTW: SR.symbol does not have a description)
> 
> SR.symbol is faster, but only lets you declare one variable at a time.
> SR.var will parse a string, so something like SR.var('x,y') will work,
> but it's a tiny bit slower (thanks to the parsing).

Ok. What is the reason for not having only one function with a keyword
argment preparse=False (or similar) ? (historical?)

Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] difference between SR.symbol and SR.var

2015-04-10 Thread Daniel Krenn
Can someone explain me the difference between SR.symbol and SR.var ?

(BTW: SR.symbol does not have a description)

Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] Re: problem installing spkg lie-2.2.2.p5

2015-03-05 Thread Daniel Friedan
I'll withdraw this question.  

The home page for LIE
http://wwwmathlabo.univ-poitiers.fr/~maavl/LiE/
links to a note on compiling LIE on a mac
http://wwwmathlabo.univ-poitiers.fr/~maavl/LiE/MacOSX.html
which makes it sound like too much trouble, especially in conjunction with 
the Sagemath spkg installer.

I now have the lie spkg installed on a Scientific Linux machine at work.  
I'll use it there.

thanks,
Daniel

Daniel Friedan

On Wednesday, March 4, 2015 at 12:15:54 AM UTC, Daniel Friedan wrote:
>
> 'sudo ./sage -i lie' gives me an error message (copied below).  I'd 
> appreciate advice.
>
> Sage 6.4.1
> Mac OS X 10.6.8
>
> daniel@df$ bison --version
> bison (GNU Bison) 2.3
>
> I notice the installer says
> Host system:
> Darwin df 10.8.0 Darwin Kernel Version 10.8.0: Tue Jun  7 16:33:36 PDT 
> 2011; root:xnu-1504.15.3~1/RELEASE_I386 i386
>
> This is the .app version of Sage 6.4.1 advertised for OS X 10.7, which has 
> worked fine for me under 10.6.8 until now.
>
> If this looks to be related to my antiquated  OS X 10.6.8, then never 
> mind.  We'll try installing lie-2.2.2.p5 on our symbolic math server at my 
> university (under Scientific Linux).
>
> thanks,
> Daniel
>
> Daniel Friedan
>
>
>
> daniel@df$ sudo ./sage -i lie
> Password:
> Found package lie in 
> /Applications/Sage-6.4.1.app/Contents/Resources/sage/upstream/lie-2.2.2.p5.spkg
> lie-2.2.2.p5
> ====
> Extracting package 
> /Applications/Sage-6.4.1.app/Contents/Resources/sage/upstream/lie-2.2.2.p5.spkg
> -rw-r--r--  1 daniel  admin  328820 Mar  3 23:51 
> /Applications/Sage-6.4.1.app/Contents/Resources/sage/upstream/lie-2.2.2.p5.spkg
> Finished extraction
> 
> Host system:
> Darwin df 10.8.0 Darwin Kernel Version 10.8.0: Tue Jun  7 16:33:36 PDT 
> 2011; root:xnu-1504.15.3~1/RELEASE_I386 i386
> 
> C compiler: gcc
> C compiler version:
> dyld: lazy symbol binding failed: Symbol not found: _strndup
>   Referenced from: 
> /Applications/Sage-6.4.1.app/Contents/Resources/sage/local/libexec/ccache/gcc
>   Expected in: /usr/lib/libSystem.B.dylib
>
> dyld: Symbol not found: _strndup
>   Referenced from: 
> /Applications/Sage-6.4.1.app/Contents/Resources/sage/local/libexec/ccache/gcc
>   Expected in: /usr/lib/libSystem.B.dylib
>
> /Applications/Sage-6.4.1.app/Contents/Resources/sage/src/bin/sage-spkg: 
> line 662: 34912 Trace/BPT trap  $CC -v
> 
> dyld: lazy symbol binding failed: Symbol not found: _strndup
>   Referenced from: 
> /Applications/Sage-6.4.1.app/Contents/Resources/sage/local/bin/patch
>   Expected in: /usr/lib/libSystem.B.dylib
>
> dyld: Symbol not found: _strndup
>   Referenced from: 
> /Applications/Sage-6.4.1.app/Contents/Resources/sage/local/bin/patch
>   Expected in: /usr/lib/libSystem.B.dylib
>
> ./spkg-install: line 14: 34916 Trace/BPT trap  patch -p1 < 
> ../patches/00-string.h.patch
> Error patching LiE.
>
> real0m0.022s
> user0m0.002s
> sys0m0.008s
> 
> Error installing package lie-2.2.2.p5
> 
> Please email sage-devel (http://groups.google.com/group/sage-devel)
> explaining the problem and including the relevant part of the log file
>   
> /Applications/Sage-6.4.1.app/Contents/Resources/sage/logs/pkgs/lie-2.2.2.p5.log
> Describe your computer, operating system, etc.
> If you want to try to fix the problem yourself, *don't* just cd to
> /Applications/Sage-6.4.1.app/Contents/Resources/sage/local/var/tmp/sage/build/lie-2.2.2.p5
>  
> and type 'make' or whatever is appropriate.
> Instead, the following commands setup all environment variables
> correctly and load a subshell for you to debug the error:
>   (cd 
> '/Applications/Sage-6.4.1.app/Contents/Resources/sage/local/var/tmp/sage/build/lie-2.2.2.p5'
>  
> && '/Applications/Sage-6.4.1.app/Contents/Resources/sage/sage' --sh)
> When you are done debugging, you can type "exit" to leave the subshell.
> ****
> daniel@df$ which bison
> /usr/bin/bison
> daniel@df$ bison --version
> bison (GNU Bison) 2.3
> Written by Robert Corbett and Richard Stallman.
>
> Copyright (C) 2006 Free Software Foundation, Inc.
> This is free software; see the source for copying conditions.  There is NO
> warranty; not even for MERCHANTABILITY or FITNESS FOR A PART

[sage-support] Re: problem installing spkg lie-2.2.2.p5

2015-03-04 Thread Daniel Friedan
> First of all you should not use sudo to do that. 

I was following advice given in a previous thread about installing spkg 
lie-2.2.2

https://groups.google.com/forum/?fromgroups#!searchin/sage-support/lie-2.2.2/sage-support/8zPUkmFOcqA/jaG1Yu9SSwkJ

> Then, how did you install Sage on your computer? Did you compile Sage 
from source? 

I downloaded  a binary version of Sage, downloaded from 
> This is the .app version of Sage 6.4.1 advertised for OS X 10.7, which 
has worked fine for me under 10.6.8 until now.

thanks,
Daniel



-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] problem installing spkg lie-2.2.2.p5

2015-03-03 Thread Daniel Friedan
'sudo ./sage -i lie' gives me an error message (copied below).  I'd 
appreciate advice.

Sage 6.4.1
Mac OS X 10.6.8

daniel@df$ bison --version
bison (GNU Bison) 2.3

I notice the installer says
Host system:
Darwin df 10.8.0 Darwin Kernel Version 10.8.0: Tue Jun  7 16:33:36 PDT 
2011; root:xnu-1504.15.3~1/RELEASE_I386 i386

This is the .app version of Sage 6.4.1 advertised for OS X 10.7, which has 
worked fine for me under 10.6.8 until now.

If this looks to be related to my antiquated  OS X 10.6.8, then never 
mind.  We'll try installing lie-2.2.2.p5 on our symbolic math server at my 
university (under Scientific Linux).

thanks,
Daniel

Daniel Friedan



daniel@df$ sudo ./sage -i lie
Password:
Found package lie in 
/Applications/Sage-6.4.1.app/Contents/Resources/sage/upstream/lie-2.2.2.p5.spkg
lie-2.2.2.p5

Extracting package 
/Applications/Sage-6.4.1.app/Contents/Resources/sage/upstream/lie-2.2.2.p5.spkg
-rw-r--r--  1 daniel  admin  328820 Mar  3 23:51 
/Applications/Sage-6.4.1.app/Contents/Resources/sage/upstream/lie-2.2.2.p5.spkg
Finished extraction

Host system:
Darwin df 10.8.0 Darwin Kernel Version 10.8.0: Tue Jun  7 16:33:36 PDT 
2011; root:xnu-1504.15.3~1/RELEASE_I386 i386

C compiler: gcc
C compiler version:
dyld: lazy symbol binding failed: Symbol not found: _strndup
  Referenced from: 
/Applications/Sage-6.4.1.app/Contents/Resources/sage/local/libexec/ccache/gcc
  Expected in: /usr/lib/libSystem.B.dylib

dyld: Symbol not found: _strndup
  Referenced from: 
/Applications/Sage-6.4.1.app/Contents/Resources/sage/local/libexec/ccache/gcc
  Expected in: /usr/lib/libSystem.B.dylib

/Applications/Sage-6.4.1.app/Contents/Resources/sage/src/bin/sage-spkg: 
line 662: 34912 Trace/BPT trap  $CC -v

dyld: lazy symbol binding failed: Symbol not found: _strndup
  Referenced from: 
/Applications/Sage-6.4.1.app/Contents/Resources/sage/local/bin/patch
  Expected in: /usr/lib/libSystem.B.dylib

dyld: Symbol not found: _strndup
  Referenced from: 
/Applications/Sage-6.4.1.app/Contents/Resources/sage/local/bin/patch
  Expected in: /usr/lib/libSystem.B.dylib

./spkg-install: line 14: 34916 Trace/BPT trap  patch -p1 < 
../patches/00-string.h.patch
Error patching LiE.

real0m0.022s
user0m0.002s
sys0m0.008s

Error installing package lie-2.2.2.p5

Please email sage-devel (http://groups.google.com/group/sage-devel)
explaining the problem and including the relevant part of the log file
  
/Applications/Sage-6.4.1.app/Contents/Resources/sage/logs/pkgs/lie-2.2.2.p5.log
Describe your computer, operating system, etc.
If you want to try to fix the problem yourself, *don't* just cd to
/Applications/Sage-6.4.1.app/Contents/Resources/sage/local/var/tmp/sage/build/lie-2.2.2.p5
 
and type 'make' or whatever is appropriate.
Instead, the following commands setup all environment variables
correctly and load a subshell for you to debug the error:
  (cd 
'/Applications/Sage-6.4.1.app/Contents/Resources/sage/local/var/tmp/sage/build/lie-2.2.2.p5'
 
&& '/Applications/Sage-6.4.1.app/Contents/Resources/sage/sage' --sh)
When you are done debugging, you can type "exit" to leave the subshell.
********
daniel@df$ which bison
/usr/bin/bison
daniel@df$ bison --version
bison (GNU Bison) 2.3
Written by Robert Corbett and Richard Stallman.

Copyright (C) 2006 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
daniel@df$ 

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] Re: running a notebook server & pyopenssl

2015-02-22 Thread Daniel Krenn
Am 2015-02-22 um 19:31 schrieb Volker Braun:
> I think thats fixed in pyopenssl-0.14. I opened a ticket
> at http://trac.sagemath.org/ticket/17831

> Easiest solution is probably pip install pyopenssl

Seems to work now.

Thanks.

Daniel

> 
> On Saturday, February 21, 2015 at 12:47:31 PM UTC+1, John Cremona wrote:
> 
> Has something changed between 6.4 and 6.5 regarding running a notebook
> server (default, not ipython) with secure=True?  I repeatedly get the
> message
> 
> RuntimeError: HTTPS cannot be used without pyOpenSSL installed. See
> the Sage README for more information.
> sage@fermat:~$ cat start_sage_server
> /usr/local/bin/sage --notebook default interface='' accounts=True
> secure=True automatic_login=False
> despite having explicitly installed pyopenssl (using ./sage -i
> pyopenssl after building finished) followed by ./sage -g python and
> then make (which rebuilt a whole lot of things previously built by
> make).
> 
> I am building from source on ubuntu 14.04 using a git repository which
> is updated on each release.
> 
> I have even done a "makedistclean" to start from scratch and releated
> all the above, but the command line
> 
> /usr/local/bin/sage --notebook default interface='' accounts=True
> secure=True automatic_login=False
> 
> still gives the quoted error.
> 
> John Cremona
> 
> PS yes, I know that I can tell all the users of the machine to switch
> to the cloud, as most of them have.  that is not really the point.
> 
> -- 
> 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
> <mailto:sage-support+unsubscr...@googlegroups.com>.
> To post to this group, send email to sage-support@googlegroups.com
> <mailto:sage-support@googlegroups.com>.
> Visit this group at http://groups.google.com/group/sage-support.
> For more options, visit https://groups.google.com/d/optout.

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] running a notebook server & pyopenssl

2015-02-21 Thread Daniel Krenn
Related to the following?

https://groups.google.com/d/msg/sage-devel/JQlb4bbBXjQ/ck-0QVQUepUJ


Am 2015-02-21 um 12:46 schrieb John Cremona:
> Has something changed between 6.4 and 6.5 regarding running a notebook
> server (default, not ipython) with secure=True?  I repeatedly get the
> message
> 
> RuntimeError: HTTPS cannot be used without pyOpenSSL installed. See
> the Sage README for more information.
> sage@fermat:~$ cat start_sage_server
> /usr/local/bin/sage --notebook default interface='' accounts=True
> secure=True automatic_login=False
> despite having explicitly installed pyopenssl (using ./sage -i
> pyopenssl after building finished) followed by ./sage -g python and
> then make (which rebuilt a whole lot of things previously built by
> make).
> 
> I am building from source on ubuntu 14.04 using a git repository which
> is updated on each release.
> 
> I have even done a "makedistclean" to start from scratch and releated
> all the above, but the command line
> 
> /usr/local/bin/sage --notebook default interface='' accounts=True
> secure=True automatic_login=False
> 
> still gives the quoted error.
> 
> John Cremona
> 
> PS yes, I know that I can tell all the users of the machine to switch
> to the cloud, as most of them have.  that is not really the point.
> 

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] Secure connection fails using Firefox 33

2014-10-27 Thread Daniel Krenn
Am 2014-10-27 um 19:08 schrieb mjs:
> With the recent release of Firefox 33 (now shipped to Fedora, coming
> soon to an OS near you), I can no longer connect to my Sage 6.3 server. 
> The error I get is:
> 
> An error occurred during a connection to sage.math.clemson.edu:34567.
> The key does not support the requested operation. (Error code:
> sec_error_invalid_key)
> 
> The page you are trying to view cannot be shown because the
> authenticity of the received data could not be verified.
> Please contact the website owners to inform them of this problem.
> 
> This is apparently due to Firefox removing support for SSL other than
> that provided by libPKIX. There seem to be a few different possible
> issues with the key that is generated when Sage is built that might
> cause this, e.g., key not long enough (Firefox now requires keys to be
> 1024 bits or more).  Has anyone else seen this?  

Yes, I have the same problem.

Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] best cpu for Sage server?

2014-09-18 Thread Daniel Friedan
Could anybody offer specific advice on what cpu to buy for a symbolic math 
server?  It will run Sage, Mathematica, and python code.  We'll be using it 
to do theoretical physics.

Our current machine is about 4 years old.  It cost about $4K at the time.  
Its specs are:
 1U server
 two quad-core processors at 2.66GHz (Intel Core2 Quad Q9400 ?) 
  for a total of 8 CPU's 
 64GB of memory 
 a 1-terabyte hard disk 
 running 64-bit Scientific Linux. 

We can get advice from colleagues who do numerical work for high energy 
experimental physics and condensed matter physics, but nobody else in our 
department does large-scale symbolic math.

thanks,
Daniel Friedan

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] Cannot plot in both notebook and terminal mode

2014-09-09 Thread Daniel Krenn
Am 2014-09-09 um 05:03 schrieb Miguel Yorro:
> Hi! I'm using Craig Finch Sage Beginner's Guide to learn to use Sage.
> However, when I ran the following code (both in the notebook and
> terminal mode)
> 
> |
> sage:var('x')
> x
> sage:sinc(x)=sin(x)/x
> sage:plot(sinc,(x,-10,10))

Try one of the following:

sage: var('x')
x
sage: sinc(x) = sin(x)/x

sage: sinc
x |--> sin(x)/x
sage: sinc(x)
sin(x)/x

sage: plot(sinc, (-10, 10))

sage: plot(sinc(x), (x, -10, 10))

Both work for me. "sinc" is a function, so if you use it directly as you
did, you don't have to specify a variable in plot. If you want to do
this, use "sinc(x)", which is a symbolic expression.

Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] Re: volunteering to produce Mac OS X 10.6 .app versions

2014-09-02 Thread Daniel Friedan
I've now opened a trac ticket:
#16919 <http://trac.sagemath.org/ticket/16919> new 
<http://trac.sagemath.org/query?status=new>  defect 
<http://trac.sagemath.org/query?status=%21closed&type=defect>  mistake in 
sage/src/bin/sage-bdist, OSX app is always built 32-bit 
Daniel

On Monday, September 1, 2014 1:24:20 PM UTC, Volker Braun wrote:
>
> Did you open a trac ticket to fix the sage-bdist script?
>
>
> On Monday, September 1, 2014 2:17:57 PM UTC+1, Daniel Friedan wrote:
>>
>> I believe I've now succeeded in building a Mac OS X 10.6 .app version 
>> of Sage 6.3 (with help recorded in a separate thread).
>>
>> I had to fix a mistake in the file src/bin/sage-bdist (a mistake
>> that affects the official OS X .app builds), and I also had to
>> make a few other changes to that file.  (Details at the end of
>> this posting.)
>>
>> I'd be happy to upload
>>   sage-6.3-x86_64-Darwin-app.dmg
>> if somebody will tell me how to do it.
>>
>> I'd also be happy to volunteer to produce future Mac OS X 10.6 
>> .app versions.
>>
>> I'm a bit unsure that I've done enough to validate the build:
>> (1) 'make' finishes with no error message at the end
>> (2) './sage -bdist' finishes with "** BUILD SUCCEEDED **"
>> (3) the 'file' commands
>>   $ file Sage-6.3.app/Contents/MacOS/Sage
>>   $ file Sage-6.3.app/Contents/Resources/sage/local/bin/*
>>   $ file Sage-6.3.app/Contents/Resources/sage/local/lib/*
>> show all architectures are 64-bit.
>> (4) Sage-6.3.app runs under OS X 10.6.8
>> (5) a sample workbook executes properly
>>
>> Is there more that one should do to validate the build?
>>
>> Is there any way to tell from inside Sage that it is running in 
>> 64-bit mode?
>>
>> The output from '$ ./sage -bdist' showed some strange looking command 
>> line options:
>>   -mmacosx-version-min=10.4
>> and
>>setenv MACOSX_DEPLOYMENT_TARGET 10.4
>> and gave a warning:
>> :0: warning: Mac OS X version 10.5 or later is needed for 
>> use of the new objc abi
>>
>> Why do these command line options refer to '10.4'?
>>
>> ==
>> Procedure for building a Mac OS X 10.6 .app version of Sage 6.3
>>
>> (1) The file src/bin/sage-bdist contains a mistake:
>>'ARCHES' should be 'ARCHS'.
>> The effect of the mistake is that the OS X application is 
>> always built as 32-bit ('i386').  This can be seen by running 
>> $ file Sage-6.3.app/Contents/MacOS/Sage
>> in the OS X 10.9 .app version currently being distributed 
>> officially.
>>
>> (2) sage-bdist uses `uname -m` to determine the target 
>> architecture.  Some of the older 64-bit Macintoshes can only boot into 
>> a 32-bit system.  These machines run 64-bit Sage perfectly well.  
>> They can make and build 64-bit Sage perfectly well.  The problem is that 
>> `uname -m` returns 'i386'.  I added an environment variable to 
>> override `uname -m` (SAGE_APP_TARGET_ARCH==x86_64).
>>
>> I also added some code to sage-bdist to append '-app' to the name 
>> of the .dmg file produced.
>>
>> I also added an environment variable (SAGE_APP_GZ=no) to prevent 
>> the final compression stage, to save time during debugging 
>> sage-bdist.
>>
>> The procedure that worked for making and building the Mac OS X 10.6 .app 
>> version of Sage 6.3 was:
>>
>> $ git clone git://github.com/sagemath/sage.git
>> $ cd sage
>> $ export MAKE="make -j2"
>> $ $MAKE
>> $ cp ../sage-bdist-TARGET_ARCH-app src/bin/sage-bdist
>> $ git remote add trac git://trac.sagemath.org/sage.git -t master
>> $ git fetch trac u/iandrus/trac-16796
>> $ git checkout FETCH_HEAD
>> $ export SAGE_APP_TARGET_ARCH=x86_64
>> $ export SAGE_APP_DMG=yes
>> $ export SAGE_APP_BUNDLE=yes
>> $ ./sage -bdist
>>
>> It produced a somewhat smaller version of Sage 6.3 than the 
>> officially distributed OS X 10.6 version.  It looks like the size 
>> difference is due to git stuff.  Starting with a fresh clone 
>> seems worthwhile (cloning is a small fraction of the 'make' time.)
>>
>> Daniel
>>
>>

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] Re: volunteering to produce Mac OS X 10.6 .app versions

2014-09-01 Thread Daniel Friedan
No, I don't have a trac account.  I'm not sure I have the time to satisfy 
the requirement "Make sure you understand the review process, and the 
procedures for opening and closing tickets."  I'm already a bit exhausted 
from debugging the OSX 10.6 build process. 

Daniel

On Monday, September 1, 2014 1:24:20 PM UTC, Volker Braun wrote:
>
> Did you open a trac ticket to fix the sage-bdist script?
>
>
> On Monday, September 1, 2014 2:17:57 PM UTC+1, Daniel Friedan wrote:
>>
>> I believe I've now succeeded in building a Mac OS X 10.6 .app version 
>> of Sage 6.3 (with help recorded in a separate thread).
>>
>> I had to fix a mistake in the file src/bin/sage-bdist (a mistake
>> that affects the official OS X .app builds), and I also had to
>> make a few other changes to that file.  (Details at the end of
>> this posting.)
>>
>> I'd be happy to upload
>>   sage-6.3-x86_64-Darwin-app.dmg
>> if somebody will tell me how to do it.
>>
>> I'd also be happy to volunteer to produce future Mac OS X 10.6 
>> .app versions.
>>
>> I'm a bit unsure that I've done enough to validate the build:
>> (1) 'make' finishes with no error message at the end
>> (2) './sage -bdist' finishes with "** BUILD SUCCEEDED **"
>> (3) the 'file' commands
>>   $ file Sage-6.3.app/Contents/MacOS/Sage
>>   $ file Sage-6.3.app/Contents/Resources/sage/local/bin/*
>>   $ file Sage-6.3.app/Contents/Resources/sage/local/lib/*
>> show all architectures are 64-bit.
>> (4) Sage-6.3.app runs under OS X 10.6.8
>> (5) a sample workbook executes properly
>>
>> Is there more that one should do to validate the build?
>>
>> Is there any way to tell from inside Sage that it is running in 
>> 64-bit mode?
>>
>> The output from '$ ./sage -bdist' showed some strange looking command 
>> line options:
>>   -mmacosx-version-min=10.4
>> and
>>setenv MACOSX_DEPLOYMENT_TARGET 10.4
>> and gave a warning:
>> :0: warning: Mac OS X version 10.5 or later is needed for 
>> use of the new objc abi
>>
>> Why do these command line options refer to '10.4'?
>>
>> ==
>> Procedure for building a Mac OS X 10.6 .app version of Sage 6.3
>>
>> (1) The file src/bin/sage-bdist contains a mistake:
>>'ARCHES' should be 'ARCHS'.
>> The effect of the mistake is that the OS X application is 
>> always built as 32-bit ('i386').  This can be seen by running 
>> $ file Sage-6.3.app/Contents/MacOS/Sage
>> in the OS X 10.9 .app version currently being distributed 
>> officially.
>>
>> (2) sage-bdist uses `uname -m` to determine the target 
>> architecture.  Some of the older 64-bit Macintoshes can only boot into 
>> a 32-bit system.  These machines run 64-bit Sage perfectly well.  
>> They can make and build 64-bit Sage perfectly well.  The problem is that 
>> `uname -m` returns 'i386'.  I added an environment variable to 
>> override `uname -m` (SAGE_APP_TARGET_ARCH==x86_64).
>>
>> I also added some code to sage-bdist to append '-app' to the name 
>> of the .dmg file produced.
>>
>> I also added an environment variable (SAGE_APP_GZ=no) to prevent 
>> the final compression stage, to save time during debugging 
>> sage-bdist.
>>
>> The procedure that worked for making and building the Mac OS X 10.6 .app 
>> version of Sage 6.3 was:
>>
>> $ git clone git://github.com/sagemath/sage.git
>> $ cd sage
>> $ export MAKE="make -j2"
>> $ $MAKE
>> $ cp ../sage-bdist-TARGET_ARCH-app src/bin/sage-bdist
>> $ git remote add trac git://trac.sagemath.org/sage.git -t master
>> $ git fetch trac u/iandrus/trac-16796
>> $ git checkout FETCH_HEAD
>> $ export SAGE_APP_TARGET_ARCH=x86_64
>> $ export SAGE_APP_DMG=yes
>> $ export SAGE_APP_BUNDLE=yes
>> $ ./sage -bdist
>>
>> It produced a somewhat smaller version of Sage 6.3 than the 
>> officially distributed OS X 10.6 version.  It looks like the size 
>> difference is due to git stuff.  Starting with a fresh clone 
>> seems worthwhile (cloning is a small fraction of the 'make' time.)
>>
>> Daniel
>>
>>

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] volunteering to produce Mac OS X 10.6 .app versions

2014-09-01 Thread Daniel Friedan
I believe I've now succeeded in building a Mac OS X 10.6 .app version 
of Sage 6.3 (with help recorded in a separate thread).

I had to fix a mistake in the file src/bin/sage-bdist (a mistake
that affects the official OS X .app builds), and I also had to
make a few other changes to that file.  (Details at the end of
this posting.)

I'd be happy to upload
  sage-6.3-x86_64-Darwin-app.dmg
if somebody will tell me how to do it.

I'd also be happy to volunteer to produce future Mac OS X 10.6 
.app versions.

I'm a bit unsure that I've done enough to validate the build:
(1) 'make' finishes with no error message at the end
(2) './sage -bdist' finishes with "** BUILD SUCCEEDED **"
(3) the 'file' commands
  $ file Sage-6.3.app/Contents/MacOS/Sage
  $ file Sage-6.3.app/Contents/Resources/sage/local/bin/*
  $ file Sage-6.3.app/Contents/Resources/sage/local/lib/*
show all architectures are 64-bit.
(4) Sage-6.3.app runs under OS X 10.6.8
(5) a sample workbook executes properly

Is there more that one should do to validate the build?

Is there any way to tell from inside Sage that it is running in 
64-bit mode?

The output from '$ ./sage -bdist' showed some strange looking command line 
options:
  -mmacosx-version-min=10.4
and
   setenv MACOSX_DEPLOYMENT_TARGET 10.4
and gave a warning:
:0: warning: Mac OS X version 10.5 or later is needed for use 
of the new objc abi

Why do these command line options refer to '10.4'?

==
Procedure for building a Mac OS X 10.6 .app version of Sage 6.3

(1) The file src/bin/sage-bdist contains a mistake:
   'ARCHES' should be 'ARCHS'.
The effect of the mistake is that the OS X application is 
always built as 32-bit ('i386').  This can be seen by running 
$ file Sage-6.3.app/Contents/MacOS/Sage
in the OS X 10.9 .app version currently being distributed 
officially.

(2) sage-bdist uses `uname -m` to determine the target 
architecture.  Some of the older 64-bit Macintoshes can only boot into 
a 32-bit system.  These machines run 64-bit Sage perfectly well.  
They can make and build 64-bit Sage perfectly well.  The problem is that 
`uname -m` returns 'i386'.  I added an environment variable to 
override `uname -m` (SAGE_APP_TARGET_ARCH==x86_64).

I also added some code to sage-bdist to append '-app' to the name 
of the .dmg file produced.

I also added an environment variable (SAGE_APP_GZ=no) to prevent 
the final compression stage, to save time during debugging 
sage-bdist.

The procedure that worked for making and building the Mac OS X 10.6 .app 
version of Sage 6.3 was:

$ git clone git://github.com/sagemath/sage.git
$ cd sage
$ export MAKE="make -j2"
$ $MAKE
$ cp ../sage-bdist-TARGET_ARCH-app src/bin/sage-bdist
$ git remote add trac git://trac.sagemath.org/sage.git -t master
$ git fetch trac u/iandrus/trac-16796
$ git checkout FETCH_HEAD
$ export SAGE_APP_TARGET_ARCH=x86_64
$ export SAGE_APP_DMG=yes
$ export SAGE_APP_BUNDLE=yes
$ ./sage -bdist

It produced a somewhat smaller version of Sage 6.3 than the 
officially distributed OS X 10.6 version.  It looks like the size 
difference is due to git stuff.  Starting with a fresh clone 
seems worthwhile (cloning is a small fraction of the 'make' time.)

Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] error in sage-bdist (for building OS X .app Sage)

2014-09-01 Thread Daniel Friedan
The file src/bin/sage-bdist contains a mistake:
   'ARCHES' should be 'ARCHS'.

The effect of the mistake is that the OS X application is always
built as 32-bit ('i386').  

This can be seen in the OS X 10.9 .app version
currently being distributed officially, by running
$ file Sage-6.3.app/Contents/MacOS/Sage

Everything in sage/local/{bin,lib} is 64-bit, so the mistake 
probably has no significant effect on the running of sage code.

Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] backward substitution during solving polynomial equation

2014-08-31 Thread Daniel Krenn
Am 2014-08-29 um 21:25 schrieb Daniel Krenn:
> I want to solve polynomial equations and in order to do so, I do
> something like:
> 
> sage: R. = PolynomialRing(QQ, order='lex')
> sage: I = R.ideal([x*y-1, x^2-y^2])
> sage: I.groebner_basis()
> [x - y^3, y^4 - 1]

Meanwhile, I found, which seems to do what I want:

sage: I.variety()
[{y: -1, x: -1}, {y: 1, x: 1}]
sage: I.variety(ring=QQbar)
[{y: -1, x: -1}, {y: -1*I, x: 1*I}, {y: 1*I, x: -1*I}, {y: 1, x: 1}]
sage: I.variety(ring=ZZ)
[{y: -1, x: -1}, {y: 1, x: 1}]

Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] backward substitution during solving polynomial equation

2014-08-29 Thread Daniel Krenn
I want to solve polynomial equations and in order to do so, I do
something like:

sage: R. = PolynomialRing(QQ, order='lex')
sage: I = R.ideal([x*y-1, x^2-y^2])
sage: I.groebner_basis()
[x - y^3, y^4 - 1]

Now I have to take the equation with only one variable, find the
solutions for it (over so QQ or so) and use each of the possible
solitions in the equation with the two variables and solve again and so on.

What is the Sage command to do this operation, i.e., backwards
substituting to find a solution?

("solve" seems to be very much an overkill and it is not that
transparent in what it does...)

Daniel

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] Re: sage-6.3-x86_64-Darwin-OSX_10.6_x86_64-app.dmg won't be built?

2014-08-28 Thread Daniel Friedan
(1) The file system is fine.  Despite the name, '/NOT_ON_SSD/' is just a 
subdirectory of '/' on the imac's internal disk, which is an SSD with a 
Journaled HFS+ file system with 140GB free.  
$ mount
/dev/disk0s2 on / (hfs, local, journaled, noatime)

(2) '$ ./sage -f polybori' succeeded:

Done installing PolyBoRi.

real2m12.677s
user1m59.620s
sys0m11.988s
Successfully installed polybori-0.8.3
Deleting temporary build directory
/NOT_ON_SSD/Software/sage_build/build2/sage/local/var/tmp/sage/build/polybori-0.8.3
Finished installing polybori-0.8.3.spkg

Warning: it might be needed to update the Sage library before
installed packages work: you should run 'make' from $SAGE_ROOT
before running Sage.

(3) I then tried (without running 'make distclean'):
$ export SAGE64=yes
$ export MAKE="make -j2"
$ $MAKE

and got the same error:
Error building Sage.
The following package(s) may have failed to build:
package: polybori-0.8.3

(4) I'm now trying 'make' again from scratch.  It will take 4-6 hours, 
depending on whether the error recurs.

Daniel

On Thursday, August 28, 2014 8:42:44 AM UTC, Dima Pasechnik wrote:
>
> On 2014-08-27, Daniel Friedan > wrote: 
> > --=_Part_4855_138320293.1409165879953 
> > Content-Type: multipart/alternative; 
> > boundary="=_Part_4856_1171858397.1409165879953" 
> > 
> > --=_Part_4856_1171858397.1409165879953 
> > Content-Type: text/plain; charset=UTF-8 
> > 
> > All the executables/libraries are 64bit.  (per output from $ file 
> > sage/local/lib/*; file sage/local/bin/*) 
> > 
> > Attached is the log for the package that failed: polybori-0.8.3.log 
>
> weird, it ends up with an error in creating a manpage...: 
>
> scons: *** 
> [/NOT_ON_SSD/Software/sage_build/build2/sage/local/man/man1/PolyGUI2.1] 
> Source 
> `/NOT_ON_SSD/Software/sage_build/build2/sage/local/man/man1/PolyGUI.1' not 
> found, needed by target 
> `/NOT_ON_SSD/Software/sage_build/build2/sage/local/man/man1/PolyGUI2.1'. 
> scons: building terminated because of errors. 
> Error installing PolyBoRi. 
>
> What kind of a filesystem do you have mounted on /NOT_ON_SSD/ ? 
>
> Could you post the output of 
>
> $ mount 
>
>
> A wild guess might be that if it's some kind of vfat thing, then it might 
> misbehave when 
> you use a 64-bit tool, scons, there... 
> (or you're just running out of space on the device...) 
>
> If it's the case, you might try your build on a proper OSX filesystem 
> instead. 
>
> -- 
>
> PS. just to make sure you can reproduce it, can you run 
> $ ./sage -f polybori 
>
> in the directory you build Sage in, and see if you end up with the same 
> error? 
>
>
>

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] Re: sage-6.3-x86_64-Darwin-OSX_10.6_x86_64-app.dmg won't be built?

2014-08-27 Thread Daniel Friedan
All the executables/libraries are 64bit.  (per output from $ file 
sage/local/lib/*; file sage/local/bin/*)

Attached is the log for the package that failed: polybori-0.8.3.log

Daniel


On Wednesday, August 27, 2014 6:17:23 PM UTC, Dima Pasechnik wrote:
>
> On 2014-08-27, Daniel Friedan > wrote: 
> > --=_Part_3092_594188982.1409156737747 
> > Content-Type: text/plain; charset=UTF-8 
> > 
> > Still trying to build 64bit Sage 6.3 on an OS X 10.6.8 Core 2 Duo 
> machine. 
> > 
> > Dima's suggestion '$ export SAGE64=yes ' did not work.   
>
> did it have any effect on the type of executables/libraries that did build 
> OK? 
> (you can use 'file' in SAGE_LOCAL/lib and SAGE_LOCAL/bin to find out...) 
>
> if yes, please post the log related to the package (from 
> SAGE_ROOT/logs/pkgs/) 
>
> > 
> > 'make' failed -- one package failed to build (error message copied 
> below).   
> > 
> > Note that 'make'  previously succeeded without '$ export SAGE64=yes ' . 
> > 
> > '$ ./sage -bdist' succeeded, but produced a 32 bit Sage-6.3.app  which 
> was 
> > only 1.1G large (compared to 3.5G for the usual Sage-6.3.app). 
>
> probably something incomplete and not working. 
>
>
>

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


polybori-0.8.3.log
Description: Binary data


[sage-support] Re: sage-6.3-x86_64-Darwin-OSX_10.6_x86_64-app.dmg won't be built?

2014-08-27 Thread Daniel Friedan
Still trying to build 64bit Sage 6.3 on an OS X 10.6.8 Core 2 Duo machine.

Dima's suggestion '$ export SAGE64=yes ' did not work.  

'make' failed -- one package failed to build (error message copied below).  

Note that 'make'  previously succeeded without '$ export SAGE64=yes ' .

'$ ./sage -bdist' succeeded, but produced a 32 bit Sage-6.3.app  which was 
only 1.1G large (compared to 3.5G for the usual Sage-6.3.app).

=
2014-08-27 build Sage-6.3 trying for 64bit version

$ git clone git://github.com/sagemath/sage.git
$ cd sage
$ git checkout 6.3
$ export SAGE64=yes
$ export MAKE="make -j2"
$ $MAKE

[... lots of output ...]

***
Error building Sage.

The following package(s) may have failed to build:

package: polybori-0.8.3
log file: 
//NOT_ON_SSD/Software/sage_build/build2/sage/logs/pkgs/polybori-0.8.3.log
build directory: 
//NOT_ON_SSD/Software/sage_build/build2/sage/local/var/tmp/sage/build/polybori-0.8.3

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: *** [build] Error 1

$ git checkout 6.3

$ git remote add trac git://trac.sagemath.org/sage.git -t master
$ git fetch trac u/iandrus/trac-16796
$ git checkout FETCH_HEAD

$ export SAGE_APP_DMG=yes
$ export SAGE_APP_BUNDLE=yes
$ ./sage -bdist

[Build succeeded but produced 32 bit app version, size only 1.1G]
=
thanks,
Daniel Friedan

On Tuesday, August 26, 2014 8:19:22 PM UTC, Dima Pasechnik wrote:
>
> On 2014-08-26, Daniel Friedan > wrote: 
> > --=_Part_4367_1566256233.1409080390865 
> > Content-Type: text/plain; charset=UTF-8 
> > 
> > I've been able to run the 64 bit version of Sage 6.2 onn my Core 2 Duo 
> OS X 
> > 10.6 macbookpro with no trouble.   
> > This is the version I downloaded as 
> > *sage-6.2-x86_64-Darwin-OSX_10.6_x86_64-app.dmg* 
> ><
> http://boxen.math.washington.edu/home/sagemath/sage-mirror/osx/intel/sage-6.2-x86_64-Darwin-OSX_10.6_x86_64-app.dmg>
>  
>
> > 
> > The problem seems to be with *building* a 64 bit version. 
> > Is it impossible to build a 64bit version of Sage on this machine? 
>
> Perhaps you just have to 
>
> $ export SAGE64=yes 
>
> before starting make. 
>
> cf. http://www.sagemath.org/doc/installation/source.html 
> for details. 
> (it says SAGE64=yes is only needed on OSX 10.4 and 10.5 though) 
>
>
>

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] Re: sage-6.3-x86_64-Darwin-OSX_10.6_x86_64-app.dmg won't be built?

2014-08-26 Thread Daniel Friedan
I've been able to run the 64 bit version of Sage 6.2 onn my Core 2 Duo OS X 
10.6 macbookpro with no trouble.  
This is the version I downloaded as
*sage-6.2-x86_64-Darwin-OSX_10.6_x86_64-app.dmg* 
<http://boxen.math.washington.edu/home/sagemath/sage-mirror/osx/intel/sage-6.2-x86_64-Darwin-OSX_10.6_x86_64-app.dmg>

The problem seems to be with *building* a 64 bit version.
Is it impossible to build a 64bit version of Sage on this machine?

thanks,
Daniel

On Tuesday, August 26, 2014 1:59:37 PM UTC, Dima Pasechnik wrote:
>
> On 2014-08-26, Volker Braun > wrote: 
> > --=_Part_2182_349848151.1409057890862 
> > Content-Type: text/plain; charset=UTF-8 
> > 
> > You have to manually rename the sage-6.3-i386-Darwin.dmg to include the 
> > -app and version details. 
> > 
> > It seems you built 32-bit binaries, which you can verify with "file" 
> e.g. 
> > On the old 10.6 buildbot the output defaulted to 64 bit. No idea why 
> that 
> > is or how to change the defaults for xcode commandline tools. 
>
> I presume the old buildbot had better hardware than Core2 Duo (that's what 
> the OP has in a laptop). 
> For the latter one cannot really get OSX10.6 running in 64-bit mode. 
> Apple apparently preferred users upgrading to 10.7, 
> instead of providing 64-bit support for these CPUs. 
>
> We have seen these issues few years ago, when these 
> machines hit the market. 
> As I have such a laptop (running 64-bit Debian Linux now :-)) 
> myself, I knew this all too well. 
> (But I can't recall details now; all I recall was quite a 
> few complaints that binary releases of Sage didn't work) 
>
>
>
> > 
> > 
> > 
> > On Tuesday, August 26, 2014 12:55:30 PM UTC+1, Daniel Friedan wrote: 
> >> 
> >> Dima's suggestion worked.  My OS X 10.6.8 build of Sage 6.3 succeeded, 
> >> produced a .dmg file containing an app version that ran and passed some 
> >> rudimentary tests. 
> >> 
> >> I have a few questions about the resulting build.  Modulo these 
> questions, 
> >> I could volunteer to produce OSX 10.6 builds of future Sage versions 
> (both 
> >> app and non-app).  I'd probably need some hand-holding when/if things 
> go 
> >> wrong. 
> >> 
> >> The .dmg file that was produced was named 
> >>sage-6.3-i386-Darwin.dmg 
> >> This differs from the name of the Sage 6.2 .dmg that I downloaded and 
> used 
> >> previously: 
> >>sage-6.2-x86_64-Darwin-OSX_10.6_x86_64-app.dmg 
> >> 
> >> Did I leave out some build option to get 64bit? 
> >> How can I determine if my build is 64bit? 
> >> The name of the .dmg file does not contain '-app' or 'OSX_10.6'.  Did I 
> >> leave out build options? 
> >> 
> >> Here's what I did for the build.  I am using a Core 2 Duo cpu running 
> OS X 
> >> 10.6.8. 
> >> 
> >> git clone git://github.com/sagemath/sage.git 
> >> cd sage 
> >> export MAKE="make -j2" 
> >> $MAKE 
> >> 
> >> git checkout 6.3 
> >> 
> >> git remote add trac git://trac.sagemath.org/sage.git -t master 
> >> git fetch trac u/iandrus/trac-16796 
> >> git checkout FETCH_HEAD 
> >> 
> >> export SAGE_APP_DMG=yes 
> >> export SAGE_APP_BUNDLE=yes 
> >> ./sage -bdist 
> >> 
> >> thanks, 
> >> Daniel 
> >> 
> >> On Friday, August 22, 2014 11:08:40 PM UTC, Dima Pasechnik wrote: 
> >>> 
> >>> On 2014-08-22, Daniel Friedan  wrote: 
> >>> > --=_Part_1632_1626995138.1408746138628 
> >>> > Content-Type: text/plain; charset=UTF-8 
> >>> > 
> >>> > Again, trying to build Sage 6.3 under OS X 10.6.8 (Intel Core 2 duo 
> >>> cpu). 
> >>> > 
> >>> > This time I did run 'make', but ended with "** BUILD FAILED **" 
> >>> > 
> >>> > $ git clone git://github.com/sagemath/sage.git 
> >>> > $ cd sage 
> >>> > $ export MAKE="make -j2" 
> >>> > $ $MAKE 
> >>> > ...[wait 6 hours]... 
> >>> > $ git checkout 6.3 
> >>> > $ export SAGE_APP_DMG=yes 
> >>> > $ export SAGE_APP_BUNDLE=yes 
> >>> > $ ./sage -bdist 
> >>> > 
> >>> 
> >>> 
> >>> 
> >>> Actually, 
> >>> $ git checkout 6.3 
> >>> should obviously have come before $MAKE, as 
&g

[sage-support] Re: sage-6.3-x86_64-Darwin-OSX_10.6_x86_64-app.dmg won't be built?

2014-08-26 Thread Daniel Friedan
Dima's suggestion worked.  My OS X 10.6.8 build of Sage 6.3 succeeded, 
produced a .dmg file containing an app version that ran and passed some 
rudimentary tests.

I have a few questions about the resulting build.  Modulo these questions, 
I could volunteer to produce OSX 10.6 builds of future Sage versions (both 
app and non-app).  I'd probably need some hand-holding when/if things go 
wrong.

The .dmg file that was produced was named
   sage-6.3-i386-Darwin.dmg
This differs from the name of the Sage 6.2 .dmg that I downloaded and used 
previously:
   sage-6.2-x86_64-Darwin-OSX_10.6_x86_64-app.dmg

Did I leave out some build option to get 64bit?
How can I determine if my build is 64bit?
The name of the .dmg file does not contain '-app' or 'OSX_10.6'.  Did I 
leave out build options?

Here's what I did for the build.  I am using a Core 2 Duo cpu running OS X 
10.6.8.

git clone git://github.com/sagemath/sage.git
cd sage
export MAKE="make -j2"
$MAKE

git checkout 6.3

git remote add trac git://trac.sagemath.org/sage.git -t master
git fetch trac u/iandrus/trac-16796
git checkout FETCH_HEAD

export SAGE_APP_DMG=yes
export SAGE_APP_BUNDLE=yes
./sage -bdist

thanks,
Daniel

On Friday, August 22, 2014 11:08:40 PM UTC, Dima Pasechnik wrote:
>
> On 2014-08-22, Daniel Friedan > wrote: 
> > --=_Part_1632_1626995138.1408746138628 
> > Content-Type: text/plain; charset=UTF-8 
> > 
> > Again, trying to build Sage 6.3 under OS X 10.6.8 (Intel Core 2 duo 
> cpu). 
> > 
> > This time I did run 'make', but ended with "** BUILD FAILED **" 
> > 
> > $ git clone git://github.com/sagemath/sage.git 
> > $ cd sage 
> > $ export MAKE="make -j2" 
> > $ $MAKE 
> > ...[wait 6 hours]... 
> > $ git checkout 6.3 
> > $ export SAGE_APP_DMG=yes 
> > $ export SAGE_APP_BUNDLE=yes 
> > $ ./sage -bdist 
> > 
>
>
>
> Actually, 
> $ git checkout 6.3 
> should obviously have come before $MAKE, as 
> this is the version you want to build and distribute 
> (hopefully this was OK, as 
> $ git clone git://github.com/sagemath/sage.git 
> checks out version 6.3 anyway, IMHO) 
>
>
> Anyhow, you seem to hit the bug fixed in http://trac.sagemath.org/16796 
> (this fix is not in 6.3) 
>
> You need to apply it, I suppose. 
> Have a look at the Sage developer guide for detailed instructions 
> (this is basically 3 git commands you need, as outlined below) 
>
>
>  first of all, you need to add trac git server to the list of remotes: 
>
> $ git remote add trac git://trac.sagemath.org/sage.git -t master 
>
>  then, we get the patch from trac.sagemath.org/16796 
>
> $ git fetch trac u/iandrus/trac-16796 
>
>  finally, we apply it: 
>
> $ git checkout FETCH_HEAD 
>
> now 
> ./sage -bdist 
> should succeed 
> (no need to rebuild Sage, as we only changed src/mac-app/AppController.m 
> which is not a part of Sage proper) 
>
> HTH, 
> Dima 
>
>

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] Re: sage-6.3-x86_64-Darwin-OSX_10.6_x86_64-app.dmg won't be built?

2014-08-22 Thread Daniel Friedan
Again, trying to build Sage 6.3 under OS X 10.6.8 (Intel Core 2 duo cpu).

This time I did run 'make', but ended with "** BUILD FAILED **"

$ git clone git://github.com/sagemath/sage.git
$ cd sage
$ export MAKE="make -j2"
$ $MAKE
...[wait 6 hours]...
$ git checkout 6.3
$ export SAGE_APP_DMG=yes
$ export SAGE_APP_BUNDLE=yes
$ ./sage -bdist

The tail of the output from './sage -bdist' was

CompileC 
build/Sage.build/Debug/Sage.build/Objects-normal/i386/AppController.o 
AppController.m normal i386 objective-c com.apple.compilers.llvmgcc42
cd /NOT_ON_SSD/Software/sage_build/sage/src/mac-app
setenv LANG en_US.US-ASCII
/Developer/usr/bin/llvm-gcc-4.2 -x objective-c -arch i386 
-fmessage-length=0 -pipe -std=gnu99 -Wno-trigraphs -fpascal-strings -O0 
-Wreturn-type -Wunused-variable -fasm-blocks -mmacosx-version-min=10.4 
-gdwarf-2 -fvisibility=hidden -iquote 
/NOT_ON_SSD/Software/sage_build/sage/src/mac-app/build/Sage.build/Debug/Sage.build/Sage-generated-files.hmap
 
-I/NOT_ON_SSD/Software/sage_build/sage/src/mac-app/build/Sage.build/Debug/Sage.build/Sage-own-target-headers.hmap
 
-I/NOT_ON_SSD/Software/sage_build/sage/src/mac-app/build/Sage.build/Debug/Sage.build/Sage-all-target-headers.hmap
 
-iquote 
/NOT_ON_SSD/Software/sage_build/sage/src/mac-app/build/Sage.build/Debug/Sage.build/Sage-project-headers.hmap
 
-I/NOT_ON_SSD/Software/sage_build/sage/src/mac-app/build/Debug/include 
-I/NOT_ON_SSD/Software/sage_build/sage/src/mac-app/build/Sage.build/Debug/Sage.build/DerivedSources/i386
 
-I/NOT_ON_SSD/Software/sage_build/sage/src/mac-app/build/Sage.build/Debug/Sage.build/DerivedSources
 
-F/NOT_ON_SSD/Software/sage_build/sage/src/mac-app/build/Debug -include 
/var/folders/3P/3P9Z7q3dGRexXy8O5coyfk+++TI/-Caches-/com.apple.Xcode.501/SharedPrecompiledHeaders/Sage_Prefix-gloqutariauqusgrjhneruvqyalg/Sage_Prefix.pch
 
-c /NOT_ON_SSD/Software/sage_build/sage/src/mac-app/AppController.m -o 
/NOT_ON_SSD/Software/sage_build/sage/src/mac-app/build/Sage.build/Debug/Sage.build/Objects-normal/i386/AppController.o
/NOT_ON_SSD/Software/sage_build/sage/src/mac-app/AppController.m: In 
function '-[AppController taskTerminated:]':
/NOT_ON_SSD/Software/sage_build/sage/src/mac-app/AppController.m:199: 
error: 'NSModalResponse' undeclared (first use in this function)
/NOT_ON_SSD/Software/sage_build/sage/src/mac-app/AppController.m:199: 
error: (Each undeclared identifier is reported only once
/NOT_ON_SSD/Software/sage_build/sage/src/mac-app/AppController.m:199: 
error: for each function it appears in.)
/NOT_ON_SSD/Software/sage_build/sage/src/mac-app/AppController.m:199: 
error: expected ';' before 'resp'
/NOT_ON_SSD/Software/sage_build/sage/src/mac-app/AppController.m:200: 
error: 'resp' undeclared (first use in this function)
/NOT_ON_SSD/Software/sage_build/sage/src/mac-app/AppController.m:200: 
error: 'NSModalResponseOK' undeclared (first use in this function)
/NOT_ON_SSD/Software/sage_build/sage/src/mac-app/AppController.m: In 
function '-[AppController ensureReadWrite]':
/NOT_ON_SSD/Software/sage_build/sage/src/mac-app/AppController.m:362: 
error: 'NSModalResponse' undeclared (first use in this function)
/NOT_ON_SSD/Software/sage_build/sage/src/mac-app/AppController.m:362: 
error: expected ';' before 'resp'
/NOT_ON_SSD/Software/sage_build/sage/src/mac-app/AppController.m:363: 
error: 'resp' undeclared (first use in this function)
/NOT_ON_SSD/Software/sage_build/sage/src/mac-app/AppController.m:363: 
error: 'NSModalResponseOK' undeclared (first use in this function)
/NOT_ON_SSD/Software/sage_build/sage/src/mac-app/AppController.m:366: 
error: 'NSModalResponseCancel' undeclared (first use in this function)

CompileC 
build/Sage.build/Debug/Sage.build/Objects-normal/i386/PreferencePanelController.o
 
PreferencePanelController.m normal i386 objective-c 
com.apple.compilers.llvmgcc42
cd /NOT_ON_SSD/Software/sage_build/sage/src/mac-app
setenv LANG en_US.US-ASCII
/Developer/usr/bin/llvm-gcc-4.2 -x objective-c -arch i386 
-fmessage-length=0 -pipe -std=gnu99 -Wno-trigraphs -fpascal-strings -O0 
-Wreturn-type -Wunused-variable -fasm-blocks -mmacosx-version-min=10.4 
-gdwarf-2 -fvisibility=hidden -iquote 
/NOT_ON_SSD/Software/sage_build/sage/src/mac-app/build/Sage.build/Debug/Sage.build/Sage-generated-files.hmap
 
-I/NOT_ON_SSD/Software/sage_build/sage/src/mac-app/build/Sage.build/Debug/Sage.build/Sage-own-target-headers.hmap
 
-I/NOT_ON_SSD/Software/sage_build/sage/src/mac-app/build/Sage.build/Debug/Sage.build/Sage-all-target-headers.hmap
 
-iquote 
/NOT_ON_SSD/Software/sage_build/sage/src/mac-app/build/Sage.build/Debug/Sage.build/Sage-project-headers.hmap
 
-I/NOT_ON_SSD/Software/sage_build/sage/src/mac-app/build/Debug/include 
-I/NOT_ON_SSD/Software/sage_build/sage/src/mac-app/build/Sage.build/Debug/Sage.build/DerivedSources/i386
 
-I/NOT_ON_SSD/Software/sage_build/sage/src/mac-app/build/Sage.build/Debug/Sage.build/DerivedSources
 
-F/NOT_ON_SSD/Software/sage_build/sage/src/mac-app/build/Debug -include 
/var/fold

[sage-support] Re: sage-6.3-x86_64-Darwin-OSX_10.6_x86_64-app.dmg won't be built?

2014-08-22 Thread Daniel Friedan
I already deleted the posting that Dima is replying to.  I misread the 
instructions and omit the 'make' step,

On Friday, August 22, 2014 2:24:15 PM UTC, Dima Pasechnik wrote:
>
> On 2014-08-22, Daniel Friedan > wrote: 
> > --=_Part_1227_548338737.1408715857673 
> > Content-Type: text/plain; charset=UTF-8 
> > 
> > My OS X 10.6.8 machine does have and Intel Core 2 Duo processor. 
> > 
> > Volker's recipe did not work.  Here's what it produced: 
> > 
> > I tried following Volker's instructions for building the app bundle 
> under OS X 10.6.8, but it failed. 
>
> this the an unclear error message: 
>
> > find: /Volumes/4TB-1/Sage_building/sage/local/var/lib/sage/installed: No 
> such file or directory 
>
> that is to say, "no, Sage was not installed, one didn't even try..." 
>
> He skipped 'make'. 
>
> After 
>
> $ git clone git://github.com/sagemath/sage.git 
> $ cd sage 
>
> you need to build sage 
>
> by running 'make'. To use 2 cores, do the following 
>
> $ export MAKE="make -j2" 
> $ $MAKE 
>
> (better do it overnight, as it will take a while, and you might also need 
> to disable 
> sleeping on your laptop...) 
>
>
>
>
> > 
> > OS X 10.6.8 
> > 
> > $ cd /Volumes/4TB-1 
> > $ mkdir Sage_building 
> > $ cd Sage_building/ 
> > $ git clone git://github.com/sagemath/sage.git 
> > Cloning into 'sage'... 
> > remote: Counting objects: 246211, done. 
> > remote: Compressing objects: 100% (675/675), done. 
> > remote: Total 246211 (delta 1082), reused 992 (delta 779) 
> > Receiving objects: 100% (246211/246211), 74.73 MiB | 7.38 MiB/s, done. 
> > Resolving deltas: 100% (172257/172257), done. 
> > Checking connectivity... done. 
> > Checking out files: 100% (4220/4220), done. 
> > 
> > $ cd sage 
> > $ git checkout 6.3 
> > Note: checking out '6.3'. 
> > 
> > You are in 'detached HEAD' state. You can look around, make experimental 
> > changes and commit them, and you can discard any commits you make in 
> this 
> > state without impacting any branches by performing another checkout. 
> > 
> > If you want to create a new branch to retain commits you create, you may 
> > do so (now or later) by using -b with the checkout command again. 
> Example: 
> > 
> >   git checkout -b new_branch_name 
> > 
> > HEAD is now at 00199fb... Updated Sage version to 6.3 
> > 
> > $ export SAGE_APP_DMG=yes 
> > $ export SAGE_APP_BUNDLE=yes 
> > $ ./sage -bdist 
> > find: /Volumes/4TB-1/Sage_building/sage/local/var/lib/sage/installed: No 
> such file or directory 
> > Sage version 6.3, release date 2014-08-10 
> > rm -rf config configure build/Makefile-auto.in 
> >   % Total% Received % Xferd  Average Speed   TimeTime Time 
>  Current 
> >  Dload  Upload   Total   SpentLeft 
>  Speed 
> > 100 89470  100 894700 0   105k  0 --:--:-- --:--:-- --:--:-- 
>  215k 
> > Cloning into 
> '/Volumes/4TB-1/Sage_building/sage/tmp/sage-6.3-i386-Darwin'... 
> > warning: templates not found 
> /Volumes/4TB-1/Sage_building/sage/local/share/git-core/templates 
> > done. 
> > Checking out files: 100% (4220/4220), done. 
> > Checking connectivity: 246211, done. 
> > Finished cloning Sage sources 
> > Copying files over to tmp directory 
> > tar: local: Cannot stat: No such file or directory 
> > tar: Error exit delayed from previous errors. 
> > cp: /Volumes/4TB-1/Sage_building/sage/local/bin/sage-README-osx.txt: No 
> such file or directory 
> > $ 
> > 
> > 
> > 
> > 
> > On Friday, August 22, 2014 1:47:15 PM UTC, Dima Pasechnik wrote: 
> >> 
> >> On 2014-08-22, Daniel Friedan > wrote: 
> >> > --=_Part_5_1837348027.1408711654748 
> >> > Content-Type: text/plain; charset=UTF-8 
> >> > 
> >> > I've done a couple of experiments with the latest version of Sage 
> (6.3) 
> >> > under OS X 10.6.8, using the official 10.7 and 10.6 binaries 
> available 
> >> for 
> >> > download. 
> >> 
> >> Please also pay attention to the CPU type. If you want your binary to 
> run 
> >> on all 
> >> the machines capable of running OSX 10.6.8, you might need to be more 
> >> careful than just 
> >> running Volker's recepy. 
> >> Specifically, Core2 Duo chips are pretty much screwed up under OSX 
> 10.6, 
>

[sage-support] Re: sage-6.3-x86_64-Darwin-OSX_10.6_x86_64-app.dmg won't be built?

2014-08-22 Thread Daniel Friedan
My OS X 10.6.8 machine does have and Intel Core 2 Duo processor.

Volker's recipe did not work.  Here's what it produced:

I tried following Volker's instructions for building the app bundle under OS X 
10.6.8, but it failed.

OS X 10.6.8

$ cd /Volumes/4TB-1
$ mkdir Sage_building
$ cd Sage_building/
$ git clone git://github.com/sagemath/sage.git
Cloning into 'sage'...
remote: Counting objects: 246211, done.
remote: Compressing objects: 100% (675/675), done.
remote: Total 246211 (delta 1082), reused 992 (delta 779)
Receiving objects: 100% (246211/246211), 74.73 MiB | 7.38 MiB/s, done.
Resolving deltas: 100% (172257/172257), done.
Checking connectivity... done.
Checking out files: 100% (4220/4220), done.

$ cd sage
$ git checkout 6.3
Note: checking out '6.3'.

You are in 'detached HEAD' state. You can look around, make experimental
changes and commit them, and you can discard any commits you make in this
state without impacting any branches by performing another checkout.

If you want to create a new branch to retain commits you create, you may
do so (now or later) by using -b with the checkout command again. Example:

  git checkout -b new_branch_name

HEAD is now at 00199fb... Updated Sage version to 6.3

$ export SAGE_APP_DMG=yes
$ export SAGE_APP_BUNDLE=yes
$ ./sage -bdist
find: /Volumes/4TB-1/Sage_building/sage/local/var/lib/sage/installed: No such 
file or directory
Sage version 6.3, release date 2014-08-10
rm -rf config configure build/Makefile-auto.in
  % Total% Received % Xferd  Average Speed   TimeTime Time  Current
 Dload  Upload   Total   SpentLeft  Speed
100 89470  100 894700 0   105k  0 --:--:-- --:--:-- --:--:--  215k
Cloning into '/Volumes/4TB-1/Sage_building/sage/tmp/sage-6.3-i386-Darwin'...
warning: templates not found 
/Volumes/4TB-1/Sage_building/sage/local/share/git-core/templates
done.
Checking out files: 100% (4220/4220), done.
Checking connectivity: 246211, done.
Finished cloning Sage sources
Copying files over to tmp directory
tar: local: Cannot stat: No such file or directory
tar: Error exit delayed from previous errors.
cp: /Volumes/4TB-1/Sage_building/sage/local/bin/sage-README-osx.txt: No such 
file or directory
$




On Friday, August 22, 2014 1:47:15 PM UTC, Dima Pasechnik wrote:
>
> On 2014-08-22, Daniel Friedan > wrote: 
> > --=_Part_5_1837348027.1408711654748 
> > Content-Type: text/plain; charset=UTF-8 
> > 
> > I've done a couple of experiments with the latest version of Sage (6.3) 
> > under OS X 10.6.8, using the official 10.7 and 10.6 binaries available 
> for 
> > download. 
>
> Please also pay attention to the CPU type. If you want your binary to run 
> on all 
> the machines capable of running OSX 10.6.8, you might need to be more 
> careful than just 
> running Volker's recepy. 
> Specifically, Core2 Duo chips are pretty much screwed up under OSX 10.6, 
> as their 64-bit 
> capabilities aren't really well-supported. 
>
> At least it would be important to know the CPU type you use exactly. 
>
> Just in case, 
> Dima 
>
> > 
> > (1) *sage-6.3-x86_64-Darwin-OSX_10.7_x86_64.dmg* 
> ><
> http://boxen.math.washington.edu/home/sagemath/sage-mirror/osx/intel/sage-6.3-x86_64-Darwin-OSX_10.7_x86_64.dmg>
>  
>
> > 
> > This is an app version (the file name should be changed to 
> > *sage-6.3-x86_64-Darwin-OSX_10.7_x86_64-app.dmg* 
> ><
> http://boxen.math.washington.edu/home/sagemath/sage-mirror/osx/intel/sage-6.3-x86_64-Darwin-OSX_10.7_x86_64.dmg>
>  
>
> > ). 
> > 
> > It runs on OS X 10.6.8 (though I didn't test much). 
> > 
> > It seems large, 4.53 GB. 
> > 
> > (2) *sage-6.3-x86_64-Darwin-OSX_10.6_x86_64.dmg* 
> ><
> http://boxen.math.washington.edu/home/sagemath/sage-mirror/osx/intel/sage-6.3-x86_64-Darwin-OSX_10.6_x86_64.dmg>
>  
>
> > 
> > This is the non-app version.  I turned it into an app version by the 
> > following: 
> >   1.  moved sage/ out of sage-6.2.app/Contents/Resources/ 
> >   2.  copied sage-6.2.app/ and named the copy sage-6.3.app/ 
> >   3.  moved the 6.3 version of sage/ into 
> > sage-6.3.app/Contents/Resources/ 
> >   4.  edit a few lines in sage-6.3.app/Contents/Info.plist 
> (actually, I 
> > should have but didn't bother). 
> > 
> > So it seems trivial to make an OS X 10.6 app version from a OS X 10.6 
> > non-app version. 
> > 
> > The size is 3.55 GB, smaller by about 1GB than the official OS X 10.7 
> app 
> > version. 
> > 
> > For comparison, the official sage-6.2-app is 3.32 GB. 
> > 
> > Daniel 
> > 
> > 
> > 
>
>

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] Re: sage-6.3-x86_64-Darwin-OSX_10.6_x86_64-app.dmg won't be built?

2014-08-22 Thread Daniel Friedan
I've done a couple of experiments with the latest version of Sage (6.3) 
under OS X 10.6.8, using the official 10.7 and 10.6 binaries available for 
download.

(1) *sage-6.3-x86_64-Darwin-OSX_10.7_x86_64.dmg* 
<http://boxen.math.washington.edu/home/sagemath/sage-mirror/osx/intel/sage-6.3-x86_64-Darwin-OSX_10.7_x86_64.dmg>

This is an app version (the file name should be changed to 
*sage-6.3-x86_64-Darwin-OSX_10.7_x86_64-app.dmg* 
<http://boxen.math.washington.edu/home/sagemath/sage-mirror/osx/intel/sage-6.3-x86_64-Darwin-OSX_10.7_x86_64.dmg>
).

It runs on OS X 10.6.8 (though I didn't test much).

It seems large, 4.53 GB.

(2) *sage-6.3-x86_64-Darwin-OSX_10.6_x86_64.dmg* 
<http://boxen.math.washington.edu/home/sagemath/sage-mirror/osx/intel/sage-6.3-x86_64-Darwin-OSX_10.6_x86_64.dmg>

This is the non-app version.  I turned it into an app version by the 
following:
  1.  moved sage/ out of sage-6.2.app/Contents/Resources/
  2.  copied sage-6.2.app/ and named the copy sage-6.3.app/
  3.  moved the 6.3 version of sage/ into 
sage-6.3.app/Contents/Resources/
  4.  edit a few lines in sage-6.3.app/Contents/Info.plist (actually, I 
should have but didn't bother).

So it seems trivial to make an OS X 10.6 app version from a OS X 10.6 
non-app version.

The size is 3.55 GB, smaller by about 1GB than the official OS X 10.7 app 
version.

For comparison, the official sage-6.2-app is 3.32 GB.

Daniel



-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


  1   2   3   >