Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/ActiveState/code
/ __mul__
Method
__mul__
recipes/Python/580610_Auto_differentiation/recipe-580610.py:80–82 ·
view source on GitHub ↗
(u, v)
Source
from the content-addressed store, hash-verified
78
return
Num(float(u) - float(v), d(u) - d(v))
79
80
def
__mul__(u, v):
81
u, v, du, dv = float(u), float(v), d(u), d(v)
82
return
Num(u * v, u * dv + v * du)
83
84
def
__truediv__(u, v):
85
u, v, du, dv = float(u), float(v), d(u), d(v)
Callers
nothing calls this directly
Calls
2
Num
Class · 0.70
d
Function · 0.50
Tested by
no test coverage detected