It looks like you're using an Ad Blocker.

Please white-list or disable AboveTopSecret.com in your ad-blocking tool.

Thank you.

 

Some features of ATS will be disabled while you continue to use an ad-blocker.

 

Using LaTex and AMS-LaTex

page: 1
5

log in

join
share:

posted on Aug, 10 2017 @ 05:57 PM
link   
Hi Ye of Little Hope!

I was kind of intimidated in the amount of time and energy I might have had to invest in learning yet another computer tool, language, text markup language. So I held off for as long as I could being old fashioned and scribbling on paper with pen, sweat, and beer!

I was bored, out of beer, food, and money, the other night so I picked up one of my math books. I was reading an introduction (College level) to algebra and noticed a couple things still being taught and thought, "That is so backwards!" I figured I could write some things down and maybe, just maybe, write it up in a paper to see what sticks against the wall. Went to the arXiv and saw that everything is very well regulated. One item is the exclusive use of LaTex.


LaTeX (... a shortening of Lamport TeX) is a document preparation system. When writing, the writer uses plain text as opposed to the formatted text found in WYSIWYG word processors like Microsoft Word, LibreOffice Writer and Apple Pages. The writer uses markup tagging conventions to define the general structure of a document (such as article, book, and letter), to stylise text throughout a document (such as bold and italics), and to add citations and cross-references.

Wikipedia - LaTex.

The one used to do maths is a variation called AMS-LaTex.

So off to latex-project.org I go. First thing is, "Download the files..." GAH! I can't just install any old files I want to on a computer at work. So I search around a bit more.

I found this site: Hostmath (.com)

It has a little window that you enter in LaTex commands in and the output is displayed below. You can either type in free hand or, like I tend to do here, write it off in another document then cut-n-paste.

Reference material to get started, wikibooks.org: LaTex.

After wasting my lunch hour I actually found it to be fun!



Which is converted to...



The output is the same as one at Wikipedia for the Riemann Hypothesis. It is not really that much more difficult than doing BBcodes here at ATS. I went on and created code for Euler's Product and an expansion of both the RH code and Euler. Bwaaahaaahaaaaa!

I hope that this is informative and if you had ever wondered what the heck it was all about that you try the Hostmath site and get some hands-on learning of LaTex!


edit on 10-8-2017 by TEOTWAWKIAIFF because: speling and clarity




posted on Aug, 15 2017 @ 02:34 PM
link   

source: xkcd.com, Collatz Conjecture

The Collatz Conjecture is fairly easy to explain. You probably were bored silly in school when it was presented.


Take any positive integer n. If n is even, divide it by 2 to get n / 2. If n is odd, multiply it by 3 and add 1 to obtain 3n + 1. Repeat the process indefinitely. The conjecture is that no matter what number you start with, you will always eventually reach 1.

Wikipedia


Seems easy, right? So try a few numbers. Restated, take any positive number, if it is even, divide it by 2 and that is your new number; if it is odd, do the other math step; do this enough times you end up at 1.

n = 4 (yup, even), n = (4/2) = 2; (yup, even), n = (2/2) = 1

Done!

All even numbers will always ‘sink’ to one.

Why?

An even number is a number that can be evenly divided – Euclid

Modern math has a function called “modulo” which states, for even values of n, the following is true,
n ≡ 0 (mod 2)

It reads: “n is congruent to zero, mod 2”

For odd numbers you can use the same notation can be used but with a different result. n ≡ 1 (mod 2)

Basically, divide any number by 2 and you will get either [0, 1] as a result.

Why bother even looking at even numbers then?!! Eventually, if the even number kicks out an odd number, you will either have already dealt with it, or, you are going to deal with it in the future!

To create odd number, you have the clues in the modulo math.

Odd number = 2 * x + 1, x ϵ [1, 2, 3, …]

Continued...

edit on 15-8-2017 by TEOTWAWKIAIFF because: formatting

edit on 15-8-2017 by TEOTWAWKIAIFF because: clarity



posted on Aug, 15 2017 @ 02:48 PM
link   
... continued

