0
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

「Myscript」(手書き文字や画像内の数式をLaTeXやMathML、テキストに変換する方法)をやってみた。

Last updated at Posted at 2023-12-18

オリジナル

MyScript公式サイト

参考

>QiitaではMathJaxというライブラリを使っていて、ブラウザ上で美しい数式を見ることができます。
>MathJaxにおける数式の記述方法は TeX記法 に則っています。

>Wikipedia で数式を記述する方法には TeX 記法()と HTML による表現の二種類があります。...

>LaTeX ←→ HTML/XHTML/XML/MathML/EPUB

2024-11-30 追加

(別件) mathmlで表示したい。

勉強中

・左寄せにする方法を教えて下さい。

\begin{aligned}
N=\int ^{\cdot }_{A}\sigma _{x}dA\\
M=\int ^{\cdot }_{A}\sigma _{x}ydA\\
Q=\int ^{\cdot }_{A}\tau dA
\end{aligned}

横に並べた。上を編集しました。

N=\int ^{\cdot }_{A}\sigma _{x}dA 
M=\int ^{\cdot }_{A}\sigma _{x}ydA
Q=\int ^{\cdot }_{A}\tau dA
\dfrac{d^{2}y}{dx^{2}}=\dfrac{M}{EI_{z}}

MathMLの勉強を開始

・(2023-12-7)

MathML 数式組版入門  > PDF(内容を読む/ダウンロード)第1.1版 様

https://www.antenna.co.jp/AHF/ahf_publication/MathML/mathml-guide.pdf
https://www.antenna.co.jp/AHF/ahf_publication/index.html#MathML
https://moji.gr.jp/mich/

大学入試数学問題集成 様

>MathMLを使う
>ところが,最近では,完全にテキストベースで入力できるため,...
https://mathexamtest.web.fc2.com/sonota/usagemathml.html
>行のインデント規則
https://mathexamtest.web.fc2.com/sonota/mathmlhtml/usagecss.html

物理数学付録 様

以下練習中

