Tikz:在 tikz 环境中无法使用 \tilde

Tikz:在 tikz 环境中无法使用 \tilde

从我的帖子开始将节点放置在两个圆的交点处,我遇到了一个问题。

当我编译文档时,\tilde F渲染~F时 F 上没有波浪号。但是我无法在较小范围内复制此问题。

以下是我的序言:

\documentclass[11pt, dvipsnames]{article}

\usepackage{amsmath}
\usepackage{amssymb}
\usepackage{eucal}
\usepackage{pxfonts}
\usepackage{setspace}
\usepackage{enumerate}
\usepackage{amscd}
\usepackage{dsfont}
\usepackage{wasysym}
\usepackage{tikz}
\usepackage{tikz-qtree}
\usepackage{mathtools}
\usepackage{kurier}
\usepackage{pgfplots}
\usepackage{listings}
\usepackage{etoolbox}
\usepackage{tikz-3dplot}
\usepackage{float}
\usepackage{wrapfig}
\usepackage{multirow}
\usepackage{array}
\usepackage{tkz-fct}
\usepackage{graphicx}
\usepackage{datetime}
\usepackage{fancyhdr}
\usepackage{xcolor}
\usepackage[protrusion = true, expansion]{microtype}
\usepackage{marvosym}
\usepackage{starfont}
\usepackage{fixltx2e}                                                  
\usepackage{hyperref}
\usepackage[margin = 0.75in]{geometry}
\usepackage[caption = false]{subfig}
\usepackage[all]{hypcap}

%  arctanh                                                                           
\DeclareMathOperator\arctanh{arctanh}

