[sage-support] Re: Numeric Approximation with Symbolics

2018-02-26 Thread Ralf Stephan
On Tuesday, February 27, 2018 at 1:06:37 AM UTC+1, Pstrang Rzekle wrote:

> Is there a way to trick SageMath into presenting numeric approximations 
> with symbolics? In this specific case, handling numbers with units attached.
>

You will have to use an internal method and convert the number of digits to 
bits yourself, until that is fixed:

sage: x._convert({'parent':RealField(10)})
(1.0e-6)*centimeter

Regards,

-- 
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: How to get special values of arccos

2018-02-26 Thread Ralf Stephan
On Monday, February 26, 2018 at 9:08:47 AM UTC+1, Simon King wrote:
>
> Question: How can one get the exact value of arccos(1/2*sqrt(sqrt(2) + 2)) 
> (which is pi/8)? I tried .simplify_full() and so on, but to no avail. 
>

First, there is no such ready functionality. There are probably several 
ways to enable this for you as user, the simplest being a function that 
builds up a dict with (expr : expr) pairs that gets pre-filled with things 
like (1/2*sqrt(sqrt(2) + 2) : pi/8) which you just look up. This is 
possible because the simplification from cos(pi/8) to 1/2*sqrt(sqrt(2) + 2) 
is one of only a finite number of cases implemented.

A more mathematical solution would be to convert 1/2*sqrt(sqrt(2) + 2) to 
an algebraic number (QQbar) and look at the degree d of its minimal 
polynomial. I'm not an expert but pretty sure that d divides n in 
cos(m/n*pi). From experience n / d is probably not greater than 4, so maybe 
it suffices to check d, 2d, and 4d as candidates for n, and loop through 
all m coprime to n. This algorithm is slow however, so it's better to put 
it in as part of ex.simplify_full().

Improvements appreciated,

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To 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] Is this a bug?

2018-02-26 Thread David Joyner
On Mon, Feb 26, 2018 at 8:52 PM, Juan Luis Varona
 wrote:
> In sagemath 7.5, we can use this code:
>
> t=var('t');
> M=matrix(4,[[0,0,5/4,2],[t,0,0,0],[0,1,0,0],[0,0,1,0]]);
> P=charpoly(M);
> P.substitute(x=1)
>
> Then, we get the correct answer
> -13/4*t + 1
>
> However, the same code gives an error with sagemath 8.2.
>
> A workaround that again gives the correct answer with sagemath 8.2 is the
> following:
>
> t=var('t');
> M=matrix(4,[[0,0,5/4,2],[t,0,0,0],[0,1,0,0],[0,0,1,0]]);
> P=charpoly(M);
> y=var('y')
> P.substitute(x=y).substitute(y=1)
>
> What is happening?
>
> Is this a bug or a strange feature of the "x" obtained from charpoly?
>

This works in 7.6 and on cocalc.com:

sage: PR. = PolynomialRing(QQ, 2, "x,t")
sage: M=matrix(PR,[[0,0,5/4,2],[t,0,0,0],[0,1,0,0],[0,0,1,0]])
sage: P = M.charpoly()
sage: P(1)
-13/4*t + 1



> Thanks in advance!
>
> Juan Luis Varona
>
> --
> 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] Is this a bug?

2018-02-26 Thread Juan Luis Varona
In sagemath 7.5, we can use this code:

t=var('t');
M=matrix(4,[[0,0,5/4,2],[t,0,0,0],[0,1,0,0],[0,0,1,0]]);
P=charpoly(M);
P.substitute(x=1)

Then, we get the correct answer
-13/4*t + 1

However, the same code gives an error with sagemath 8.2.

A workaround that again gives the correct answer with sagemath 8.2 is the 
following:

t=var('t');
M=matrix(4,[[0,0,5/4,2],[t,0,0,0],[0,1,0,0],[0,0,1,0]]);
P=charpoly(M);
y=var('y')
P.substitute(x=y).substitute(y=1)

