Contact
CoCalc Logo Icon
StoreFeaturesDocsShareSupport News AboutSign UpSign In
| Download

Examples of using latex in cocalc

Views: 1132
1
## -*- encoding: utf-8 -*-
2
3
# This file was *autogenerated* from the file simple.sagetex.sage
4
from sage.all_cmdline import * # import sage library
5
6
_sage_const_2 = Integer(2); _sage_const_1 = Integer(1); _sage_const_0 = Integer(0); _sage_const_7 = Integer(7); _sage_const_8 = Integer(8); _sage_const_13 = Integer(13); _sage_const_10 = Integer(10); _sage_const_14 = Integer(14); _sage_const_201809234098 = Integer(201809234098)## This file (simple.sagetex.sage) was *autogenerated* from simple.tex with sagetex.sty version 2015/08/26 v3.0-92d9f7a.
7
import sagetex
8
_st_ = sagetex.SageTeXProcessor('simple', version='2015/08/26 v3.0-92d9f7a', version_check=True)
9
try:
10
_st_.current_tex_line = _sage_const_8
11
_st_.inline(_sage_const_0 , latex(factor(_sage_const_201809234098 )))
12
except:
13
_st_.goboom(_sage_const_8 )
14
_st_.current_tex_line = _sage_const_10
15
_st_.blockbegin()
16
try:
17
a = random()
18
b = _sage_const_7
19
except:
20
_st_.goboom(_sage_const_13 )
21
_st_.blockend()
22
try:
23
_st_.current_tex_line = _sage_const_14
24
_st_.inline(_sage_const_1 , latex(a))
25
except:
26
_st_.goboom(_sage_const_14 )
27
try:
28
_st_.current_tex_line = _sage_const_14
29
_st_.inline(_sage_const_2 , latex(a+b))
30
except:
31
_st_.goboom(_sage_const_14 )
32
_st_.endofdoc()
33
34
35