Using Latex for formulas

NOTE: This is only if you are using it within OpenOffice

All of this translates to the formulas below

P_total = AC{V^2}f + {%tau}AVI_shortf + VI_leak newline
P_o = C_o {{V_o}^2}f newline
P_n = 0.5 P_o newline
I_leak = K_2 W(V over {T_ox})^2 func e^({{%alpha}T_ox over V}) newline
sum from 0 to 100 (a^2)(b^3)d newline
where, left lbrace {stack{a, contanst# b, variable # d, dynamic}} right rbrace


Using GNUPlot

GNU plot is one of the most useful applications on Linux for creating plots. GNU plot takes in data in the following format

10 324.12 12312 56
100 34231.3 2312123 67

There are three columns here, there can be any number, make sure the data is separated by a space. You can make your program write the data directly in a file, call it whatever you want to, e.g. "simout.dat"

# Fire gnuplot
gnuplot>

# draw using the first two columns from the data file
gnuplot> plot "simout.dat" using 1:2

# draw using the first and second col AND first and third col.
gnuplot> plot "simout.dat" using 1:2, "simout.dat" using 1:3

#draw using lines
gnuplot> plot "simout.dat" using 1:2 with lines, "simout.dat" using 1:3 with lines

# draw using points on the lines
gnuplot> plot "simout.dat" using 1:2 with linespoint, "simout.dat" using 1:3 with linespoint

# draw with a legend for the lines
gnuplot> plot "simout.dat" using 1:2 with linespoint ti "Marks in CA", "simout.dat" using 1:3 with linespoint ti "Marks in WUC"

# set title
set title "The title of the plot"

# set X label
set xlabel "Blocks (N)"

# Set Y label
set ylabel "Performance [MFlops]"

# Set x and y Range
set xrange [100:10000]
set yrange [0:10e6]

# Set log scale on X
set logscale x

There are so many other things that you can do with GNUPlot, which I even don't know as I am still learning how to use it.

Excellent tutorial here (that is how I got started).

Using commands recursively with find

I copied my home folder to Windows for a backup and when I copied them back for some weird reason all the directories had executables privileges.

This is what I did to get rid of it recursively

$ find . -type d -exec chmod 755 {} \;

you can pass any command as an argument to -exec. Some useful things that you can do with find are here