diff --git a/404.html b/404.html index b665c0f..a400403 100644 --- a/404.html +++ b/404.html @@ -15,7 +15,7 @@
- + \ No newline at end of file diff --git a/api-ex.html b/api-ex.html index ffc1ae8..54943b1 100644 --- a/api-ex.html +++ b/api-ex.html @@ -453,7 +453,7 @@ }

Page Frontmatter

{
   "outline": "deep"
 }

More

Check out the documentation for the full list of runtime APIs.

- + \ No newline at end of file diff --git a/api/index.html b/api/index.html index 70aee41..3db62f8 100644 --- a/api/index.html +++ b/api/index.html @@ -18,7 +18,7 @@
Skip to content
- + \ No newline at end of file diff --git a/api/mp_math/angle.html b/api/mp_math/angle.html index e278edd..d7c3338 100644 --- a/api/mp_math/angle.html +++ b/api/mp_math/angle.html @@ -116,7 +116,7 @@ if isinstance(other, AnyAngle): return self.radian / other.radian return AnyAngle(self.radian / other, is_radian=True) - + \ No newline at end of file diff --git a/api/mp_math/const.html b/api/mp_math/const.html index c86dd9c..3bc63a8 100644 --- a/api/mp_math/const.html +++ b/api/mp_math/const.html @@ -18,7 +18,7 @@
Skip to content

var EPSILON = 0.0001

  • 说明: ε

var APPROX = 0.001

  • 说明: 约等于误差
- + \ No newline at end of file diff --git a/api/mp_math/equation.html b/api/mp_math/equation.html index 16dae5a..976f0fb 100644 --- a/api/mp_math/equation.html +++ b/api/mp_math/equation.html @@ -12,7 +12,7 @@ - + @@ -32,6 +32,14 @@ if isinstance(var, int): def partial_derivative_func(*args: Var) -> Var: + """ + @litedoc-hide + Args: + *args: + + Returns: + + """ args_list_plus = list(args) args_list_plus[var] += epsilon args_list_minus = list(args) @@ -41,6 +49,7 @@ elif isinstance(var, tuple): def high_order_partial_derivative_func(*args: Var) -> Var: + """@litedoc-hide""" result_func = func for v in var: result_func = get_partial_derivative_func(result_func, v, epsilon) @@ -70,7 +79,7 @@ return Point3(self.x_func(t[0]), self.y_func(t[0]), self.z_func(t[0])) else: return tuple([Point3(x, y, z) for x, y, z in zip(self.x_func(t), self.y_func(t), self.z_func(t))]) - + \ No newline at end of file diff --git a/api/mp_math/index.html b/api/mp_math/index.html index 4952d61..c7b1939 100644 --- a/api/mp_math/index.html +++ b/api/mp_math/index.html @@ -18,7 +18,7 @@
Skip to content
- + \ No newline at end of file diff --git a/api/mp_math/line.html b/api/mp_math/line.html index daf27d8..da4826f 100644 --- a/api/mp_math/line.html +++ b/api/mp_math/line.html @@ -195,7 +195,7 @@ """ return self.direction.is_parallel(other.direction) and (self.point - other.point).is_parallel(self.direction) - + \ No newline at end of file diff --git a/api/mp_math/mp_math_typing.html b/api/mp_math/mp_math_typing.html index 0b9d493..31267b1 100644 --- a/api/mp_math/mp_math_typing.html +++ b/api/mp_math/mp_math_typing.html @@ -18,7 +18,7 @@
Skip to content

var RealNumber = int | float

  • 类型: TypeAlias

  • 说明: 实数

var Number = RealNumber | complex

  • 类型: TypeAlias

  • 说明: 数

var SingleVar = TypeVar('SingleVar', bound=Number)

  • 说明: 单变量

var ArrayVar = TypeVar('ArrayVar', bound=Iterable[Number])

  • 说明: 数组变量

var Var = SingleVar | ArrayVar

  • 类型: TypeAlias

  • 说明: 变量

var OneSingleVarFunc = Callable[[SingleVar], SingleVar]

  • 类型: TypeAlias

  • 说明: 一元单变量函数

var OneArrayFunc = Callable[[ArrayVar], ArrayVar]

  • 类型: TypeAlias

  • 说明: 一元数组函数

var OneVarFunc = OneSingleVarFunc | OneArrayFunc

  • 类型: TypeAlias

  • 说明: 一元函数

var TwoSingleVarsFunc = Callable[[SingleVar, SingleVar], SingleVar]

  • 类型: TypeAlias

  • 说明: 二元单变量函数

var TwoArraysFunc = Callable[[ArrayVar, ArrayVar], ArrayVar]

  • 类型: TypeAlias

  • 说明: 二元数组函数

var TwoVarsFunc = TwoSingleVarsFunc | TwoArraysFunc

  • 类型: TypeAlias

  • 说明: 二元函数

var ThreeSingleVarsFunc = Callable[[SingleVar, SingleVar, SingleVar], SingleVar]

  • 类型: TypeAlias

  • 说明: 三元单变量函数

var ThreeArraysFunc = Callable[[ArrayVar, ArrayVar, ArrayVar], ArrayVar]

  • 类型: TypeAlias

  • 说明: 三元数组函数

var ThreeVarsFunc = ThreeSingleVarsFunc | ThreeArraysFunc

  • 类型: TypeAlias

  • 说明: 三元函数

var MultiSingleVarsFunc = Callable[..., SingleVar]

  • 类型: TypeAlias

  • 说明: 多元单变量函数

var MultiArraysFunc = Callable[..., ArrayVar]

  • 类型: TypeAlias

  • 说明: 多元数组函数

var MultiVarsFunc = MultiSingleVarsFunc | MultiArraysFunc

  • 类型: TypeAlias

  • 说明: 多元函数

- + \ No newline at end of file diff --git a/api/mp_math/plane.html b/api/mp_math/plane.html index f9fe0cd..215519b 100644 --- a/api/mp_math/plane.html +++ b/api/mp_math/plane.html @@ -213,7 +213,7 @@ raise TypeError(f"unsupported operand type(s) for &: 'Plane3' and '{type(other)}'")

method __eq__(self, other) -> bool

源代码
python
def __eq__(self, other) -> bool:
     return self.approx(other)

method __rand__(self, other: Line3) -> Point3

源代码
python
def __rand__(self, other: 'Line3') -> 'Point3':
     return self.cal_intersection_point3(other)
- + \ No newline at end of file diff --git a/api/mp_math/point.html b/api/mp_math/point.html index 6b5adb7..ee5ea9a 100644 --- a/api/mp_math/point.html +++ b/api/mp_math/point.html @@ -68,7 +68,7 @@ """ from .vector import Vector3 return Vector3(self.x - other.x, self.y - other.y, self.z - other.z) - + \ No newline at end of file diff --git a/api/mp_math/segment.html b/api/mp_math/segment.html index fd9e918..9a2a480 100644 --- a/api/mp_math/segment.html +++ b/api/mp_math/segment.html @@ -31,7 +31,7 @@ self.length = self.direction.length '中心点' self.midpoint = Point3((self.p1.x + self.p2.x) / 2, (self.p1.y + self.p2.y) / 2, (self.p1.z + self.p2.z) / 2) - + \ No newline at end of file diff --git a/api/mp_math/utils.html b/api/mp_math/utils.html index 561e198..360bd68 100644 --- a/api/mp_math/utils.html +++ b/api/mp_math/utils.html @@ -81,7 +81,7 @@ self.raise_type_error(other)

method raise_type_error(self, other)

源代码
python
def raise_type_error(self, other):
     raise TypeError(f'Unsupported type: {type(self.value)} and {type(other)}')

method __ne__(self, other)

源代码
python
def __ne__(self, other):
     return not self.__eq__(other)
- + \ No newline at end of file diff --git a/api/mp_math/vector.html b/api/mp_math/vector.html index 3c2dc6c..97fedbc 100644 --- a/api/mp_math/vector.html +++ b/api/mp_math/vector.html @@ -204,7 +204,7 @@ return self.x * other.x + self.y * other.y + self.z * other.z

method self / other: RealNumber => Vector3

源代码
python
def __truediv__(self, other: RealNumber) -> 'Vector3':
     return Vector3(self.x / other, self.y / other, self.z / other)

method - self

源代码
python
def __neg__(self):
     return Vector3(-self.x, -self.y, -self.z)

var zero_vector3 = Vector3(0, 0, 0)

var x_axis = Vector3(1, 0, 0)

var y_axis = Vector3(0, 1, 0)

