“複數”的版本间的差异

来自GeoGebra Manual
跳转至: 导航搜索
 
第9行: 第9行:
  
 
{{examples|1=加法與減法:
 
{{examples|1=加法與減法:
* <code>(2 + 1ί) + (1 – 2ί)</code>  回傳 複數 3 – 1ί 。
+
* <code>(2 + 1ί) + (1 – 2ί)</code>  算出 複數 3 – 1ί 。
* <code>(2 + 1ί) - (1 – 2ί)</code>  回傳 複數 1 + 3ί 。}}
+
* <code>(2 + 1ί) - (1 – 2ί)</code>  算出 複數 1 + 3ί 。}}
 
{{examples|1=乘法與除法:
 
{{examples|1=乘法與除法:
* <code>(2 + 1ί) * (1 – 2ί)</code>  回傳 複數 4 – 3ί 。
+
* <code>(2 + 1ί) * (1 – 2ί)</code>  算出 複數 4 – 3ί 。
* <code>(2 + 1ί) / (1 – 2ί)</code>  回傳 複數 0 + 1ί 。}}
+
* <code>(2 + 1ί) / (1 – 2ί)</code>  算出 複數 0 + 1ί 。}}
{{Note|1=The usual multiplication <code>(2, 1)*(1, -2)</code> gives you the scalar product of the two vectors.}}
+
{{Note|1= 若是輸入 <code>(2, 1)*(1, -2)</code> 則是計算兩個向量的內積。}}
 
<br>
 
<br>
The following commands and [[Predefined Functions and Operators|predefined operators]] can also be used:
+
也可以使用下列指令和[[ 內建函數與運算子| 內建函數]]
* <code>x(w)</code> or <code>real(w)</code> return the real part of the complex number ''w''
+
* <code>x(w)</code> <code>real(w)</code> 取得複數 ''w'' 的實部。
* <code>y(w)</code> or <code>imaginary(w)</code> return the imaginary part of the complex number ''w''
+
* <code>y(w)</code> <code>imaginary(w)</code> 取得複數 ''w'' 的虛部。
* <code>abs(w)</code> or <code>[[Length Command|Length]][w]</code> return the absolute value of the complex number ''w''
+
* <code>abs(w)</code> <code>[[Length_指令|Length]][w]</code> 計算複數 ''w'' 的絕對值。
* <code>arg(w)</code> or <code>[[Angle Command|Angle]][w]</code> return the argument of the complex number ''w''
+
* <code>arg(w)</code> <code>[[Angle_指令|Angle]][w]</code> 計算複數 ''w'' 的幅角。
:{{Note|arg(w) is a number between -180° and 180°, while Angle[w] returns values between and 360°.}}
+
:{{Note|arg(w) 算出來的值介於 -180° 180° 之間,然而 Angle[w] 算出來的值是介於 360° 之間。}}
* <code>conjugate(w)</code> or <code>[[Reflect Command|Reflect]][w,xAxis]</code> return the conjugate of the complex number ''w''
+
* <code>conjugate(w)</code> <code>[[Reflect_指令|Reflect]][w,xAxis]</code> 求出複數 ''w'' 的共軛複數。
 
<br>
 
<br>
GeoGebra also recognizes expressions involving [[Numbers and Angles|real]] and complex numbers.
+
GeoGebra 也能處理混合[[ 數值與角度| 實數]] 和複數的運算式。
 
{{examples|1=<br>
 
{{examples|1=<br>
* <code>3 + (4 + 5ί)</code> gives you the complex number 7 + 5ί.
+
* <code>3 + (4 + 5ί)</code> 算出複數 7 + 5ί
* <code>3 - (4 + 5ί)</code> gives you the complex number -1 - 5ί.
+
* <code>3 - (4 + 5ί)</code> 算出複數 -1 - 5ί
* <code>3 / (0 + 1ί)</code> gives you the complex number 0 - 3ί.
+
* <code>3 / (0 + 1ί)</code> 算出複數 0 - 3ί
* <code>3 * (1 + 2ί)</code> gives you the complex number 3 + 6ί.}}
+
* <code>3 * (1 + 2ί)</code> 算出複數 3 + 6ί }}

2021年6月10日 (四) 03:12的最新版本

Accessories dictionary.png
本頁為官方文件,一般使用者無法修改,若有任何誤謬,請與官方聯絡。如欲編輯,請至本頁的開放版


GeoGebra 其實並沒有直接支援複數物件,但可以利用來模擬複數的相關運算。

範例: 若您在指令列輸入複數 3 + 4ί,會發現 Menu view graphics.svg 繪圖區產生一個點 (3, 4)。但這個點在 Menu view algebra.svg 代數區會以 3 + 4ί 表示。
備註: 您可將任何點改成以複數形式顯示在 Menu view algebra.svg 代數區。開啟點的 Menu-options.svg 屬性對話窗,並從代數分頁的坐標清單中選取複數即可。

指令列輸入時,可以從符號箱內選取虛數單位 ί ,或是使用快捷鍵 Alt + i。除非您是在 Menu view cas.svg 運算區輸入,或是您之前已經定義過變數 i ,否則預設情況下,變數 i 會被認為是有序數對 i = (0, 1)或複數 0 + 1ί 。也就是說,您可以在指令列使用變數 i 來輸入複數(例如:q = 3 + 4i),但不適用於 Menu view cas.svg 運算區

範例: 加法與減法:
  • (2 + 1ί) + (1 – 2ί) 算出複數 3 – 1ί 。
  • (2 + 1ί) - (1 – 2ί) 算出複數 1 + 3ί 。
範例: 乘法與除法:
  • (2 + 1ί) * (1 – 2ί) 算出複數 4 – 3ί 。
  • (2 + 1ί) / (1 – 2ί) 算出複數 0 + 1ί 。
備註: 若是輸入 (2, 1)*(1, -2) 則是計算兩個向量的內積。


也可以使用下列指令和內建函數

  • x(w)real(w) 取得複數 w 的實部。
  • y(w)imaginary(w) 取得複數 w 的虛部。
  • abs(w)Length[w] 計算複數 w 的絕對值。
  • arg(w)Angle[w] 計算複數 w 的幅角。
備註: arg(w) 算出來的值介於 -180° 和 180° 之間,然而 Angle[w] 算出來的值是介於 0° 和 360° 之間。
  • conjugate(w)Reflect[w,xAxis] 求出複數 w 的共軛複數。


GeoGebra 也能處理混合實數和複數的運算式。

範例:
  • 3 + (4 + 5ί) 算出複數 7 + 5ί 。
  • 3 - (4 + 5ί) 算出複數 -1 - 5ί 。
  • 3 / (0 + 1ί) 算出複數 0 - 3ί 。
  • 3 * (1 + 2ί) 算出複數 3 + 6ί 。

Comments

IsComplex[] 的替代方案[编辑]

有時候可能會遇到某些情況,像是 x()y() 函數無法套用在實數上,所以必須檢查某數在 GeoGebra 中是否為複數。但卻沒有像是 IsComplex 指令可以使用。此時您必須使用一個小技巧,輸入 complex = IsDefined[sqrt(a) + sqrt(-a)] ∧ (a ≠ 0) 來檢查 a 是否為複數。

備註: 虛部為 0 的複數,像是 a = 2 + 0i,也會被視為複數而通過此測試。若您只是想要確認某個複數 a 的虛部不是 0,可輸入 y(a) != 0
© 2024 International GeoGebra Institute