What is happening?

Is this a bug or a strange feature of the "x" obtained from charpoly?

Thanks in advance!

Juan Luis Varona

-- 
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] Numeric Approximation with Symbolics

2018-02-26 Thread Pstrang Rzekle
Is there a way to trick SageMath into presenting numeric approximations 
with symbolics? In this specific case, handling numbers with units attached.

For example:

┌┐
│ SageMath version 8.1, Release Date: 2017-12-07 │
│ Type "notebook()" for the browser-based notebook interface.│
│ Type "help()" for help.│
└┘
sage: cm = units.length.centimeter;
sage: x = 1e-6*cm;
sage: x
(1.00e-6)*centimeter
sage: x.n(digits=2)


---
TypeError Traceback (most recent call last)
 in ()
> 1 x.n(digits=Integer(2))


/home/Scratch/Install/Linux/SageMath/sage-8.1-Fedora_26-x86_64/SageMath/src/
sage/structure/element.pyx in sage.structure.element.Element.n (build/
cythonized/sage/structure/element.c:8063)()
861 0.667
862 """
--> 863 return self.numerical_approx(prec, digits, algorithm)
864 
865 N = deprecated_function_alias(13055, n)


/home/Scratch/Install/Linux/SageMath/sage-8.1-Fedora_26-x86_64/SageMath/src/sage/symbolic/expression.pyx
 
in sage.symbolic.expression.Expression.numerical_approx 
(build/cythonized/sage/symbolic/expression.cpp:36128)()
   5782 res = x.pyobject()
   5783 else:
-> 5784 raise TypeError("cannot evaluate symbolic expression 
numerically")
   5785 
   5786 # Important -- the  we get might not be a valid output for 
numerical_approx in


TypeError: cannot evaluate symbolic expression numerically


Thank you for any suggestions!

-- 
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] Computing large degree isogenies in Sage

2018-02-26 Thread ET
I have been playing lately with isogeny computation functions that Sage 
provides, but I noticed that they kind of get stuck (computations does not 
finish in reasonable time) when using _largish_ values, which doesn't seem 
to happen when using Magma's isogeny computation functions.

 For example, this 

 
is one case where the computations doesn't seem to finish in a reasonable 
time, but a simple search reveals other cases too, such as this 
,
 
and this 

.

With the introduction of SIDH, isogeny-based crypto has gained a lot of 
attention, and people have started to play around with these functions 
more, though, it can get a bit annoying when these functions don't give 
results in a reasonable time for large numbers, which Magma seems to be 
comfortable in handling. Do you have any idea why they don't give answers 
for  _largish_ isogeny degrees? Also, is there a way to do chaining of low 
degree isogenies so they work in reasonable time?

Shortly, how can one compute in Sage in a _reasonable_ time isogeny of 
degree  $3^239$ and $2^372$ in this field and elliptic curve:

p = 
10354717741769305252977768237866805321427389645549071170116189679054678940682478846502882896561066713624553211618840202385203911976522554393044160468771151816976706840078913334358399730952774926980235086850991501872665651576831
 
Fp = GF(p) R. = PolynomialRing(Fp) # The quadratic extension via x^2 + 1 
since p = 3 mod 4 
Fp2. = Fp.extension(x^2 + 1) 
E = EllipticCurve(Fp2, [1,0])

The exact values can be found 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] Re: computing problem

2018-02-26 Thread Dima Pasechnik
This is a Maxima bug; running this in Sage's version of Maxima gives

(%i5) integrate(sqrt(cos(2*(x)))/sin(x),x);

sign: argument cannot be imaginary; found %i
 -- an error. To debug this try: debugmode(true);

The same error is produced by the latest Maxima:

Maxima 5.41.0 http://maxima.sourceforge.net
using Lisp SBCL 1.4.4
Distributed under the GNU Public License. See the file COPYING.
Dedicated to the memory of William Schelter.
The function bug_report() provides bug reporting information.
(%i1) integrate(sqrt(cos(2*(x)))/sin(x),x);

sign: argument cannot be imaginary; found %i
 -- an error. To debug this try: debugmode(true);




On Monday, February 26, 2018 at 4:51:45 PM UTC, Michael Colin D' Souza 
wrote:
>
> integral(sqrt(cos(2*(x)))/sin(x),x) gave a runtime error message 
> "RuntimeError: ECL says: Error executing code in Maxima:".
>

-- 
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] computing problem

2018-02-26 Thread Michael Colin D' Souza
integral(sqrt(cos(2*(x)))/sin(x),x) gave a runtime error message 
"RuntimeError: ECL says: Error executing code in Maxima:".

-- 
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: Help installing from source in Mac OSX 10.11.6

2018-02-26 Thread mforets
Yes, i wish now to recompile (git trac pull on develp branch) after a 
while. In a fresh session, if i try to make after a distclean i get the 
different error message below related to some dyld: Library not loaded: 
/usr/local/opt/mpfr/lib/libmpfr.4.dylib Referenced from: 
/usr/local/bin/gawk.

If possible i would like to avoid a system upgrade (newest XCode + Mac OS 
Sierra). Thanks!

$ cd ~/sage-src/sage/
$ unset DYLD_LIBRARY_PATH
$ echo $DYLD_LIBRARY_PATH

$ export 
PATH=/Users/forets/Library/Python/2.7/bin/:/Users/forets/.rbenv/shims:/Applications/usr/bin:/Applications/Julia-0.6.app/Contents/Resources/julia/bin/:/Users/forets/Projects/OCRG/ocrg_git/:/Users/forets/Tools/spaceex_src/sspaceex/Release:/Applications/MATLAB_R2016a.app/bin:~/Tools/sage-master:/Library/Frameworks/Python.framework/Versions/3.5/bin:/usr/local/opt/coreutils/libexec/gnubin:/usr/local/bin:/usr/local/bin:/Library/Frameworks/Python.framework/Versions/3.5/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/X11/bin:/Library/TeX/texbin

$ make distclean && make="MAKE -j4" make
/Applications/Xcode.app/Contents/Developer/usr/bin/make build/make/Makefile 
--stop
make[1]: `build/make/Makefile' is up to date.
build/bin/sage-logger \
"cd build/make && ./install 'build-clean'" logs/install.log
*** ALL ENVIRONMENT VARIABLES BEFORE BUILD: ***
Apple_PubSub_Socket_Render=/private/tmp/com.apple.launchd.B1SYzE4DrX/Render
CARLIN_REACH_ROOT=/Users/forets/Projects/nliftZonotopes
CORA_ROOT=/Users/forets/Tools/CORA_2016_orig
DISPLAY=/private/tmp/com.apple.launchd.vkRKLUhZIY/org.macosforge.xquartz:0
GRB_LICENSE_FILE=/Users/forets/gurobi.lic
HOME=/Users/forets
LC_ALL=en_US.UTF-8
LC_CTYPE=UTF-8
LOGNAME=forets
MAKE=make
MAKEFLAGS= V=1
MAKELEVEL=1
MANPATH=/opt/local/share/man:
MFLAGS=
PATH=/Users/forets/sage-src/sage/build/bin:/Users/forets/sage-src/sage/src/bin:/bin:/Users/forets/Library/Python/2.7/bin/:/Users/forets/.rbenv/shims:/Applications/usr/bin:/Applications/Julia-0.6.app/Contents/Resources/julia/bin/:/Users/forets/Projects/OCRG/ocrg_git/:/Users/forets/Tools/spaceex_src/sspaceex/Release:/Applications/MATLAB_R2016a.app/bin:/Users/forets/Tools/sage-master:/Library/Frameworks/Python.framework/Versions/3.5/bin:/usr/local/opt/coreutils/libexec/gnubin:/usr/local/bin:/usr/local/bin:/Library/Frameworks/Python.framework/Versions/3.5/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/X11/bin:/Library/TeX/texbin
PWD=/Users/forets/sage-src/sage/build/make
PYTHONPATH=
RBENV_SHELL=bash
SAGE_EXTCODE=/share/sage/ext
SAGE_LOGS=/Users/forets/sage-src/sage/logs/pkgs
SAGE_ORIG_PATH=/Users/forets/Library/Python/2.7/bin/:/Users/forets/.rbenv/shims:/Applications/usr/bin:/Applications/Julia-0.6.app/Contents/Resources/julia/bin/:/Users/forets/Projects/OCRG/ocrg_git/:/Users/forets/Tools/spaceex_src/sspaceex/Release:/Applications/MATLAB_R2016a.app/bin:/Users/forets/Tools/sage-master:/Library/Frameworks/Python.framework/Versions/3.5/bin:/usr/local/opt/coreutils/libexec/gnubin:/usr/local/bin:/usr/local/bin:/Library/Frameworks/Python.framework/Versions/3.5/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/X11/bin:/Library/TeX/texbin
SAGE_ORIG_PATH_SET=True
SAGE_ROOT=/Users/forets/sage-src/sage
SAGE_SHARE=/share
SAGE_SPKG_INST=/var/lib/sage/installed
SAGE_SRC=/Users/forets/sage-src/sage/src
SAGE_VERSION=8.2.beta6
SHELL=/bin/bash
SHLVL=4
SSH_AUTH_SOCK=/private/tmp/com.apple.launchd.XbkLnbFxaK/Listeners
TERM=xterm-256color
TERM_PROGRAM=Apple_Terminal
TERM_PROGRAM_VERSION=361.1
TERM_SESSION_ID=6C92C554-47AF-4E23-8485-C90C8FDDDBB7
TMPDIR=/var/folders/b_/qy7kpq613ld0g06jy9g16hz0gp/T/
USER=forets
XPC_FLAGS=0x0
XPC_SERVICE_NAME=0
_=/usr/local/opt/coreutils/libexec/gnubin/env
__CF_USER_TEXT_ENCODING=0x1F6:0x0:0x0
***
Deleting package build directories...
rm -rf "/var/tmp/sage/build"
cd "/Users/forets/sage-src/sage/src/doc" && make clean
rm -rf en/reference/*/sage
rm -rf en/reference/*/sagenb
rm -rf en/reference/sage
rm -rf en/reference/sagenb
rm -f common/*.pyc
rm -rf "/share/doc/sage"
cd "/Users/forets/sage-src/sage/src" && make clean
Deleting Sage library build artifacts...
rm -rf c_lib .cython_version # from old sage versions
rm -rf build
find . -name '*.pyc' | xargs rm -f
rm -rf sage/ext/interpreters

real0m0.107s
user0m0.039s
sys0m0.044s
Sage build/upgrade complete!
/Applications/Xcode.app/Contents/Developer/usr/bin/make misc-clean
Deleting miscellaneous artifacts generated by build system ...
rm -rf logs
rm -rf dist
rm -rf tmp
rm -f aclocal.m4 config.log config.status confcache
rm -rf autom4te.cache
rm -f build/make/Makefile build/make/Makefile-auto
rm -f .BUILDSTART
Deleting all remaining output from build system ...
rm -rf local
rm -f src/bin/sage-env-config
/Applications/Xcode.app/Contents/Developer/usr/bin/make build/make/Makefile 
--stop
rm -f config.log
mkdir -p logs/pkgs
ln -s logs/pkgs/config.log config.log
checking for a BSD-compatible install... 
/usr/local/opt/coreutils/libexec/gnubin/install -c

[sage-support] Re: Help installing from source in Mac OSX 10.11.6

2018-02-26 Thread Dima Pasechnik
you probably didn't update sage for a while there. make distclean ?


On Monday, February 26, 2018 at 10:12:31 AM UTC, mforets wrote:
>
> Hello,
> In a Mac OSX 10.11.6 with Xcode 8.2.1, compiling sage 8.2.beta6 from 
> sources i get the error message below:
>
> $ make
> /Applications/Xcode.app/Contents/Developer/usr/bin/make 
> build/make/Makefile --stop
> ./bootstrap -d
> rm -rf config configure build/make/Makefile-auto.in
> configure.ac:390: installing 'config/compile'
> configure.ac:105: installing 'config/config.guess'
> configure.ac:105: installing 'config/config.sub'
> configure.ac:68: installing 'config/install-sh'
> configure.ac:68: installing 'config/missing'
> rm -f config.log
> mkdir -p logs/pkgs
> ln -s logs/pkgs/config.log config.log
> running CONFIG_SHELL=/bin/sh /bin/sh ./configure --no-create --no-recursion
> checking for a BSD-compatible install... 
> /usr/local/opt/coreutils/libexec/gnubin/install -c
> checking whether build environment is sane... yes
> checking for a thread-safe mkdir -p... 
> /usr/local/opt/coreutils/libexec/gnubin/mkdir -p
> checking for gawk... gawk
> checking whether make sets $(MAKE)... yes
> checking whether make supports nested variables... yes
> checking whether to enable maintainer-specific portions of Makefiles... yes
> checking for root user... no
> checking build system type... x86_64-apple-darwin15.6.0
> checking host system type... x86_64-apple-darwin15.6.0
> checking for ar... yes
> checking for m4... yes
> checking for ranlib... yes
> checking for strip... yes
> checking for GNU or BSD tar... /usr/bin/tar
> checking for GNU make... /usr/bin/make
> checking for latex... yes
> checking for perl... /usr/bin/perl
> checking for Perl version 5.8.0 or later... yes
> checking for git... /usr/bin/git
> checking for yasm... no
> dyld: Library not loaded: /usr/local/opt/mpfr/lib/libmpfr.4.dylib
>   Referenced from: /usr/local/bin/awk
>   Reason: image not found
> local/bin/sage-env: line 339: [: -ge: unary operator expected
> : error: unknown value '10.-4' of -mmacosx-version-min
> conftest.cpp:2:6: error: 'inf' does not name a type
>  auto inf = 1.0 / std::complex();
>   ^
> configure: Installing GCC because installed g++ is broken
> checking for gcc... gcc
> checking whether the C compiler works... yes
> checking for C compiler default output file name... a.out
> checking for suffix of executables... 
> checking whether we are cross compiling... no
> checking for suffix of object files... o
> checking whether we are using the GNU C compiler... yes
> checking whether gcc accepts -g... yes
> checking for gcc option to accept ISO C89... none needed
> checking whether gcc understands -c and -o together... yes
> checking for style of include used by make... GNU
> checking dependency style of gcc... none
> checking how to run the C preprocessor... gcc -E
> checking for g++... g++
> checking whether we are using the GNU C++ compiler... yes
> checking whether g++ accepts -g... yes
> checking dependency style of g++... none
> checking for gfortran... gfortran
> checking whether we are using the GNU Fortran compiler... yes
> checking whether gfortran accepts -g... yes
> checking for C compiler vendor... clang
> checking for gcc... gcc
> checking whether we are using the GNU Objective C compiler... yes
> checking whether gcc accepts -g... yes
> checking dependency style of gcc... none
> checking for g++... g++
> checking whether we are using the GNU Objective C++ compiler... yes
> checking whether g++ accepts -g... yes
> checking dependency style of g++... none
> checking for curl 7.22... /usr/bin/curl
> checking for grep that handles long lines and -e... /usr/bin/grep
> checking for egrep... /usr/bin/grep -E
> checking for ANSI C header files... yes
> checking for sys/types.h... yes
> checking for sys/stat.h... yes
> checking for stdlib.h... yes
> checking for string.h... yes
> checking for memory.h... yes
> checking for strings.h... yes
> checking for inttypes.h... yes
> checking for stdint.h... yes
> checking for unistd.h... yes
> checking curl/curl.h usability... yes
> checking curl/curl.h presence... yes
> checking for curl/curl.h... yes
> checking how to run the C++ preprocessor... g++ -E
> checking complex.h usability... yes
> checking complex.h presence... yes
> checking for complex.h... yes
> checking whether g++ supports C++11 features by default... no
> checking whether g++ supports C++11 features with -std=gnu++11... yes
> checking for gcc option to accept ISO C99... none needed
> checking for Fortran flag needed to accept free-form source... -ffree-form
> checking for sqrt in -lm... yes
> ***
> ***
> You are using OS X Lion (or later).
> You are strongly advised to install Apple's latest Xcode
> unless you already have it. You can install this using
> the App Store. Also, make sure you install Xcode's
> Command Line Tools -- see Sage's README.txt.
> configure: 

[sage-support] Help installing from source in Mac OSX 10.11.6

2018-02-26 Thread mforets
Hello,
In a Mac OSX 10.11.6 with Xcode 8.2.1, compiling sage 8.2.beta6 from 
sources i get the error message below:

$ make
/Applications/Xcode.app/Contents/Developer/usr/bin/make build/make/Makefile 
--stop
./bootstrap -d
rm -rf config configure build/make/Makefile-auto.in
configure.ac:390: installing 'config/compile'
configure.ac:105: installing 'config/config.guess'
configure.ac:105: installing 'config/config.sub'
configure.ac:68: installing 'config/install-sh'
configure.ac:68: installing 'config/missing'
rm -f config.log
mkdir -p logs/pkgs
ln -s logs/pkgs/config.log config.log
running CONFIG_SHELL=/bin/sh /bin/sh ./configure --no-create --no-recursion
checking for a BSD-compatible install... 
/usr/local/opt/coreutils/libexec/gnubin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... 
/usr/local/opt/coreutils/libexec/gnubin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking whether make supports nested variables... yes
checking whether to enable maintainer-specific portions of Makefiles... yes
checking for root user... no
checking build system type... x86_64-apple-darwin15.6.0
checking host system type... x86_64-apple-darwin15.6.0
checking for ar... yes
checking for m4... yes
checking for ranlib... yes
checking for strip... yes
checking for GNU or BSD tar... /usr/bin/tar
checking for GNU make... /usr/bin/make
checking for latex... yes
checking for perl... /usr/bin/perl
checking for Perl version 5.8.0 or later... yes
checking for git... /usr/bin/git
checking for yasm... no
dyld: Library not loaded: /usr/local/opt/mpfr/lib/libmpfr.4.dylib
  Referenced from: /usr/local/bin/awk
  Reason: image not found
local/bin/sage-env: line 339: [: -ge: unary operator expected
: error: unknown value '10.-4' of -mmacosx-version-min
conftest.cpp:2:6: error: 'inf' does not name a type
 auto inf = 1.0 / std::complex();
  ^
configure: Installing GCC because installed g++ is broken
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables... 
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking whether gcc understands -c and -o together... yes
checking for style of include used by make... GNU
checking dependency style of gcc... none
checking how to run the C preprocessor... gcc -E
checking for g++... g++
checking whether we are using the GNU C++ compiler... yes
checking whether g++ accepts -g... yes
checking dependency style of g++... none
checking for gfortran... gfortran
checking whether we are using the GNU Fortran compiler... yes
checking whether gfortran accepts -g... yes
checking for C compiler vendor... clang
checking for gcc... gcc
checking whether we are using the GNU Objective C compiler... yes
checking whether gcc accepts -g... yes
checking dependency style of gcc... none
checking for g++... g++
checking whether we are using the GNU Objective C++ compiler... yes
checking whether g++ accepts -g... yes
checking dependency style of g++... none
checking for curl 7.22... /usr/bin/curl
checking for grep that handles long lines and -e... /usr/bin/grep
checking for egrep... /usr/bin/grep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking curl/curl.h usability... yes
checking curl/curl.h presence... yes
checking for curl/curl.h... yes
checking how to run the C++ preprocessor... g++ -E
checking complex.h usability... yes
checking complex.h presence... yes
checking for complex.h... yes
checking whether g++ supports C++11 features by default... no
checking whether g++ supports C++11 features with -std=gnu++11... yes
checking for gcc option to accept ISO C99... none needed
checking for Fortran flag needed to accept free-form source... -ffree-form
checking for sqrt in -lm... yes
***
***
You are using OS X Lion (or later).
You are strongly advised to install Apple's latest Xcode
unless you already have it. You can install this using
the App Store. Also, make sure you install Xcode's
Command Line Tools -- see Sage's README.txt.
configure: error: "found MacPorts in /opt/local/bin/port. Either:
(1) rename /opt/local and /sw, or
(2) change PATH and DYLD_LIBRARY_PATH
(Once Sage is built, you can restore them.)
If you would like to try to build Sage anyway (to help porting),
export the variable 'SAGE_PORT' to something non-empty.
make[1]: *** [build/make/Makefile] Error 1
make: *** [all] Error 2


[sage-support] Re: Error installing package brial-1.0.1.p1

2018-02-26 Thread Dima Pasechnik
well, I honestly don't even know a Sagemath component which uses SQL.
Presumably it is not a so important problem.

-- 
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: Error installing package brial-1.0.1.p1

2018-02-26 Thread hans . sachs
Goiod Morning Dima,

I thought sage works fine on my server - this is only the half truth

user with $HOME on a local drive - no problems

but all my users has the $HOME on a nfs-mount - so I have similar problems 
as by 'make'

is this a critical bug or tolerable?



[john-d@fb09-pg-s202 bin]$ ./sage
┌┐
│ SageMath version 8.1, Release Date: 2017-12-07 │
│ Type "notebook()" for the browser-based notebook interface.│
│ Type "help()" for help.│
└┘
[SageTerminalApp] ERROR | Failed to open SQLite history 
/home/home2/john-d/.sage/ipython-5.0.0/profile_default/history.sqlite 
(database is locked).
[SageTerminalApp] ERROR | History file was moved to 
/home/home2/john-d/.sage/ipython-5.0.0/profile_default/history-corrupt.sqlite 
and a new file created.
[SageTerminalApp] ERROR | Failed to open SQLite history 
/home/home2/john-d/.sage/ipython-5.0.0/profile_default/history.sqlite 
(database is locked).
[SageTerminalApp] ERROR | History file was moved to 
/home/home2/john-d/.sage/ipython-5.0.0/profile_default/history-corrupt.sqlite 
and a new file created.
[SageTerminalApp] ERROR | Failed to open SQLite history 
/home/home2/john-d/.sage/ipython-5.0.0/profile_default/history.sqlite 
(database is locked).
[SageTerminalApp] ERROR | Failed to load history too many times, history 
will not be saved.


-- 
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 to get special values of arccos

2018-02-26 Thread Simon King
Hi!

SageMath knows a couple of special values for the cosine function, such
as
  sage: cos(pi/8)
  1/2*sqrt(sqrt(2) + 2)

However, SageMath's knowledge of special values of the arccos function
seems a lot more limited:
  sage: arccos(_)
  arccos(1/2*sqrt(sqrt(2) + 2))
  sage: arccos(1/2)
  1/3*pi

Question: How can one get the exact value of arccos(1/2*sqrt(sqrt(2) + 2))
(which is pi/8)? I tried .simplify_full() and so on, but to no avail.

Best regards,
Simon

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-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.