See what being limited to BBcodes does? If you quote the previous post you see that there are several items that converted over to what BBcode it wants to. That is why the LaTex mark-up language was invented. So all the output will look the same. Plus a PDF can be watermarked, time-date stamped, etc. That is what they are doing over at the arXiv. This prevents somebody else from appropriating your work. It also makes it difficult to prove that somebody else was first even if they claim it. The problem with arXiv.org is that it is restricted (not any old shmoe can post a paper).

See, quantamagazine.com - A Long-Sought Proof, Found and Almost Lost, for the tales of a retired statistician that proved a math problem but only knew MS Word. The proof was never review because he never heard of LaTex! A couple mathematicians came to his rescue and posted his proof out to the arXiv and it was finally accepted!

That is what I am doing! Screwing around with Collatz, found a couple interesting things out and taking the time to learn LaTex so maybe, just maybe, I can find a sponsor on the arXiv to see if what I found is valid or not.

This is my motivation to get old documentation here at work updated so I can shove it off to somebody else on the next step of the process and work on my LaTex skills.

Next up, a LaTex treatment of the above mess in pretty, formatted PDF glory!

- end (this installment) -

PS - There are versions available for iPhone, Andriod, etc.
edit on 15-8-2017 by TEOTWAWKIAIFF because: proper end to a "continued"



posted on Aug, 15 2017 @ 04:27 PM
link   
The below is the code for the LaTex image following (the equatin)



The caption should say, "Collatz Conjecture Function" but hey, for 15 minutes of looking up various functions, I'm not going to complain! It took me an hour to get back onto ATS to upload, way more than it took me to look up some formatting and functions.

It is so much better to see it as math. The choice is called "parity" of a number. If, when divided by two, there is no remainder, it is even (congruent to "0" as the number divides equally). If there is a remainder of 1 then it is odd. The result of dividing by two is one or the other. Your options are to divide by two; or, multiply by 3 and add 1 (I have a variation up as the f(n), since the result will always be even, why not divide by two immediately? So I did).

I haven't done math in a while where I have to decipher my own scribble! This is such a vast improvement over Word's equation editor! I don't know why I had an irrational fear of "another" language as in the end, it save so much time.


edit on 15-8-2017 by TEOTWAWKIAIFF because: keep it simple teot



posted on Sep, 7 2017 @ 05:22 PM
link   
Update

 


The environment is rather robust! LaTex uses a bunch of scripts (looks like Perl) with a bunch of fonts (you do not have to load them all), and converts your text file (ends with ‘.tex’) to an intermediate file (this one ends, ‘.DVI’). The included files that you create in another document application need to be known where you placed them (typically the same file folder, named the same but with different file type endings). Then the DVI and associated files are all combined into a single PDF file.

The nice thing about this format is that depending on the journal (or book, or whatever other output you are generating—there is a music format!), they can have specific headers you can download as templates. That way they do not allow all kinds of crazy colors or unnecessary fonts pollute their pre-defined standard.

It assumed that certain document types are going to have certain characteristics. For example, a “book” is going to be different than a “journal article” with a page of references at the end. A journal article does not need an epilogue, etc.

The real cool part is you do not need to number your pages! You do not number your figures! You use block commands to specify that the next section is a figure and what to do with it (place in-line with the text or leave it to the end, e.g.) When the .tex file is converted to DVI format all those figure numbers and pagination is figured out! You can add an index or appendices as needed and LaTex will number it all!

Let’s say you have a great Excel table with a pivot and a nice graph. You can make certain everything is perfect, save it, then send it to a helper application that will convert the .xls format over to one LaTex recognizes (open source), then you tell it to use that file (remember those associated files mentioned before? That LaTex needed to know where they were? This is why!), and automagically it appears where you tell it to! It gets a number assigned to it which is also cross-referenced in the index with page numbers! Need a caption for your figure? Within your LaTex figure block use a command to add a caption to the figure. You then get “Fig. x – ‘Whatever helper text you added’” underneath. All the positioning, numbering and everything else is already taken care of; again, how cool is that!?

One word of warning: you need to RTFM: read the funny manual! The format looks strange at first but I am now “reading” it pretty well. That is what… a couple days doing math functions and a couple hours reading about the document as a whole spread over a couple weeks. Not too bad.

Now I just need to get the Mac version, get my mac back up and running first (I guess), and start plinking around with arcane and frustrating LaTex debugging!



new topics

top topics
 
5

log in

join