光的世界︰【□○閱讀】話眼睛《六》

由於矩陣乘法 Matrix multiplication 符合『結合律』 Associative︰

Properties of the matrix product (any number)

The same properties will hold, as long as the ordering of matrices is not changed. Some of the previous properties for more than two matrices generalize as follows.

  1. Associative:
    The matrix product is associative. If three matrices A, B, and C are respectively m × p, p × q, and q × r matrices, then there are two ways of grouping them without changing their order, and

    \mathbf {ABC} =\mathbf {A} (\mathbf {BC} )=(\mathbf {AB} )\mathbf {C}

    is an m × r matrix.
    If four matrices A, B, C, and D are respectively m × p, p × q, q × r, and r × s matrices, then there are five ways of grouping them without changing their order, and

    \mathbf {ABCD} =((\mathbf {AB} )\mathbf {C} )\mathbf {D} =(\mathbf {A} (\mathbf {BC} ))\mathbf {D} =\mathbf {A} ((\mathbf {BC} )\mathbf {D} )=\mathbf {A} (\mathbf {B} (\mathbf {CD} ))=(\mathbf {AB} )(\mathbf {CD} )

    is an m × s matrix.
    In general, the number of possible ways of grouping n matrices for multiplication is equal to the (n − 1)th Catalan number

  2. Trace:The trace of a product of n matrices A1, A2, …, An is invariant under cyclic permutations of the matrices in the product:
    \mathrm {tr} (\mathbf {A} _{1}\mathbf {A} _{2}\mathbf {A} _{3}\ldots \mathbf {A} _{n-2}\mathbf {A} _{n-1}\mathbf {A} _{n})=\mathrm {tr} (\mathbf {A} _{2}\mathbf {A} _{3}\mathbf {A} _{4}\ldots \mathbf {A} _{n-1}\mathbf {A} _{n}\mathbf {A} _{1})=\mathrm {tr} (\mathbf {A} _{3}\mathbf {A} _{4}\mathbf {A} _{5}\ldots \mathbf {A} _{n}\mathbf {A} _{1}\mathbf {A} _{2})=\ldots
  3. Determinant:For square matrices only, the determinant of a product is the product of determinants:
    \det \left(\prod _{i=1}^{n}\mathbf {A} _{i}\right)=\prod _{i=1}^{n}\det \left(\mathbf {A} _{i}\right)

所以我們可以藉著物理意義、結構目的及不同主點面參考系為結合單元組構複雜光學矩陣,探究設計理念,闡述成像條件也。其實這正是矩陣光學能夠化繁為簡,清楚明白表達事理的重要原因。或許因為看來十分平常,應該不說自明,通常教科書裡很少提及!正因同一光學矩陣在不同視角下,可能變換其組合形式,為著減少誤解 ,方便閱讀 □○ 起見,特以角膜為範例演示此義,以利後續文本之鋪陳矣。

【端點系表述】

角膜 = 角膜後緣 * 角膜厚度 * 角膜前緣

在此表述下角膜光學矩陣十分複雜。

