Second round of final edits
This commit is contained in:
parent
c423123cc3
commit
aadb1823b2
@ -153,7 +153,7 @@ I'm pushing this to my own git server as I write this. You can find it \href{htt
|
||||
|
||||
You can just skip over all the diversions in here if you want. It's just how my mind works. (And yes, there will be politics in this. \textit{You have been warned.}) Also, I use a lot of em-dashes, parentheses, and footnotes because that is also how my mind works. It's just one big long stream of consciousness up in here most days.
|
||||
|
||||
If you want to donate money to provide financial support for the creation of this zine (and all the hours of research that go into it), you can do so at
|
||||
If you want to donate financial support for the creation of this zine (and all the hours of research that go into it), you can do so at
|
||||
|
||||
\kref{https://paypal.me/kjodle}{https://paypal.me/kjodle} (Thanks!)
|
||||
|
||||
@ -180,7 +180,7 @@ I'm gratified that this zine has a small but dedicated fan base who have a lot o
|
||||
|
||||
I apologize that I can't get these out on a more regular basis. When I was younger, I wrote all the time, but as I get older, I find that I write more slowly and often with great difficulty. Part of that is no doubt my current job (which I was going to write about that in this issue, but I ran out of space, so it will have to wait until next time) and part of it is…well, all the things that go along with just trying to make it in this day and age.
|
||||
|
||||
And a large part of it is no doubt because I have short bursts when I get quite a bit done, and then long periods where I get nothing done. One of my college professors said that I tend to ``run hot and cold'', some other people have told me that this sounds like bipolar disorder, and others have said that this is a natural part of the creative process for some people. I suppose there isn't any reason that it couldn't be all three.
|
||||
And a large part of it is no doubt because I have short bursts when I get quite a bit done, and then long periods where I get nothing done. This is not new—one of my college professors said that I tend to ``run hot and cold''. Some people have told me that this sounds like bipolar disorder, and others have said that this is a natural part of the creative process for some people. I suppose there isn't any reason that it couldn't be all three.
|
||||
|
||||
Another reason is that I find I write best when I can work longhand. There is just something about the feel of pen or pencil on paper that really gets my creative gears going. Once they get going, I can usually switch to working digitally without too many problems.
|
||||
|
||||
@ -214,9 +214,9 @@ I did not realize it at the time,\footnote{I may not have realized it until just
|
||||
\vspace{-4mm}
|
||||
|
||||
\begin{multicols}{2}
|
||||
If you complain about being stuck in a low-paying job, people tell you that you should go to college. If you do go to college and then complain about being crushed under a tremendous amount of student loan debt, people tell you that you should have gotten a job that doesn't require a college degree. It's a vicious circle.
|
||||
If you complain about being stuck in a low-paying job, people of a certain stripe tell you that you should go to college. If you do go to college and then complain about being crushed under a tremendous amount of student loan debt, those same people will then tell you that you should have gotten a job that doesn't require a college degree.
|
||||
|
||||
What never gets pointed out is that college costs have risen disproportionately compared to the rate of inflation. From 1980 to 2024, the average price to attend a four-year college full time went from just over \$10,000 a year to almost \$30,000 a year when adjusted for inflation\footnote{\kref{https://www.forbes.com/advisor/student-loans/college-tuition-inflation/}{https://www.forbes.com/advisor/student-loans/college-tuition-inflation/}}—an increase of 180\%. Whereas the state of California used to provide \textit{free} college tuition back in the day\footnote{\kref{https://www.insidehighered.com/blogs/digital-tweed/tuition-free-college-yesterday-and-tomorrow}{https://www.insidehighered.com/blogs/digital-tweed/tuition-free-college\\-yesterday-and-tomorrow}} it no longer does—because then-governor Ronald Reagan wanted to punish the University of California for tolerating student activism.\footnote{\kref{https://calmatters.org/explainers/cost-of-college-california/\#d6b48652-908b-4639-be19-3f09ecab02f9}{https://calmatters.org/explainers/cost-of-college-california/\#d6b48652-\\908b-4639-be19-3f09ecab02f9}}\textsuperscript{,} \footnote{For more detailed information on rising college costs, see \kref{https://educationdata.org/average-cost-of-college-by-year}{https://educationdata.\\org/average-cost-of-college-by-year}.}
|
||||
What people consistently fail to remember is that college costs have risen disproportionately compared to the rate of inflation. From 1980 to 2024, the average price to attend a four-year college full time went from just over \$10,000 a year to almost \$30,000 a year when adjusted for inflation\footnote{\kref{https://www.forbes.com/advisor/student-loans/college-tuition-inflation/}{https://www.forbes.com/advisor/student-loans/college-tuition-inflation/}}—an increase of 180\%. Whereas the state of California used to provide \textit{free} college tuition back in the day\footnote{\kref{https://www.insidehighered.com/blogs/digital-tweed/tuition-free-college-yesterday-and-tomorrow}{https://www.insidehighered.com/blogs/digital-tweed/tuition-free-college\\-yesterday-and-tomorrow}} it no longer does—because then-governor Ronald Reagan wanted to punish the University of California for tolerating student activism.\footnote{\kref{https://calmatters.org/explainers/cost-of-college-california/\#d6b48652-908b-4639-be19-3f09ecab02f9}{https://calmatters.org/explainers/cost-of-college-california/\#d6b48652-\\908b-4639-be19-3f09ecab02f9}}\textsuperscript{,} \footnote{For more detailed information on rising college costs, see \kref{https://educationdata.org/average-cost-of-college-by-year}{https://educationdata.\\org/average-cost-of-college-by-year}.} (Oh no! We've taught people how to think and now they're doing it!)
|
||||
|
||||
A well-educated populace is a public good and there is no humane reason why any economically successful nation should burden its youth with high levels of student loan debt. There are plenty of inhumane reasons, however, the primary one being that conservative politicians do not want a well-educated populace, as it is easier to exploit them for commercial gains if they have no idea what is happening to them. It's much easier to pin their woes on the boogeyman of ``communism'' despite the fact that they have no idea what communism actually is. In short, unless you have capital, capitalism is not your friend.
|
||||
\end{multicols}
|
||||
@ -226,45 +226,46 @@ A well-educated populace is a public good and there is no humane reason why any
|
||||
|
||||
His second argument was that as a prospective biology teacher, I was required to get a group science ``minor'', which is in quotation marks because it was actually 36 credit hours (the equivalent of a major) rather than the 20 credit hours typical of an actual minor. As a result, I would have little time or energy (or money!) for another minor.
|
||||
|
||||
So in 2008 I decided to go back to teaching. To renew my license, I needed to get eight credit hours in ``a teachable subject'' and I decided to take a couple of English classes, as that would both meet the legal requirements and also give me a chance to read and write for credit.
|
||||
There are very solid reasons I got of out teaching, but unemployment makes us do strange things. So in 2008 I decided to go back to teaching. To renew my license, I needed to get eight credit hours in ``a teachable subject'' and I decided to take a couple of English classes, as that would both meet the legal requirements and also give me a chance to read and write for credit.
|
||||
|
||||
As they say, things happened.
|
||||
|
||||
At first I signed up for two English classes. But then I thought, that's eight credit hours. If I take three more I could actually get the full minor. Why not? So a couple of English classes became an English minor, which eventually became an English major.
|
||||
|
||||
Becoming a biology teacher required that I take a \textit{methods} class, which is a class about…well, basically it's a class about how to \textit{be} a biology teacher. It teaches you how to plan labs and field trips, and how to do things in a safe way so that nobody gets hurt, and covers the specifics of teaching biology that were not covered in your regular education classes.
|
||||
Becoming a biology teacher required that I take a \textit{methods} class, which is a class about…well, basically it's a class about how to \textit{be} a biology teacher. It teaches you how to plan labs and field trips, and how to do things in a safe way so that nobody gets hurt, and it covers the specifics of teaching biology that were not covered in your regular education classes.
|
||||
|
||||
Becoming an English teacher required that I take \textit{three} methods classes: one about teaching literature, another about teaching grammar, and a third about teaching writing. I remember very little about the first two. To be honest, I remember more about the graduate class I took in fairy and folk tales, because those tales evolve like living beings—which in a way they are. This was where biology and literature overlapped for me in the Venn diagram of my life.
|
||||
Becoming an English teacher required that I take \textit{three} methods classes, however: one about teaching literature, another about teaching grammar, and a third about teaching writing. I remember very little about the first two. To be honest, I remember more about the graduate class I took in fairy and folk tales, because those tales evolve like living beings—which in a way they are. This was where biology and literature overlapped for me in the Venn diagram of my life.
|
||||
|
||||
The one thing I remember very distinctly about the writing methods course was that our capstone project had to be \textit{online}. Oh wow, I thought—I've been creating websites for a while now. But I was worried. I had been hearing about how young people were so good with technology, far better than any previous generation, in fact. I was sure whatever they came up with would just blow my feeble old school attempts out of the water.
|
||||
|
||||
I could not have been more wrong.
|
||||
|
||||
Our instructor asked how many of us had any experience creating websites. Only three of us raised our hands: a middle-aged woman, a college-aged woman, and myself. Half of the rest of the class had mildly panicked looks on their faces.
|
||||
Our instructor asked how many of us had any experience creating websites. Only three of us raised our hands: a woman close to my age, a college-aged woman, and myself. Half of the rest of the class looked perplexed and the other half looked mildly panicked.
|
||||
|
||||
Our instructor sent the three of us into a small computer lab at the end of the classroom to start making plans while she explained to the rest of the class how to create a web site. Of course, if you leave three students alone in a room, they're not going to get any work done—they're going to sit and talk. It doesn't matter what their ages are—work is just not going to be a priority for them. Instead, we sat and talked about how we got here.
|
||||
Our instructor sent the three of us into a small computer lab at the end of the classroom to start making plans while she explained to the rest of the class how to create a web site. Of course, if you leave three students alone in a room, they're not going to get any work done—they're going to sit and talk. It doesn't matter what their ages are—work is just not going to be a priority for them. We didn't work. Instead, we sat and talked about how we got here.
|
||||
|
||||
As it turns out, the older woman and I both had experience creating websites from scratch and the younger woman (the only one of the three us who was still on Plan A) had once set up a forum for her gaming community using phpBB, which is not quite the same thing as setting up a website, but close enough. It's better than nothing. She also spent quite a bit of time talking about ``leetspeak'' which had somehow passed me by—perhaps because I have never been much of a gamer.\footnote{Everything I read about this makes me feel that is either something that is pretty cool or the most annoying thing in the world. I can't quite make up my mind.}
|
||||
|
||||
Still, this left some twenty-odd young people on the other side of that door who were utterly clueless about how to create a website, and were more than a little nervous about the prospect.
|
||||
|
||||
I mention all of this because what I often heard then was young people are \textit{so} good with computers, that they are \textit{so} comfortable with computers, and why wouldn't they be? After all, they grew up with them. In fact, the term that got bounced around a lot in the education world at the time was ``digital native''. It was just assumed that young people could do anything with computers because they had grown up with them.
|
||||
I mention all of this because it was generally assumed that young people were \textit{so} good with computers, that they were \textit{so} comfortable with computers, and why wouldn't they be? After all, they grew up with them. In fact, the term that got bounced around a lot in the education world at the time was ``digital native''. It was just assumed that young people could do anything with computers because they had grown up with them.
|
||||
|
||||
Well, I had grown up with computers, too, only I did it twenty-five years before these kids did and the computers I grew up with did not have a GUI or a mouse. They made you think a little bit more than modern computers.
|
||||
|
||||
But it is not the presence or absence of a mouse or a GUI that makes you good with a computer. A lot of kids my age also had Commodore 64s and all they did with them was shove a cartridge in the back and play games. This in no way prepared them to know how to set up a spreadsheet in VisiCalc to balance your checkbook.\footnote{Which was one of the very first things I ever tried to do with a spreadsheet. It is not nearly as easy as one might think.}
|
||||
|
||||
I blame the educational industrial complex here, which I believe is where the term ``digital native'' came from. (And again, this is a feature, not a bug, of capitalism. The main goal under capitalism is to just extract as much money as you can from the people around you, and it doesn't really matter if you are correct or not. Your only value is determined by how much wealth you bring to the shareholders.)
|
||||
I blame the educational industrial complex here, which I believe is where the term ``digital native'' came from. (And again, this is a feature, not a bug, of capitalism. Your main goal under capitalism is to just extract as much money as you can from the people around you, and it doesn't really matter whether you are doing the right thing or not. Your only value is determined by how much wealth you bring to the shareholders.)
|
||||
|
||||
Growing up with a computer in your house doesn't mean that you'll be an expert at anything and everything digital any more than growing up with a car in the driveway means you'll know how to drive it, let alone change the oil or rebuild the carburetor. It's a completely false assumption.
|
||||
Growing up with a computer in your house doesn't mean that you'll be an expert at anything and everything digital any more than growing up with a car in the driveway means you'll know how to drive it, let alone change the oil or rebuild the carburetor. It's a completely false assumption. The looks on my fellow students' faces proved that.
|
||||
|
||||
Still, most if not all of these other students figured it out. They created their lesson plans, they got them online, they presented a highly abbreviated form of them to the class, they got their final grade, and they moved on.
|
||||
|
||||
I did actually get mine online by crafting html and css by hand.\footnote{Shades of \textit{The Pushcart War}! One my favorite books from my childhood that shows that resistance is most definitely not futile.} And for a while it lived in a subdomain on my website but then \textit{mobile} became the thing and I was not good at adapting sites to be mobile-friendly at that point (it's a piece of cake now\footnote{Also, there some sites that just \textit{shouldn't} be mobile-friendly. Do you really want air traffic controllers directing airplanes from their phones?} and I also changed webhosts because I was not happy with some of the business decisions my then current webhost made and then I changed webhosts \textit{again} because the dream host I had found (WebFaction) had been purchased by GoDaddy (which is a terrible company) and I eventually found a job outside of teaching because you can only eat for so long on a substitute teacher's salary, and I've let it go by the wayside. I'm sure I still have the files on a back-up drive somewhere, so I could theoretically get it online again (and in a mobile-friendly form) if I wanted to and had a long Saturday afternoon to devote to it.
|
||||
I did get mine online by doing what I'd always done—crafting html and css by hand.\footnote{Shades of \textit{The Pushcart War}! One my favorite books from my childhood that shows that resistance is most definitely not futile.} And for a while it lived in a subdomain on my website but then \textit{mobile} became the thing and I was not good at adapting sites to be mobile-friendly at that point (it's a piece of cake now\footnote{Also, there some sites that just \textit{shouldn't} be mobile-friendly. Do you really want air traffic controllers directing airplanes from their phones?}) and I also changed webhosts because I was not happy with some of the business decisions my then current webhost made and then I changed webhosts \textit{again} because the dream host I had found (WebFaction) had been purchased by GoDaddy (which is a terrible company) and I eventually found a job outside of teaching because you can only eat for so long on a substitute teacher's salary, and I've let it go by the wayside. I'm sure I still have the files on a back-up drive somewhere, so I could theoretically get it online again (and in a mobile-friendly form) if I wanted to and had a long Saturday afternoon to devote to it.
|
||||
|
||||
But I'm not going to be a teacher ever again, so there's no point in that. That would be looking backward, not looking forward. And I don't like to get mired in the past, despite the fact that I have spent so many of these columns talking about what a delight it was. The fact is that \textit{parts} of it were delightful and many more parts were utterly terrifying.
|
||||
|
||||
And if that's the past, who knows what the future holds?
|
||||
Terror or delight? Either way, like my former classmates, I'm moving on.
|
||||
|
||||
|
||||
\chapter{How to Be Good With Computers}
|
||||
@ -280,7 +281,7 @@ First, they are not afraid to experiment. They know how to \textit{undo} things,
|
||||
|
||||
Second, they are good at recognizing patterns. This means that they don't need to reinvent the wheel each time; they can look at a new problem and see if it is similar to an old one and whether it's possible to adapt an older, tried and true solution to this new problem. ``The thing that hath been, it is that which shall be; and that which is done is that which shall be done: and there is no new thing under the sun.''\footnote{Eccleiastes 1:9} All our new problems are just iterations of our old problems.
|
||||
|
||||
Third, they are good at searching the web for a solution. This is easier now than it was twenty years ago because the web is simply so much bigger than it was then. There is an art and a science to this, so much so that we used to use the term ``google-fu'' or ``search-fu''\footnote{Like ``kung-fu''. Get it? \textit{Get it?} Sometimes we are tiresome people.}. But all this really means is knowing how to construct a search query that does not return superfluous answers. In the old days it was largely knowing how Boolean operators worked, and then selecting appropriate arguments for those operators. These days, artificial intelligence is probably going to screw this completely up. (Or they already have—I recently saw a screen clip of an AI bot recommending adding half a cup of glue to your gravy to thicken it up. I'm sure this would work, but it would not be the gravy you are looking for.)
|
||||
Third, they are good at searching the web for a solution. This is easier now than it was twenty years ago because the web is simply so much bigger than it was then. There is an art and a science to this, so much so that we used to use the term ``google-fu'' or ``search-fu''\footnote{Like ``kung-fu''. Get it? \textit{Get it?} Sometimes we are tiresome people.}. But all this really means is knowing how to construct a search query that does not return superfluous answers. In the old days it was largely knowing how Boolean operators worked, and then selecting appropriate arguments for those operators. These days, artificial intelligence is probably going to screw this completely up. (Or it already has—I recently saw a screen clip of an AI bot recommending adding half a cup of glue to your gravy to thicken it up. I'm sure this would work, but it would not be the gravy you are looking for.)
|
||||
|
||||
I can give a couple of examples here. At my old job, we received planning schedules from our customers on a weekly basis. Our material planner would print these out and enter their data into our system which would then give us an idea of how much production we needed to run each week.
|
||||
|
||||
@ -292,9 +293,9 @@ Because it worked (and worked \textit{well}) I was lauded as a guy who is ``good
|
||||
|
||||
But does this make me an expert at Microsoft Excel or at VBA? Hardly. I mean, it did to all those people who saw this spreadsheet in action. But I didn't view myself as someone who was good at Excel or VBA. I just viewed myself as someone with a dogged determination to keep experimenting until I got it right. To me, the idea of someone who is ``good with computers'' is \textit{very} relative and not at all absolute.
|
||||
|
||||
Proof of this came in the form of an engineer that we hired out of his early retirement. He said he was not good with computers, but that he was adequate to the task required. Despite being merely adequate, he showed me a trick that I have been using ever since.
|
||||
Proof of this came in the form of an engineer that we hired out of his early retirement. He said he was not good with computers, but that he was adequate to the task required. Despite being ``merely adequate'', he showed me a trick that I have been using ever since.
|
||||
|
||||
One of my many frustrations with Excel, and indeed pretty much any spreadsheet program, has always been that if you need to edit the data at the end of the cell\footnote{where I am most likely to make a mistake} it's always a two-step process. Either you click on the cell to select it and then click in the formula bar to move the cursor to the end of that data, or you have to click on the cell to select it, and then click again on the right end of that cell to move the cursor. (If you click in the middle of the cell, then that's where the cursor ends up. Who is in charge of this stuff?)
|
||||
One of my many frustrations with Excel, and indeed pretty much any spreadsheet program, has always been that if you need to edit the data at the end of the cell\footnote{Which is where I am most likely to make a mistake.} it's always a two-step process. Either you click on the cell to select it and then click in the formula bar to move the cursor to the end of that data, or you have to click on the cell to select it, and then click again on the right end of that cell to move the cursor to the end of that data. (If you click in the middle of the cell, then that's where the cursor ends up. Who is in charge of this stuff?)
|
||||
|
||||
Just writing all that gives me a headache. It's no wonder people so often give the side-eye not just to Excel but to most Microsoft products. (As they should.)
|
||||
|
||||
@ -312,7 +313,7 @@ To my way of thinking the person who is responsible for the maintenance of this
|
||||
|
||||
I am still able to use VBA to do little bits here and there for other people—creating forms that generate a pdf and then automatically attach it to an email, for instance. I've done this a couple of times and the people on the other end have been suitably impressed, so I've added this skill to my resume. Imposter syndrome be damned!
|
||||
|
||||
The number one characteristic I've discovered that is shared by all people who are generally viewed as ``good with computers'' is \textit{confidence}. Not knowledge, not skill, not experience. \textit{Confidence}. It's true that confidence comes from knowledge, skill, and experience, but I've met a lot of people who have all three of those things\footnote{How can you \textit{not} have experience with computers in 2024, when even Amish people have cell phones? It's because you can either choose to recognize that they are a part of your experience and roll with it, or refuse to acknowledge them and fight a losing battle against them.} but who still lack confidence and thus do not see themselves, nor are by others, as being good with computers. I've had to coach a lot of people like this over the years and while it's easy to give someone knowledge, or experience, or skill, it's almost impossible to get them to put those three things together into confidence. It's really something they have to gain on their own, and they either do or they don't. I'm not sure why this is.
|
||||
The number one characteristic I've discovered that is shared by all people who are generally viewed as ``good with computers'' is \textit{confidence}. Not knowledge, not skill, not experience. \textit{Confidence}. It's true that confidence comes from knowledge, skill, and experience, but I've met a lot of people who have all three of those things\footnote{How can you \textit{not} have experience with computers in 2024, when even Amish people have cell phones? It's because you can either choose to recognize that they are a part of your experience and roll with it, or refuse to acknowledge them and fight a losing battle against them.} but who still lack confidence and thus do not see themselves, nor are seen by others, as being good with computers. I've had to coach a lot of people like this over the years and while it's easy to give someone knowledge, or experience, or skill, it's almost impossible to get them to put those three things together into confidence. It's really something they have to gain on their own, and they either do or they don't. I'm not sure why this is.
|
||||
|
||||
% New section starts with a drop cap
|
||||
\medskip
|
||||
@ -349,7 +350,7 @@ alias gita="git add *"
|
||||
alias gitx="git add *.tex"
|
||||
\end{Verbatim}
|
||||
|
||||
The first one just prints out the status of any git project that I'm working. The second one will automatically add all files (except for invisible files) to the commit. Because I use \LaTeX{} a lot, I also have the third one, which will commit any new or changed files that end in a \texttt{.tex} extension.
|
||||
The first one just prints out the status of any git project that I'm working on. The second one will automatically add all files (except for invisible files) to the commit. Because I use \LaTeX{} a lot, I also have the third one, which will commit any new or changed files that end in a \texttt{.tex} extension.
|
||||
|
||||
I rarely have invisible files in my git repositories except for the .gitignore file, which I seldom change, so I don't need a bash alias for it. I find it easy enough to type \verb+git add .gitignore+ on the rare occasion that I need it. But if I did want to add that file on a regular basis, I could just change that line to:
|
||||
|
||||
@ -367,7 +368,7 @@ Of course, if I were changing my \textit{.gitignore} file that often, I would st
|
||||
|
||||
\section{Bash Commands for \textit{git}}
|
||||
|
||||
It would be nice if we could do the same sort of thing for \texttt{git commit}, but we can't, because we need to add some sort of message to our commit. In other words, it requires an \textit{argument}. So for that, we need to add a \textit{function} to bash.
|
||||
It would be nice if we could do the same sort of thing for \texttt{git commit}, but we can't, because we need to add a message to our commit. In other words, it requires an \textit{argument}. So for that, we need to add a \textit{function} to bash.
|
||||
|
||||
As it turns out, this is pretty simple. It looks like this:
|
||||
|
||||
@ -383,7 +384,7 @@ First, we start with our basic function, which is written like any other functio
|
||||
gitm()
|
||||
\end{Verbatim}
|
||||
|
||||
Now we add whatever commands we want between curly brackets. In this case we're only going to add one, which is the \verb+git commit -m "$1";+ bit. The only thing unique here is that we have a variable (\verb+$1+) which references our first and only argument, which is the commit message we are going to add.
|
||||
Now we add whatever commands we want between curly brackets. In this case we're only going to add one, which is the \verb+git commit -m "$1";+ bit. The only thing unique here is that we have a variable (\verb+$1+) that references our first and only argument, which is the commit message we are going to add.
|
||||
|
||||
Once we have added all the files we need to our commit, we can then create the commit with something like this:
|
||||
|
||||
@ -397,7 +398,7 @@ which is a \textit{bit} shorter than typing
|
||||
git commit -m "Updated section on bash aliases"
|
||||
\end{Verbatim}
|
||||
|
||||
Admittedly, this doesn't save us a ton of keystrokes every time we use it, but if we make git commits on a regular basis, it saves enough keystrokes to make it worth it. Also, it's a shorter construction, so there's that much less chance of making a typo.
|
||||
Admittedly, this doesn't save us a ton of keystrokes every time we use it, but if we make git commits on a regular basis, it saves enough keystrokes to make it worthwhile. Also, it's a shorter construction, so there's that much less chance of making a typo.
|
||||
|
||||
\section{More about bash commands}
|
||||
|
||||
@ -410,9 +411,9 @@ cdl() {
|
||||
\end{Verbatim}
|
||||
% $
|
||||
|
||||
This will change to whichever directory we specify with the \verb+$1+ placeholder, and then present a directory listing which shows all files, with human-readable sizes, in a long format. That may not be highly useful, but it's enough to give you an idea of how powerful this using bash aliases and Bash functions can be.
|
||||
This will change to whichever directory we specify with the \verb+$1+ placeholder, and then present a directory listing which shows all files, with human-readable sizes, in a long format. That may not be highly useful, but it's enough to give you an idea of how powerful bash aliases and bash functions can be.
|
||||
|
||||
As another example, I like to write rough drafts in longhand, on notebook paper. I find that I am more creative that way. The problem is that I intensely dislike being surrounded by piles of paper. (ADHD means that if I can't see something, it no longer exists. So my brain will only really see whatever is on top of the pile.) So whenever I finish up a rough draft, I scan it to a ``Drafts'' folder, where it goes into a subfolder labeled for whatever projects it belongs to.\footnote{Yep, there is a subfolder labeled ``the codex'' with drafts for this zine.} So that I can see everything, I use the \texttt{tree} command to create a file which lists every single scan in that ``Drafts'' folder.
|
||||
As another example, I like to write rough drafts in longhand, on notebook paper. I find that I am more creative that way. The problem is that I intensely dislike being surrounded by piles of paper. (ADHD means that if I can't see something, it no longer exists. So my brain will only see whatever is on top of the pile.) Whenever I finish up a rough draft, I scan it to a ``Drafts'' folder, where it goes into a subfolder labeled for whatever projects it belongs to.\footnote{Yep, there is a subfolder labeled ``the codex'' with drafts for this zine.} So that I can see everything, I use the \texttt{tree} command to create a file which lists every single scan in that ``Drafts'' folder.
|
||||
|
||||
So far, so good, but running the same \texttt{tree} command consistently is not something my brain is set up to do. So I added this function to my \texttt{.bashrc} file:
|
||||
|
||||
@ -420,9 +421,9 @@ So far, so good, but running the same \texttt{tree} command consistently is not
|
||||
drafts(){ tree $HOME/Drafts/ -R --prune > $HOME/Drafts/list.txt; }
|
||||
\end{Verbatim}
|
||||
|
||||
What that command does is go to that ``Drafts'' folder, runs the \texttt{tree} command with the \texttt{-R} (recursive) and \texttt{--prune} (to ignore empty directories) options and then sends the standard output to a file called \texttt{list.txt}. I print out the \texttt{list.txt} file whenever I am searching for something to write up, and I can see in an instant what rough drafts I can work on. My ADHD brain is pretty happy with this arrangement, as nothing gets buried in a pile of files, and I don't have a ton of paper sitting around.
|
||||
What that command does is go to that ``Drafts'' folder, runs the \texttt{tree} command with the \texttt{-R} (recursive) and \texttt{--prune} (to ignore empty directories) options and then sends the standard output to a file called \texttt{list.txt}. I look at that \texttt{list.txt} file whenever I am searching for something to write up, and I can see in an instant what rough drafts I can work on. My ADHD brain is pretty happy with this arrangement, as nothing gets buried in a pile of files, and I don't have a ton of paper sitting around.
|
||||
|
||||
For what it's worth, I also have a backup script (as I mentioned in issue \#2) just for this folder. And I added that command to the top of that backup script, so that before anything gets backed up to my cloud, that \texttt{list.txt} file gets updated and uploaded as well.
|
||||
For what it's worth, I also have a backup script (as I mentioned in issue \#2) just for this folder. I added that command to the top of that backup script, so that before anything gets backed up to my cloud, that \texttt{list.txt} file gets updated and uploaded as well.
|
||||
|
||||
\section{Reloading the \texttt{.bashrc} File}
|
||||
|
||||
@ -442,17 +443,17 @@ And of course, there is also a shorthand version:
|
||||
|
||||
\chapter{The Right Ways vs The Wrong Ways \\{\small (i.e., The Hierarchy of Errors)}}
|
||||
|
||||
A lot of us grew up hearing that ``there's a right way to do things and a wrong way to do things.'' I don't disagree that there is always a \textit{wrong} way to do things, but like house maintenance, working on computers quickly teaches you that there are a \textit{lot} of different wrong ways to do things.
|
||||
A lot of us grew up hearing that ``there's a right way to do things and a wrong way to do things.'' I don't disagree that there is always a \textit{wrong} way to do things, but like house maintenance, working on computers quickly teaches you that there are a \textit{lot} of different wrong ways to do things. And despite what some people think, there is often more than one right way to do things.
|
||||
|
||||
Experience has shown me that not all wrong ways are wrong in the same way or to the same degree, and that the same is true of right ways. There may be multiple right ways to get something done, but some require less work and some require more work. It is not simply a black-and-white issue.
|
||||
Experience has shown me that not all wrong ways are wrong in the same way or to the same degree, and that the same is true of right ways. There may be multiple right ways to get something done, but some require less work and some require more work. It is not a black-and-white issue.
|
||||
|
||||
In the past few years, I've started thinking of things less in terms of a particular ``right way'' opposed to a particular ``wrong way'', and started thinking in terms of a spectrum of choices, some of which are obviously wrong (but wrong to varying degrees) and some of which are right because they work, but you have to take different roads to get there.
|
||||
In the past few years, I've started thinking of things less in terms of a particular ``right way'' opposed to a particular ``wrong way'', and started thinking in terms of a spectrum of choices, some of which are obviously wrong (but wrong to varying degrees) and some of which are right because they work (but again, right to varying degrees).
|
||||
|
||||
What I have tried to do here is to create a hierarchy of ``rightness'' and ``wrongness'' as a way to organize my thinking on this subject; I can then jump in and discuss why things fall the way they do. No doubt, other people might have more distinctions or fewer in their hierarchy, or might have things in a separate order, or might have different reasons.
|
||||
What I have tried to do here is to create a hierarchy of ``rightness'' and ``wrongness'' as a way to organize my thinking on this subject; I can then jump in and discuss why things fall where they do. No doubt, other people might have more or fewer distinctions in their hierarchy, or might have things in a separate order, or might have different reasons.
|
||||
|
||||
My purpose here is to see if I am actually making any progress, or if I am simply doing things randomly, as adult-onset attention deficit disorder is apparently a thing in my life. In other words, do my changes move me up in this hierarchy, or do they move me down?
|
||||
|
||||
And, as we shall see, sometimes it's beneficial to do something the wrong way. You generally learn more by doing things wrong than you do by doing them correctly.
|
||||
And, as we shall see, sometimes it's beneficial to do something the wrong way. You generally learn more by doing things incorrectly than you do by doing them correctly.
|
||||
|
||||
\krule{6mm}{0mm}
|
||||
\begin{center}
|
||||
@ -497,7 +498,7 @@ Let's start at the bottom, and work our way up from there.
|
||||
|
||||
\section{Very Wrong Ways}
|
||||
|
||||
Very wrongs ways are very wrong because not only do they not work, they take other things down with them.
|
||||
Very wrong ways are very wrong because not only do they not work, they take other things down with them.
|
||||
|
||||
\paragraph{It doesn't work and it breaks things in weird places.} You may wonder why this is worse than ``It doesn't work and it breaks almost everything else'' but for me the answer is simple: it can be terribly difficult to find those weird places. When I say ``weird'' I mean that they may be obscure places that nobody looks, they may be distant from the current situation and apparently unconnected,\footnote{But nothing is \textit{truly} disconnected from anything else.}, or they may be things that you don't have to rely on very often, so you may not discover that they are broken until days, weeks, or even months later.
|
||||
|
||||
@ -509,7 +510,7 @@ Very wrongs ways are very wrong because not only do they not work, they take oth
|
||||
|
||||
Wrong ways may work, but they break other things along the way. As we shall see, this is not always a bad thing.
|
||||
|
||||
\paragraph{It works, but it breaks things in weird places.} Again, the main issue here is that those weird places may not be obvious at first. You might use this technique, and it looks like it's working fine, but suddenly there is a person in Germany whose toilet no longer flushes properly. Or it works fine for you now, but in ten months \textit{your} toilet no longer flushes properly. And because these two things are so separated in place (in the former case) or time (in the latter case) it can be difficult to connect the two things, and we might end up spending a lot of time going down rabbit holes when the real solution is right in front of us the entire time. We waste time and effort.
|
||||
\paragraph{It works, but it breaks things in weird places.} Again, the main issue here is that those weird places may not be obvious at first. You might use this technique, and it looks like it's working fine, but suddenly there is a person in Germany whose toilet no longer flushes properly. Or it works fine for you now, but in ten months \textit{your} toilet no longer flushes properly. And because these two things are so separated in place (in the former case) or time (in the latter case) it can be difficult to connect the two things, and we might end up spending a lot of time going down rabbit holes when the real solution is right there in front of us the entire time. We waste time and effort.
|
||||
|
||||
\paragraph{It works, but it breaks almost everything else.} This is almost exactly like ``It doesn't work and it breaks almost everything else'' except that your solution \textit{does} work. You just need to look at your overall system and figure out why everything else is going into meltdown mode.
|
||||
|
||||
@ -525,13 +526,13 @@ Wrong ways may work, but they break other things along the way. As we shall see,
|
||||
|
||||
\paragraph{It works, but you have no idea why.} I was very tempted to put this in the wrong\textit{ish} section, and in some cases it may certainly belong there. Quite frankly, you \textit{should} know why a technique works. Not knowing why can be dangerous, because you can assume too much about this particular technique. That may cause you to be a bit overconfident with it, and use it in a situation that doesn't really warrant its use.
|
||||
|
||||
\paragraph{It works, but it requires you to rework some other parts of the project.} I admit, I was at a loss as to where to put this one. And I guess it depends if you are using a kludge or a best practice, so I'm going to assume you are using a best practice. In which case, this shows you places that you were possibly \textit{not} using something which is a best practice, and now you need to make those things better.
|
||||
\paragraph{It works, but it requires you to rework some other parts of the project.} I admit, I was at a loss as to where to put this one. And I guess it depends on whether you are using a kludge or a best practice, so I'm going to assume you are using a best practice. In which case, this shows you places that you were possibly \textit{not} using something which is a best practice, and now you need to make those things better.
|
||||
|
||||
\paragraph{It works, but it's a bit of a kludge.} A kludge is not always a bad thing (sometimes you have to work with what you have) but they are at best, inelegant, and at worst weighty and ugly. But they work for now, they don't break things, and they will last until you learn or can afford a better way. (I created a bit of a kludge when I couldn't figure out how to indent a bibliography entry.\footnote{You can see it in action in this commit for a different project: \kref{https://git.kjodle.net/kjodle/Notes-on-Python/commit/d4f93ec00f1e1078b1cfcb3aacd3481eb82bb0cd}{https://git.kjodle.net/kjodle/Notes-on-Python/commit/d4f93ec00f1e1078b1cfcb3a\\acd3481eb82bb0cd}.} Does it work? Yes. Am I happy with it? Not entirely. I'm 75\% sure there is a better way to do this, but I haven't found it yet. But it works for now, and I've marked it as a kludge, so I know this is something that I can come back to later. At least I made this less weighty and hid its heft and inelegance by turning it into a macro.)
|
||||
|
||||
\section{Right Ways}
|
||||
|
||||
\paragraph{It works, and is considered a best practice.} A best practice is one that has generally been accepted as the best way to do things not because it is perfect, but because it produces results that are better than the results achieved by other methods. This is a good thing. A best practice is a best practice because it's proven itself. It's not perfect (hence it's a ``best practice'' not a ``perfect practice''), but you can count on it to get the job done. And because it is a best practice, when things go pear-shaped, it's probably because of something you've done, but if it isn't, there will most likely be a lot of people who are \textit{very} interested in helping you.
|
||||
\paragraph{It works, and is considered a best practice.} A best practice is one that has generally been accepted as the best way to do things not because it is perfect, but because it produces results that are better than the results achieved by other methods, with either minimal or zero negative side-effects. This is a good thing. A best practice is a best practice because it's proven itself. It's not perfect (hence it's a ``best practice'' not a ``perfect practice''), but you can count on it to get the job done. And because it is a best practice, when things go pear-shaped, it's most likely because of something you've done, but if it isn't, there will probably be a lot of people who are \textit{very} interested in helping you.
|
||||
|
||||
Unfortunately, sometimes a best practice is arrived at that for no other reason than ``that's how we've always done it and nothing has exploded yet.'' That's not great, but still…have a fire extinguisher handy.
|
||||
|
||||
@ -539,7 +540,7 @@ Unfortunately, sometimes a best practice is arrived at that for no other reason
|
||||
|
||||
\paragraph{It's a true hack.}
|
||||
|
||||
As I said way back in the first issue, I define a hack as ``an appropriate application of ingenuity''\footnote{See \kref{http://www.catb.org/~esr/jargon/html/meaning-of-hack.html}{http://www.catb.org/~esr/jargon/html/meaning-of-hack.html} for more information.}. True hacks are rare and often small, whereas false hacks (that is, it only resembles a hack; like the wizard in \textit{The Wizard of Oz} who says he's a wizard and looks like a wizard, but is not an actual wizard) are all too common, and the internet is littered with them\footnote{See issues \#1 and 3 for lots of examples.}.
|
||||
As I said way back in the first issue, I define a hack as ``an appropriate application of ingenuity''\footnote{See \kref{http://www.catb.org/~esr/jargon/html/meaning-of-hack.html}{http://www.catb.org/~esr/jargon/html/meaning-of-hack.html} for more information.}. True hacks are rare and often small, whereas false hacks are all too common, and the internet is littered with them\footnote{See issues \#1 and 3 for lots of examples.}. A false hack only resembles a hack; like the wizard in \textit{The Wizard of Oz} who says he's a wizard and looks like a wizard, but is not an actual wizard.
|
||||
|
||||
If you find a true hack, enjoy it, preserve it, and help to disseminate it.
|
||||
|
||||
@ -547,13 +548,13 @@ If you find a true hack, enjoy it, preserve it, and help to disseminate it.
|
||||
|
||||
Way back in issue \#1 of this zine\footnote{Which is only three issues ago, but considering that I published it in 2021, it \textit{seems} like a long time ago. I really need to get my act together and get these out on a more regular basis.} I talked about my workflow for scanning documents because I am trying to be as digital as possible.
|
||||
|
||||
In that article ``A Scanner Darkly, but with a workflow'' I mentioned that I used one piece of commercial software (VueScan) because it did what no FOSS\footnote{Free and Open Source} software that I knew of at the time could do: work with my all-in-one printer/scanner and also sort pages effectively when my scanner's ADF\footnote{Automatic Document Feeder} does not duplex (i.e., it does not flip pages over to scan the other side). While it is great software, and I did not mind paying the \$100 for a one-year subscription to it (the software company behind it is pretty much a father and son team), I didn't like being dependent on it.
|
||||
In that article ``A Scanner Darkly, but with a workflow'' I mentioned that I used one piece of commercial software (VueScan) because it did what no FOSS software that I knew of at the time could do: work with my all-in-one printer/scanner and also sort pages effectively when my scanner's ADF\footnote{Automatic Document Feeder} does not duplex (i.e., it does not flip pages over to scan the other side). While it is great software, and I did not mind paying the \$100 for a one-year subscription to it (the software company behind it is pretty much a father and son team), I didn't like being dependent on it.
|
||||
|
||||
The reasoning is simple. If a company decides to stop producing a product, that's it; you're done. I used to have a great plugin on my WordPress sites that added social media sharing icons to each post. The company that made it got bought out by Oracle. You might think this is a great thing, because Oracle is a big huge company with a lot of resources. But when big huge companies buy small independent companies, they are often only interested in one or two of their products, and let the rest go. And this is exactly what happened. Oracle suddenly decided they weren't going to support this plugin and it just stopped working. The company's webpage for the plugin redirected to an Oracle page that basically said ``fuck off'' and little more. No explanation, no recommendations of similar plugins, nothing.
|
||||
|
||||
At least when FOSS software projects get abandoned or the original developers get better paying jobs delivering pizza, there is always the chance that someone else will take over the project. Better yet, you—yes, \textit{you}—can donate money to the project to help support it.
|
||||
|
||||
I first found out about NAPS2\footnote{\kref{https://www.naps2.com/}{https://www.naps2.com/}} because I had downloaded a book from the Internet Archive\footnote{\textit{Inherit the Stars} by James P. Hogan, which you can read at \kref{https://archive.org/details/inheritstars00jame}{https://archive.org/deta\\ils/inheritstars00jame}} and the pages were very, very yellowed. (It had been scanned from a pulp paperback printed on cheap paper with a high acid content. How seldom we plan for the future!)
|
||||
I first found out about NAPS2 (\kref{https://www.naps2.com/}{https://www.naps2.com/}) because I had downloaded a book from the Internet Archive\footnote{\textit{Inherit the Stars} by James P. Hogan, which you can read at \kref{https://archive.org/details/inheritstars00jame}{https://archive.org/deta\\ils/inheritstars00jame}} and the pages were very, very yellowed. (It had been scanned from a pulp paperback printed on cheap paper with a high acid content. How seldom we plan for the future!)
|
||||
|
||||
I was looking for a way to lighten the background of the pages so that it would be easier to read. My usual solution for this would be to open the pdf in GIMP, opening each page as a separate layer. I could then figure out the settings for one page, convert that into a script (GIMP is scriptable!), apply that script to every single layer, and export the entire thing as a pdf, remembering to tick the box that says to export layers as pages, and also to do it in reverse order.
|
||||
|
||||
@ -565,9 +566,9 @@ I searched and I searched, and I was rewarded for that search. Someone mentioned
|
||||
|
||||
How do you clean up a scanned book from the Internet Archive? The way I would normally handle this would be the GIMP method I described earlier. But that's a lot of work for a book I just want to read and be done with. (No archivist work for me here.)
|
||||
|
||||
The workflow for this is fairly simple. First you import your pdf using the ``Import'' button. Then you select all the pages and click the ``Image'' button. The options are pretty limited: you can adjust the brightness and contrast, adjust the hue and saturation, or you can sharpen. It also has an image called ``Document Correction'' which is great if you are scanning in a lot of hand written notes and need to add a lot of contrast. (This doesn't work so greatly in the case of a badly yellowed book, unfortunately.) You just make your corrections, and also make sure to tick the box that says ``Apply to all pages''—something I often forget to do.
|
||||
The workflow for this is fairly simple. First you import your pdf using the ``Import'' button, then you select all the pages and click the ``Image'' button. The options are pretty limited: you can adjust the brightness and contrast, adjust the hue and saturation, or you can sharpen. It also has an option called ``Document Correction'' which is great if you are scanning hand written notes and need to add a lot of contrast. (This doesn't work so greatly in the case of a badly yellowed book, unfortunately.) You just make your corrections, and also make sure to tick the box that says ``Apply to all pages''—something I often forget to do.
|
||||
|
||||
You're probably not going to get a perfect book back, because the options are pretty limited. The trade-off is that you pick your settings once, and then NAPS2 handles all the work while you go get yourself a cup of coffee—or take a nap.
|
||||
You're probably not going to get a perfect book back, because the options are pretty limited when you're correcting an entire book at once. The trade-off is that you pick your settings once, and then NAPS2 handles all the work while you go get yourself a cup of coffee—or take a nap.
|
||||
|
||||
\section{Interleaving}
|
||||
|
||||
@ -581,13 +582,13 @@ I'm a scientist, so I experimented. I took five sheets of scrap paper, wrote the
|
||||
\caption{The document as originally drawn}
|
||||
\label{naps2-orig}
|
||||
\centering
|
||||
\kpage{1}\kpage{2}\kpage{3}\kpage{4}\kpage{5}\kpage{6}\kpage{7}\kpage{8}\kpage{9}\kpage{10}
|
||||
\kpage{1}\kpage{2}\hspace{1mm}\kpage{3}\kpage{4}\hspace{1mm}\kpage{5}\kpage{6}\hspace{1mm}\kpage{7}\kpage{8}\hspace{1mm}\kpage{9}\kpage{10}
|
||||
\end{figure}
|
||||
|
||||
Because I wrote on both sides of each side of paper in order to emulate a double-sided original, I scanned the pages, and then flipped them over and scanned the other sides. And because I am scanning these upside down, the even numbers end up in reverse order. So I ended up with a pdf that looked like figure \ref{naps2-scan}.
|
||||
|
||||
Using this scanner means every page has to be scanned twice—one time for the front side, and a second time for the reverse side. As a result ``upside-down'' has a couple of meanings here. My scanner's ADF accepts pages with the side you want to scan face down. It then flips them over when it scans them, which rotates them around both the $z$-axis and the $y$-axis. Because it flips them over along the $y$-axis, I only have to spin them around the $z$-axis. This should seem self-explanatory, but it often isn't—I had to use the scanner at work the other day and it took me three times to get it right.
|
||||
|
||||
Because I wrote on both sides of each side of paper in order to emulate a double-sided original, I scanned the pages, and then spun them around the $z$-axis and scanned the other sides. And because I am scanning these face down, the even numbers end up in reverse order. So I ended up with a pdf that looked like figure \ref{naps2-scan}.
|
||||
|
||||
\begin{figure}[h]
|
||||
\caption{The document as originally scanned}
|
||||
\label{naps2-scan}
|
||||
@ -610,7 +611,7 @@ If that looks like the original document, it is definitely not an accident; it i
|
||||
|
||||
Even though NAPS2 was designed to be a pdf scanner, it also has the ability to save individual scans as images. Even more importantly, because each scanned page is basically an image, you can also edit each page as an image by double clicking on it, where you get editing options like crop and rotate, in addition to the ones I mentioned earlier. This is pretty handy if you're scanning something like a manual that has different sized pages, or is printed on large sheets and folded into a box so that you have to scan it in sections,\footnote{Every piece of furniture I've ever assembled has instructions like this, but I've run into quite a few manuals that are miniature versions of this, like the earbuds I wear on my daily walk.} or a package that has care instructions on one or more sides.
|
||||
|
||||
And if you're wondering why I keep banging on about manuals, it's because I do keep them. For years, I kept them all in a large three ring binder filled with page protectors that I could slip them into. It was big, and it was awkward, and I didn't dare grab it the wrong way or I'd have manuals all over the floor.
|
||||
If you're wondering why I keep banging on about manuals, it's because I do keep them. For years I kept them all in a large three ring binder filled with page protectors that I could slip them into. It was big, and it was awkward, and I didn't dare grab it the wrong way or I'd have manuals all over the floor.
|
||||
|
||||
At some point, I realized that most manuals are available in convenient pdf form from the manufacturer's website, so I started downloading those, making sure the pdf was identical (or identical \textit{enough}) to the original, and then tossing the original in the recycling. But for those that aren't—yep, I scan them.
|
||||
|
||||
@ -672,13 +673,13 @@ which will give us:
|
||||
\noindent{}\ce{Hg^2+ ->[I-] HgI2 ->[I-] [Hg^{II}I4]^2-}
|
||||
\vspace{\baselineskip}
|
||||
|
||||
If you need something fairly straightforward, the \texttt{mhchem} package is for you. It has a simple, intuitive interface and it does a great job.
|
||||
If you need something fairly straightforward, all in all the \texttt{mhchem} package is for you. It has a simple, intuitive interface and it does a great job. I wish I'd known about this when I was teaching.
|
||||
|
||||
\section{Package \texttt{chemformula}}
|
||||
|
||||
The \texttt{chemformula} package is similar to \texttt{mhchem} in many respects, but is stricter about how certain items are input. In return, it has more options to customize the output.
|
||||
|
||||
Again, it's pretty intuitive. To write the chemical formula for copper(II) sulfate pentahydrate, we would use code like this:
|
||||
Like \texttt{mhchem}, it's pretty intuitive. To write the chemical formula for copper(II) sulfate pentahydrate, we would use code like this:
|
||||
|
||||
\begin{Verbatim}[]
|
||||
\ch{CuSO4 * 5 H20}
|
||||
@ -698,26 +699,26 @@ You can also use math mode in \texttt{chemformula}. For example, this code:
|
||||
\ch{$2n$ Na + $n$ Cl2 -> $2n$ NaCl}
|
||||
\end{Verbatim}
|
||||
|
||||
will give us this reaction:
|
||||
gives us this reaction:
|
||||
|
||||
\vspace{\baselineskip}
|
||||
\noindent{}\ch{$2n$ Na + $n$ Cl2 -> $2n$ NaCl}
|
||||
\vspace{\baselineskip}
|
||||
|
||||
We can also write the names of substances underneath them by using a ! and two pairs of parentheses. This code:
|
||||
We can also write the names of substances underneath them by using a ! and two pairs of parentheses, like this
|
||||
|
||||
\begin{Verbatim}[]
|
||||
\ch{!( sodium )( $2n$ Na ) + !( chlorine )( $n$ Cl2 ) -> !( s
|
||||
odium\ chloride )( $2n$ NaCl )}
|
||||
\end{Verbatim}
|
||||
|
||||
gives us this example:
|
||||
which gives us this:
|
||||
|
||||
\vspace{\baselineskip}
|
||||
\noindent{}\ch{!( sodium )( $2n$ Na ) + !( chlorine )( $n$ Cl2 ) -> !( sodium\ chloride )( $2n$ NaCl )}
|
||||
\vspace{\baselineskip}
|
||||
|
||||
Notice that we had to use spaces inside the parentheses so that the package will know how to format these separate types of input. Also, because a space delineates different inputs, in order to get that space in ``sodium chloride'' we had to escape the space with a backward slash.
|
||||
We had to use spaces inside the parentheses so that the package will know how to format these separate types of input. Also, because a space delineates different inputs, in order to get that space in ``sodium chloride'' we had to escape the space with a backward slash.
|
||||
|
||||
Again, there are lots of options to customize the output. Here's one with fractions:
|
||||
|
||||
@ -738,7 +739,7 @@ Like I said, this one operates a lot like \texttt{mhchem}. If \texttt{mhchem} wo
|
||||
|
||||
\section{Package \texttt{chemfig}}
|
||||
|
||||
If you need to draw chemical structures, then \texttt{chemfig} is the package for you. It uses a \texttt{chemfig} environment, and loads \texttt{tikz} if it hasn't already been loaded.\footnote{See issue \#2, \S{} 7.2 for some basics about drawing with \texttt{tikz}.} You can pass a set of parameters to that environment to change the appearance of individual molecules.
|
||||
If you need to draw chemical structures, then \texttt{chemfig} is the package for you. It uses a \texttt{chemfig} environment, and loads \texttt{tikz} if it hasn't already been loaded.\footnote{See issue \#2, \S{} 7.2 for some basics about drawing with \texttt{tikz}.}
|
||||
|
||||
\subsection{Basic Syntax}
|
||||
|
||||
@ -775,13 +776,13 @@ produces this figure:
|
||||
\noindent{}\chemfig{H_3C-C(=[1]O)(-[7]OH)}
|
||||
\vspace{\baselineskip}
|
||||
|
||||
Note that angles are always specified with regard to the origin and to the horizontal, regardless of where they start. In other words, [1] = $1 * 45\degree = 45\degree$ and [7] = $7 * 45\degree = 315\degree$.
|
||||
Note that angles are always specified with regard to the origin and to the horizontal, regardless of where they start. In other words, [1] = $1 \times 45\degree = 45\degree$ and [7] = $7 \times 45\degree = 315\degree$.
|
||||
|
||||
\subsection{Ring Structures }
|
||||
|
||||
We can also create ring structures pretty easily by using an asterisk at the beginning of our definition. I've created some examples below, where the syntax should be fairly easy to understand. (And notice the use of \texttt{[,0.75]} to change the length of the line of the bond to the functional groups.)
|
||||
|
||||
Note that rings always begin with the atom in the southwest corner, which I've labeled here:
|
||||
Rings always begin with the atom in the southwest corner, which I've labeled here:
|
||||
|
||||
\vspace{\baselineskip}
|
||||
\chemfig{SW*6(-=-=-=)}
|
||||
@ -903,7 +904,7 @@ You can even use \texttt{chemfigure} to show reactions, using a \texttt{scheme}.
|
||||
|
||||
\vspace{\baselineskip}
|
||||
\vspace{\baselineskip}
|
||||
Notice the use of \texttt{setchemfig} to scale the reaction to 75\% so it would fit on the page, and then its use again to reset the scale back to 100\%. (Although the latter is a moot point, as we are done now.)
|
||||
I had to use \texttt{setchemfig} to scale the reaction to 75\% so it would fit on the page, and then its use again to reset the scale back to 100\%. (Although the latter is a moot point, as we are done now.)
|
||||
|
||||
This is an easy package to master, and really fun to use. I encourage you to try it.
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user