Triângulo como “picture” do LaTeX desenhado no blog

Na secção  5.2 de The Not So Short Introduction to LaTeX2ɛ   de Tobias Oetiker, Hubert Partl, Irene Hyna e Elisabeth Schlegl é descrito o ” Picture Environment”. Daí (p. 97) adaptei o exemplo seguinte. Este código LaTeX:

$\setlength{\unitlength}{0.8cm}\begin{picture}(6,5)\put(1,0.5){\line(2,1){3}}\put(4,2){\line(-2,1){2}}\put(2,3){\line(-2,-5){1}}\put(0.7,0.3){A}\put(4.05,1.9){B}\put(1.7,2.95){C}\put(3.1,2.5){a}\put(1.3,1.7){b}\put(2.5,1.05){c}\end{picture}$

desenha  o triângulo

\setlength{\unitlength}{0.8cm}\begin{picture}(6,5)\put(1,0.5){\line(2,1){3}}\put(4,2){\line(-2,1){2}}\put(2,3){\line(-2,-5){1}}\put(0.7,0.3){A}\put(4.05,1.9){B}\put(1.7,2.95){C}\put(3.1,2.5){a}\put(1.3,1.7){b}\put(2.5,1.05){c}\end{picture}

que tem o inconveniente das letras não estarem em itálico. Passando-as a itálico através de \textit, modifiquei o código LaTeX para

$\setlength{\unitlength}{0.8cm}\begin{picture}(6,5)\put(1,0.5){\line(2,1){3}}\put(4,2){\line(-2,1){2}}\put(2,3){\line(-2,-5){1}}\put(0.7,0.3){\textit{A}}\put(4.05,1.9){\textit{B}}\put(1.7,2.95){\textit{C}}\put(3.1,2.5){\textit{a}}\put(1.3,1.7){\textit{b}}\put(2.5,1.05){\textit{c}}\end{picture}$

simulando desta forma o que no picture environment se obtém com as letras escritas entre $, mas que aqui entra em conflito com a sintaxe reconhecida pelo WordPress,  ficando

\setlength{\unitlength}{0.8cm}\begin{picture}(6,5)\put(1,0.5){\line(2,1){3}}\put(4,2){\line(-2,1){2}}\put(2,3){\line(-2,-5){1}}\put(0.7,0.3){\textit{A}}\put(4.05,1.9){\textit{B}}\put(1.7,2.95){\textit{C}}\put(3.1,2.5){\textit{a}}\put(1.3,1.7){\textit{b}}\put(2.5,1.05){\textit{c}}\end{picture}

Outros exemplos: este triângulo com a unidade de comprimento igual a 1 cm

$\setlength{\unitlength}{1cm}\begin{picture}(6,5)\put(1,1){\line(0,1){3}}\put(1,1){\line(1,0){4}}\put(1,4){\line(4,-3){4}}\put(0.6,0.8){\textit{C}}\put(5.05,0.8){\textit{B}}\put(0.6,4.05){\textit{A}}\put(3,2.55){\textit{c}}\put(0.6,2.5){\textit{b}}\put(2.95,0.6){\textit{a}}\thinlines\put(1,1.2){\line(1,0){0.2}}\put(1.2,1){\line(0,1){0.2}}\end{picture}$

\setlength{\unitlength}{1cm}\begin{picture}(6,5)\put(1,1){\line(0,1){3}}\put(1,1){\line(1,0){4}}\put(1,4){\line(4,-3){4}}\put(0.6,0.8){\textit{C}}\put(5.05,0.8){\textit{B}}\put(0.6,4.05){\textit{A}}\put(3,2.55){\textit{c}}\put(0.6,2.5){\textit{b}}\put(2.95,0.6){\textit{a}}\put(1,1.2){\line(1,0){0.2}}\put(1.2,1){\line(0,1){0.2}}\end{picture}

c^2=a^2+b^2

e este com 2 cm de unidade de comprimento

$\setlength{\unitlength}{2cm}\begin{picture}(6,5)\put(1,1){\line(0,1){3}}\put(1,1){\line(1,0){4}}\put(1,4){\line(4,-3){4}}\put(0.6,0.8){\textit{C}}\put(5.05,0.8){\textit{B}}\put(0.6,4.05){\textit{A}}\put(3,2.55){\textit{c}}\put(0.6,2.5){\textit{b}}\put(2.95,0.6){\textit{a}}\put(1,1.2){\line(1,0){0.2}}\put(1.2,1){\line(0,1){0.2}}\end{picture}$

\setlength{\unitlength}{2cm}\begin{picture}(6,5)\put(1,1){\line(0,1){3}}\put(1,1){\line(1,0){4}}\put(1,4){\line(4,-3){4}}\put(0.6,0.8){\textit{C}}\put(5.05,0.8){\textit{B}}\put(0.6,4.05){\textit{A}}\put(3,2.55){\textit{c}}\put(0.6,2.5){\textit{b}}\put(2.95,0.6){\textit{a}}\put(1,1.2){\line(1,0){0.2}}\put(1.2,1){\line(0,1){0.2}}\end{picture}

