[Tex/LaTex] Simple way to typeset vector going in and out of the plane in tikz

tikz-pgfvector

Is there a way to easy achieve this result?
Something like the symbol recommended from wikipedia but with the dot of the vector bigger.

enter image description here

And is it possibile to do that in \tikzset ,I was triyng something like

\tikzset{mystyle/.style={draw, circle}}
    \node[mystyle] (nodename) {} ;

But this draws only the circle around… I was surprised not to find anything, so maybe this is a possible duplicate.

Best Answer

Yes. One option is to use pics.

\documentclass[tikz,border=3.14mm]{standalone}
\begin{document}

\tikzset{
   pics/.cd,
   vector out/.style={
      code={
         \draw[#1] (0,0)  circle (1) (45:1) -- (225:1) (135:1) -- (315:1);
      }%end code   
   }%end style
}%end tikzset
\tikzset{
   pics/.cd,
   vector in/.style={
      code={
        \draw[#1] (0,0)  circle (1);
        \fill[#1] (0,0)  circle (.1);
      }%end code   
   }%end style
}%end tikzset
\begin{tikzpicture}%
\path (0,0)  pic {vector out={line width=1.5pt}} (3,0)  pic {vector in={line
width=1.5pt}};
\end{tikzpicture}

\end{document}

enter image description here

EDIT: With relative line widths:

\documentclass[tikz,border=3.14mm]{standalone}
\begin{document}

\tikzset{
   pics/.cd,
   vector out/.style args={#1/#2}{
      code={
         \draw[#1] (0,0)  circle (1);
         \draw[#2] (45:1) -- (225:1) (135:1) -- (315:1);
      }%end code   
   }%end style
}%end tikzset
\tikzset{
   pics/vector in/.style args={#1/#2/#3}{
      code={
        \draw[line width=#1] (0,0)  circle (1);
        \fill[#2] (0,0)  circle (#3);
      }%end code   
   }%end style
}%end tikzset
\begin{tikzpicture}%
\path (0,0)  pic {vector out={line width=3pt/line width=2pt}} (3,0)  
pic {vector in=1.5pt/blue/.2};

\end{tikzpicture}

\end{document}

enter image description here