1
$\begingroup$
<< Notation`
Notation`ClearNotations[];
Notation`Symbolize[NotationTemplateTag[
\!\(\*OverscriptBox[\(\[Tau]\), \(^\)]\)], 
 WorkingForm -> TraditionalForm]
(*Overscript[\[Tau], ^] =1*)
ValueQ[
\!\(\*OverscriptBox[\(\[Tau]\), \(^\)]\)]

\!\(\*OverscriptBox[\(\[Tau]\), \(^\)]\) =. /; ValueQ[
\!\(\*OverscriptBox[\(\[Tau]\), \(^\)]\)];

\!\(\*OverscriptBox[\(\[Tau]\), \(^\)]\) 

enter image description here

If ValueQ[] return False, why it still complains Unset "Assignment on OverHat for Overscript[\[Tau], ^] not found"

I just want to clear specific values of the OverHat or Subscript

When it runs again, it complains Symbolize Warning: The box structure attempting to be symbolized , even though I have added Notation'ClearNotations[]; enter image description here

Using If

enter image description here

OverHat[\[Rho]] Unset fails in If expression, but succeeds in OverHat[\[Rho]]=.

$\endgroup$
3
  • $\begingroup$ Would If[ValueQ[t], t = .] work? Is it mandatory for you to use Condition? $\endgroup$
    – MarcoB
    Jun 24 at 11:24
  • $\begingroup$ No, I just want to clear the values of OverHat[v]. If works. Why Condition does not work? $\endgroup$
    – eason
    Jun 24 at 11:30
  • 1
    $\begingroup$ Condition is a pattern test function, and you have no pattern in your expression. $\endgroup$
    – MarcoB
    Jun 24 at 11:33

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.