Skip to content

Commit b76ec65

Browse files
committed
Escape N, S, O symbols when feeding sympy
1 parent 591619c commit b76ec65

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

core/DisplaySympy.cc

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,12 @@ DisplaySympy::DisplaySympy(const Kernel& kernel, const Ex& e)
7676

7777
{"\\partial", "Derivative"},
7878
{"\\dot", "dot"},
79-
{"\\ddot", "ddot"}
79+
{"\\ddot", "ddot"},
80+
81+
// A few symbols are reserved by sympy.
82+
{"N", "sympyN"},
83+
{"O", "sympyO"},
84+
{"S", "sympyS"}
8085
};
8186
}
8287

0 commit comments

Comments
 (0)