ベクトルからCラベルを非表示にする

ベクトルからCラベルを非表示にする

次のようなコードがあります:

\documentclass{article}

\usepackage{tikz}
\usetikzlibrary{decorations.markings,arrows}
\begin{document}

\begin{tikzpicture}
\coordinate (B) at (1,2);
\coordinate (A) at (3,4);

\coordinate (C) at (3,4);


\draw [fill=blue] (B) circle (2pt) node [left] {};
\draw [fill=blue] (A) circle (2pt) node [left] {A1};

\draw [-latex, red, thick] (B) -- (A);

\coordinate (B) at (1,2);
\coordinate (A) at (4,2);

\draw [fill=blue] (B) circle (2pt) node [left] {};
\draw [fill=blue] (A) circle (2pt) node [right] {A2};

\draw [-latex, red, thick] (B) -- (A);

\draw[postaction={decorate,decoration={markings,mark=at position 0.25 with {\arrow[black,line width=1.5pt]{>}}}}](C)node[below]{C}--(A)node[above]{A};

\end{tikzpicture}

We can define the positive combination of $A_1$ and $A_2$ to be the vectors lying in the cone between them. The line that crosses $A_1$ and $A_2$ (their heads) is the affine combination of them (one of the points plays the role of the origin of the axis).

\end{document}

これは次のものを生成します:

ここに画像の説明を入力してください

C ラベルを消すにはどうすればいいですか?

答え1

node[below]{C}最後のコマンドを削除します\draw

以下に、同じ出力を生成するコードの簡略化されたバージョンを示します。参考までに。

\documentclass[border=10pt]{standalone}

\usepackage{tikz}
\usetikzlibrary{decorations.markings,arrows}
\begin{document}

    \begin{tikzpicture}
    \coordinate (A) at (4,2);
    \coordinate (B) at (1,2);   
    \coordinate (C) at (3,4);

    \draw [latex-latex, red, thick] (A) -- (B) -- (C);

    \draw [fill=blue] (A) circle (2pt) node [right=5pt] {$ A_2 $};
    \draw [fill=blue] (B) circle (2pt);
    \draw [fill=blue] (C) circle (2pt) node [right=5pt] {$ A_1 $};  


    \draw[postaction={%
                decorate,
                decoration={%
                    markings,
                    mark=at position 0.25 with {%
                        \arrow[line width=1.5pt]{>}
        }}}] (C) -- (A);

    \end{tikzpicture}

\end{document}

ここに画像の説明を入力してください

答え2

以前はこの質問を見たことがありませんでした... ほぼ 7 年経った今、これらのベクトルを描く別の方法を示します (練習用):

\documentclass{article}
\usepackage{tikz}
\usetikzlibrary{arrows.meta, 
                decorations.markings}

\begin{document}
\begin{center}
    \begin{tikzpicture}[
dot/.style = {circle, draw, fill=blue!30, inner sep=2pt, 
              node contents={}},
decoration = {markings,
              mark=at position 0.5 with {\arrow{Straight Barb[length=3pt, line width=1.2pt]}}},
                        ]
\coordinate (A);
\coordinate[label=right:$A_1$] (A1)  at (2,4);
\coordinate[label=right:$A_2$] (A2)  at (3,0);
%
\path       (A) node[dot]  (A1) node[dot] (A2) node[dot];
\draw[-Stealth, red, very thick] (A) edge (A1)   to  (A2);
\draw[postaction={decorate}]  (A1) -- (A2);
    \end{tikzpicture}
\end{center}
We can define the positive combination of $A_1$ and $A_2$ to be the vectors lying in the cone between them. The line that crosses $A_1$ and $A_2$ (their heads) is the affine combination of them (one of the points plays the role of the origin of the axis).

\end{document}

ここに画像の説明を入力してください

関連情報