c^2=a^2+b^2

Finalmente um exemplo mais completo (unidade de comprimento igual a 1.5 cm):

$\setlength{\unitlength}{1.5cm}\begin{picture}(6,5)\put(1,1){\line(0,1){3}}\put(1,1){\line(1,0){4}}\put(1,4){\line(4,-3){4}}\put(1,1){\line(3,4){1.45}}\put(0.7,0.8){\textit{C}}\put(5.05,0.8){\textit{B}}\put(0.7,4.05){\textit{A}}\put(3,2.55){\textit{c}}\put(0.6,2.5){\textit{b}}\put(2.95,0.6){\textit{a}}\put(2.5,2.9){\textit{D}}\put(1.7,2.2){h}\put(1,1.2){\line(1,0){0.2}}\put(1.2,1){\line(0,1){0.2}}\end{picture}$

\setlength{\unitlength}{1.5cm}\begin{picture}(6,5)\put(1,1){\line(0,1){3}}\put(1,1){\line(1,0){4}}\put(1,4){\line(4,-3){4}}\put(1,1){\line(3,4){1.45}}\put(0.7,0.8){\textit{C}}\put(5.05,0.8){\textit{B}}\put(0.7,4.05){\textit{A}}\put(3,2.55){\textit{c}}\put(0.6,2.5){\textit{b}}\put(2.95,0.6){\textit{a}}\put(2.5,2.9){\textit{D}}\put(1.7,2.2){h}\put(1,1.2){\line(1,0){0.2}}\put(1.2,1){\line(0,1){0.2}}\end{picture}

c^2=a^2+b^2

A=\dfrac{ch}{2}

e este com  unidade de comprimento igual a 1cm

$\setlength{\unitlength}{1cm}\begin{picture}(6,5)\put(1,1){\line(0,1){3}}\put(1,1){\line(1,0){4}}\put(1,4){\line(4,-3){4}}\put(1,1){\line(3,4){1.45}}\put(0.7,0.8){\textit{C}}\put(5.05,0.8){\textit{B}}\put(0.7,4.05){\textit{A}}\put(3,2.55){\textit{c}}\put(0.6,2.5){\textit{b}}\put(2.95,0.6){\textit{a}}\put(2.5,2.9){\textit{D}}\put(1.7,2.2){h}\put(1,1.2){\line(1,0){0.2}}\put(1.2,1){\line(0,1){0.2}}\end{picture}$

\setlength{\unitlength}{1cm}\begin{picture}(6,5)\put(1,1){\line(0,1){3}}\put(1,1){\line(1,0){4}}\put(1,4){\line(4,-3){4}}\put(1,1){\line(3,4){1.45}}\put(0.7,0.8){\textit{C}}\put(5.05,0.8){\textit{B}}\put(0.7,4.05){\textit{A}}\put(3,2.55){\textit{c}}\put(0.6,2.5){\textit{b}}\put(2.95,0.6){\textit{a}}\put(2.5,2.9){\textit{D}}\put(1.7,2.2){h}\put(1,1.2){\line(1,0){0.2}}\put(1.2,1){\line(0,1){0.2}}\end{picture}

c^2=a^2+b^2

A=\dfrac{ch}{2}

Triângulo isósceles

    $\setlength{\unitlength}{1cm}\begin{picture}(8,6)\put(1,1){\line(3,4){3}}\put(4,5){\line(3,-4){3}}\put(1,1){\line(1,0){6}}\put(4,5){\line(0,-1){4}}\put(2.3,3.2){\textit{a}}\put(5.7,3.1){\textit{c}}\put(3.8,0.5){\textit{b}}\put(4.1,2.7){\textit{h}}\end{picture}$

\setlength{\unitlength}{1cm}\begin{picture}(8,6)\put(1,1){\line(3,4){3}}\put(4,5){\line(3,-4){3}}\put(1,1){\line(1,0){6}}\put(4,5){\line(0,-1){4}}\put(2.3,3.2){\textit{a}}\put(5.7,3.1){\textit{c}}\put(3.8,0.5){\textit{b}}\put(4.1,2.7){\textit{h}}\end{picture}

Triângulo como “picture” do LaTeX desenhado no blog

Um pensamento sobre “Triângulo como “picture” do LaTeX desenhado no blog

Deixe uma Resposta

Preencha os seus detalhes abaixo ou clique num ícone para iniciar sessão:

Logótipo da WordPress.com

Está a comentar usando a sua conta WordPress.com Terminar Sessão / Alterar )

Imagem do Twitter

Está a comentar usando a sua conta Twitter Terminar Sessão / Alterar )

Facebook photo

Está a comentar usando a sua conta Facebook Terminar Sessão / Alterar )

Google+ photo

Está a comentar usando a sua conta Google+ Terminar Sessão / Alterar )

Connecting to %s