学習環境
- Surface 3 (4G LTE)、Surface 3 タイプ カバー、Surface ペン(端末)
- Windows 10 Pro (OS)
- Nebo(Windows アプリ)
- iPad Pro + Apple Pencil
- MyScript Nebo(iPad アプリ)
- 参考書籍
数学読本〈1〉数・式の計算/方程式/不等式 (松坂 和夫(著)、岩波書店)の第1章(数学はここから始まる-数)、1.2(実数の演算と大小)、絶対値の問8.を取り組んでみる。
a または b が0の場合。
a、b が共に正の場合。
a、 b が共に負の場合。
a、 b の符号が異なる場合。
よって、
が成り立つ。
(証明終)
コード(Emacs)
Python 3
#!/usr/bin/env python3
from sympy import pprint, symbols, Rational
print('8.')
a = symbols('a', positive=True)
b = symbols('b', negative=True)
nums = [0, a, b]
for t in nums:
for s in nums:
print(abs(t * s) == abs(t) * abs(s))
入出力結果(Terminal, Jupyter(IPython))
$ ./sample10.py 8. True True True True True True True True True $
0 コメント:
コメントを投稿