From c6ec1a454b05e0d9f6bf77296b133235fd67f991 Mon Sep 17 00:00:00 2001 From: Zhao Liang Date: Fri, 6 Jan 2023 17:02:35 +0800 Subject: [PATCH] [Doc] Update type.md (#7038) Since we have made `matrix` and `vector` to be different types in v1.4.0, the documentation needs to be updated. --- docs/lang/articles/type_system/type.md | 14 -------------- 1 file changed, 14 deletions(-) diff --git a/docs/lang/articles/type_system/type.md b/docs/lang/articles/type_system/type.md index 2b6d9ee9243cf..6b5e933867717 100644 --- a/docs/lang/articles/type_system/type.md +++ b/docs/lang/articles/type_system/type.md @@ -213,20 +213,6 @@ def test(): print(length(v)) ``` -In practical terms, `ti.types.matrix` only would suffice your need for vector/matrix customization because Taichi treats vectors as a special kind of matrices, i.e., matrices with one column. - -In fact, calling `ti.types.vector()` produces a matrix type of a single column: - -``` -vec3 = ti.types.vector(3, float) # Equivalent to vec3 = ti.types.matrix(3, 1, float) -``` - -Similarly, `ti.Vector()` simply converts the input into a matrix of a single column: - -```python -v = ti.Vector([1, 1, 1]) # equivalent to v = ti.Matrix([[1], [1], [1]]) -``` - ### Struct types and dataclass