pi@raspberrypi:~ ipython3 Python 3.4.2 (default, Oct 19 2014, 13:31:11)  Type "copyright", "credits" or "license" for more information.  IPython 2.3.0 -- An enhanced Interactive Python. ?         -> Introduction and overview of IPython's features. %quickref -> Quick reference. help      -> Python's own help system. object?   -> Details about 'object', use 'object??' for extra details.  In [1]: from sympy import *  In [2]: from sympy.physics.optics import FreeSpace, FlatRefraction, ThinLens, GeometricRay, CurvedRefraction  In [3]: R1, R2, d, N, n, m = symbols('R1, R2, d, N, n, m')  In [4]: init_printing()  In [5]: 角膜前緣 = CurvedRefraction(R1, n, N)  In [6]: 角膜前緣 Out[6]:  ⎡  1     0⎤ ⎢         ⎥ ⎢-N + n  n⎥ ⎢──────  ─⎥ ⎣ N⋅R₁   N⎦  In [7]: 角膜厚度 = FreeSpace(d)  In [8]: 角膜厚度 Out[8]:  ⎡1  d⎤ ⎢    ⎥ ⎣0  1⎦  In [9]: 角膜後緣 = CurvedRefraction(R2, N, m)  In [10]: 角膜後緣 Out[10]:  ⎡  1    0⎤ ⎢        ⎥ ⎢N - m  N⎥ ⎢─────  ─⎥ ⎣ R₂⋅m  m⎦  In [11]: 角膜 = 角膜後緣 * 角膜厚度 * 角膜前緣  In [12]: 角膜 Out[12]:  ⎡             d⋅(-N + n)                  d⋅n       ⎤ ⎢         1 + ──────────                  ───       ⎥ ⎢                N⋅R₁                      N        ⎥ ⎢                                                   ⎥ ⎢                 ⎛N   d⋅(N - m)⎞    ⎛N   d⋅(N - m)⎞⎥ ⎢        (-N + n)⋅⎜─ + ─────────⎟  n⋅⎜─ + ─────────⎟⎥ ⎢N - m            ⎝m      R₂⋅m  ⎠    ⎝m      R₂⋅m  ⎠⎥ ⎢───── + ────────────────────────  ─────────────────⎥ ⎣ R₂⋅m             N⋅R₁                    N        ⎦  In [13]:  </pre>    <span style="color: #003300;">【主平面表述】</span>  <span style="color: #808080;">主平面角膜表達式 = 後主平面 * 角膜 * 前主平面</span>  <span style="color: #808080;">= 後主平面 * 角膜後緣 * 角膜厚度 * 角膜前緣 * 前主平面</span>  <span style="color: #003300;">用前、後主平面作參考系,角膜光學矩陣表述可以簡化為</span>  \left( \begin{array}{cc}
1 &  0  \\
- \frac{1}{f} & \frac{n}{m} \end{array} \right) 此處-\frac{1}{f}= 主平面角膜表達式.C 。 <pre class="lang:python decode:true">In [13]: 前主平面 = FreeSpace((n/m - 角膜.D) / 角膜.C)  In [14]: 前主平面 Out[14]:  ⎡              ⎛N   d⋅(N - m)⎞      ⎤ ⎢            n⋅⎜─ + ─────────⎟      ⎥ ⎢        n     ⎝m      R₂⋅m  ⎠      ⎥ ⎢        ─ - ─────────────────      ⎥ ⎢        m           N              ⎥ ⎢1  ────────────────────────────────⎥ ⎢                    ⎛N   d⋅(N - m)⎞⎥ ⎢           (-N + n)⋅⎜─ + ─────────⎟⎥ ⎢   N - m            ⎝m      R₂⋅m  ⎠⎥ ⎢   ───── + ────────────────────────⎥ ⎢    R₂⋅m             N⋅R₁          ⎥ ⎢                                   ⎥ ⎣0                 1                ⎦  In [15]: 後主平面 = FreeSpace((1 - 角膜.A) / 角膜.C)  In [16]: 後主平面 Out[16]:  ⎡                 -d⋅(-N + n)              ⎤ ⎢1  ───────────────────────────────────────⎥ ⎢        ⎛                 ⎛N   d⋅(N - m)⎞⎞⎥ ⎢        ⎜        (-N + n)⋅⎜─ + ─────────⎟⎟⎥ ⎢        ⎜N - m            ⎝m      R₂⋅m  ⎠⎟⎥ ⎢   N⋅R₁⋅⎜───── + ────────────────────────⎟⎥ ⎢        ⎝ R₂⋅m             N⋅R₁          ⎠⎥ ⎢                                          ⎥ ⎣0                     1                   ⎦  In [17]: 主平面角膜表達式 = 後主平面 * 角膜 * 前主平面  In [18]: 主平面角膜表達式.A Out[18]: 1  In [19]: 主平面角膜表達式.B.simplify() Out[19]: 0  In [20]: 主平面角膜表達式.C Out[20]:                   ⎛N   d⋅(N - m)⎞         (-N + n)⋅⎜─ + ─────────⎟ N - m            ⎝m      R₂⋅m  ⎠ ───── + ────────────────────────  R₂⋅m             N⋅R₁            In [21]: 主平面角膜表達式.D Out[21]:  n ─ m  In [22]:  </pre>    <span style="color: #003300;">【焦平面表述】</span>  <span style="color: #808080;">焦平面角膜表達式 = 後焦平面 * 主平面角膜表達式 * 前焦平面</span>  <span style="color: #808080;">= 後焦平面 *後主平面 * 角膜後緣 * 角膜厚度 * 角膜前緣 * 前主平面* 前焦平面</span>  <span style="color: #003300;">按造《<a style="color: #003300;" href="http://www.freesandal.org/?p=58020">光的世界︰矩陣光學六丙</a>》文本所說的前、後焦點之求法,可得</span>  <span style="color: #003300;">前焦距 =\frac{n}{m} f</span>  <span style="color: #003300;">後焦距 =f。</span>  <span style="color: #003300;">再依據《<a style="color: #003300;" href="http://www.freesandal.org/?p=58227">光的世界︰矩陣光學六己</a>》文本焦、焦面之解法,給出</span>  <span style="color: #003300;"> </span> \left( \begin{array}{cc}
0 & \frac{n}{m} f \\
- \frac{1}{f} & 0 \end{array} \right) <span style="color: #003300;">這個焦、焦式。</span> <pre class="lang:python decode:true ">In [22]: 前焦平面 = FreeSpace(- n/(m * 主平面角膜表達式.C))  In [23]: 前焦平面 Out[23]:  ⎡                   -n                  ⎤ ⎢1  ────────────────────────────────────⎥ ⎢     ⎛                 ⎛N   d⋅(N - m)⎞⎞⎥ ⎢     ⎜        (-N + n)⋅⎜─ + ─────────⎟⎟⎥ ⎢     ⎜N - m            ⎝m      R₂⋅m  ⎠⎟⎥ ⎢   m⋅⎜───── + ────────────────────────⎟⎥ ⎢     ⎝ R₂⋅m             N⋅R₁          ⎠⎥ ⎢                                       ⎥ ⎣0                   1                  ⎦  In [24]: 後焦平面 = FreeSpace(-1/主平面角膜表達式.C)  In [25]: 後焦平面 Out[25]:  ⎡                 -1                ⎤ ⎢1  ────────────────────────────────⎥ ⎢                    ⎛N   d⋅(N - m)⎞⎥ ⎢           (-N + n)⋅⎜─ + ─────────⎟⎥ ⎢   N - m            ⎝m      R₂⋅m  ⎠⎥ ⎢   ───── + ────────────────────────⎥ ⎢    R₂⋅m             N⋅R₁          ⎥ ⎢                                   ⎥ ⎣0                 1                ⎦  In [26]: 焦平面角膜表達式 = 後焦平面 * 主平面角膜表達式 * 前焦平面  In [27]: 焦平面角膜表達式.A.simplify() Out[27]: 0  In [28]: 焦平面角膜表達式.B.simplify() Out[28]:                             N⋅R₁⋅R₂⋅n                             ────────────────────────────────────────────────────────────────    2       2       2                                             - N ⋅R₁ + N ⋅R₂ + N ⋅d + N⋅R₁⋅m - N⋅R₂⋅n - N⋅d⋅m - N⋅d⋅n + d⋅m⋅n  In [29]: 焦平面角膜表達式.C.simplify() Out[29]:  N⋅R₁⋅(N - m) - (N - n)⋅(N⋅R₂ + d⋅(N - m)) ─────────────────────────────────────────                 N⋅R₁⋅R₂⋅m                  In [30]: 焦平面角膜表達式.D.simplify() Out[30]: 0  In [31]:  </pre>    <span style="color: #003300;">讀者自可驗證牛頓成像公式為</span>  <span style="color: #003300;">x \cdot x' =  \frac{n}{m} f \cdot f的吧!! </span>  <span style="color: #808080;">但思『焦、焦』面『參考系』︰</span>  <img class="alignnone size-full wp-image-58035" src="http://www.freesandal.org/wp-content/uploads/牛頓成像公式.png" alt="牛頓成像公式" width="1310" height="581" />  <span style="color: #808080;">可用牛頓成像公式︰</span>  <span style="color: #003300;">x \cdot x' = FFL * BFL$ 。

─── 摘自《光的世界︰矩陣光學六己

 

亦能了下式之觀點乎??

焦平面角膜表達式 = [後焦平面 *後主平面] * [角膜後緣 * 角膜厚度 * 角膜前緣] * [前主平面* 前焦平面]