f(x) = \left\{
\begin{array}{ll}
1 & (x \geq 0)\\
0 & (x < 0)
\end{array}
\right.
\overrightarrow{a}\overrightarrow{b}
<mover>
 <mrow>
 <mi>V</mi>
 <mi>W</mi>
 </mrow>
 <mo>&rarr;</mo>
</mover>
<mover>
 <mrow>
 <mi>V</mi>
 <mi>W</mi>
 </mrow>
 <mo>&rarr;</mo>
</mover>




\left(\right. \sqrt[n]{2} + \sqrt[n]{2^{2}} + \sqrt[n]{2^{3}}
\underset{n &rightarrow; &infin;}{lim} \frac{1}{n} &it; \left(\right. \sqrt[n]{2} + \sqrt[n]{2^{2}} + \sqrt[n]{2^{3}}
<math>
<mrow><mstyle displaystyle="true"><msubsup><mo>&int;</mo>
<mn>0</mn><mi>&pi;</mi></msubsup></mstyle><mi>sin</mi>
<mo>&af;</mo><mn>3</mn><mo>&it;</mo><mi>x</mi>
<mo>&it;</mo><mi>cos</mi><mo>&af;</mo><mn>2</mn>
<mo>&it;</mo><mi>x</mi><mo>&it;</mo><mi mathvariant="italic">dx</mi>
<mo rspace=".2em">=</mo><mrow class="b2box">
<mspace width="1em"></mspace><mtext>ハ</mtext>
<mspace width="1em"></mspace></mrow></mrow></math>
&int;_{0}^{1} \left(\right. 2 &it; x + 1 \left.\right) &it; log &af; \left(\right. x + 1 \left.\right) &it; dx = \text{イ} &int;_{\frac{1}{2}}^{1} x^{- 2} &it; e^{\frac{1}{x}} &it; dx = \text{ロ} &int;_{0}^{&pi;} sin &af; 3 &it; x &it; cos &af; 2 &it; x &it; dx = \text{ハ} \underset{n &rightarrow; &infin;}{lim} \frac{1}{n} &it; \left(\right. \sqrt[n]{2} + \sqrt[n]{2^{2}} + \sqrt[n]{2^{3}}+ &ctdot; + \sqrt[n]{2^{n}} \left.\right) \text{ニ} F &af; \left(\right. x \left.\right) = &int;_{1}^{e^{x}} \left(\left(\right. log &af; t \left.\right)\right)^{3} &it; dtF^{&prime;} &af; \left(\right. x \left.\right) \text{ホ} \left(log\right)_{3} &af; \left(\right. x^{2} - 1 \left.\right)= \frac{6}{\left(log\right)_{x} &af; 3}+ \left(log\right)_{3} &af; \frac{1}{x^{2} &it; \left(\right. x^{2} + 2 \left.\right)} \text{ヘ} \underset{x &rightarrow; - &infin;}{lim} \frac{f &af; \left(\right. x \left.\right)}{x^{2} + x} = 3\underset{x &rightarrow; 1}{lim} \frac{f &af; \left(\right. x \left.\right)}{x^{2} - x} = 52f &af; \left(\right. x \left.\right) \text{ト} z^{4} = - 8 + 8 &it; \sqrt{3} &it; ii \text{チ} OABCu0 < u < 1OAu : 1 - uD \text{,}ABu : 1 - uEOEBDPOCu : 1 - uF \text{,}CBu : 1 - uGOGBFQ\overset{&rightarrow;}{OA} = \overset{&rightarrow;}{a} \text{,}\overset{&rightarrow;}{OB} = \overset{&rightarrow;}{b} \text{,}\overset{&rightarrow;}{OC} = \overset{&rightarrow;}{c}\overset{&rightarrow;}{OP}\overset{&rightarrow;}{a} \text{,}\overset{&rightarrow;}{b} \text{,}u\overset{&rightarrow;}{OP} = \text{イ} \overset{&rightarrow;}{PQ}\overset{&rightarrow;}{a} \text{,}\overset{&rightarrow;}{b} \text{,}\overset{&rightarrow;}{c} \text{,}u\overset{&rightarrow;}{PQ} = \text{ロ} \overset{&rightarrow;}{a} \text{,}\overset{&rightarrow;}{b} \text{,}\overset{&rightarrow;}{c}2\left|\right. \overset{&rightarrow;}{PQ} \left|\right.u = \text{ハ}  \text{ニ} 9191122A73BCA11B12 \text{イ}  \text{ロ} ABC \text{ハ} ABC \text{ニ} \left{\right. a_{n} \left.\right}nS_{n}a_{1} = 1 \text{,}a_{n + 1} = S_{n} + \left(\left(\right. n + 1 \left.\right)\right)^{2}\text{(} n = 1 \text{,} 2 \text{,} 3 \text{,} &ctdot; \text{)}a_{n + 1}a_{n}na_{n + 1} = \text{イ} b_{n} = a_{n + 1} - a_{n}b_{n + 1}b_{n}b_{n + 1} = \text{ロ} b_{n}nb_{n} = \text{ハ} a_{n}na_{n} = \text{ニ} n\underset{x &rightarrow; &infin;}{lim} \frac{x^{n}}{e^{x}} = 0te^{t} > ttxnxe^{x} > \left(\left(\right. \frac{x}{n + 1} \left.\right)\right)^{n + 1}\underset{x &rightarrow; &infin;}{lim} \frac{x^{n}}{e^{x}} = 0\left{\right. a_{n} \left.\right}a_{1} = 0 \text{,}\frac{1}{a_{n + 1}} = a_{n} + \frac{4}{n}\text{(} n = 1 \text{,} 2 \text{,} 3 \text{,} &ctdot; \text{)}a_{2} \text{,}a_{3} \text{,}a_{4}\left{\right. a_{n} \left.\right}a_{n}

>MathJaxにおける数式の記述方法はTeX記法に則っています。

<math xmlns='http://www.w3.org/1998/Math/MathML'> <mover> <mrow> <mi> a </mi> </mrow> <mrow> <mo> &#x2192; <!-- rightwards arrow --> </mo> </mrow> </mover> <mover> <mrow> <mi> b </mi> </mrow> <mrow> <mo> &#x2192; <!-- rightwards arrow --> </mo> </mrow> </mover> </math>
<mover> <mrow> <mi> a </mi> </mrow> <mrow> <mo> &#x2192; <!-- rightwards arrow --> </mo> </mrow> </mover> <mover> <mrow> <mi> b </mi> </mrow> <mrow> <mo> &#x2192; <!-- rightwards arrow --> </mo> </mrow> </mover> 
<mrow> <mi> a </mi> </mrow> <mrow> <mo> &#x2192; <!-- rightwards arrow --> </mo> </mrow> </mover> <mover> <mrow> <mi> b </mi> </mrow> <mrow> <mo> &#x2192; <!-- rightwards arrow --> </mo> </mrow> 
<mrow> <mi> a </mi> </mrow> <mrow> <mo> &#x2192; <!-- rightwards arrow --> </mo> </mrow> </mover> <mover> <mrow> <mi> b </mi> </mrow> <mrow> <mo> &#x2192; <!-- rightwards arrow --> </mo> </mrow> 
\overrightarrow{a}\overrightarrow{b}
\overrightarrow{a}\overrightarrow{b}
<math display="block"> <!-- トップレベル要素 -->
  <mrow> <!-- 可変長引数のレイアウトスキーマ -->
    <mfrac> <!-- 2引数のレイアウトスキーマ -->
      <mn>1</mn> <!-- トークン -->
      <mi>x</mi> <!-- トークン -->
    </mfrac>
  </mrow>
</math>
<math display="block"> <!-- トップレベル要素 -->
  <mrow> <!-- 可変長引数のレイアウトスキーマ -->
    <mfrac> <!-- 2引数のレイアウトスキーマ -->
      <mn>1</mn> <!-- トークン -->
      <mi>x</mi> <!-- トークン -->
    </mfrac>
  </mrow>
</math>

練習中_中括弧 (2024/01/10)

・???2段書きは、()になります。

\left\{ a+b\right\}
<math xmlns='http://www.w3.org/1998/Math/MathML'> <mrow> <mo> { </mo> <mi> a </mi> <mo> + </mo> <mi> b </mi> <mo> } </mo> </mrow> </math>
0
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?