
(require (quote calc-ext))

(defun calc-Need-calc-comp nil (byte-code "À‡" [nil] 1))

(defun math-compose-expr (a prec) (byte-code "T	
=…
 	† … 	=?ƒ1 Ä…! 	‰ˆ�M 	�N 	\"E)‚B	:?…= �O 	!?ƒL �P �Q 	!P‚B�R 	!ƒ¹�S 	!�T =†u �U 8…u 	:?†u 	@�V >ƒL�W >ƒº �X 	!Ä�N �Y �Z >ƒ§ �[ �U 8!‚­ �U 8�\\ 8E\"*‚I�] =…Ë @G�U UƒD�X 	!ÄÄ	�^ �_ �U 8!ƒñ �` ‚ô �a �b �c �U �d �e �U 8!!�f �d �\\ 8!%E
�g Uƒ*
‚@�^ �h 
�i �j �k !EF,‚I�d 	!‚¶�] =?ƒ_�d 	\"‚¶�S 	!�l >ƒ¿�m �\\ 	8!ƒ„�N �U 	8\"‚¼�b �^ �h �N �U 	8�n \"	@�o =ƒ¨�p ‚«�q �N �\\ 	8�n \"�j &‚¶�g U†ç	:?†Ô	@�r >?†ç…ç�s �t \"?ƒó�d 	\"‚¶�d 	\"Ä
�u �v Vƒ�w ‚�x \"…W�y 
�n �z �n !O�i �{ �\\ \"�{ �U \"ED\"
�| �n !ÄO‰ˆ‚þˆ�u �} \"…��b �^ �n �z �n !O�~ � �{ �U \"�{ �\\ \"E�{ �€ \"%‰ˆ
ƒ³�^ �y 
C\"B‚µ*‚B	@�� N…w�‚ =?…w	@�� NÄÄ�ƒ \"‰…'�ƒ 	GSA\"‰…�„ A	A\"‰…�N \"†'�ƒ ÄA\"‰…'�… A	\"†v�ƒ Ä\"‰…v�ƒ 	GSA\"‰…]�„ A	A\"‰…]�N \"†v�ƒ ÄA\"‰…v�… A	\"+†B	@�† =ƒƒ”�n �U O‚—�a ƒª�U �\\ O‚­�a �‡ >�ˆ >�‰ >†Ï�~ †Ù�a …å�Š 	!†î�‹ >ƒ÷�n ‚ú�Œ �G =ƒ�� ‚�Ž =ƒ�c ‚�� ! �� >…h!?…h�‘ 	!…h�‘ �U 	8!?…h\"†h	G�’ W…_�U 	8G�’ W†hß‰ ˆÄƒ‹…y�Š �U 	8!†‚�‹ >ƒ‹�n ‚Ž�Œ ‰ˆ	G�\\ UƒÄ�^ �~ Q�“ �U 	8A�~ P#�~ QF‚ˆ	GS#�U 	8GS$�Y #S�\\ \"%�” �• �– �• �— %C…ý�~ P…�~ PPC�˜ #S…�™ …#�~ PP\"$C�š 	A�U $%$�• �› %C�˜ #SƒX�~ …TQ‚k…_ƒh�œ ‚k�a \"…w�~ P…‚�~ PPC$C$,‚&…š	A…š�� 	!ƒ¦�ž 	ß\"‚ …·	A…·�” =?ƒ\"†Å	G�’ W''ƒÒ	GS‚Õ�Ÿ #�Y #S�\\ \"%�� Ä!�^ �� %�  	A'ƒ#‚�€ ß#BBD-‚\"†	G�’ Wƒµ�¡ =…*�‘ 	!ƒ@�• �¢ �£ 	A!�¤ #‚²�¥ =…N�‘ 	!ƒh�• �¦ �§ �¨ 	!A!�© #‚²�ª =…v�‘ 	!ƒœ�b �^ �« �“ 	A�~ P#�j &‚²�^ �“ 	A�~ P#F‚�b �^ �“ �U 	8�\\ 	8�€ 	8E�~ P#�¡ =ƒê�¬ ‚í�­ �~ àD�N 	GS	8�® �a \"ƒ�Œ ‚�n \"&
.
‚B	@�¯ =ƒ	AAƒá�U 	8�† =ƒQ�^ �° �“ 	AA�p �n #�­ F‚Þ�U 	8�o =ƒw�^ �h �“ 	AA�p �n #�± F‚Þ�U 	8�² =ƒ��^ �h �“ 	AA�q �n #�³ F‚Þ�U 	8�´ =ƒÖ�^ �\\ 	8�µ >ƒ¾�h ‚Á�° �“ 	AAA�¶ �n #�· F‚Þ�¸ �¹ 	\"‚�U 	8�† =ƒó�º ‚�U 	8�´ =ƒ�\\ 	8�» >ƒ�¼ ‚�º ‚�¼ ‚B	@�½ =ƒS	�¾ �\\ 	8)\"((ƒB�¿ (@!‚O	�¡ =…j*…j*�n U?…j�u �À �¿ �U 	8!\"ƒ€�¸ �Á �¿ �U 	8!\"‚O	+…»-,�U ‰(ˆ,…ž�® ,@	\"?…·+ß=…«,A,(T‰(ˆ‚�ˆ,)ƒÙ+�U =ƒÍ�Â ‚Ö�¸ �Ã (\"‚O	�Ä >ƒò�Å �¿ �U 	8!!‚O	�¥ =…	�u �Æ �¿ �\\ 	8!\"ƒF	�N �Ç �½ �È �¿ �U 	8!�n �É O!�È �¿ �\\ 	8!�n �É O!ED\"‚O	�¿ �U 	8!)‚B	@�´ =ƒè	�b �^ �ª =ƒq	�a ‚†	�U 	8�Ê >ƒƒ	�h ‚†	�° �N �\\ 	8�n \"�¡ =ƒ¡	�Ë ‚³	�¥ =ƒ°	�Ì ‚³	�¶ �N �€ 	8�n \"�ª =ƒÎ	�a ‚ã	�U 	8�Í >ƒà	�j ‚ã	�Î &‚B	@�Ï =ƒ
.@�Ð =ƒ
�Ñ 	!‚
�Ò �Ñ 	!�Ó Q‚B	@�Ô =…'
	AA…'
�Õ >ƒª
	AA/�Ö >…E
�S �U 	8!�Ô =…b
�• �U 	8AA/\"/�U 	8‰ˆ‚/
ˆ�b �^ �N �U 	8�Œ \"�× =ƒ„
�h ‚‡
�° �“ /�p �n #�× =ƒ¢
�j ‚¥
�Î %)‚B	@�Ô =…Â
	G�€ U…Â
�] =ƒE�N �U 	8�Œ \"0�” �N �\\ 	8�n \"1�S 0!�i =†�S 0!�M =…�S �\\ 08!�i =…�\\ 08‰0ƒ9�i �U 08�^ �\\ 08�p 1FE‚A�i 01E+‚B	@�Ô =…]	G�€ U…]�Ø =ƒˆ�b �^ �N �U 	8�Œ \"�Ù �N �\\ 	8�n \"�Ú %‚B	@�Û =…—�¡ =ƒ³�^ �Ü �N �U 	8�n \"�Ý F‚BÄ…Æ	@�Û =…Æ�¥ =ƒâ�^ �Þ �N �U 	8�É \"�Ý F‚B	@�ß =…ñ�] =ƒƒ� �à �U 	8!†@�S �U 	8!�á >†@�S �U 	8!�o =…@�_ �U �U 	88!…@�\\ �U 	88�n =ƒ\\�^ �h �N �U 	8�n \"�j F‚h�N �U 	8�â \"�” �g �N �\\ 	8�n \"*E‚B	@�Y =…’�] =ƒ�S �U 	8!�ã >ƒ«�” ‚®�] �N �U 	8�n \")�S �\\ 	8!�ä >ƒÓ�” ‚Ö�] �N �\\ 	8�n \")10�b �c �å 0!0�æ 1%*‚B	@�ç >…�¡ =…	G�Ÿ Uƒx�b �^ 	@�è =ƒ1�é ‚4�ê �ë �N �\\ 	8�n \"�ì �N �€ 	8�n \"�í �N �î 	8�n \"�ï �N �U 	8�n \"�Ý &‚B	@�ð =…�	G�\\ V…��ñ >ƒ	A-	G�€ Uƒ¦�U ‚§ß+2,,A…½�® ,@2@\"…Ï,A,2A‰2ˆ‚­ˆ�• �ò ,Aƒø�“ �ó �ô 	A!A!�p �n #�õ D‚ùÄ�N 	GS	8�n \"�Ó D#+‚B	@�ö =…5	G�\\ U…5�÷ �U 	8!…5�� �U 	8!ƒb�‚ =ƒU�ø �ž �U 	8ß\"�j Q‚_�ž �U 	8Ä\"‚B	@�ù =…‰	G�\\ U…‰�÷ �U 	8!…‰�� �U 	8!ƒ�‚ =ƒ©�ú �ž �U 	8ß\"�j Q‚Ä�ž �U 	8Ä\"Ä,
�u �û \"…ï�| �n !S,àD�n ,O
BB
,ÄO‰ˆ‚»ˆ�ó 
B!‰
ˆ�ü U†�ý �\\ E
B‰
ˆ�^ 
B+‚B	@�þ =…C�‚ =?…C	G�€ U…C�O �\\ 	8!ƒ£�N �U 	8�É \"
�\\ 	8Vƒ��¡ =ƒv�^ �ÿ 
� F‚š�¥ =ƒŽ�^ �
�F‚š�^ �h 
�j F‚Ÿ
)‚B	@�=…�‚ =?…	G�>…�÷ �U 	8!…�O �\\ 	8!ƒø�€ 	8?†õ�÷ �€ 	8!…õ�� �€ 	8!‚�\\ 	8?†�÷ �\\ 	8!…�� �\\ 	8!ƒu�O �\\ 	8!…*�\\ 	833ƒ7�€ ‚:�\\ 	84Ä54ƒ`�“ �U 	8A�ž 4Ä\"3†\\#‚q�^ ���U 	8A\"B+‚B	@�>…¯�‚ =?…¯	G�>…¯�÷ �U 	8!…¯�\\ 	8?†¯�O �\\ 	8!ƒ�n %�n (�\\ 	8†Å��	�U 	8A\"
�
Ä
\"‰
ˆ
ƒ	@�=ƒô�c ‚	@�=ƒ�� ‚�� %
BB‚�~ ,‚B	@�>…D�‚ =?…D	G�>…D�€ 	8?†D�O �€ 	8!ƒ}	@�=ƒV� ‚Y�i �N �U 	8�€ 	8†l�n \"�N �\\ 	8�n \"E‚B	@�=…«�‚ =?…«	G�>…«�\\ 	8?†«�O �\\ 	8!ƒÙ�>ƒ½�” ‚¿�N �U 	8�\\ 	8†Ô�n \")‚B	@�=…ô	G�>…ô��U 	8!ƒO�\\ 	8ƒ@�^ �˜ �U 	8�÷ �\\ 	8!…�� �\\ 	8!ƒ/�ž �\\ 	8Ä\"‚;�N �\\ 	8�n \"\"B‚L��U 	8�\"‚B	@�>…j	G�>…j��U 	8!ƒ(�U 	8�n Uƒ�a ‚%�\\ 	8ƒ»�÷ �\\ 	8!…œ�� �\\ 	8!ƒ¬�ž �\\ 	8Ä\"‚¸�N �\\ 	8�n \"‚¾�~ 
�
!6�
!7�� 	@�=ƒâ6S‚	@�=ƒ��U 	8S67\\\"6S\\‚�Y ��U 	867\\\"S�\\ \"�˜ �U 	8
\"BB+‚B	@�=…Yß‰8…Y� >…YƒL�\\ ‚O�U U…Y	G�€ Uƒ¢�b �^ �¡ =ƒq�!‚t�\"�N �U 	8�n \"�¡ =ƒ��#‚’�$�N �\\ 	8�n \"%‚B�‚ =?…Ò	@�%=…»	G�î UƒÊ�s �&:\"‚Ò�'	@:\"99…ø	G�€ U†è	@�%=…ø�(�€ 98�É \"ƒÓ�î 98†�\\ 98�€ 98^VƒÞ�¡ =…%�)	!?ƒ^�S 	!�Y =ƒI�^ �*�N 	�É \"�Ý F‚[�^ �ÿ �N 	�É \"� F‚Û�¥ =ƒÉ�S 	!�Y =†�Y �+\"�,Uƒ—�^ �*�N 	�É \"�Ý F‚Æ�)	!ƒ´�^ �-�N 	�É \"�.F‚Æ�^ ��N 	�É \"�F‚Û�^ �h �N 	�n \"�j F‚Ð�¡ =…õ	@�/>…õ�n Yƒ�^ �*�N 	�É \"�Ý F‚Ð	@�%=ƒQ�b �^ �N �U 	8�\\ 98\"�0�N �\\ 	8�n \"�õ �N �€ 	8�€ 98\"&‚Ð…_�1	!?…_�\\ 98�€ 98^Uƒ{S‰ˆÄ‚|;�N �U 	8�\\ 98\"<�N �\\ 	8�€ 98\"=�® 9@�2\"…É�3<!�4=…É�^ �h <�j F‰<ˆ�¡ =…�® 9@�2\"†ê�® 9@�5\"…=;…ú=G�U U?…�^ �*=�Ý F‰=ˆ	@�=…?†&�s �6:\"…�7�U 	8!>�8�\\ 	8!?�9<!†a�S >!�:>…a�] =…a�;@�3=!†…�S ?!�<>……�] =……�;A@…A…A�=Y… A�>X†çA�?Y…²A�@X†çA�;Y…ÄA�AX†çA�B>†çA�C=…ç�u �D�E=!\"?…�S >!�½ =…ýA�F=?…�b �^ �ý ;�U E<àD�~ =&,†Ï�b �^ �ý ;�U E<àD�® 9@�2\"†œ�® 9@�5\"†œ�® 9@�G\"†œ�® 9@�H\"…w�9<!…w�3=!†œ�® 9@�I\"…œ�J�U 	8!…œ�K�\\ 	8!ƒ¥9@‚Ë�] =…¸�® 9@�L\"ƒÁ�M‚Ë�~ 9@�~ Q=&,‚A9…ë	G�\\ U…ë�€ 98�É Uƒò�î 98†þ�\\ 98V†�s 9@:\"9=?…�n Vƒµ�¡ =…)�)	!?ƒA�^ �ÿ �N 	�É \"� F‚²�¥ =ƒ �Y �+\"�,Uƒn�^ �*�N 	�É \"�Ý F‚��)	!ƒ‹�^ �N�N 	�É \"�OF‚��^ ��N 	�É \"�F‚²�^ �h �N 	�n \"�j F‚ï�N �U 	8�\\ 98\"<�^ <9@G�U V†Ý�P<!?ƒê�~ 9@P‚í9@E)‚A9…
	G�\\ U…
�\\ 98�É UƒÁ�€ 98�n =ƒº�¡ =…-�)�U 	8!?B�b �^ Bƒ@�Q‚C�a �u �R9@\"ƒ[9@�U ÄO‚^9@B†k9@G�\\ Vƒt�~ ‚w�a �N �U 	8�É \"B†�9@G�\\ Vƒ™�~ ‚œ�a Bƒ§�S‚ª�a �U 9:>8@&)‚¾�î 98†Ê�€ 98Vƒi�¡ =…Ý�)	!?ƒõ�^ �ÿ �N 	�É \"� F‚f�¥ =ƒT�Y �+\"�,Uƒ\"�^ �*�N 	�É \"�Ý F‚Q�)	!ƒ?�^ �N�N 	�É \"�OF‚Q�^ ��N 	�É \"�F‚f�^ �h �N 	�n \"�j F‚¾�N �U 	8�€ 98\"=�^ �u �R9@\"ƒ•9@�U ÄO‚˜9@CCG�U V†«�P=!?ƒ·C�~ P‚¹C)=E)‚A�] =…Þ	@�TN‰9…Þ�… 9	#†A�ƒ �U\"‰9…	@9AN‰9…�… 9	#†A	@D�ƒ D�V\"EÄFÄGÄ/E…*EA‰Dˆ�¾ DH\"‰E…?E@‰Dˆ�W�u �X�¿ D!\"ƒc�{ �¿ D!�U \"‚i�¿ D!!‰Dˆ�Y>…€�Å D!‰Dˆ�¡ =…¢*…¢*�n U?…¢�u �À D\"…Í�Z*!�n WƒÁ�¸ �[D\"‰D‚Í�¸ �Á D\"‰Dˆ�¥ =…à�u �\\D\"…�]DG�z �n !�U #ID�n I[O‰DˆIS‰I�n Y…D�^P‰Dˆ‚)ˆ�¡ =…;	G�\\ V†;�)�U 	8!?ƒL�ÿ F� ‰G‚�¥ =…h	G�\\ V†h�)�U 	8!?ƒy�F�‰G‚�¡ =…ŒD�n H�C=†��¥ =…�	@J>…×�u �_D\"?…×	G�\\ U…×�U 	8:?†Ê�U 	8@�`>†×�U 	8@�a>ƒ÷�¥ =ƒé�b‚ì�*F�Ý ‰G‚�¥ =ƒ�cF�.‰G‚KFL‰Gˆ�b �^ DF�“ 	A�¥ =ƒ6�d‚9�p �n #G%-))‡" [math-compose-level a math-comp-selected math-comp-tagged nil prec calc-frac-format calc-language aa math-radix-explicit-format c calc-number-radix calc-group-digits calc-group-char s comps temp temp2 left-bracket calc-vector-brackets right-bracket inner-brackets calc-matrix-brackets outer-brackets row-commas comma-spc calc-vector-commas comma vector-prec just calc-matrix-just t break calc-break-vectors calc-full-vectors rows cols base calc-display-strings full v math-expr-variable-mapping calc-language-option math-compose-hash-args p calc-arg-values calc-date-format args a1 a2 ap cprec sep bprec ca cd calc-any-evaltos op math-expr-opers setlev lhs rhs prevt nextt prevc nextc lr ops func func2 left right math-expr-function-mapping n math-eqn-special-funcs calc-function-open calc-function-close tag math-compose-expr integerp "'" prin1-to-string math-scalarp car-safe frac 1 (bigpos bigneg) (tex eqn math maple c fortran pascal) math-adjust-fraction / (c fortran) math-float 2 big horiz math-negp "- " "" list vcent math-format-number math-abs (rule 45) 10 "(" subscr ")" int-to-string (cplx polar) math-zerop 0 cplx ", " "; " (bigpos bigneg frac float) assoc ((",") (" ")) string-match 14 "\\([0-9]+\\)#\\([0-9a-zA-Z., ]+\\)" "\\([0-9]+\\)#\\([0-9a-dA-D., ]+\\)" nconc match-beginning math-match-substring match-end "\\*\\([0-9.]+\\)\\^\\(-?[0-9]+\\)\\()?\\)\\'" " " supscr 3 math-compose-forms unform assq apply funcall vec R O C math-vector-no-parens P 1000 vright center vleft (nil big) math-matrixp 7 math-compose-vector flat append (horiz) (vleft) make-list "  " math-compose-matrix (vleft) ";" math-vector-is-string math-vector-to-string 5 math-compose-rows tex (horiz "\\matrix{ ") math-compose-tex-matrix (" }") eqn (horiz "matrix { ") math-compose-eqn-matrix math-transpose ("}") maple "matrix(" " \\ldots" " ..." equal incomplete "[" ", ..." polar "; ..." intv (0 1) " .. " " .. ..." format "%s" "[ ..." (0 1) "( ..." var rassq symbol-name "\\`[a-zA-Z][a-zA-Z0-9]+\\'" "\\hbox{%s}" "#" "#%d" (c fortran pascal maple) math-to-underscores ".'\\'" calcFunc-Prime intern -1 (0 1) " \\ldots " " ... " (0 2) "]" date X math-format-date "<" ">" calcFunc-subscr (c pascal fortran maple) (pascal fortran) fortran math "[[" "]]" calcFunc-sqrt "\\sqrt{" "}" "sqrt {" ^ math-looks-negp (^ / frac calcFunc-sqrt) 201 (/ frac) (/ frac) math-comp-height (rule 45) (calcFunc-sum calcFunc-prod) calcFunc-sum "\\sum" "\\prod" "_{" "=" "}^{" 4 "}{" calcFunc-lambda (nil flat big) (horiz "<") nreverse reverse " : " calcFunc-string math-vectorp "string(" calcFunc-bstring "bstring(" "[^ ] +[^ ]" -123 set calcFunc-cprec "\\left( " " \\right)" "{left ( " " right )}" calcFunc-choriz (2 3 4) mapcar (lambda (x) (byte-code "Ä!Å=ƒ Æ	† 
† \"Ç‰ˆ‚# Æ
†\" \"‡" [x bprec cprec prec car-safe calcFunc-bstring math-compose-expr -123] 5)) (calcFunc-cvert calcFunc-clvert calcFunc-crvert) (2 3) (lambda (x) (byte-code "ÁÁÁÁÉ!Ê>… GË>… @Ì8‰ˆÉ!Í=…\\ GÎ>…\\ Ì8?†\\ ÏÌ8!…L Ì8GÐU…L ÑÌ8!†\\ ÒÌ8!…\\ Ì8ÓXƒ€ ÔÏÌ8!ƒs ÕÌ8Á\"ÖH‚z Ì8†z ×D‰‚£ É!Ø>…” GÙ>…” Ì8Ö=†£ ?†£ Ú\"‰ˆ
ƒ® Û
!‚¯ Ö
ƒº Ü
!‚» Ö‰ˆÝ=ƒÐ Þß#‰‚î à=ƒÞ ‰‚î á=…î Þß$‰ˆÞ#‰ˆ
,‡" [b nil cc a d x prec base v car-safe (calcFunc-cbase calcFunc-ctbase calcFunc-cbbase) (1 2) 1 calcFunc-crule (1 2) math-vectorp 2 math-vector-is-string natnump 255 rule math-vector-to-string 0 45 (calcFunc-cvspace calcFunc-ctspace calcFunc-cbspace) (2 3) math-compose-expr math-comp-ascent math-comp-descent calcFunc-cbase + -1 calcFunc-ctbase calcFunc-cbbase] 17)) delq calcFunc-cvert calcFunc-clvert (calcFunc-csup calcFunc-csub) (3 4) calcFunc-csup calcFunc-cflat (2 3) (nil big) calcFunc-cspace (2 3) natnump make-string 32 (calcFunc-cvspace calcFunc-ctspace calcFunc-cbspace) (2 3) math-comp-ascent math-comp-descent calcFunc-ctspace calcFunc-cbspace * calcFunc-evalto (tex eqn) "\\evalto " "evalto " " \\to " " -> " calcFunc-if "?" math-assq2 /= math-tex-expr-is-flat "{" 100 9 "( " " )" (/ calcFunc-choose calcFunc-evalto) " ? " math-primp "^" math-comp-first-char 45 "_" "2x" math-prod-last-term math-prod-first-term math-comp-last-char (^ calcFunc-subscr calcFunc-sqrt frac) 48 (calcFunc-sqrt calcFunc-sum calcFunc-prod calcFunc-integ) 97 122 65 90 57 (46 95 35 40 91 123) 92 "\\`\\\\left(" math-comp-first-string 40 "**" "*" "/" math-num-integerp math-integerp "=>" "  =>  " "{( " " )}" math-comp-is-flat "\\left" "\\`u\\([^a-zA-Z]\\)\\'" "\\right" math-compose-big ((nil . math-compose-normal) (flat . math-compose-normal) (big . math-compose-normal) (c . math-compose-c) (pascal . math-compose-pascal) (fortran . math-compose-fortran) (tex . math-compose-tex) (eqn . math-compose-eqn) (math . math-compose-math) (maple . math-compose-maple)) ((mod . calcFunc-makemod) (sdev . calcFunc-sdev) (+ . calcFunc-add) (- . calcFunc-sub) (* . calcFunc-mul) (/ . calcFunc-div) (% . calcFunc-mod) (^ . calcFunc-pow) (neg . calcFunc-neg) (| . calcFunc-vconcat)) math-remove-dashes "\\`calcFunc-\\([a-zA-Z0-9']+\\)\\'" (c fortran pascal maple) prefix-numeric-value "\\%s" "[^']'+\\'" - " prime" "\\hbox{" (bigpos bigneg frac float) (var *) "~{" " ( " " , "] 306))

(defconst math-eqn-special-funcs (quote (calcFunc-log calcFunc-ln calcFunc-exp calcFunc-sin calcFunc-cos calcFunc-tan calcFunc-sinh calcFunc-cosh calcFunc-tanh calcFunc-arcsin calcFunc-arccos calcFunc-arctan calcFunc-arcsinh calcFunc-arccosh calcFunc-arctanh)))

(defun math-prod-first-term (x) (byte-code "Á!Â=… Ã8‰ˆ‚  ˆ‡" [x car-safe * 1] 4))

(defun math-prod-last-term (x) (byte-code "Á!Â=… Ã8‰ˆ‚  ˆ‡" [x car-safe * 2] 4))

(defun math-compose-vector (a sep prec) (byte-code "ƒH ÅÆ	DÇ@\"CA‰…> È@!É=ƒ+ 	SÇ@Ê\")‚0 Ç@\"Ë	D
BBB‰ˆ‚ ˆÌ
!)BB‚I Í‡" [a math-compose-level c prec sep horiz set math-compose-expr car-safe calcFunc-bstring -123 break nreverse ""] 11))

(defun math-vector-no-parens (a) (byte-code "AA† ÁÂ8!Ã=?‡" [a car-safe 1 *] 3))

(defun math-compose-matrix (a col cols base) (byte-code "ÇÂT‰X… ÈÉ\"BB	B‰ˆ‚ ˆÊ	!*‡" [col res nil cols just base a 0 mapcar (lambda (r) (byte-code "ÅÆ	8
\"Uƒ Ç‚ ÈPE‡" [col r vector-prec cols comma-spc horiz math-compose-expr "" " "] 5)) nreverse] 6))

(defun math-compose-rows (a count first) (byte-code "AƒQ 	ÉXƒ1 	ÉWƒ ÊAËÂ#‚. Ì=ƒ$ Í‚% ÎPÊAËÂ#B‚N Ïƒ= ÐP‚> ÑÒ@\"FÊA	SÂ#B‚j Ïƒ] ÐP‚^ ÑÒ@\"ÐPFC‡" [a count nil calc-language comma first left-bracket vector-prec right-bracket 0 math-compose-rows -1 tex "  \\ldots" "  ..." horiz " " "  " math-compose-expr] 10))

(defun math-compose-tex-matrix (a) (byte-code "Aƒ Á@AÂÃ#ÄÅA!BB‚ Á@AÂÃ#C‡" [a math-compose-vector " & " 0 " \\\\ " math-compose-tex-matrix] 6))

(defun math-compose-eqn-matrix (a) (byte-code "ƒ5 	Å=ƒ Æ‚ 	Ç=ƒ È‚ ÉÊDËTÌ@AÍÎ#)ÏÐA!BBBBB‚6 Ä‡" [a calc-matrix-just t math-compose-level nil right "rcol " center "ccol " "lcol " break "{ " math-compose-vector " above " 1000 " } " math-compose-eqn-matrix] 8))

(defun math-vector-is-string (a) (byte-code "A‰…6 Á@!… @ÂX†6 Ã@!Ä=…6 ÁÅ@8!…6 Æ@8Ç=…6 Å@8ÂX…> Èˆ‚  ˆ?‡" [a natnump 255 car-safe cplx 1 2 0 nil] 5))

(defun math-vector-to-string (a &optional quoted) (byte-code "ÈÉÊA\"!‰ˆËÌ\"…‚ Íƒ Ì‚ Îƒ# ‚$ Ïƒ, Ð‚- ÑÒË
	#‰…� Ó	H\"‰ƒd Í	OA	TÒOQ	AG\\‰‚} Í	OÔ	HÕ\\\"	TÒOQ	Ö\\‰ˆ‚5 -ˆƒŽ ××Q‚� ‡" [a p pat quoted codes math-vector-to-string-chars fmt new concat mapcar (lambda (x) (byte-code ":ƒ Á8‚ ‡" [x 1] 2)) string-match "[ -\\\"]" 0 "[ -]" ((127 . "^?")) "\\^%c" "^%c" nil assq format 64 2 "\""] 12))

(defconst math-vector-to-string-chars (quote ((34 . "\\\"") (92 . "\\\\") (7 . "\\a") (8 . "\\b") (27 . "\\e") (12 . "\\f") (10 . "\\n") (13 . "\\r") (9 . "\\t") (127 . "\\^?"))))

(defun math-to-underscores (x) (byte-code "ÁÂ\"ƒ ÃÄÅ\"ÆÄÇ\"Q!‚ ‡" [x string-match "\\`\\(.*\\)#\\(.*\\)\\'" math-to-underscores math-match-substring 1 "_" 2] 8))

(defun math-tex-expr-is-flat (a) (byte-code ":?†
 @Á>†@ @Â>†@ @Ã>…1 A‰…& Ä@!…. Åˆ‚ ˆ?†@ @Æ>…@ ÄÇ8!‡" [a (bigpos bigneg) (float var) (+ - * neg) math-tex-expr-is-flat nil (^ calcFunc-subscr) 1] 4))

(put (quote calcFunc-log) (quote math-compose-big) (quote math-compose-log))

(defun math-compose-log (a prec) (byte-code "GÂU… ÃÄÅÆÇÈÉ8Ê\")EËÈÌ8Ê\"Í%‡" [a calc-language 3 list horiz subscr "log" flat math-compose-expr 2 1000 "(" 1 ")"] 8))

(put (quote calcFunc-log10) (quote math-compose-big) (quote math-compose-log10))

(defun math-compose-log10 (a prec) (byte-code "GÁU… ÂÃÄÅÆEÇÈÉ8Ê\"Ë%‡" [a 2 list horiz subscr "log" "10" "(" math-compose-expr 1 1000 ")"] 7))

(put (quote calcFunc-deriv) (quote math-compose-big) (quote math-compose-deriv))

(put (quote calcFunc-tderiv) (quote math-compose-big) (quote math-compose-deriv))

(defun math-compose-deriv (a prec) (byte-code "GÂU… ÃÄÅÆÇÈ8EDÅÆÉÊ8EDE	\"‡" [a prec 3 math-compose-expr / calcFunc-choriz vec (calcFunc-string (vec 100)) 1 (calcFunc-string (vec 100)) 2] 8))

(put (quote calcFunc-sqrt) (quote math-compose-big) (quote math-compose-sqrt))

(defun math-compose-sqrt (a prec) (byte-code "GÅU…N ÆÇ8È\"É	!Ê	!
\\Ë	!ÌÇUƒ* Í‚+ ÎÏÅ\\Ð\"PÑÇUƒ= Ò‚I ÓÌSDÔSÕ\"Ö#Í	FF-‡" [a c d h w 2 math-compose-expr 1 0 math-comp-ascent math-comp-descent math-comp-width vleft " " "  " make-string 95 horiz "V" append make-list " |" ("\\|")] 14))

(put (quote calcFunc-choose) (quote math-compose-big) (quote math-compose-choose))

(defun math-compose-choose (a prec) (byte-code "ÃÄ	8Å\"ÃÆ	8Å\"ÇÈÉÊË!Ì
%ÍF*‡" [a1 a a2 math-compose-expr 1 0 2 horiz "(" list vcent math-comp-height " " ")"] 11))

(put (quote calcFunc-integ) (quote math-compose-big) (quote math-compose-integ))

(defun math-compose-integ (a prec) (byte-code "GÉ>…Ù ÊË8!Ã=…Ù 
ÌY… Í
Î\"ÏË8Ð\"ÊË8!Ã=…R ÊÑ8!Ò=…> ÓÑÑ88!†R ÊÑ8!Ô=…R ÕËÑ88!Ïƒj ÖÑ8×ØÙÑË88\"!\"‚m Ñ8Ú\"ÛÜ8… ÏÜ8Ð\"Ý8…� ÏÝ8Ð\"Þß	ƒ™ à‚š áâãƒ¥ Ü‚¦ ËD…² ßäECå…¾ ßäEC$ƒÈ á‚Ì ßæE	ƒÔ ç‚Õ á&.‡" [a parens prec var over expr calc-language low high (3 5) car-safe 2 196 /= 1000 math-compose-expr 0 1 / math-numberp ^ math-looks-negp math-mul math-build-var-name format "d%s" 185 flat 3 4 list horiz "(" "" append vcent "  " ("  /" " | " " | " " | " "/  ") " d" ")"] 24))

(put (quote calcFunc-sum) (quote math-compose-big) (quote math-compose-sum))

(defun math-compose-sum (a prec) (byte-code "GÇ>…ƒ ÈÉ8Ê\"ËÈÌ8Í\"Î8…# ÈÎ8Í\"Ï8…2 ÐÑÏ\"ÒÍ#ÓÔÕ>ƒ@ Ö‚A ×ØÙƒK Î‚L ÌD…S CÚƒa ÔÛFC‚c C$ÜÉ8!Ý>ƒr Þ‚s ×	ß>ƒ à‚€ ×&-‡" [a expr calc-language var low high prec (3 5 6) math-compose-expr 1 185 flat 2 0 3 4 math-compose-vector nthcdr ", " list horiz (180 201) "(" "" append vcent ("---- " "\\    " " >   " "/    " "---- ") " = " car-safe (calcFunc-sum calcFunc-prod) " " (180 201) ")"] 16))

(put (quote calcFunc-prod) (quote math-compose-big) (quote math-compose-prod))

(defun math-compose-prod (a prec) (byte-code "GÇ>…ƒ ÈÉ8Ê\"ËÈÌ8Í\"Î8…# ÈÎ8Í\"Ï8…2 ÐÑÏ\"ÒÍ#ÓÔÕ>ƒ@ Ö‚A ×ØÙƒK Î‚L ÌD…S CÚƒa ÔÛFC‚c C$ÜÉ8!Ý>ƒr Þ‚s ×	ß>ƒ à‚€ ×&-‡" [a expr calc-language var low high prec (3 5 6) math-compose-expr 1 198 flat 2 0 3 4 math-compose-vector nthcdr ", " list horiz (196 201) "(" "" append vcent ("----- " " | |  " " | |  " " | |  ") " = " car-safe (calcFunc-sum calcFunc-prod) " " (196 201) ")"] 16))

(defun math-stack-value-offset-fancy nil (byte-code "ÉÊ	!!
Ë=ƒE ƒ Ì]‰‚! Í!…! ‰ˆÎGÍ!…/ ƒ: ZÏ]‚; ÏZÏ]#‰‚Œ ƒy ÐÑ\"Z‰ˆÍ!…f ÎG#^‰ˆÏY…v \\]‰‚Œ Í!…‚ ‰ˆÐZÑ\"‰ˆÍ!…§ ÏW†¡ …¡ V…§ ‰)‡" [cwid c calc-display-just calc-display-origin wid calc-line-breaking off calc-right-label t + math-comp-width right 5 integerp - 0 / 2] 13))

(defun math-composition-to-string (c &optional width) (byte-code "† Ã ‰ˆ	ƒ Ä
Å\"‚' Æ
!ƒ! Ç
\"‚' ÈÉ
\"!‡" [width calc-display-raw c calc-window-width math-comp-to-string-raw 0 math-comp-is-flat math-comp-to-string-flat math-vert-comp-to-string math-comp-simplify] 8))

(defun math-comp-is-flat (c) (byte-code ":?ƒ
 Á‚c @Ã>ƒ Á‚c @Ä=ƒ5 A‰…' Å@!…/ Âˆ‚ ˆ?‚c @Æ>ƒS GÇU…P È8ÉU…P ÅÊ8!‚c @Ë=ƒb ÅÊ8!‚c Â‡" [c t nil (set break) horiz math-comp-is-flat (vleft vcent vright) 3 1 0 2 tag] 5))

(defun math-comp-to-string-flat (c full-width) (byte-code "ƒ ÎÏ
!)‚œ ÐÐÎÎ… Ñ	ÒÓ!ˆÒ
!ˆÒÔ!ˆÎHÐ

GÎV…’ 
ÎHÕU…’ GÎV…’ GS‰HÖU?…e ×ˆ‚R ˆÕIˆTGW…| THÕUƒ� TÖIˆØ‰‚‘ Ù‰)ˆ
Q*.‡" [math-comp-sel-hpos comp-pos c comp-buf comp-word comp-margin comp-highlight math-comp-selected calc-show-selections comp-level str math-comp-buf-string prefix k 0 math-comp-sel-flat-term "" -1 math-comp-to-string-flat-term (set -1 0) (break -1) 32 10 nil " " "
"] 7))

(setq math-comp-buf-string (make-vector 10 ""))

(setq math-comp-buf-margin (make-vector 10 0))

(setq math-comp-buf-level (make-vector 10 0))

(defun math-comp-to-string-flat-term (c) (byte-code ":?ƒ( 	… Ù!‰ˆ
GÚUƒ ‚ 
PG\\‰‚y@Û=ƒA A‰…> Ü@!ˆ‚/ ‚y@Ý=ƒŽ Þ8…‹ T‰ˆGY…p ß\"ß\"ß\"‰ˆàIˆá8†� Ú\\IˆÞ8I‚y@â=ƒ<?ƒ§ 	
P	à‰‚9ÚÕ
V…ã 
H‰ˆGÚU…È 
W…Õ 
T‰
ˆ‚´ ˆGÚV†ã 	GÚV…ÕàÕÕ
H‰ˆãV…
ƒ
ä‚Þåˆ‰*ˆG\\‰ˆGÚV……ÚHæU……	GÚV……	G	S‰HçU?…TÕˆ‚@ˆ	æIˆT	GW…n	THæUƒ€	TçIˆè‰‚„é‰)ˆê	éëæ\"%	Z\\‰ˆ
àIˆ
T‰
X…Ô
HV…Ð

HZ\\Iˆ‚ª+*ˆÞ8HU…êHá\\WƒñÕ‚9HGÚUƒ
‚
Pà‰ˆÞ8HW…2S‰ˆHGÚU†.HP‰ˆ‚ˆI)‚y@ì=ƒtÞ8=ƒY?Üá8!)‚qÞ8Ø=ƒlÕÜá8!)‚qÜá8!‚yÜá8!‡" [c comp-highlight comp-word comp-pos comp-level math-comp-buf-string math-comp-buf-margin math-comp-buf-level calc-line-breaking comp-buf i str full-width prefix mrg wid j new calc-line-numbering comp-margin k nil math-comp-selected calc-show-selections t math-comp-highlight-string 0 horiz math-comp-to-string-flat-term set 1 vconcat "" 2 break 12 5 (while (<= j comp-level) (aset math-comp-buf-margin j (+ (aref math-comp-buf-margin j) (- new mrg))) (setq j (1+ j))) 32 10 " " "
" concat make-string tag] 13))

(defun math-comp-highlight-string (s) (byte-code "Ã!‰ˆG	S‰ÄY…* 	HÅ>†& 	
ƒ$ Æ‚% ÇIˆ‚	 )ˆ‡" [s i calc-show-selections copy-sequence 0 (32 10) 46 35] 5))

(defun math-comp-sel-flat-term (c) (byte-code ":?ƒ 	G\\‰‚c @Å>†c @Æ=ƒ5 A‰…' 
ÇW…2 È@!ˆ‚ ‚c @É=ƒ^ 	
XƒV ÈÊ8!ˆ	
V…S Ç‰‚[ ÈÊ8!‚c ÈÊ8!‡" [c comp-pos math-comp-sel-cpos math-comp-sel-tag t (set break) horiz 1000000 math-comp-sel-flat-term tag 2] 6))

(defun math-comp-simplify (c full-width) (byte-code "ËCÌÍÌÌ… ÉÎ
!ˆÏ	BB.‡" [comp-buf comp-base comp-height comp-hpos comp-vpos comp-highlight math-comp-selected calc-show-selections comp-tag nil c "" 0 1 math-comp-simplify-term vleft] 7))

(defun math-comp-add-string (s h v) (byte-code "GÊV…z 
\\ƒ Ë	GÌ$‚y 	ÊWƒ9 ÍÎ	[Ï\"\"
[	ZÊ‰‚S 	Y…S ÍÎ	ZTÏ\"\"	T‰ˆÐ	\"Ñ@Ò@GZÓ\"	ƒu Ô!‚v Q\"))‡" [s vv v comp-base math-comp-sel-hpos h comp-buf comp-height str comp-highlight 0 math-comp-add-string-sel 1 nconc make-list "" nthcdr setcar make-string 32 math-comp-highlight-string] 13))

(defun math-comp-add-string-sel (x y w h) (byte-code "	X… 
\\	V… X… \\V…# È‰‡" [y math-comp-sel-vpos h x math-comp-sel-hpos w math-comp-sel-tag comp-tag 10000] 2))

(defun math-comp-simplify-term (c) (byte-code ";ƒ Ñ	
#ˆ	G\\‰‚™@Ò>ƒ Ã‚™@Ó=ƒ8 A‰…5 Ô@!ˆ‚& ‚™@Õ>ƒÌ 
Ö8Z×Ø8!S\\ÙÚAA\"ÛÜ\"@Ý=ƒc Þ‚o @ß=ƒn Ö‚o ØA‰ˆA‰…Â à@!á=ƒ” ÑâÖ@8\"	
#‚§ 	ãä@Z\"Ø\"\\Ô@!)ˆA…¾ 
å@!×Ö8!\\\\A‰ˆ‚v ˆ	\\‰,‚™@æ=ƒÖ†Ü ×Ö8!åØ8!		ÔÖ8!ˆ

	\\ZÔØ8!ˆ…ç
è
é×Ø8!#	
Zê!$,‚™@ë=ƒ^×Ø8!åÖ8!	
	ÔÖ8!ˆ

	\\\\ÔØ8!ˆ…Zç
	
Zê!$-‚™@ì=…™Ö8=ƒ|?ÔØ8!)‚™Ö8Ç=ƒ�ÃÔØ8!)‚™ÔØ8!)‡" [c comp-hpos comp-vpos nil widths maxwid bias t asc desc oldh math-comp-sel-hpos oldv math-comp-selected comp-highlight calc-show-selections comp-tag math-comp-add-string (set break) horiz math-comp-simplify-term (vleft vcent vright) 1 math-comp-ascent 2 mapcar math-comp-width apply max vleft 0 vcent car-safe rule make-string / * math-comp-descent supscr math-comp-add-string-sel - -1 math-comp-height subscr tag] 32))

(defun math-comp-first-char (c) (byte-code ";ƒ GÁV… ÂÁ\"‚E @Ã>ƒ9 A‰…% Ä@!…- Åˆ‚ ˆ…6 Æ@!‚E @Ç=…E ÆÈ8!‡" [c 0 elt (horiz subscr supscr) math-comp-is-null nil math-comp-first-char tag 2] 6))

(defun math-comp-first-string (c) (byte-code ";ƒ GÁV… ‚B @Â=ƒ6 A‰…\" Ã@!…* Äˆ‚ ˆ…3 Å@!‚B @Æ=…B ÅÇ8!‡" [c 0 horiz math-comp-is-null nil math-comp-first-string tag 2] 5))

(defun math-comp-last-char (c) (byte-code ";ƒ GÁV… ÂGS\"‚M @Ã=ƒA ÄA!…) Å@!…4 A‰ˆ‚! ˆ…= Æ@!)‚M @Ç=…M ÆÈ8!‡" [c 0 elt horiz reverse math-comp-is-null math-comp-last-char tag 2] 7))

(defun math-comp-is-null (c) (byte-code ";ƒ GÂU‚C @Ã>ƒ, A‰… Ä@!…& Åˆ‚ ˆ?‚C @Æ=ƒ; ÄÇ8!‚C @È>…C Á‡" [c t 0 (horiz subscr supscr) math-comp-is-null nil tag 2 (set break)] 4))

(defun math-comp-width (c) (byte-code ":?ƒ G‚d @Ã>ƒ- ÄA‰…' 	Å@!\\‰ˆ‚ ˆ	)‚d @Æ>ƒT A‰ˆÄA‰…N 	Å@!]‰ˆ‚; ˆ	)‚d @Ç=ƒc ÅÈ8!‚d Ä‡" [c accum t (horiz subscr supscr) 0 math-comp-width (vcent vleft vright) tag 2] 5))

(defun math-comp-height (c) (byte-code ";ƒ	 Á‚ Â!Ã!\\‡" [c 1 math-comp-ascent math-comp-descent] 4))

(defun math-comp-ascent (c) (byte-code ":?ƒ
 Ã‚{ @Ä=ƒ, ÅA‰…& 	Æ@!]‰ˆ‚ ˆ	)‚{ @Ç>ƒF Ã8ÅVƒB Ã8T‚C Ã‚{ @È=ƒ\\ ÆÃ8!ÉÊ8!T]‚{ @Ë=ƒk ÆÃ8!‚{ @Ì=ƒz ÆÊ8!‚{ Ã‡" [c accum t 1 horiz 0 math-comp-ascent (vcent vleft vright) supscr math-comp-height 2 subscr tag] 7))

(defun math-comp-descent (c) (byte-code ":?ƒ
 Ã‚� @Ä=ƒ, ÃA‰…& 	Å@!]‰ˆ‚ ˆ	)‚� @Æ>ƒY Ç8[A‰ˆA‰…P 	È@!\\‰ˆ‚= ˆ	SÃ])‚� @É=ƒh ÅÇ8!‚� @Ê=ƒ} ÅÇ8!ÈË8!\\‚� @Ì=ƒŒ ÅË8!‚� Ã‡" [c accum t 0 horiz math-comp-descent (vcent vleft vright) 1 math-comp-height supscr subscr 2 tag] 8))

(defun calcFunc-cwidth (a &optional prec) (byte-code "… Â!?… ÃÄ\"ˆÅÆ	† Ç\"!‡" [prec a integerp math-reject-arg fixnump math-comp-width math-compose-expr 0] 6))

(defun calcFunc-cheight (a &optional prec) (byte-code "… Â!?… ÃÄ\"ˆ	@Å>…# 	GÆ>…# Ç	8È=ƒ* È‚4 ÉÊ	†2 È\"!‡" [prec a integerp math-reject-arg fixnump (calcFunc-cvspace calcFunc-ctspace calcFunc-cbspace) (2 3) 1 0 math-comp-height math-compose-expr] 6))

(defun calcFunc-cascent (a &optional prec) (byte-code "… Â!?… ÃÄ\"ˆ	@Å>…# 	GÆ>…# Ç	8È=ƒ* È‚4 ÉÊ	†2 È\"!‡" [prec a integerp math-reject-arg fixnump (calcFunc-cvspace calcFunc-ctspace calcFunc-cbspace) (2 3) 1 0 math-comp-ascent math-compose-expr] 6))

(defun calcFunc-cdescent (a &optional prec) (byte-code "… Â!?… ÃÄ\"ˆÅÆ	† Ç\"!‡" [prec a integerp math-reject-arg fixnump math-comp-descent math-compose-expr 0] 6))

(defun math-vert-comp-to-string (c) (byte-code ";ƒ	 ‚ ÁAA!‡" [c math-vert-comp-to-string-step] 2))

(defun math-vert-comp-to-string-step (c) (byte-code "Aƒ @ÁÂA!Q‚ @‡" [c "
" math-vert-comp-to-string-step] 4))

(defun math-comp-to-string-raw (c indent) (byte-code ":?†
 @Ä=ƒ Å!‚D A?ƒ# ÆÇ@!ÈQ‚D ÉÊÇ@!G#ËÆÇ@!ÌÍÎ8
\"ÏAA
\"È&)‡" [c t next-indent indent set prin1-to-string "(" symbol-name ")" + 2 concat " " math-comp-to-string-raw 1 math-comp-to-string-raw-step] 14))

(defun math-comp-to-string-raw-step (cl indent) (byte-code "ƒ ÂÃ	Ä\"Å@	\"ÆA	\"R‚ Ç‡" [cl indent "
" make-string 32 math-comp-to-string-raw math-comp-to-string-raw-step ""] 8))
