Rational
✖
Rational
詳細

- n/m の形式で有理数を入力することができる.
- パターンオブジェクト_Rationalは,有理数を表すのに使用することができる.単独の整数を表すには使用できない.
- Rational数の部分を抽出するためには,NumeratorとDenominatorを使用しなければならない.
例題
すべて開くすべて閉じる例 (1)基本的な使用例
スコープ (7)標準的な使用例のスコープの概要
In[1]:=1

✖
https://wolfram.com/xid/0ftwdq0-cs2sr3
Out[1]=1

In[1]:=1

✖
https://wolfram.com/xid/0ftwdq0-hk90qs
Out[1]=1

有理数の完全形(FullForm)はRational[numerator,denominator]である:
In[1]:=1

✖
https://wolfram.com/xid/0ftwdq0-mnsx3u

FullFormを使って有理数を入力する:
In[1]:=1

✖
https://wolfram.com/xid/0ftwdq0-hqatym
Out[1]=1

有理数(Rational)の部分抽出にはNumeratorおよびDenominatorを使う必要がある:
In[1]:=1

✖
https://wolfram.com/xid/0ftwdq0-fpote4
In[2]:=2

✖
https://wolfram.com/xid/0ftwdq0-ieh23t
Out[2]=2

Partではうまくいかない:
In[3]:=3

✖
https://wolfram.com/xid/0ftwdq0-ncd4ep

Out[3]=3

パターンオブジェクト_Rationalを使って有理数を表すことができる:
In[1]:=1

✖
https://wolfram.com/xid/0ftwdq0-bmkazl
Out[1]=1

In[2]:=2

✖
https://wolfram.com/xid/0ftwdq0-lchct
Out[2]=2

In[1]:=1

✖
https://wolfram.com/xid/0ftwdq0-qpscu
In[2]:=2

✖
https://wolfram.com/xid/0ftwdq0-b3cxcx
Out[2]=2

In[3]:=3

✖
https://wolfram.com/xid/0ftwdq0-5e47
Out[3]=3

アプリケーション (1)この関数で解くことのできる問題の例
In[1]:=1

✖
https://wolfram.com/xid/0ftwdq0-ee8rml
In[2]:=2

✖
https://wolfram.com/xid/0ftwdq0-bbrpgv
Out[2]=2

In[3]:=3

✖
https://wolfram.com/xid/0ftwdq0-b9vkay
Out[3]=3

In[4]:=4

✖
https://wolfram.com/xid/0ftwdq0-c11cev
In[5]:=5

✖
https://wolfram.com/xid/0ftwdq0-y8l48
Out[5]=5

特性と関係 (5)この関数の特性および他の関数との関係
In[1]:=1

✖
https://wolfram.com/xid/0ftwdq0-edzc7w
Out[1]=1

In[1]:=1

✖
https://wolfram.com/xid/0ftwdq0-f6kng6
Out[1]=1

In[1]:=1

✖
https://wolfram.com/xid/0ftwdq0-fz7wo1
Out[1]=1

有理数のDenominatorは正である:
In[1]:=1

✖
https://wolfram.com/xid/0ftwdq0-c29mn5
Out[1]=1

In[2]:=2

✖
https://wolfram.com/xid/0ftwdq0-c7eqv
Out[2]=2

有理数のNumeratorとDenominatorは互いに素である:
In[3]:=3

✖
https://wolfram.com/xid/0ftwdq0-iwixp2
Out[3]=3

Rationalsを使って仮定と行域条件を示す:
In[1]:=1

✖
https://wolfram.com/xid/0ftwdq0-d41svw
Out[1]=1

考えられる問題 (1)よく起る問題と予期しない動作
Wolfram Research (1988), Rational, Wolfram言語関数, https://reference.wolfram.com/language/ref/Rational.html.
✖
Wolfram Research (1988), Rational, Wolfram言語関数, https://reference.wolfram.com/language/ref/Rational.html.
テキスト
Wolfram Research (1988), Rational, Wolfram言語関数, https://reference.wolfram.com/language/ref/Rational.html.
✖
Wolfram Research (1988), Rational, Wolfram言語関数, https://reference.wolfram.com/language/ref/Rational.html.
CMS
Wolfram Language. 1988. "Rational." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/Rational.html.
✖
Wolfram Language. 1988. "Rational." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/Rational.html.
APA
Wolfram Language. (1988). Rational. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/Rational.html
✖
Wolfram Language. (1988). Rational. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/Rational.html
BibTeX
✖
@misc{reference.wolfram_2025_rational, author="Wolfram Research", title="{Rational}", year="1988", howpublished="\url{https://reference.wolfram.com/language/ref/Rational.html}", note=[Accessed: 10-May-2025
]}
BibLaTeX
✖
@online{reference.wolfram_2025_rational, organization={Wolfram Research}, title={Rational}, year={1988}, url={https://reference.wolfram.com/language/ref/Rational.html}, note=[Accessed: 10-May-2025
]}