当前位置: 首页>>代码示例>>Python>>正文


Python Basic.sin方法代码示例

本文整理汇总了Python中sympy.core.basic.Basic.sin方法的典型用法代码示例。如果您正苦于以下问题:Python Basic.sin方法的具体用法?Python Basic.sin怎么用?Python Basic.sin使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在sympy.core.basic.Basic的用法示例。


在下文中一共展示了Basic.sin方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: _eval_expand_complex

# 需要导入模块: from sympy.core.basic import Basic [as 别名]
# 或者: from sympy.core.basic.Basic import sin [as 别名]
 def _eval_expand_complex(self, *args):
     if self[0].is_real:
         return self
     re, im = self[0].as_real_imag()
     denom = sinh(re)**2 + Basic.sin(im)**2
     return (sinh(re)*cosh(re) - \
         S.ImaginaryUnit*Basic.sin(im)*Basic.cos(im))/denom
开发者ID:certik,项目名称:sympy-oldcore,代码行数:9,代码来源:hyperbolic.py

示例2: vertices

# 需要导入模块: from sympy.core.basic import Basic [as 别名]
# 或者: from sympy.core.basic.Basic import sin [as 别名]
 def vertices(self):
     Polygon.vertices.__doc__
     points = []
     c, r, n = self[:]
     v = 2*S.Pi/n
     for k in xrange(0, n):
         points.append( Point(c[0] + r*Basic.cos(k*v), c[1] + r*Basic.sin(k*v)) )
     return points
开发者ID:certik,项目名称:sympy-oldcore,代码行数:10,代码来源:polygon.py

示例3: _eval_apply

# 需要导入模块: from sympy.core.basic import Basic [as 别名]
# 或者: from sympy.core.basic.Basic import sin [as 别名]
    def _eval_apply(self, arg):
        arg = Basic.sympify(arg)

        if isinstance(arg, Basic.Number):
            if isinstance(arg, Basic.NaN):
                return S.NaN
            elif isinstance(arg, Basic.Infinity):
                return S.Infinity
            elif isinstance(arg, Basic.NegativeInfinity):
                return S.NegativeInfinity
            elif isinstance(arg, Basic.Zero):
                return S.Zero
            elif arg.is_negative:
                return -self(-arg)
        else:
            i_coeff = arg.as_coefficient(S.ImaginaryUnit)

            if i_coeff is not None:
                return S.ImaginaryUnit * Basic.sin(i_coeff)
            else:
                coeff, terms = arg.as_coeff_terms()

                if coeff.is_negative:
                    return -self(-arg)
开发者ID:certik,项目名称:sympy-oldcore,代码行数:26,代码来源:hyperbolic.py

示例4: _eval_expand_complex

# 需要导入模块: from sympy.core.basic import Basic [as 别名]
# 或者: from sympy.core.basic.Basic import sin [as 别名]
 def _eval_expand_complex(self, *args):
     re, im = self[0].as_real_imag()
     cos, sin = Basic.cos(im), Basic.sin(im)
     return exp(re) * cos + S.ImaginaryUnit * exp(re) * sin
开发者ID:certik,项目名称:sympy-oldcore,代码行数:6,代码来源:exponential.py

示例5: arbitrary_point

# 需要导入模块: from sympy.core.basic import Basic [as 别名]
# 或者: from sympy.core.basic.Basic import sin [as 别名]
 def arbitrary_point(self, parameter_name='t'):
     """Returns a symbolic point that is on the ellipse."""
     t = Basic.Symbol(parameter_name, real=True)
     return Point(
             self.center[0] + self.hradius*Basic.cos(t),
             self.center[1] + self.vradius*Basic.sin(t))
开发者ID:certik,项目名称:sympy-oldcore,代码行数:8,代码来源:ellipse.py


注:本文中的sympy.core.basic.Basic.sin方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。