var z_axis = Vector3(0, 0, 1)

- + \ No newline at end of file diff --git a/api/particle/index.html b/api/particle/index.html index 616edc3..b18f34e 100644 --- a/api/particle/index.html +++ b/api/particle/index.html @@ -18,7 +18,7 @@
Skip to content
- + \ No newline at end of file diff --git a/api/presets/index.html b/api/presets/index.html index 7ad81f6..afc89e0 100644 --- a/api/presets/index.html +++ b/api/presets/index.html @@ -18,7 +18,7 @@
Skip to content
- + \ No newline at end of file diff --git a/api/presets/model/index.html b/api/presets/model/index.html index ea35564..80028a4 100644 --- a/api/presets/model/index.html +++ b/api/presets/model/index.html @@ -35,7 +35,7 @@ y_array = radius * np.sin(phi_list) * np.sin(theta_list) z_array = radius * np.cos(phi_list) return [Point3(x_array[i], y_array[i], z_array[i]) for i in range(num)] - + \ No newline at end of file diff --git a/assets/api_mp_math_equation.md.BcXDoPv-.js b/assets/api_mp_math_equation.md.Cn4Dbi_N.js similarity index 94% rename from assets/api_mp_math_equation.md.BcXDoPv-.js rename to assets/api_mp_math_equation.md.Cn4Dbi_N.js index 6be8850..e6df063 100644 --- a/assets/api_mp_math_equation.md.BcXDoPv-.js +++ b/assets/api_mp_math_equation.md.Cn4Dbi_N.js @@ -1,4 +1,4 @@ -import{_ as s,c as i,o as a,a2 as n}from"./chunks/framework.BV61Qrc0.js";const u=JSON.parse('{"title":"mbcp.mp_math.equation","description":"","frontmatter":{"title":"mbcp.mp_math.equation"},"headers":[],"relativePath":"api/mp_math/equation.md","filePath":"api/mp_math/equation.md"}'),l={name:"api/mp_math/equation.md"},t=n(`

func get_partial_derivative_func(func: MultiVarsFunc = EPSILON) -> MultiVarsFunc

说明: 求N元函数一阶偏导函数。这玩意不太稳定,慎用。

参数:

返回: 偏导函数

引发:

源代码
python
def get_partial_derivative_func(func: MultiVarsFunc, var: int | tuple[int, ...], epsilon: Number=EPSILON) -> MultiVarsFunc:
+import{_ as s,c as i,o as a,a2 as n}from"./chunks/framework.BV61Qrc0.js";const F=JSON.parse('{"title":"mbcp.mp_math.equation","description":"","frontmatter":{"title":"mbcp.mp_math.equation"},"headers":[],"relativePath":"api/mp_math/equation.md","filePath":"api/mp_math/equation.md"}'),l={name:"api/mp_math/equation.md"},t=n(`

func get_partial_derivative_func(func: MultiVarsFunc = EPSILON) -> MultiVarsFunc

说明: 求N元函数一阶偏导函数。这玩意不太稳定,慎用。

参数:

  • func: 函数
  • var: 变量位置,可为整数(一阶偏导)或整数元组(高阶偏导)
  • epsilon: 偏移量

返回: 偏导函数

引发:

  • ValueError 无效变量类型
源代码
python
def get_partial_derivative_func(func: MultiVarsFunc, var: int | tuple[int, ...], epsilon: Number=EPSILON) -> MultiVarsFunc:
     """
     求N元函数一阶偏导函数。这玩意不太稳定,慎用。
     Args:
@@ -13,6 +13,14 @@ import{_ as s,c as i,o as a,a2 as n}from"./chunks/framework.BV61Qrc0.js";const u
     if isinstance(var, int):
 
         def partial_derivative_func(*args: Var) -> Var:
+            """
+            @litedoc-hide
+            Args:
+                *args:
+
+            Returns:
+
+            """
             args_list_plus = list(args)
             args_list_plus[var] += epsilon
             args_list_minus = list(args)
@@ -22,6 +30,7 @@ import{_ as s,c as i,o as a,a2 as n}from"./chunks/framework.BV61Qrc0.js";const u
     elif isinstance(var, tuple):
 
         def high_order_partial_derivative_func(*args: Var) -> Var:
+            """@litedoc-hide"""
             result_func = func
             for v in var:
                 result_func = get_partial_derivative_func(result_func, v, epsilon)
@@ -50,4 +59,4 @@ import{_ as s,c as i,o as a,a2 as n}from"./chunks/framework.BV61Qrc0.js";const u
     if len(t) == 1:
         return Point3(self.x_func(t[0]), self.y_func(t[0]), self.z_func(t[0]))
     else:
-        return tuple([Point3(x, y, z) for x, y, z in zip(self.x_func(t), self.y_func(t), self.z_func(t))])
`,19),h=[t];function p(k,e,r,E,d,g){return a(),i("div",null,h)}const y=s(l,[["render",p]]);export{u as __pageData,y as default}; + return tuple([Point3(x, y, z) for x, y, z in zip(self.x_func(t), self.y_func(t), self.z_func(t))])
`,19),h=[t];function p(k,e,r,E,d,g){return a(),i("div",null,h)}const u=s(l,[["render",p]]);export{F as __pageData,u as default}; diff --git a/assets/api_mp_math_equation.md.BcXDoPv-.lean.js b/assets/api_mp_math_equation.md.Cn4Dbi_N.lean.js similarity index 71% rename from assets/api_mp_math_equation.md.BcXDoPv-.lean.js rename to assets/api_mp_math_equation.md.Cn4Dbi_N.lean.js index af2da64..ab9b8a3 100644 --- a/assets/api_mp_math_equation.md.BcXDoPv-.lean.js +++ b/assets/api_mp_math_equation.md.Cn4Dbi_N.lean.js @@ -1 +1 @@ -import{_ as s,c as i,o as a,a2 as n}from"./chunks/framework.BV61Qrc0.js";const u=JSON.parse('{"title":"mbcp.mp_math.equation","description":"","frontmatter":{"title":"mbcp.mp_math.equation"},"headers":[],"relativePath":"api/mp_math/equation.md","filePath":"api/mp_math/equation.md"}'),l={name:"api/mp_math/equation.md"},t=n("",19),h=[t];function p(k,e,r,E,d,g){return a(),i("div",null,h)}const y=s(l,[["render",p]]);export{u as __pageData,y as default}; +import{_ as s,c as i,o as a,a2 as n}from"./chunks/framework.BV61Qrc0.js";const F=JSON.parse('{"title":"mbcp.mp_math.equation","description":"","frontmatter":{"title":"mbcp.mp_math.equation"},"headers":[],"relativePath":"api/mp_math/equation.md","filePath":"api/mp_math/equation.md"}'),l={name:"api/mp_math/equation.md"},t=n("",19),h=[t];function p(k,e,r,E,d,g){return a(),i("div",null,h)}const u=s(l,[["render",p]]);export{F as __pageData,u as default}; diff --git a/assets/en_api_mp_math_equation.md.CiUDCfZP.js b/assets/en_api_mp_math_equation.md.DU8q_g4G.js similarity index 94% rename from assets/en_api_mp_math_equation.md.CiUDCfZP.js rename to assets/en_api_mp_math_equation.md.DU8q_g4G.js index 45e3b0d..5669c7c 100644 --- a/assets/en_api_mp_math_equation.md.CiUDCfZP.js +++ b/assets/en_api_mp_math_equation.md.DU8q_g4G.js @@ -13,6 +13,14 @@ import{_ as s,c as i,o as a,a2 as n}from"./chunks/framework.BV61Qrc0.js";const u if isinstance(var, int): def partial_derivative_func(*args: Var) -> Var: + """ + @litedoc-hide + Args: + *args: + + Returns: + + """ args_list_plus = list(args) args_list_plus[var] += epsilon args_list_minus = list(args) @@ -22,6 +30,7 @@ import{_ as s,c as i,o as a,a2 as n}from"./chunks/framework.BV61Qrc0.js";const u elif isinstance(var, tuple): def high_order_partial_derivative_func(*args: Var) -> Var: + """@litedoc-hide""" result_func = func for v in var: result_func = get_partial_derivative_func(result_func, v, epsilon) @@ -50,4 +59,4 @@ import{_ as s,c as i,o as a,a2 as n}from"./chunks/framework.BV61Qrc0.js";const u if len(t) == 1: return Point3(self.x_func(t[0]), self.y_func(t[0]), self.z_func(t[0])) else: - return tuple([Point3(x, y, z) for x, y, z in zip(self.x_func(t), self.y_func(t), self.z_func(t))])`,19),h=[t];function p(k,e,r,E,d,g){return a(),i("div",null,h)}const y=s(l,[["render",p]]);export{u as __pageData,y as default}; + return tuple([Point3(x, y, z) for x, y, z in zip(self.x_func(t), self.y_func(t), self.z_func(t))])`,19),h=[t];function p(k,e,r,E,d,g){return a(),i("div",null,h)}const F=s(l,[["render",p]]);export{u as __pageData,F as default}; diff --git a/assets/en_api_mp_math_equation.md.CiUDCfZP.lean.js b/assets/en_api_mp_math_equation.md.DU8q_g4G.lean.js similarity index 82% rename from assets/en_api_mp_math_equation.md.CiUDCfZP.lean.js rename to assets/en_api_mp_math_equation.md.DU8q_g4G.lean.js index 2a24e62..31b29d2 100644 --- a/assets/en_api_mp_math_equation.md.CiUDCfZP.lean.js +++ b/assets/en_api_mp_math_equation.md.DU8q_g4G.lean.js @@ -1 +1 @@ -import{_ as s,c as i,o as a,a2 as n}from"./chunks/framework.BV61Qrc0.js";const u=JSON.parse('{"title":"mbcp.mp_math.equation","description":"","frontmatter":{"title":"mbcp.mp_math.equation"},"headers":[],"relativePath":"en/api/mp_math/equation.md","filePath":"en/api/mp_math/equation.md"}'),l={name:"en/api/mp_math/equation.md"},t=n("",19),h=[t];function p(k,e,r,E,d,g){return a(),i("div",null,h)}const y=s(l,[["render",p]]);export{u as __pageData,y as default}; +import{_ as s,c as i,o as a,a2 as n}from"./chunks/framework.BV61Qrc0.js";const u=JSON.parse('{"title":"mbcp.mp_math.equation","description":"","frontmatter":{"title":"mbcp.mp_math.equation"},"headers":[],"relativePath":"en/api/mp_math/equation.md","filePath":"en/api/mp_math/equation.md"}'),l={name:"en/api/mp_math/equation.md"},t=n("",19),h=[t];function p(k,e,r,E,d,g){return a(),i("div",null,h)}const F=s(l,[["render",p]]);export{u as __pageData,F as default}; diff --git a/assets/ja_api_mp_math_equation.md.O5E3UAo5.js b/assets/ja_api_mp_math_equation.md.-GejNICN.js similarity index 94% rename from assets/ja_api_mp_math_equation.md.O5E3UAo5.js rename to assets/ja_api_mp_math_equation.md.-GejNICN.js index ccfe044..a68f6f8 100644 --- a/assets/ja_api_mp_math_equation.md.O5E3UAo5.js +++ b/assets/ja_api_mp_math_equation.md.-GejNICN.js @@ -1,4 +1,4 @@ -import{_ as s,c as i,o as a,a2 as n}from"./chunks/framework.BV61Qrc0.js";const u=JSON.parse('{"title":"mbcp.mp_math.equation","description":"","frontmatter":{"title":"mbcp.mp_math.equation"},"headers":[],"relativePath":"ja/api/mp_math/equation.md","filePath":"ja/api/mp_math/equation.md"}'),l={name:"ja/api/mp_math/equation.md"},t=n(`

func get_partial_derivative_func(func: MultiVarsFunc = EPSILON) -> MultiVarsFunc

説明: 求N元函数一阶偏导函数。这玩意不太稳定,慎用。

引数:

戻り値: 偏导函数

例外:

ソースコード
python
def get_partial_derivative_func(func: MultiVarsFunc, var: int | tuple[int, ...], epsilon: Number=EPSILON) -> MultiVarsFunc:
+import{_ as s,c as i,o as a,a2 as n}from"./chunks/framework.BV61Qrc0.js";const F=JSON.parse('{"title":"mbcp.mp_math.equation","description":"","frontmatter":{"title":"mbcp.mp_math.equation"},"headers":[],"relativePath":"ja/api/mp_math/equation.md","filePath":"ja/api/mp_math/equation.md"}'),l={name:"ja/api/mp_math/equation.md"},t=n(`

func get_partial_derivative_func(func: MultiVarsFunc = EPSILON) -> MultiVarsFunc

説明: 求N元函数一阶偏导函数。这玩意不太稳定,慎用。

引数:

  • func: 函数
  • var: 变量位置,可为整数(一阶偏导)或整数元组(高阶偏导)
  • epsilon: 偏移量

戻り値: 偏导函数

例外:

  • ValueError 无效变量类型
ソースコード
python
def get_partial_derivative_func(func: MultiVarsFunc, var: int | tuple[int, ...], epsilon: Number=EPSILON) -> MultiVarsFunc:
     """
     求N元函数一阶偏导函数。这玩意不太稳定,慎用。
     Args:
@@ -13,6 +13,14 @@ import{_ as s,c as i,o as a,a2 as n}from"./chunks/framework.BV61Qrc0.js";const u
     if isinstance(var, int):
 
         def partial_derivative_func(*args: Var) -> Var:
+            """
+            @litedoc-hide
+            Args:
+                *args:
+
+            Returns:
+
+            """
             args_list_plus = list(args)
             args_list_plus[var] += epsilon
             args_list_minus = list(args)
@@ -22,6 +30,7 @@ import{_ as s,c as i,o as a,a2 as n}from"./chunks/framework.BV61Qrc0.js";const u
     elif isinstance(var, tuple):
 
         def high_order_partial_derivative_func(*args: Var) -> Var:
+            """@litedoc-hide"""
             result_func = func
             for v in var:
                 result_func = get_partial_derivative_func(result_func, v, epsilon)
@@ -50,4 +59,4 @@ import{_ as s,c as i,o as a,a2 as n}from"./chunks/framework.BV61Qrc0.js";const u
     if len(t) == 1:
         return Point3(self.x_func(t[0]), self.y_func(t[0]), self.z_func(t[0]))
     else:
-        return tuple([Point3(x, y, z) for x, y, z in zip(self.x_func(t), self.y_func(t), self.z_func(t))])
`,19),h=[t];function p(k,e,r,E,d,g){return a(),i("div",null,h)}const y=s(l,[["render",p]]);export{u as __pageData,y as default}; + return tuple([Point3(x, y, z) for x, y, z in zip(self.x_func(t), self.y_func(t), self.z_func(t))])
`,19),h=[t];function p(k,e,r,E,d,g){return a(),i("div",null,h)}const u=s(l,[["render",p]]);export{F as __pageData,u as default}; diff --git a/assets/ja_api_mp_math_equation.md.O5E3UAo5.lean.js b/assets/ja_api_mp_math_equation.md.-GejNICN.lean.js similarity index 69% rename from assets/ja_api_mp_math_equation.md.O5E3UAo5.lean.js rename to assets/ja_api_mp_math_equation.md.-GejNICN.lean.js index e36dd60..cef2091 100644 --- a/assets/ja_api_mp_math_equation.md.O5E3UAo5.lean.js +++ b/assets/ja_api_mp_math_equation.md.-GejNICN.lean.js @@ -1 +1 @@ -import{_ as s,c as i,o as a,a2 as n}from"./chunks/framework.BV61Qrc0.js";const u=JSON.parse('{"title":"mbcp.mp_math.equation","description":"","frontmatter":{"title":"mbcp.mp_math.equation"},"headers":[],"relativePath":"ja/api/mp_math/equation.md","filePath":"ja/api/mp_math/equation.md"}'),l={name:"ja/api/mp_math/equation.md"},t=n("",19),h=[t];function p(k,e,r,E,d,g){return a(),i("div",null,h)}const y=s(l,[["render",p]]);export{u as __pageData,y as default}; +import{_ as s,c as i,o as a,a2 as n}from"./chunks/framework.BV61Qrc0.js";const F=JSON.parse('{"title":"mbcp.mp_math.equation","description":"","frontmatter":{"title":"mbcp.mp_math.equation"},"headers":[],"relativePath":"ja/api/mp_math/equation.md","filePath":"ja/api/mp_math/equation.md"}'),l={name:"ja/api/mp_math/equation.md"},t=n("",19),h=[t];function p(k,e,r,E,d,g){return a(),i("div",null,h)}const u=s(l,[["render",p]]);export{F as __pageData,u as default}; diff --git a/assets/zht_api_mp_math_equation.md.CXSb9fP6.js b/assets/zht_api_mp_math_equation.md.MGSqd_Ep.js similarity index 94% rename from assets/zht_api_mp_math_equation.md.CXSb9fP6.js rename to assets/zht_api_mp_math_equation.md.MGSqd_Ep.js index 22dae6b..c29835b 100644 --- a/assets/zht_api_mp_math_equation.md.CXSb9fP6.js +++ b/assets/zht_api_mp_math_equation.md.MGSqd_Ep.js @@ -1,4 +1,4 @@ -import{_ as s,c as i,o as a,a2 as n}from"./chunks/framework.BV61Qrc0.js";const u=JSON.parse('{"title":"mbcp.mp_math.equation","description":"","frontmatter":{"title":"mbcp.mp_math.equation"},"headers":[],"relativePath":"zht/api/mp_math/equation.md","filePath":"zht/api/mp_math/equation.md"}'),l={name:"zht/api/mp_math/equation.md"},t=n(`

func get_partial_derivative_func(func: MultiVarsFunc = EPSILON) -> MultiVarsFunc

説明: 求N元函数一阶偏导函数。这玩意不太稳定,慎用。

變數説明:

返回: 偏导函数

抛出:

源碼
python
def get_partial_derivative_func(func: MultiVarsFunc, var: int | tuple[int, ...], epsilon: Number=EPSILON) -> MultiVarsFunc:
+import{_ as s,c as i,o as a,a2 as n}from"./chunks/framework.BV61Qrc0.js";const F=JSON.parse('{"title":"mbcp.mp_math.equation","description":"","frontmatter":{"title":"mbcp.mp_math.equation"},"headers":[],"relativePath":"zht/api/mp_math/equation.md","filePath":"zht/api/mp_math/equation.md"}'),l={name:"zht/api/mp_math/equation.md"},t=n(`

func get_partial_derivative_func(func: MultiVarsFunc = EPSILON) -> MultiVarsFunc

説明: 求N元函数一阶偏导函数。这玩意不太稳定,慎用。

變數説明:

  • func: 函数
  • var: 变量位置,可为整数(一阶偏导)或整数元组(高阶偏导)
  • epsilon: 偏移量

返回: 偏导函数

抛出:

  • ValueError 无效变量类型
源碼
python
def get_partial_derivative_func(func: MultiVarsFunc, var: int | tuple[int, ...], epsilon: Number=EPSILON) -> MultiVarsFunc:
     """
     求N元函数一阶偏导函数。这玩意不太稳定,慎用。
     Args:
@@ -13,6 +13,14 @@ import{_ as s,c as i,o as a,a2 as n}from"./chunks/framework.BV61Qrc0.js";const u
     if isinstance(var, int):
 
         def partial_derivative_func(*args: Var) -> Var:
+            """
+            @litedoc-hide
+            Args:
+                *args:
+
+            Returns:
+
+            """
             args_list_plus = list(args)
             args_list_plus[var] += epsilon
             args_list_minus = list(args)
@@ -22,6 +30,7 @@ import{_ as s,c as i,o as a,a2 as n}from"./chunks/framework.BV61Qrc0.js";const u
     elif isinstance(var, tuple):
 
         def high_order_partial_derivative_func(*args: Var) -> Var:
+            """@litedoc-hide"""
             result_func = func
             for v in var:
                 result_func = get_partial_derivative_func(result_func, v, epsilon)
@@ -50,4 +59,4 @@ import{_ as s,c as i,o as a,a2 as n}from"./chunks/framework.BV61Qrc0.js";const u
     if len(t) == 1:
         return Point3(self.x_func(t[0]), self.y_func(t[0]), self.z_func(t[0]))
     else:
-        return tuple([Point3(x, y, z) for x, y, z in zip(self.x_func(t), self.y_func(t), self.z_func(t))])
`,19),h=[t];function p(k,e,r,E,d,g){return a(),i("div",null,h)}const y=s(l,[["render",p]]);export{u as __pageData,y as default}; + return tuple([Point3(x, y, z) for x, y, z in zip(self.x_func(t), self.y_func(t), self.z_func(t))])
`,19),h=[t];function p(k,e,r,E,d,g){return a(),i("div",null,h)}const u=s(l,[["render",p]]);export{F as __pageData,u as default}; diff --git a/assets/zht_api_mp_math_equation.md.CXSb9fP6.lean.js b/assets/zht_api_mp_math_equation.md.MGSqd_Ep.lean.js similarity index 68% rename from assets/zht_api_mp_math_equation.md.CXSb9fP6.lean.js rename to assets/zht_api_mp_math_equation.md.MGSqd_Ep.lean.js index a050cc7..7559bab 100644 --- a/assets/zht_api_mp_math_equation.md.CXSb9fP6.lean.js +++ b/assets/zht_api_mp_math_equation.md.MGSqd_Ep.lean.js @@ -1 +1 @@ -import{_ as s,c as i,o as a,a2 as n}from"./chunks/framework.BV61Qrc0.js";const u=JSON.parse('{"title":"mbcp.mp_math.equation","description":"","frontmatter":{"title":"mbcp.mp_math.equation"},"headers":[],"relativePath":"zht/api/mp_math/equation.md","filePath":"zht/api/mp_math/equation.md"}'),l={name:"zht/api/mp_math/equation.md"},t=n("",19),h=[t];function p(k,e,r,E,d,g){return a(),i("div",null,h)}const y=s(l,[["render",p]]);export{u as __pageData,y as default}; +import{_ as s,c as i,o as a,a2 as n}from"./chunks/framework.BV61Qrc0.js";const F=JSON.parse('{"title":"mbcp.mp_math.equation","description":"","frontmatter":{"title":"mbcp.mp_math.equation"},"headers":[],"relativePath":"zht/api/mp_math/equation.md","filePath":"zht/api/mp_math/equation.md"}'),l={name:"zht/api/mp_math/equation.md"},t=n("",19),h=[t];function p(k,e,r,E,d,g){return a(),i("div",null,h)}const u=s(l,[["render",p]]);export{F as __pageData,u as default}; diff --git a/en/api/index.html b/en/api/index.html index 4194fe9..9914944 100644 --- a/en/api/index.html +++ b/en/api/index.html @@ -18,7 +18,7 @@
Skip to content
- + \ No newline at end of file diff --git a/en/api/mp_math/angle.html b/en/api/mp_math/angle.html index 7d18f38..9d07d0b 100644 --- a/en/api/mp_math/angle.html +++ b/en/api/mp_math/angle.html @@ -116,7 +116,7 @@ if isinstance(other, AnyAngle): return self.radian / other.radian return AnyAngle(self.radian / other, is_radian=True) - + \ No newline at end of file diff --git a/en/api/mp_math/const.html b/en/api/mp_math/const.html index 531b388..2689be7 100644 --- a/en/api/mp_math/const.html +++ b/en/api/mp_math/const.html @@ -18,7 +18,7 @@
Skip to content

var EPSILON = 0.0001

  • Description: ε

var APPROX = 0.001

  • Description: 约等于误差
- + \ No newline at end of file diff --git a/en/api/mp_math/equation.html b/en/api/mp_math/equation.html index ecad321..acbde78 100644 --- a/en/api/mp_math/equation.html +++ b/en/api/mp_math/equation.html @@ -12,7 +12,7 @@ - + @@ -32,6 +32,14 @@ if isinstance(var, int): def partial_derivative_func(*args: Var) -> Var: + """ + @litedoc-hide + Args: + *args: + + Returns: + + """ args_list_plus = list(args) args_list_plus[var] += epsilon args_list_minus = list(args) @@ -41,6 +49,7 @@ elif isinstance(var, tuple): def high_order_partial_derivative_func(*args: Var) -> Var: + """@litedoc-hide""" result_func = func for v in var: result_func = get_partial_derivative_func(result_func, v, epsilon) @@ -70,7 +79,7 @@ return Point3(self.x_func(t[0]), self.y_func(t[0]), self.z_func(t[0])) else: return tuple([Point3(x, y, z) for x, y, z in zip(self.x_func(t), self.y_func(t), self.z_func(t))]) - + \ No newline at end of file diff --git a/en/api/mp_math/index.html b/en/api/mp_math/index.html index 18a2dd4..551254d 100644 --- a/en/api/mp_math/index.html +++ b/en/api/mp_math/index.html @@ -18,7 +18,7 @@
Skip to content
- + \ No newline at end of file diff --git a/en/api/mp_math/line.html b/en/api/mp_math/line.html index a371576..147d978 100644 --- a/en/api/mp_math/line.html +++ b/en/api/mp_math/line.html @@ -195,7 +195,7 @@ """ return self.direction.is_parallel(other.direction) and (self.point - other.point).is_parallel(self.direction) - + \ No newline at end of file diff --git a/en/api/mp_math/mp_math_typing.html b/en/api/mp_math/mp_math_typing.html index 2c2424b..b8e1636 100644 --- a/en/api/mp_math/mp_math_typing.html +++ b/en/api/mp_math/mp_math_typing.html @@ -18,7 +18,7 @@
Skip to content

var RealNumber = int | float

  • Type: TypeAlias

  • Description: 实数

var Number = RealNumber | complex

  • Type: TypeAlias

  • Description: 数

var SingleVar = TypeVar('SingleVar', bound=Number)

  • Description: 单变量

var ArrayVar = TypeVar('ArrayVar', bound=Iterable[Number])

  • Description: 数组变量

var Var = SingleVar | ArrayVar

  • Type: TypeAlias

  • Description: 变量

var OneSingleVarFunc = Callable[[SingleVar], SingleVar]

  • Type: TypeAlias

  • Description: 一元单变量函数

var OneArrayFunc = Callable[[ArrayVar], ArrayVar]

  • Type: TypeAlias

  • Description: 一元数组函数

var OneVarFunc = OneSingleVarFunc | OneArrayFunc

  • Type: TypeAlias

  • Description: 一元函数

var TwoSingleVarsFunc = Callable[[SingleVar, SingleVar], SingleVar]

  • Type: TypeAlias

  • Description: 二元单变量函数

var TwoArraysFunc = Callable[[ArrayVar, ArrayVar], ArrayVar]

  • Type: TypeAlias

  • Description: 二元数组函数

var TwoVarsFunc = TwoSingleVarsFunc | TwoArraysFunc

  • Type: TypeAlias

  • Description: 二元函数

var ThreeSingleVarsFunc = Callable[[SingleVar, SingleVar, SingleVar], SingleVar]

  • Type: TypeAlias

  • Description: 三元单变量函数

var ThreeArraysFunc = Callable[[ArrayVar, ArrayVar, ArrayVar], ArrayVar]

  • Type: TypeAlias

  • Description: 三元数组函数

var ThreeVarsFunc = ThreeSingleVarsFunc | ThreeArraysFunc

  • Type: TypeAlias

  • Description: 三元函数

var MultiSingleVarsFunc = Callable[..., SingleVar]

  • Type: TypeAlias

  • Description: 多元单变量函数

var MultiArraysFunc = Callable[..., ArrayVar]

  • Type: TypeAlias

  • Description: 多元数组函数

var MultiVarsFunc = MultiSingleVarsFunc | MultiArraysFunc

  • Type: TypeAlias

  • Description: 多元函数

- + \ No newline at end of file diff --git a/en/api/mp_math/plane.html b/en/api/mp_math/plane.html index 180d41e..b5e713d 100644 --- a/en/api/mp_math/plane.html +++ b/en/api/mp_math/plane.html @@ -213,7 +213,7 @@ raise TypeError(f"unsupported operand type(s) for &: 'Plane3' and '{type(other)}'")

method __eq__(self, other) -> bool

Source code
python
def __eq__(self, other) -> bool:
     return self.approx(other)

method __rand__(self, other: Line3) -> Point3

Source code
python
def __rand__(self, other: 'Line3') -> 'Point3':
     return self.cal_intersection_point3(other)
- + \ No newline at end of file diff --git a/en/api/mp_math/point.html b/en/api/mp_math/point.html index 9d3d98f..f7c46a7 100644 --- a/en/api/mp_math/point.html +++ b/en/api/mp_math/point.html @@ -68,7 +68,7 @@ """ from .vector import Vector3 return Vector3(self.x - other.x, self.y - other.y, self.z - other.z) - + \ No newline at end of file diff --git a/en/api/mp_math/segment.html b/en/api/mp_math/segment.html index dcdcd6c..18a3997 100644 --- a/en/api/mp_math/segment.html +++ b/en/api/mp_math/segment.html @@ -31,7 +31,7 @@ self.length = self.direction.length '中心点' self.midpoint = Point3((self.p1.x + self.p2.x) / 2, (self.p1.y + self.p2.y) / 2, (self.p1.z + self.p2.z) / 2) - + \ No newline at end of file diff --git a/en/api/mp_math/utils.html b/en/api/mp_math/utils.html index 13e7990..5e3c700 100644 --- a/en/api/mp_math/utils.html +++ b/en/api/mp_math/utils.html @@ -81,7 +81,7 @@ self.raise_type_error(other)

method raise_type_error(self, other)

Source code
python
def raise_type_error(self, other):
     raise TypeError(f'Unsupported type: {type(self.value)} and {type(other)}')

method __ne__(self, other)

Source code
python
def __ne__(self, other):
     return not self.__eq__(other)
- + \ No newline at end of file diff --git a/en/api/mp_math/vector.html b/en/api/mp_math/vector.html index ec1fbfa..bf25036 100644 --- a/en/api/mp_math/vector.html +++ b/en/api/mp_math/vector.html @@ -204,7 +204,7 @@ return self.x * other.x + self.y * other.y + self.z * other.z

method self / other: RealNumber => Vector3

Source code
python
def __truediv__(self, other: RealNumber) -> 'Vector3':
     return Vector3(self.x / other, self.y / other, self.z / other)

method - self

Source code
python
def __neg__(self):
     return Vector3(-self.x, -self.y, -self.z)

var zero_vector3 = Vector3(0, 0, 0)

var x_axis = Vector3(1, 0, 0)

var y_axis = Vector3(0, 1, 0)

var z_axis = Vector3(0, 0, 1)

- + \ No newline at end of file diff --git a/en/api/particle/index.html b/en/api/particle/index.html index d312d8e..7690671 100644 --- a/en/api/particle/index.html +++ b/en/api/particle/index.html @@ -18,7 +18,7 @@
Skip to content
- + \ No newline at end of file diff --git a/en/api/presets/index.html b/en/api/presets/index.html index e22f674..5111229 100644 --- a/en/api/presets/index.html +++ b/en/api/presets/index.html @@ -18,7 +18,7 @@
Skip to content
- + \ No newline at end of file diff --git a/en/api/presets/model/index.html b/en/api/presets/model/index.html index cca9a17..ba4b9f3 100644 --- a/en/api/presets/model/index.html +++ b/en/api/presets/model/index.html @@ -35,7 +35,7 @@ y_array = radius * np.sin(phi_list) * np.sin(theta_list) z_array = radius * np.cos(phi_list) return [Point3(x_array[i], y_array[i], z_array[i]) for i in range(num)] - + \ No newline at end of file diff --git a/guide/index.html b/guide/index.html index 2d11489..ff58711 100644 --- a/guide/index.html +++ b/guide/index.html @@ -18,7 +18,7 @@
Skip to content

开始不了一点

- + \ No newline at end of file diff --git a/hashmap.json b/hashmap.json index 873cf17..60c9fd1 100644 --- a/hashmap.json +++ b/hashmap.json @@ -1 +1 @@ -{"api-ex.md":"DOsKaL8H","api_index.md":"BvazTqTB","api_mp_math_angle.md":"B8w0LP6o","api_mp_math_const.md":"D9zs7__H","api_mp_math_equation.md":"BcXDoPv-","api_mp_math_index.md":"4P0hk6gb","api_mp_math_line.md":"B1jAKPr1","api_mp_math_mp_math_typing.md":"COrE_fd3","api_mp_math_plane.md":"DLB54RNP","api_mp_math_point.md":"BwXaSbuz","api_mp_math_segment.md":"C6i78ST1","api_mp_math_utils.md":"Bkx3QJ6f","api_mp_math_vector.md":"Efti6kdT","api_particle_index.md":"BRCSxC3e","api_presets_index.md":"Dl6Ss91J","api_presets_model_index.md":"DY6YMRqf","en_api_index.md":"Bgu-LD1B","en_api_mp_math_angle.md":"DmK_A9xI","en_api_mp_math_const.md":"D_Flpj8t","en_api_mp_math_equation.md":"CiUDCfZP","en_api_mp_math_index.md":"DrjDUYBY","en_api_mp_math_line.md":"BBlzflWh","en_api_mp_math_mp_math_typing.md":"CyXXFdS4","en_api_mp_math_plane.md":"cxytQLD4","en_api_mp_math_point.md":"CXQGh5Zt","en_api_mp_math_segment.md":"CxreVgqR","en_api_mp_math_utils.md":"aavLLFMy","en_api_mp_math_vector.md":"BvKJEw7_","en_api_particle_index.md":"CmC1QX5o","en_api_presets_index.md":"CZ5hl_7D","en_api_presets_model_index.md":"DBfUZUBC","guide_index.md":"BE2yloik","index.md":"BE1qChTt","ja_api_index.md":"4BnflFIm","ja_api_mp_math_angle.md":"DxBe_g0o","ja_api_mp_math_const.md":"CyaIJkFx","ja_api_mp_math_equation.md":"O5E3UAo5","ja_api_mp_math_index.md":"CSAMHYsB","ja_api_mp_math_line.md":"CMfQT6TH","ja_api_mp_math_mp_math_typing.md":"Bl5kyhpI","ja_api_mp_math_plane.md":"Cm4a8eqF","ja_api_mp_math_point.md":"CQAIjHfb","ja_api_mp_math_segment.md":"D0U5bMSu","ja_api_mp_math_utils.md":"CXGqGLUs","ja_api_mp_math_vector.md":"C9TtayJk","ja_api_particle_index.md":"E2YnH7EN","ja_api_presets_index.md":"ATGcHt9d","ja_api_presets_model_index.md":"DAVK1sDI","md-ex.md":"BX0WqOqv","zht_api_index.md":"Dq4XPUKZ","zht_api_mp_math_angle.md":"_4N19GGe","zht_api_mp_math_const.md":"B8uQOIr_","zht_api_mp_math_equation.md":"CXSb9fP6","zht_api_mp_math_index.md":"D09y2ubg","zht_api_mp_math_line.md":"4ncoPmkZ","zht_api_mp_math_mp_math_typing.md":"DLx0IibM","zht_api_mp_math_plane.md":"Buk-SLcC","zht_api_mp_math_point.md":"Bb3tyGv-","zht_api_mp_math_segment.md":"U_lS4vUA","zht_api_mp_math_utils.md":"ig9jQkoA","zht_api_mp_math_vector.md":"CDyAXuJb","zht_api_particle_index.md":"kAm9VAEw","zht_api_presets_index.md":"BmouaEaT","zht_api_presets_model_index.md":"CrdAyyCM"} +{"api-ex.md":"DOsKaL8H","api_index.md":"BvazTqTB","api_mp_math_angle.md":"B8w0LP6o","api_mp_math_const.md":"D9zs7__H","api_mp_math_equation.md":"Cn4Dbi_N","api_mp_math_index.md":"4P0hk6gb","api_mp_math_line.md":"B1jAKPr1","api_mp_math_mp_math_typing.md":"COrE_fd3","api_mp_math_plane.md":"DLB54RNP","api_mp_math_point.md":"BwXaSbuz","api_mp_math_segment.md":"C6i78ST1","api_mp_math_utils.md":"Bkx3QJ6f","api_mp_math_vector.md":"Efti6kdT","api_particle_index.md":"BRCSxC3e","api_presets_index.md":"Dl6Ss91J","api_presets_model_index.md":"DY6YMRqf","en_api_index.md":"Bgu-LD1B","en_api_mp_math_angle.md":"DmK_A9xI","en_api_mp_math_const.md":"D_Flpj8t","en_api_mp_math_equation.md":"DU8q_g4G","en_api_mp_math_index.md":"DrjDUYBY","en_api_mp_math_line.md":"BBlzflWh","en_api_mp_math_mp_math_typing.md":"CyXXFdS4","en_api_mp_math_plane.md":"cxytQLD4","en_api_mp_math_point.md":"CXQGh5Zt","en_api_mp_math_segment.md":"CxreVgqR","en_api_mp_math_utils.md":"aavLLFMy","en_api_mp_math_vector.md":"BvKJEw7_","en_api_particle_index.md":"CmC1QX5o","en_api_presets_index.md":"CZ5hl_7D","en_api_presets_model_index.md":"DBfUZUBC","guide_index.md":"BE2yloik","index.md":"BE1qChTt","ja_api_index.md":"4BnflFIm","ja_api_mp_math_angle.md":"DxBe_g0o","ja_api_mp_math_const.md":"CyaIJkFx","ja_api_mp_math_equation.md":"-GejNICN","ja_api_mp_math_index.md":"CSAMHYsB","ja_api_mp_math_line.md":"CMfQT6TH","ja_api_mp_math_mp_math_typing.md":"Bl5kyhpI","ja_api_mp_math_plane.md":"Cm4a8eqF","ja_api_mp_math_point.md":"CQAIjHfb","ja_api_mp_math_segment.md":"D0U5bMSu","ja_api_mp_math_utils.md":"CXGqGLUs","ja_api_mp_math_vector.md":"C9TtayJk","ja_api_particle_index.md":"E2YnH7EN","ja_api_presets_index.md":"ATGcHt9d","ja_api_presets_model_index.md":"DAVK1sDI","md-ex.md":"BX0WqOqv","zht_api_index.md":"Dq4XPUKZ","zht_api_mp_math_angle.md":"_4N19GGe","zht_api_mp_math_const.md":"B8uQOIr_","zht_api_mp_math_equation.md":"MGSqd_Ep","zht_api_mp_math_index.md":"D09y2ubg","zht_api_mp_math_line.md":"4ncoPmkZ","zht_api_mp_math_mp_math_typing.md":"DLx0IibM","zht_api_mp_math_plane.md":"Buk-SLcC","zht_api_mp_math_point.md":"Bb3tyGv-","zht_api_mp_math_segment.md":"U_lS4vUA","zht_api_mp_math_utils.md":"ig9jQkoA","zht_api_mp_math_vector.md":"CDyAXuJb","zht_api_particle_index.md":"kAm9VAEw","zht_api_presets_index.md":"BmouaEaT","zht_api_presets_model_index.md":"CrdAyyCM"} diff --git a/index.html b/index.html index fc19e7a..8948c40 100644 --- a/index.html +++ b/index.html @@ -18,7 +18,7 @@
Skip to content

MBCP docs

More basic change particle

用于几何运算和粒子制作的库

- + \ No newline at end of file diff --git a/ja/api/index.html b/ja/api/index.html index af2b052..fa91241 100644 --- a/ja/api/index.html +++ b/ja/api/index.html @@ -18,7 +18,7 @@
Skip to content
- + \ No newline at end of file diff --git a/ja/api/mp_math/angle.html b/ja/api/mp_math/angle.html index 7416d08..884a3da 100644 --- a/ja/api/mp_math/angle.html +++ b/ja/api/mp_math/angle.html @@ -116,7 +116,7 @@ if isinstance(other, AnyAngle): return self.radian / other.radian return AnyAngle(self.radian / other, is_radian=True) - + \ No newline at end of file diff --git a/ja/api/mp_math/const.html b/ja/api/mp_math/const.html index fe1e9b1..9061a09 100644 --- a/ja/api/mp_math/const.html +++ b/ja/api/mp_math/const.html @@ -18,7 +18,7 @@
Skip to content

var EPSILON = 0.0001

  • 説明: ε

var APPROX = 0.001

  • 説明: 约等于误差
- + \ No newline at end of file diff --git a/ja/api/mp_math/equation.html b/ja/api/mp_math/equation.html index f6b7965..17c0e18 100644 --- a/ja/api/mp_math/equation.html +++ b/ja/api/mp_math/equation.html @@ -12,7 +12,7 @@ - + @@ -32,6 +32,14 @@ if isinstance(var, int): def partial_derivative_func(*args: Var) -> Var: + """ + @litedoc-hide + Args: + *args: + + Returns: + + """ args_list_plus = list(args) args_list_plus[var] += epsilon args_list_minus = list(args) @@ -41,6 +49,7 @@ elif isinstance(var, tuple): def high_order_partial_derivative_func(*args: Var) -> Var: + """@litedoc-hide""" result_func = func for v in var: result_func = get_partial_derivative_func(result_func, v, epsilon) @@ -70,7 +79,7 @@ return Point3(self.x_func(t[0]), self.y_func(t[0]), self.z_func(t[0])) else: return tuple([Point3(x, y, z) for x, y, z in zip(self.x_func(t), self.y_func(t), self.z_func(t))]) - + \ No newline at end of file diff --git a/ja/api/mp_math/index.html b/ja/api/mp_math/index.html index 3c93967..25802c3 100644 --- a/ja/api/mp_math/index.html +++ b/ja/api/mp_math/index.html @@ -18,7 +18,7 @@
Skip to content
- + \ No newline at end of file diff --git a/ja/api/mp_math/line.html b/ja/api/mp_math/line.html index 200c308..d9510df 100644 --- a/ja/api/mp_math/line.html +++ b/ja/api/mp_math/line.html @@ -195,7 +195,7 @@ """ return self.direction.is_parallel(other.direction) and (self.point - other.point).is_parallel(self.direction) - + \ No newline at end of file diff --git a/ja/api/mp_math/mp_math_typing.html b/ja/api/mp_math/mp_math_typing.html index 7679af8..83ec983 100644 --- a/ja/api/mp_math/mp_math_typing.html +++ b/ja/api/mp_math/mp_math_typing.html @@ -18,7 +18,7 @@
Skip to content

var RealNumber = int | float

  • タイプ: TypeAlias

  • 説明: 实数

var Number = RealNumber | complex

  • タイプ: TypeAlias

  • 説明: 数

var SingleVar = TypeVar('SingleVar', bound=Number)

  • 説明: 单变量

var ArrayVar = TypeVar('ArrayVar', bound=Iterable[Number])

  • 説明: 数组变量

var Var = SingleVar | ArrayVar

  • タイプ: TypeAlias

  • 説明: 变量

var OneSingleVarFunc = Callable[[SingleVar], SingleVar]

  • タイプ: TypeAlias

  • 説明: 一元单变量函数

var OneArrayFunc = Callable[[ArrayVar], ArrayVar]

  • タイプ: TypeAlias

  • 説明: 一元数组函数

var OneVarFunc = OneSingleVarFunc | OneArrayFunc

  • タイプ: TypeAlias

  • 説明: 一元函数

var TwoSingleVarsFunc = Callable[[SingleVar, SingleVar], SingleVar]

  • タイプ: TypeAlias

  • 説明: 二元单变量函数

var TwoArraysFunc = Callable[[ArrayVar, ArrayVar], ArrayVar]

  • タイプ: TypeAlias

  • 説明: 二元数组函数

var TwoVarsFunc = TwoSingleVarsFunc | TwoArraysFunc

  • タイプ: TypeAlias

  • 説明: 二元函数

var ThreeSingleVarsFunc = Callable[[SingleVar, SingleVar, SingleVar], SingleVar]

  • タイプ: TypeAlias

  • 説明: 三元单变量函数

var ThreeArraysFunc = Callable[[ArrayVar, ArrayVar, ArrayVar], ArrayVar]

  • タイプ: TypeAlias

  • 説明: 三元数组函数

var ThreeVarsFunc = ThreeSingleVarsFunc | ThreeArraysFunc

  • タイプ: TypeAlias

  • 説明: 三元函数

var MultiSingleVarsFunc = Callable[..., SingleVar]

  • タイプ: TypeAlias

  • 説明: 多元单变量函数

var MultiArraysFunc = Callable[..., ArrayVar]

  • タイプ: TypeAlias

  • 説明: 多元数组函数

var MultiVarsFunc = MultiSingleVarsFunc | MultiArraysFunc

  • タイプ: TypeAlias

  • 説明: 多元函数

- + \ No newline at end of file diff --git a/ja/api/mp_math/plane.html b/ja/api/mp_math/plane.html index 2e3b26b..7195266 100644 --- a/ja/api/mp_math/plane.html +++ b/ja/api/mp_math/plane.html @@ -213,7 +213,7 @@ raise TypeError(f"unsupported operand type(s) for &: 'Plane3' and '{type(other)}'")

method __eq__(self, other) -> bool

ソースコード
python
def __eq__(self, other) -> bool:
     return self.approx(other)

method __rand__(self, other: Line3) -> Point3

ソースコード
python
def __rand__(self, other: 'Line3') -> 'Point3':
     return self.cal_intersection_point3(other)
- + \ No newline at end of file diff --git a/ja/api/mp_math/point.html b/ja/api/mp_math/point.html index 451fed9..15f6dad 100644 --- a/ja/api/mp_math/point.html +++ b/ja/api/mp_math/point.html @@ -68,7 +68,7 @@ """ from .vector import Vector3 return Vector3(self.x - other.x, self.y - other.y, self.z - other.z) - + \ No newline at end of file diff --git a/ja/api/mp_math/segment.html b/ja/api/mp_math/segment.html index 5f58bd3..c1a9a42 100644 --- a/ja/api/mp_math/segment.html +++ b/ja/api/mp_math/segment.html @@ -31,7 +31,7 @@ self.length = self.direction.length '中心点' self.midpoint = Point3((self.p1.x + self.p2.x) / 2, (self.p1.y + self.p2.y) / 2, (self.p1.z + self.p2.z) / 2) - + \ No newline at end of file diff --git a/ja/api/mp_math/utils.html b/ja/api/mp_math/utils.html index ac1a846..3daceaf 100644 --- a/ja/api/mp_math/utils.html +++ b/ja/api/mp_math/utils.html @@ -81,7 +81,7 @@ self.raise_type_error(other)

method raise_type_error(self, other)

ソースコード
python
def raise_type_error(self, other):
     raise TypeError(f'Unsupported type: {type(self.value)} and {type(other)}')

method __ne__(self, other)

ソースコード
python
def __ne__(self, other):
     return not self.__eq__(other)
- + \ No newline at end of file diff --git a/ja/api/mp_math/vector.html b/ja/api/mp_math/vector.html index 9f4b447..4b7b445 100644 --- a/ja/api/mp_math/vector.html +++ b/ja/api/mp_math/vector.html @@ -204,7 +204,7 @@ return self.x * other.x + self.y * other.y + self.z * other.z

method self / other: RealNumber => Vector3

ソースコード
python
def __truediv__(self, other: RealNumber) -> 'Vector3':
     return Vector3(self.x / other, self.y / other, self.z / other)

method - self

ソースコード
python
def __neg__(self):
     return Vector3(-self.x, -self.y, -self.z)

var zero_vector3 = Vector3(0, 0, 0)

var x_axis = Vector3(1, 0, 0)

var y_axis = Vector3(0, 1, 0)

var z_axis = Vector3(0, 0, 1)

- + \ No newline at end of file diff --git a/ja/api/particle/index.html b/ja/api/particle/index.html index 69b3fa1..558924a 100644 --- a/ja/api/particle/index.html +++ b/ja/api/particle/index.html @@ -18,7 +18,7 @@
Skip to content
- + \ No newline at end of file diff --git a/ja/api/presets/index.html b/ja/api/presets/index.html index 77fcfcc..020f74a 100644 --- a/ja/api/presets/index.html +++ b/ja/api/presets/index.html @@ -18,7 +18,7 @@
Skip to content
- + \ No newline at end of file diff --git a/ja/api/presets/model/index.html b/ja/api/presets/model/index.html index 032d497..c509dc3 100644 --- a/ja/api/presets/model/index.html +++ b/ja/api/presets/model/index.html @@ -35,7 +35,7 @@ y_array = radius * np.sin(phi_list) * np.sin(theta_list) z_array = radius * np.cos(phi_list) return [Point3(x_array[i], y_array[i], z_array[i]) for i in range(num)] - + \ No newline at end of file diff --git a/md-ex.html b/md-ex.html index 56d16c1..8ce2e4b 100644 --- a/md-ex.html +++ b/md-ex.html @@ -50,7 +50,7 @@ ::: details This is a details block. :::

Output

INFO

This is an info box.

TIP

This is a tip.

WARNING

This is a warning.

DANGER

This is a dangerous warning.

Details

This is a details block.

More

Check out the documentation for the full list of markdown extensions.

- + \ No newline at end of file diff --git a/zht/api/index.html b/zht/api/index.html index a0fb5dc..d9da8e8 100644 --- a/zht/api/index.html +++ b/zht/api/index.html @@ -18,7 +18,7 @@
Skip to content
- + \ No newline at end of file diff --git a/zht/api/mp_math/angle.html b/zht/api/mp_math/angle.html index 0f26fd8..2a124b9 100644 --- a/zht/api/mp_math/angle.html +++ b/zht/api/mp_math/angle.html @@ -116,7 +116,7 @@ if isinstance(other, AnyAngle): return self.radian / other.radian return AnyAngle(self.radian / other, is_radian=True) - + \ No newline at end of file diff --git a/zht/api/mp_math/const.html b/zht/api/mp_math/const.html index 7fb3172..3eb0bcc 100644 --- a/zht/api/mp_math/const.html +++ b/zht/api/mp_math/const.html @@ -18,7 +18,7 @@
Skip to content

var EPSILON = 0.0001

  • 説明: ε

var APPROX = 0.001

  • 説明: 约等于误差
- + \ No newline at end of file diff --git a/zht/api/mp_math/equation.html b/zht/api/mp_math/equation.html index 3f2553d..9c1287a 100644 --- a/zht/api/mp_math/equation.html +++ b/zht/api/mp_math/equation.html @@ -12,7 +12,7 @@ - + @@ -32,6 +32,14 @@ if isinstance(var, int): def partial_derivative_func(*args: Var) -> Var: + """ + @litedoc-hide + Args: + *args: + + Returns: + + """ args_list_plus = list(args) args_list_plus[var] += epsilon args_list_minus = list(args) @@ -41,6 +49,7 @@ elif isinstance(var, tuple): def high_order_partial_derivative_func(*args: Var) -> Var: + """@litedoc-hide""" result_func = func for v in var: result_func = get_partial_derivative_func(result_func, v, epsilon) @@ -70,7 +79,7 @@ return Point3(self.x_func(t[0]), self.y_func(t[0]), self.z_func(t[0])) else: return tuple([Point3(x, y, z) for x, y, z in zip(self.x_func(t), self.y_func(t), self.z_func(t))]) - + \ No newline at end of file diff --git a/zht/api/mp_math/index.html b/zht/api/mp_math/index.html index 8575fff..3c8528c 100644 --- a/zht/api/mp_math/index.html +++ b/zht/api/mp_math/index.html @@ -18,7 +18,7 @@
Skip to content
- + \ No newline at end of file diff --git a/zht/api/mp_math/line.html b/zht/api/mp_math/line.html index 160138f..5d7f851 100644 --- a/zht/api/mp_math/line.html +++ b/zht/api/mp_math/line.html @@ -195,7 +195,7 @@ """ return self.direction.is_parallel(other.direction) and (self.point - other.point).is_parallel(self.direction) - + \ No newline at end of file diff --git a/zht/api/mp_math/mp_math_typing.html b/zht/api/mp_math/mp_math_typing.html index 9f5f370..b5f2010 100644 --- a/zht/api/mp_math/mp_math_typing.html +++ b/zht/api/mp_math/mp_math_typing.html @@ -18,7 +18,7 @@
Skip to content

var RealNumber = int | float

  • 類型: TypeAlias

  • 説明: 实数

var Number = RealNumber | complex

  • 類型: TypeAlias

  • 説明: 数

var SingleVar = TypeVar('SingleVar', bound=Number)

  • 説明: 单变量

var ArrayVar = TypeVar('ArrayVar', bound=Iterable[Number])

  • 説明: 数组变量

var Var = SingleVar | ArrayVar

  • 類型: TypeAlias

  • 説明: 变量

var OneSingleVarFunc = Callable[[SingleVar], SingleVar]

  • 類型: TypeAlias

  • 説明: 一元单变量函数

var OneArrayFunc = Callable[[ArrayVar], ArrayVar]

  • 類型: TypeAlias

  • 説明: 一元数组函数

var OneVarFunc = OneSingleVarFunc | OneArrayFunc

  • 類型: TypeAlias

  • 説明: 一元函数

var TwoSingleVarsFunc = Callable[[SingleVar, SingleVar], SingleVar]

  • 類型: TypeAlias

  • 説明: 二元单变量函数

var TwoArraysFunc = Callable[[ArrayVar, ArrayVar], ArrayVar]

  • 類型: TypeAlias

  • 説明: 二元数组函数

var TwoVarsFunc = TwoSingleVarsFunc | TwoArraysFunc

  • 類型: TypeAlias

  • 説明: 二元函数

var ThreeSingleVarsFunc = Callable[[SingleVar, SingleVar, SingleVar], SingleVar]

  • 類型: TypeAlias

  • 説明: 三元单变量函数

var ThreeArraysFunc = Callable[[ArrayVar, ArrayVar, ArrayVar], ArrayVar]

  • 類型: TypeAlias

  • 説明: 三元数组函数

var ThreeVarsFunc = ThreeSingleVarsFunc | ThreeArraysFunc

  • 類型: TypeAlias

  • 説明: 三元函数

var MultiSingleVarsFunc = Callable[..., SingleVar]

  • 類型: TypeAlias

  • 説明: 多元单变量函数

var MultiArraysFunc = Callable[..., ArrayVar]

  • 類型: TypeAlias

  • 説明: 多元数组函数

var MultiVarsFunc = MultiSingleVarsFunc | MultiArraysFunc

  • 類型: TypeAlias

  • 説明: 多元函数

- + \ No newline at end of file diff --git a/zht/api/mp_math/plane.html b/zht/api/mp_math/plane.html index 311c551..93c99bf 100644 --- a/zht/api/mp_math/plane.html +++ b/zht/api/mp_math/plane.html @@ -213,7 +213,7 @@ raise TypeError(f"unsupported operand type(s) for &: 'Plane3' and '{type(other)}'")

method __eq__(self, other) -> bool

源碼
python
def __eq__(self, other) -> bool:
     return self.approx(other)

method __rand__(self, other: Line3) -> Point3

源碼
python
def __rand__(self, other: 'Line3') -> 'Point3':
     return self.cal_intersection_point3(other)
- + \ No newline at end of file diff --git a/zht/api/mp_math/point.html b/zht/api/mp_math/point.html index e510a88..9f80feb 100644 --- a/zht/api/mp_math/point.html +++ b/zht/api/mp_math/point.html @@ -68,7 +68,7 @@ """ from .vector import Vector3 return Vector3(self.x - other.x, self.y - other.y, self.z - other.z) - + \ No newline at end of file diff --git a/zht/api/mp_math/segment.html b/zht/api/mp_math/segment.html index c3c7d95..0a16cdf 100644 --- a/zht/api/mp_math/segment.html +++ b/zht/api/mp_math/segment.html @@ -31,7 +31,7 @@ self.length = self.direction.length '中心点' self.midpoint = Point3((self.p1.x + self.p2.x) / 2, (self.p1.y + self.p2.y) / 2, (self.p1.z + self.p2.z) / 2) - + \ No newline at end of file diff --git a/zht/api/mp_math/utils.html b/zht/api/mp_math/utils.html index 9d5661e..ac841c8 100644 --- a/zht/api/mp_math/utils.html +++ b/zht/api/mp_math/utils.html @@ -81,7 +81,7 @@ self.raise_type_error(other)

method raise_type_error(self, other)

源碼
python
def raise_type_error(self, other):
     raise TypeError(f'Unsupported type: {type(self.value)} and {type(other)}')

method __ne__(self, other)

源碼
python
def __ne__(self, other):
     return not self.__eq__(other)
- + \ No newline at end of file diff --git a/zht/api/mp_math/vector.html b/zht/api/mp_math/vector.html index 4777ee9..92a6df9 100644 --- a/zht/api/mp_math/vector.html +++ b/zht/api/mp_math/vector.html @@ -204,7 +204,7 @@ return self.x * other.x + self.y * other.y + self.z * other.z

method self / other: RealNumber => Vector3

源碼
python
def __truediv__(self, other: RealNumber) -> 'Vector3':
     return Vector3(self.x / other, self.y / other, self.z / other)

method - self

源碼
python
def __neg__(self):
     return Vector3(-self.x, -self.y, -self.z)

var zero_vector3 = Vector3(0, 0, 0)

var x_axis = Vector3(1, 0, 0)

var y_axis = Vector3(0, 1, 0)

var z_axis = Vector3(0, 0, 1)

- + \ No newline at end of file diff --git a/zht/api/particle/index.html b/zht/api/particle/index.html index 909521d..a451923 100644 --- a/zht/api/particle/index.html +++ b/zht/api/particle/index.html @@ -18,7 +18,7 @@
Skip to content
- + \ No newline at end of file diff --git a/zht/api/presets/index.html b/zht/api/presets/index.html index d6a3e90..d944da4 100644 --- a/zht/api/presets/index.html +++ b/zht/api/presets/index.html @@ -18,7 +18,7 @@
Skip to content
- + \ No newline at end of file diff --git a/zht/api/presets/model/index.html b/zht/api/presets/model/index.html index 306b781..758f498 100644 --- a/zht/api/presets/model/index.html +++ b/zht/api/presets/model/index.html @@ -35,7 +35,7 @@ y_array = radius * np.sin(phi_list) * np.sin(theta_list) z_array = radius * np.cos(phi_list) return [Point3(x_array[i], y_array[i], z_array[i]) for i in range(num)] - + \ No newline at end of file