-
-
Notifications
You must be signed in to change notification settings - Fork 531
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add Korean a_tour_of_sage and tutorial
- Loading branch information
Showing
9 changed files
with
471 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
# nodoctest | ||
# Numerical Sage documentation build configuration file, created by | ||
# sphinx-quickstart on Sat Dec 6 11:08:04 2008. | ||
# | ||
# This file is execfile()d with the current directory set to its containing dir. | ||
# | ||
# The contents of this file are pickled, so don't put values in the namespace | ||
# that aren't pickleable (module imports are okay, they're removed automatically). | ||
# | ||
# All configuration values have a default; values that are commented out | ||
# serve to show the default. | ||
|
||
from sage_docbuild.conf import release | ||
from sage_docbuild.conf import * # NOQA | ||
|
||
# Add any paths that contain custom static files (such as style sheets), | ||
# relative to this directory to html_static_path. They are copied after the | ||
# builtin static files, so a file named "default.css" will overwrite the | ||
# builtin "default.css". html_common_static_path imported from sage_docbuild.conf | ||
# contains common paths. | ||
html_static_path = [] + html_common_static_path | ||
|
||
# General information about the project. | ||
project = 'Sage 둘러보기' | ||
name = 'a_tour_of_sage' | ||
language = 'ko' | ||
|
||
# The name for this set of Sphinx documents. If None, it defaults to | ||
# "<project> v<release> documentation". | ||
html_title = project | ||
|
||
# Output file base name for HTML help builder. | ||
htmlhelp_basename = name | ||
|
||
# Grouping the document tree into LaTeX files. List of tuples | ||
# (source start file, target name, title, author, document class [howto/manual]). | ||
latex_documents = [ | ||
('index', name + '.tex', project, | ||
'The Sage Development Team', 'manual'), | ||
] |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,135 @@ | ||
=========================== | ||
Sage에 오신 것을 환영합니다 | ||
=========================== | ||
|
||
여기서 우리는 Sage를 계산기로 사용하는 간단한 여행을 할 것입니다. | ||
|
||
Sage의 명령줄은 ``sage:`` 프롬프트로 시작합니다. 다음 예제들을 실행하려면 | ||
프롬프트 다음 부분만 입력하면 됩니다. | ||
|
||
:: | ||
|
||
sage: 3 + 5 | ||
8 | ||
|
||
Jupyter 노트북에서 Sage를 사용하는 경우에도 마찬가지로 프롬프 이후의 | ||
모든 내용을 입력 셀에 넣고 :kbd:`Shift-Enter` 를 눌러 해당 출력을 얻으세요. | ||
|
||
``^`` 기호는 거듭제곱을 의미합니다. | ||
|
||
:: | ||
|
||
sage: 57.1^100 | ||
4.60904368661396e175 | ||
|
||
Sage에서 :math:`2 \times 2` 행렬의 역행렬을 계산하여 봅시다. | ||
|
||
:: | ||
|
||
sage: matrix([[1, 2], [3, 4]])^(-1) | ||
[ -2 1] | ||
[ 3/2 -1/2] | ||
|
||
이제 간단한 함수의 적분을 계산합니다. | ||
|
||
:: | ||
|
||
sage: x = var('x') # 변수 기호를 만듭니다 | ||
sage: integrate(sqrt(x) * sqrt(1 + x), x) | ||
1/4*((x + 1)^(3/2)/x^(3/2) + sqrt(x + 1)/sqrt(x))/((x + 1)^2/x^2 - 2*(x + 1)/x + 1) | ||
- 1/8*log(sqrt(x + 1)/sqrt(x) + 1) + 1/8*log(sqrt(x + 1)/sqrt(x) - 1) | ||
|
||
이것은 Sage에게 이차 방정식을 풀게 합니다. 기호 ``==`` 는 Sage에서 등식을 나타냅니다. | ||
|
||
:: | ||
|
||
sage: a = var('a') | ||
sage: S = solve(x^2 + x == a, x); S | ||
[x == -1/2*sqrt(4*a + 1) - 1/2, x == 1/2*sqrt(4*a + 1) - 1/2] | ||
|
||
결과는 등식의 목록입니다. | ||
|
||
.. link | ||
:: | ||
|
||
sage: S[0].rhs() # right hand side 즉 등식의 우변 | ||
-1/2*sqrt(4*a + 1) - 1/2 | ||
|
||
Sage는 다양한 함수의 그래프를 생성할 수도 있습니다. | ||
|
||
:: | ||
|
||
sage: show(plot(sin(x) + sin(1.6*x), 0, 40)) | ||
|
||
.. image:: sin_plot.* | ||
|
||
|
||
Sage는 매우 강력한 계산기입니다. 이를 확인하기 위하여 무작위 수로 이루어진 | ||
:math:`500 \times 500` 행렬을 생성해 보세요. | ||
|
||
:: | ||
|
||
sage: m = random_matrix(RDF, 500) | ||
|
||
Sage는 이 행렬의 고유값을 계산하고 그래픽으로 표시하는 데 1 초가 걸립니다. | ||
|
||
.. link | ||
:: | ||
|
||
sage: e = m.eigenvalues() # 약 1 초 | ||
sage: w = [(i, abs(e[i])) for i in range(len(e))] | ||
sage: show(points(w)) | ||
|
||
.. image:: eigen_plot.* | ||
|
||
|
||
Sage는 수백만 또는 수십억 자리의 큰 수도 처리할 수 있습니다. | ||
|
||
:: | ||
|
||
sage: factorial(100) | ||
93326215443944152681699238856266700490715968264381621468592963895217599993229915608941463976156518286253697920827223758251185210916864000000000000000000000000 | ||
|
||
:: | ||
|
||
sage: n = factorial(1000000) # περίπου 1 δευτερόλεπτο | ||
sage: len(n.digits()) | ||
5565709 | ||
|
||
여기에서 우리는 :math:`\pi` 의 소숫점 이하 100 자리를 계산합니다. | ||
|
||
:: | ||
|
||
sage: N(pi, digits=100) | ||
3.141592653589793238462643383279502884197169399375105820974944592307816406286208998628034825342117068 | ||
|
||
다음은 Sage에게 이변수 다항식을 인수분해하도록 요청합니다. | ||
|
||
:: | ||
|
||
sage: R.<x,y> = QQ[] | ||
sage: F = factor(x^99 + y^99) | ||
sage: F | ||
(x + y) * (x^2 - x*y + y^2) * (x^6 - x^3*y^3 + y^6) * | ||
(x^10 - x^9*y + x^8*y^2 - x^7*y^3 + x^6*y^4 - x^5*y^5 + | ||
x^4*y^6 - x^3*y^7 + x^2*y^8 - x*y^9 + y^10) * | ||
(x^20 + x^19*y - x^17*y^3 - x^16*y^4 + x^14*y^6 + x^13*y^7 - | ||
x^11*y^9 - x^10*y^10 - x^9*y^11 + x^7*y^13 + x^6*y^14 - | ||
x^4*y^16 - x^3*y^17 + x*y^19 + y^20) * (x^60 + x^57*y^3 - | ||
x^51*y^9 - x^48*y^12 + x^42*y^18 + x^39*y^21 - x^33*y^27 - | ||
x^30*y^30 - x^27*y^33 + x^21*y^39 + x^18*y^42 - x^12*y^48 - | ||
x^9*y^51 + x^3*y^57 + y^60) | ||
sage: F.expand() | ||
x^99 + y^99 | ||
|
||
Sage는 1억을 양의 정수의 합으로 표현하는 방법의 수를 계산하는 데에 1초 미만이 소요됩니다. | ||
|
||
:: | ||
|
||
sage: z = Partitions(10^8).cardinality() # περίπου .1 δευτερόλεπτα | ||
sage: z | ||
1760517045946249141360373894679135204009... | ||
|
||
Sage는 세계에서 가장 앞선 오픈소스 수학 소프트웨어입니다. |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
# nodoctest | ||
# Sage documentation build configuration file, created by | ||
# sphinx-quickstart on Thu Aug 21 20:15:55 2008. | ||
# | ||
# This file is execfile()d with the current directory set to its containing dir. | ||
# | ||
# The contents of this file are pickled, so don't put values in the namespace | ||
# that aren't pickleable (module imports are okay, they're removed automatically). | ||
# | ||
# All configuration values have a default; values that are commented out | ||
# serve to show the default. | ||
|
||
from sage_docbuild.conf import release | ||
from sage_docbuild.conf import * # NOQA | ||
|
||
# Add any paths that contain custom static files (such as style sheets), | ||
# relative to this directory to html_static_path. They are copied after the | ||
# builtin static files, so a file named "default.css" will overwrite the | ||
# builtin "default.css". html_common_static_path imported from sage_docbuild.conf | ||
# contains common paths. | ||
html_static_path = [] + html_common_static_path | ||
|
||
# Add a small edit button. | ||
html_theme_options.update({ | ||
'source_edit_link': os.path.join(source_repository, 'blob/develop/src/doc/ko/tutorial', '{filename}'), | ||
}) | ||
|
||
# General information about the project. | ||
project = "Sage 튜토리얼" | ||
|
||
# The name for this set of Sphinx documents. | ||
html_title = project | ||
html_short_title = project | ||
|
||
# Output file base name for HTML help builder. | ||
htmlhelp_basename = 'sage_tutorial' | ||
|
||
# Grouping the document tree into LaTeX files. List of tuples | ||
# (source start file, target name, title, author, document class [howto/manual]). | ||
latex_documents = [ | ||
('index', 'sage_tutorial.tex', 'Tutorial', | ||
'The Sage Development Team', 'manual'), | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
.. Sage documentation master file, created by sphinx-quickstart on Thu Aug 21 20:15:55 2008. | ||
You can adapt this file completely to your liking, but it should at least | ||
contain the root `toctree` directive. | ||
.. _tutorial: | ||
|
||
==================================== | ||
Sage 튜토리얼에 오신 것을 환영합니다 | ||
==================================== | ||
|
||
Sage는 대수학, 기하학, 수론, 암호학, 수치 계산 및 기타 관련 분야의 연구와 | ||
교육을 지원하는 무료 오픈소스 수학 소프트웨어입니다. Sage의 개발 모델과 기술 | ||
모두가 개방성, 커뮤니티 및 협업에 강한 강조를 두고 있습니다. 우리는 바퀴를 다시 | ||
발명하기보다 고급차를 만드는 목표를 가지고 있습니다. Sage의 주요 목표는 Maple, Mathematica, | ||
Magma 및 MATLAB의 지속 가능하고 무료이며 오픈소스인 대안을 만드는 것입니다. | ||
|
||
이 튜토리얼은 몇 시간 만에 Sage에 익숙해지는 가장 좋은 방법입니다. HTML 또는 PDF | ||
버전에서 읽을 수 있으며 또는 Jupyter 노트북에서 읽을 수도 있습니다 (메뉴에서 | ||
``Help`` 아래 ``Tutorial`` 을 선택하면 튜토리얼과 상호 작용할 수 있습니다). | ||
|
||
이 문서는 다음 라이선스로 제공됩니다: `Creative Commons Attribution-Share Alike | ||
3.0 License`__. | ||
|
||
__ http://creativecommons.org/licenses/by-sa/3.0/ | ||
|
||
.. toctree:: | ||
:maxdepth: 2 | ||
|
||
introduction | ||
interactive_shell |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,95 @@ | ||
.. _chapter-interactive_shell: | ||
|
||
********* | ||
대화형 셸 | ||
********* | ||
|
||
``sage`` 명령으로 Sage 인터프리터를 시작하면 많은 함수와 클래스가 도입된 수정된 | ||
버전의 ``IPython`` 셸이 시작됩니다. | ||
|
||
.. CODE-BLOCK:: text | ||
┌────────────────────────────────────────────────────────────────────┐ | ||
│ SageMath version X.X, Release Date: YYYY-MM-DD │ | ||
│ Using Python X.X.X. Type "help()" for help. │ | ||
└────────────────────────────────────────────────────────────────────┘ | ||
sage: | ||
Sage를 종료하려면 :kbd:`Ctrl+d` (또는 ``quit`` 또는 ``exit``)를 입력하세요. | ||
|
||
(시그널을 통한 종료인 ``kill -9`` 와 같은 방법을 피하십시오. 이 방법은 일부 | ||
프로세스를 종료하지 못하거나 임시 파일을 정리하지 못할 수 있습니다.) | ||
|
||
유용한 바로 가기 키와 명령어 | ||
============================ | ||
|
||
- ``?`` -- 함수에 대한 도움말 표시 | ||
|
||
- ``??`` -- 함수의 소스 코드 표시 | ||
|
||
- ``help()`` -- 명령 또는 클래스 매뉴얼 표시 (``q`` 종료를 위해) | ||
|
||
- ``!`` -- 어떤 UNIX 명령어를 입력하기 전에 사용하세요 | ||
|
||
- ``_`` -- 마지막 비어 있지 않은 출력 | ||
|
||
- ``__`` -- 끝에서 두 번째 비어 있지 않은 출력 | ||
|
||
- ``ih``, ``_oh`` -- 세션 명령어의 입력과 출력 목록 | ||
|
||
- :kbd:`Ctrl+r` -- 과거 명령어에서 검색하기 | ||
|
||
- ``%history`` 또는 ``%hist`` -- 현재 세션의 모든 이전 명령어 목록을 반환합니다 | ||
|
||
- ``%time`` --명령어 앞에 오고 실행 시간을 표시합니다 | ||
|
||
- ``timeit()`` -- 반복 실행 후 명령어 실행 시간 정보를 표시합니다. 명령어는 | ||
문자열로 입력됩니다 (``""`` 내부) | ||
|
||
- ``cputime()`` -- 처리 시간을 표시합니다; 예시 [1]_ | ||
|
||
- ``walltime()`` -- ``cputime()`` 와 유사한 명령어이지만 '실제' 시간을 | ||
측정합니다. 벽시계가 측정하는 것처럼 | ||
|
||
- ``%macro`` -- 매크로 명령어 생성 (여러 명령어의 단축키); 예제 [2]_. | ||
|
||
- ``logstart`` -- 세션 입력 명령어 기록 시작; ``load()`` 명령어를 사용하여 | ||
로드하고 다시 실행합니다 | ||
|
||
- ``save_session()`` -- 세션 저장 | ||
|
||
- ``load_session()`` -- 세션 불러오기 | ||
|
||
일부 예시 | ||
========= | ||
|
||
.. [1] ``cputime()`` | ||
.. skip | ||
:: | ||
|
||
sage: t = cputime() | ||
sage: a = int(1938) ^ int(99484) | ||
sage: b = 1938 ^ 99484 | ||
sage: c = pari(1938) ^ pari(99484) | ||
sage: cputime(t) | ||
0.11 | ||
|
||
.. [2] ``%macro`` | ||
.. skip | ||
:: | ||
|
||
sage: E = EllipticCurve([1,2,3,4,5]) | ||
sage: M = ModularSymbols(37) | ||
sage: %hist | ||
E = EllipticCurve([1,2,3,4,5]) | ||
M = ModularSymbols(37) | ||
%hist | ||
sage: %macro em 1-2 | ||
Macro `em` created. To execute, type its name (without quotes). | ||
=== Macro contents: === | ||
E = EllipticCurve([Integer(1),Integer(2),Integer(3),Integer(4),Integer(5)]) | ||
M = ModularSymbols(Integer(37)) |
Oops, something went wrong.