Skip to content

Instantly share code, notes, and snippets.

@dginev
dginev / missing_classes.md
Created January 23, 2026 03:43
LaTeX Class use in ar5iv as of Jan 2026

Classes nto yet supported by LaTeXML, as used in arXiv (ar5iv upto 12/2025)

Method

Extracted from CorTeX build system via query:

SELECT what, count(*) as c FROM log_warnings WHERE 
  category='missing_file' 
 AND (details LIKE 'Can''t find binding for class%') 
@dginev
dginev / when.cls.ltxml
Created November 14, 2025 18:33
Timing DefPrimitive and DefConstructor
LoadClass('article');
DefPrimitive('\primitive', sub { Note("primitive1:replacement"); return;},
beforeDigest => sub { Note("primitive1:beforeDigest"); return;},
afterDigest => sub { Note("primitive1:afterDigest"); return;});
DefPrimitive('\anotherprimitive', sub { Note("primitive2:replacement"); return;},
beforeDigest => sub { Note("primitive2:beforeDigest"); return;},
afterDigest => sub { Note("primitive2:afterDigest"); return;});
@dginev
dginev / algorithm.md
Created July 11, 2025 21:08
[algorithm] computing the active property list in MathML Intent

Philosophy: "All properties apply, we need only define the order of precedence."

Note: this algorithm is executed before doing interpretation and vocalization of intent expressions. It linearizes a list of properties for each node in the MathML tree, as well as each term of compound intent expressions.

Legend:

  • self-property - attached to the node itself (intent=":matrix")
  • ref-property - attached to a reference (intent = "$ref:equation-label")
  • fragment-property - attached to a non-reference head in a compound expression
  • intent="factorial:function(2:literal)"
@dginev
dginev / count_files_in_zips.md
Last active October 1, 2024 20:32
Counting all files contained in ZIP archives of a given name, in a directory with symbolic links
$ find -L -name "tex_to_html.zip" -exec unzip -l {} \; \
  | grep files \
  | awk -F: '{ split($0,a," "); print(a[2]); }' \
  > all_files_in_zips.log
  
$ ALLFILES=$(paste -sd+ all_files_in_zips.log | bc)

$ ALLZIPS=$(wc -l all_files_in_zips.log|awk -F' ' '{print $1}')
@dginev
dginev / ar5iv_2024_simple_arg_stats.csv
Last active March 27, 2024 12:21
A simple script for computing the simple ratio from MathML subtree summaries
We can't make this file beautiful and searchable because it's too large.
name[child1/grandchild_count;...],frequency
msub[mi; mi],347136608
msub[mi; mn],235654239
mover[mi; mo],121376075
msub[mi; mrow/3],96607010
msup[mi; mo],81916551
msup[mi; mn],80574746
msup[mi; mi],57340512
msup[mi; mrow/3],40204587
msup[mi; mrow/2],22792247
@dginev
dginev / CK-12-Earth-Science.md
Created February 1, 2024 17:40
Earth Science, Engineering
@dginev
dginev / arxiv_sandboxes_01_2024.md
Last active February 22, 2024 13:32
Changes to arXiv sandboxes, latexml 0.8.8-rc, 01.2024

arXiv sandboxes in CorTeX

Reference results, 07.2023

sandbox ok % warning % error % fatal %
10k shuffle 18.42 61.54 17.85 2.19
1905 13.41 56.51 26.06 4.02
2010 13.72 57.21 26.28 2.79
2111 11.58 51.41 32.23 4.79
@dginev
dginev / concepts.md
Created January 24, 2024 02:05
"Cracking the SAT Biology E/M Subject exam", MathML Intent review

Non-biology concepts:

  • ratio
  • equals, times, plus, divides, fraction
  • chemical equations (varied!)
  • power
  • percent
  • range: pH 1-2 , heart rate 60-80
  • number (notation #2 for "number 2")
  • pH (power-of-hydrogen,acidity,basicity)
  • concentration - [H^+]
@dginev
dginev / parsed.xml
Created November 1, 2023 15:20
A simple XMath example
<Math mode="inline" tex="x_{i+j}" text="x _ (i + j)">
<XMath>
<XMApp>
<XMTok role="SUBSCRIPTOP" scriptpos="post1"/>
<XMTok font="italic" role="UNKNOWN">x</XMTok>
<XMApp>
<XMTok fontsize="70%" meaning="plus" role="ADDOP">+</XMTok>
<XMTok font="italic" fontsize="70%" role="UNKNOWN">i</XMTok>
<XMTok font="italic" fontsize="70%" role="UNKNOWN">j</XMTok>
</XMApp>
@dginev
dginev / barrons-chemistry-intent.md
Last active September 13, 2023 13:26
Barron's: Let's Review Chemistry (6th edition)

Barron's: Let's Review Chemistry (6th edition, 2017)

590 pages

Concepts with notations (are they within Intent Core?)

general

  1. minus
  2. plus
  3. times