[sage-support] Re: Citing Sage properly in a paper

2022-09-04 Thread Nils Bruin
On Sunday, 4 September 2022 at 10:31:42 UTC-7 george...@gmail.com wrote:

> All,
> I am about to submit a math paper to a journal. I would like to include a 
> proper citation for Sage. The Sage web page says:
>
> "Also, be sure to find out which components of SageMath, e.g. NumPy, PARI, 
> GAP, Sage-Combinat, that your calculation uses and properly attribute those 
> systems."
>
> My question is: which component am I using?
>
> I am doing the following:
>
> x, y, z = var('x, y, z')
> factor(x^6+y^6)
> factor(x^6-y^6)
> expand((3*x^2+y^2)*(x^2+3*y^2))
>

That kind of use generally attracts a "using a computational algebra 
system" since it's such a routine operation. In fact, people wouldn't blink 
at no explanation at all or a comment about "manual computation".

Otherwise, on https://wiki.sagemath.org/Publications_using_SageMath

it lists the following code to figure out what components you use 
(probably):

sage: from sage.misc.citation import get_systems
sage: get_systems("integrate(cos(x^2), x)")
['MPFI', 'ginac', 'GMP', 'Maxima']

If you don't have it enabled already, it will give you a warning that 
cython profiling must be enabled to get reliable result. Indeed, in your 
case it would only report "ginac" (really the form "pynac" that sagemath 
uses for its symbolics) as well as "Maxima".
Note that this tool may identify externally developed software that is used 
in sage, but it doesn't look at which parts of the sage library are used. 
There are several state-of-the-art implementations made fully in the 
sagemath library of very specialist algorithms. It makes sense to look at 
authorship of some of the top-level routines you use to see if there are 
papers you can find that describe the implementation (the documentation 
does have literature references) and then refer to those papers, since in a 
sense you are using their result.


-- 
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/48d61579-af83-4d7d-a0ab-0d3966363b34n%40googlegroups.com.


[sage-support] Citing Sage properly in a paper

2022-09-04 Thread Georg Ehlers
All,
I am about to submit a math paper to a journal. I would like to include a 
proper citation for Sage. The Sage web page says:

"Also, be sure to find out which components of SageMath, e.g. NumPy, PARI, 
GAP, Sage-Combinat, that your calculation uses and properly attribute those 
systems."

My question is: which component am I using?

I am doing the following:

x, y, z = var('x, y, z')
factor(x^6+y^6)
factor(x^6-y^6)
expand((3*x^2+y^2)*(x^2+3*y^2))

and similar.

Platform: macOS 12.5.1
SageMath version 9.4, Release Date: 2021-08-22

Thank you
Georg

-- 
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/f8e756d4-5945-4e48-b3b0-2e119e7880e6n%40googlegroups.com.


[sage-support] Re: Simplifications and sagemanifold

2022-09-04 Thread Eric Gourgoulhon
Thank you for these instructive benchmarks!

Best wishes,

Eric. 

Le dimanche 4 septembre 2022 à 07:35:18 UTC+2, roger...@gmail.com a écrit :

> Thank you very much Eric! It works perfectly well for my needs.
> I've tested the time spent for calculating the Riemann tensor (restarting 
> the kernel to avoid cache) for three different simplifying methods: the 
> standard, the simplify, and a function that just returns the expression. It 
> makes a huge difference.
>
> For the Kerr-Newman metric, without simplification is ~500x faster 
> (considering the wall time).
>
> - default
> CPU times: user 5min 6s, sys: 4.16 s, total: 5min 10s
> Wall time: 3min
>
> - simplify
> CPU times: user 40.1 s, sys: 359 ms, total: 40.4 s
> Wall time: 27.3 s
>
> - no simplification
> CPU times: user 468 ms, sys: 785 µs, total: 468 ms
> Wall time: 340 ms
>
>
> For the metric given by
>
> [-1, 0, 0, 0]
> [0, h11(t, r, th, ph), h12(t, r, th, ph), h13(t, r, th, ph)]
> [0, h12(t, r, th, ph), h22(t, r, th, ph), h23(t, r, th, ph)]
> [0, h13(t, r, th, ph), h23(t, r, th, ph), h33(t, r, th, ph)]
>
> the results are more even impressive. No simplification is ~4000x faster.
>
> - default
> CPU times: user 40min 26s, sys: 17.9 s, total: 40min 43s
> Wall time: 31min 29s
>
> - simplify
> CPU times: user 3min 10s, sys: 978 ms, total: 3min 11s
> Wall time: 2min 44s
>
> - no simplification
> CPU times: user 715 ms, sys: 14.2 ms, total: 729 ms
> Wall time: 573 ms
>
> Best wishes,
>
> Rogerio
>
> Em sábado, 3 de setembro de 2022 às 12:55:33 UTC-3, egourg...@gmail.com 
> escreveu:
>
>> Le vendredi 2 septembre 2022 à 08:09:23 UTC+2, roger...@gmail.com a 
>> écrit :
>>
>>> Components of tensors in sagemanifolds are nicely simplified through 
>>> methods of chart functions. However, for large and complicated expressions, 
>>> such simplifications are very time consuming. 
>>> Is it possible to turn off these simplifications?
>>
>>
>> Yes, via the method M.set_simplify_function. It suffices to pass a fast 
>> function as argument, like simplify.  
>> For instance:
>>
>> sage: M = Manifold(4, 'M')
>> sage: X. = M.chart()
>> sage: M.set_simplify_function(simplify)
>>
>> NB: the call to M.set_simplify_function must be done after the chart(s) 
>> have been defined. It can also be done chartwise, via
>> X.calculus_method().set_simplify_function(simplify)
>>
>> See 
>>
>> https://doc.sagemath.org/html/en/reference/manifolds/sage/manifolds/manifold.html#sage.manifolds.manifold.TopologicalManifold.set_simplify_function
>> for details. 
>>
>> Best wishes,
>>
>> Eric.
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/af76ad88-21ab-44c8-a710-b4c09e6c4b77n%40googlegroups.com.