在Sympy中,函數Triangle.is_isosceles()用於檢查給定的三角形是否為等腰三角形。等腰三角形是三角形,其中兩個或更多個邊的長度相同。
用法: Triangle.is_isosceles() 返回: True: if it is isosceles, otherwise False
範例1:
# import Triangle, Point
from sympy.geometry import Triangle, Point
# using Triangle()
t1 = Triangle(Point(0, 0), Point(6, 0), Point(3, 4))
# using is_isosceles()
isIsosceles = t1.is_isosceles()
print(isIsosceles)
輸出:
True
範例2:
# import Triangle, Point
from sympy.geometry import Triangle, Point
# using Triangle()
t2 = Triangle(Point(0, 0), Point(3, 0), Point(3, 4))
# using is_isosceles()
isIsosceles = t2.is_isosceles()
print(isIsosceles)
輸出:
False
相關用法
- Python sympy.lcm()用法及代碼示例
- Python sympy.nP()用法及代碼示例
- Python sympy.nT()用法及代碼示例
- Python sympy.gcd()用法及代碼示例
- Python sympy RGS用法及代碼示例
- Python sympy.Add()用法及代碼示例
- Python sympy.lcm()用法及代碼示例
- Python sympy.gcd()用法及代碼示例
- Python sympy.div()用法及代碼示例
- Python sympy.crt()用法及代碼示例
- Python sympy.nC()用法及代碼示例
- Python sympy.sec()用法及代碼示例
- Python sympy.Mod()用法及代碼示例
- Python sympy.has()用法及代碼示例
- Python sympy.ff()用法及代碼示例
- Python sympy.rf()用法及代碼示例
- Python sympy.Pow()用法及代碼示例
- Python sympy.S()用法及代碼示例
- Python sympy.det()用法及代碼示例
- Python sympy.tan()用法及代碼示例
注:本文由純淨天空篩選整理自ravikishor大神的英文原創作品 Python – Sympy Triangle.is_isosceles() method。非經特殊聲明,原始代碼版權歸原作者所有,本譯文未經允許或授權,請勿轉載或複製。