%  phantom sections for itemize linking use hyperref and name                        
\AtBeginEnvironment{itemize}{\apptocmd{\item}{\phantomsection}{}{
    \errmessage{couldn't patch item}}}

%\listfiles                                                                          

\hypersetup{
  colorlinks,
  citecolor = Violet,
  linkcolor = Blue,
  urlcolor = Blue
}

\hypersetup{
  citebordercolor = Violet,
  filebordercolor = Red,
  linkbordercolor = Blue
}

\lstset
{
  breaklines = true,
  tabsize = 3,
  showstringspaces = false
}

\lstdefinestyle{Common}
{
  extendedchars = \true,
  language = {Python},
  frame = single,
  % ===========================================================                      
  framesep = 3pt,%expand outward.                                                    
  framerule = 0.4pt,%expand outward.                                                 
  xleftmargin = 3.7pt,%make the frame fits in the text area.                         
  xrightmargin = 3.5pt,%make the frame fits in the text area.                        
  % ===========================================================                      
  rulecolor = \color{Red}
}

\lstdefinestyle{A}
{
  style = Common,
  backgroundcolor = \color{Yellow!10},
  basicstyle = \scriptsize\color{Black}\ttfamily,
  keywordstyle = \color{Orange},
  identifierstyle = \color{Cyan},
  stringstyle = \color{Red},
  commentstyle = \color{Green}
}

\lstdefinestyle{B}
{
  style = Common,
  backgroundcolor = \color{Black},
  basicstyle = \scriptsize\color{White}\ttfamily,
  keywordstyle = \color{Orange},
  identifierstyle = \color{Cyan},
  stringstyle = \color{Red},
  commentstyle = \color{Green}
}

\usepackage{mdframed}

\pgfplotsset{compat = 1.8}

\usetikzlibrary{arrows, decorations.markings, calc, fadings,
  decorations.pathreplacing, patterns, decorations.pathmorphing, positioning,
  through, intersections, backgrounds}

\makeatletter
\tikzset{circle through extra radius/.code = {
    % unorthodox addon for the through library                                       
    % needs to be used after 'circle through'!                                       
    % this can be avoided by slightly changing the source                            
    \tikz@addoption{%                                                                
      \pgfmathsetlengthmacro\pgf@tempa{
        \pgfkeysvalueof{/pgf/minimum width} + 2 * (#1)}%                             
      \pgfset{/pgf/minimum width/.expanded = \pgf@tempa}%                            
    }%                                                                               
}}
\tikzset{
  special style/.code = {%                                                           
    \if#1\tikz@nonactiveexlmark
      \pgfkeysalso{@special style}%                                                  
    \else
      \pgfkeysalso{style/.expanded=#1}%                                              
    \fi
  },
  @special style/.style = {draw = none, fill = none}
}
\makeatother

% line numbering for tabbing                                                        
\newcommand{\tagthisaux}{%                                                          
  \refstepcounter{equation}%                                                        
  (\theequation)%                                                                   
}
\newcommand{\tagthisline}{\`\tagthisaux}
%                                                                                   

\newcommand\idea[1]{\begin{center}#1\end{center}}

%                                                                                   

\newenvironment{definition}[1][Definition]{\begin{trivlist}                         
    \item[\hskip \labelsep {\bfseries #1}]}{\end{trivlist}}

这是一个令人反感的例子,但这个例子对 Qrrbrbilbel 来说很好(可能拼写错误),但对我来说不行。

\begin{tikzpicture}[scale = .7,
    every label/.append style = {font = \small},
    dot/.style = {fill, outer sep = +0pt, inner sep = +0pt,
      shape = circle, draw = none, label = {#1}},
    dot/.default =,
    small dot/.style = {minimum size = 2.5pt, dot = {#1}},
    small dot/.default =,
    big dot/.style = {minimum size = 5pt, dot = {#1}},
    big dot/.default =
  ]
    \begin{scope}[rotate around ={-23.9625:(.75, -1)}]
      \begin{scope}
        \clip(-1, -4) rectangle (.5, 4);
        \draw [samples = 50, domain = -0.99:0.99, xshift = 1cm, red, thick]
        plot ({0.8 * (-1 - (\x)^2) / (1 - (\x)^2)},
        {1.83 * (-2) * (\x) / (1 - (\x)^2)});
      \end{scope}
      \node[scale = .75, small dot = {below: \(P_1\)}] (P1) at (3, 0) {};
      \node[scale = .75, small dot = {above, left = 3.5pt: \(P_2\)}] (P2) at
      (-1, 0) {};
      \node[scale = .75, small dot = {below: \(F\)}] (F)
      at (.75, -1) {};
      \path[blue] (F) edge (P1) edge (P2) (P1) edge (P2);
      \path ($(P1)!.7!(P2)$) coordinate (Fm) node[small dot =
      {below = 10pt, right = 3pt: \(F_m^*\)}] {};
      \foreach \cPoint in {1, 2}
        \foreach \dDeltaRadius[count = \cRadius from 0] in
        {.0cm, .4cm, .8cm}
          \node[draw, name path global/.expanded = \cPoint:\cRadius] at
          (P\cPoint.center) (\cPoint:\cRadius) [circle through = (Fm),
          circle through extra radius = \dDeltaRadius] {};
      \foreach \cRadius in {1, 2} {
        \tikzset{name intersections = {of/.expanded = {1:\cRadius} and
            2:\cRadius, name/.expanded = n'-\cRadius}}
        \foreach \cSolution in {1, 2}
          \node[black, scale = .5, big dot =
          {right: $\ifnum\cSolution = 1\expandafter\tilde\fi F^*_\cRadius$}]
          (n-\cRadius-\cSolution) at (n'-\cRadius-\cSolution){};
      }
    \end{scope}
\end{tikzpicture}

答案1

amsmath包重新定义\tilde

\tilde:
macro:->\mathaccent "707E\relax

\tilde:
macro:->\protect \mathaccentV {tilde}07E

\mathaccentV宏需要第五个参数,无论如何都应该抓住它(这就是不用作参数的F原因),但是出现了问题。\expandafter\fi

解决方法是使用

$ \ifnum\cSolution = 1\tilde F\else F\fi^*_\cRadius $

相关内容