测试Mathjax Loaded豆瓣
[实现方法:http://www.douban.com/note/154867225/]
改了豆瓣(基于这个:http://userstyles.org/users/34282 稍微改动了一下),添加了mathjax支持。由于需要比较完全的语法,而且为了测试更多的功能,所以使用下面的文章(版权是我的……)进行测试。
这个想法很早就有了:http://www.douban.com/note/144538612/ (我已经突然有点明白为什么那个时候不成功了,因为js脚本的跨域使用的问题么?我那个时候一直用自己服务器上的mathjax脚本)
其实很早之前我就给豆瓣提过建议,针对不同的小组提供不同的服务,比如物理数学的小组可以申请mathjax支持,但是豆瓣人家直接不理我……
然后我就自己尝试了,反正浏览器终端在我手里,想加些东西那还不容易啊~
Conservations laws:
\begin{alignat}{2}
(P^a+Q^a)(P_a+Q_a)&=(P'^a+Q'^a)(P'_a+Q'_a) & \qquad &\text{Energy Conservation} \\
P^a+Q^a&=P'^a+Q'^a & & \text{Momentum Conservation}
\end{alignat}
For massless photons, $P^a P_a=0$, while for particles with mass $m$, $Q^a Q_a=-m^2$. Define $\beta=\sqrt{v^av_a}$ and $\mu=\frac{v^a e_a}{\beta}$, in which $v^a$ is the three velocity and $e^a=\frac{v^a}{\beta}$ is the direction vector.
Then the conservation equations become
\begin{eqnarray}
&Q^aP_a=Q'^aP'_a& \\
&\displaystyle\frac{E'}{E}=\frac{1-\beta\mu}{1-\beta\mu'+(1-\cos\theta)E/\gamma m}=\frac{1-\beta\cos\phi}{1-\beta\cos{\phi'}+(1-\cos\theta)E/\gamma m}&
\end{eqnarray}
Next step is to simplify this equation using the electron rest frame.
At electron rest frame, $\beta=0$ (because $v^a=0$ for electron), $\gamma=\frac1{1-\beta^2}=1$. Then we have
\begin{equation}
\frac{E'}{E}=\frac{1}{1+(1-\cos\theta)E/m}
\end{equation}
This equation shows us $E'=E$ when $\cos\theta=1$ which means the photon do not change its momentum direction or $E\ll m$ which means the energy of photon is much less than the mass of the electron.
We introduce Compton wavelength by inserting $E=h\nu=h/\lambda$ into $E'/E$ and calculating the following fraction at electron rest frame,
\begin{equation}
\frac{\lambda'}{\lambda}-1=\frac{h}{\lambda}/\frac{h}{\lambda'}-1=\frac E m(1-\cos\theta)=\frac{h}{m\lambda}(1-\cos\theta)
\end{equation}
we define this $h/m=\lambda_c$.
截图:
整体效果:
右键效果:
跟我的网站的一样,不错。
显示源代码功能:
hover放大功能:
改了豆瓣(基于这个:http://userstyles.org/users/34282 稍微改动了一下),添加了mathjax支持。由于需要比较完全的语法,而且为了测试更多的功能,所以使用下面的文章(版权是我的……)进行测试。
这个想法很早就有了:http://www.douban.com/note/144538612/ (我已经突然有点明白为什么那个时候不成功了,因为js脚本的跨域使用的问题么?我那个时候一直用自己服务器上的mathjax脚本)
其实很早之前我就给豆瓣提过建议,针对不同的小组提供不同的服务,比如物理数学的小组可以申请mathjax支持,但是豆瓣人家直接不理我……
然后我就自己尝试了,反正浏览器终端在我手里,想加些东西那还不容易啊~
Conservations laws:
\begin{alignat}{2}
(P^a+Q^a)(P_a+Q_a)&=(P'^a+Q'^a)(P'_a+Q'_a) & \qquad &\text{Energy Conservation} \\
P^a+Q^a&=P'^a+Q'^a & & \text{Momentum Conservation}
\end{alignat}
For massless photons, $P^a P_a=0$, while for particles with mass $m$, $Q^a Q_a=-m^2$. Define $\beta=\sqrt{v^av_a}$ and $\mu=\frac{v^a e_a}{\beta}$, in which $v^a$ is the three velocity and $e^a=\frac{v^a}{\beta}$ is the direction vector.
Then the conservation equations become
\begin{eqnarray}
&Q^aP_a=Q'^aP'_a& \\
&\displaystyle\frac{E'}{E}=\frac{1-\beta\mu}{1-\beta\mu'+(1-\cos\theta)E/\gamma m}=\frac{1-\beta\cos\phi}{1-\beta\cos{\phi'}+(1-\cos\theta)E/\gamma m}&
\end{eqnarray}
Next step is to simplify this equation using the electron rest frame.
At electron rest frame, $\beta=0$ (because $v^a=0$ for electron), $\gamma=\frac1{1-\beta^2}=1$. Then we have
\begin{equation}
\frac{E'}{E}=\frac{1}{1+(1-\cos\theta)E/m}
\end{equation}
This equation shows us $E'=E$ when $\cos\theta=1$ which means the photon do not change its momentum direction or $E\ll m$ which means the energy of photon is much less than the mass of the electron.
We introduce Compton wavelength by inserting $E=h\nu=h/\lambda$ into $E'/E$ and calculating the following fraction at electron rest frame,
\begin{equation}
\frac{\lambda'}{\lambda}-1=\frac{h}{\lambda}/\frac{h}{\lambda'}-1=\frac E m(1-\cos\theta)=\frac{h}{m\lambda}(1-\cos\theta)
\end{equation}
we define this $h/m=\lambda_c$.
截图:
整体效果:
![]() |
右键效果:
![]() |
跟我的网站的一样,不错。
显示源代码功能:
![]() |
hover放大功能:
![]() |



