Skip to main content
Participant
January 8, 2019
Question

Math Formulas

  • January 8, 2019
  • 2 replies
  • 1667 views

Is there a way to search for formulas in the documents. A lot of the things I would like to search for are math formulas. Things with subscripts and superscripts.

This topic has been closed for replies.

2 replies

Thom Parker
Community Expert
Community Expert
January 10, 2019

If you mean searching for text with sub and super scripts, then yes, it's possible, but tricky. The idea is to acquire the median baseline and height of text on a line, then look for individual words that are smaller and above or below the baseline. If they exist, then you can extrapolate to find the complete formulas. But like I said, this is tricky and inexact stuff. You'd need a full blown AI to really do this correctly.

Thom Parker - Software Developer at PDFScriptingUse the Acrobat JavaScript Reference early and often
VinhkanAuthor
Participant
January 10, 2019

Yes so I have a text book. Electrical engineering. Full of equations on the

pages. I was scanning in one chapter which works great. Searching is good

also except the OCR doesn’t recognize those math equations. I mean it’s ok.

I can’t search the real book either. But it would have been nice.

On Thu, Jan 10, 2019 at 2:03 PM Thom Parker <forums_noreply@adobe.com>

try67
Community Expert
Community Expert
January 10, 2019

If the results of the OCR are not good then it's a lost cause.

Inspiring
January 10, 2019

There are very few few formulas or functions stored within a PDF. Almost all are user written in JabaScript and aded by the author of the form. There some folder level functions to sum,  multiply, compute an average for some calcuation options. Exponentiation is done using JavaScript's Math.pow() or Math.exp() methods. JavaScript also supports array type variables.

For a detailed answer you might want to provide more specific details. Also Adobe has a number of tutorials and videos about creating forms and http://www.pdfscripting.com has a number of free examples as well as paid for examples and lessons.

try67
Community Expert
Community Expert
January 10, 2019

I think they mean actual formulas, written on the page...