Hello World!

First off, here are a couple of cool formatting tools that I ran into getting my feet wet with WordPress:

Using Latex typesetting

Using  \LaTeX  in WordPress for nice typesetting of mathematical expressions is super easy (and one of the reasons I’m using WordPress instead of other blogging resources like Blogger). To do so just surround an expression in standard \LaTeX syntax with the $ symbol. For instance the following

i\hbar \frac{\partial}{\partial t}\Psi = \hat{H} \Psi 

results in what is likely a familiar expression if you have any experience with quantum mechanics

i\hbar \frac{\partial}{\partial t} \Psi= \hat{H} \Psi

The &s=3 entry in the above statement sets the size of the  \LaTeX expression  (s can range from -4 to 4). For more info see the following link

Inserting formatted source code

WordPress also makes it easy to directly paste formatted source code using the shortcode syntax:

Using the above syntax, you can display matlab code with highlighting. For example, replacing “SOME MATLAB CODE” above with actual source code…

function outPut = myFun(input1,input2)
outPut = 1;
for iI = 1:1000
   outPut = outPut*input1*input2 / iI;

There are a number of languages and options that are available under the shortcode syntax. For more info, see the following link.

About dustinstansbury

I recently received my PhD from UC Berkeley where I studied computational neuroscience and machine learning.

Posted on January 15, 2012, in LaTeX, MATLAB, Tips & Tricks and tagged , , , , . Bookmark the permalink. Leave a comment.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: