Cmatrix is an entertaining command-line program for Linux and Unix systems. It gives a ‘Matrix’-style display, where a rain of green characters streams down the screen, just like in the iconic Matrix film series.

Running Cmatrix command without any options.
Cmatrix Command

But other than this green streams of characters, you can do several other things with this interesting command.

🚧

Cmatrix is a CPU intensive command. So use this with caution.

Install Cmatrix in Ubuntu and Other Linux systems

Cmatrix is available in the official repositories of almost all major Linux distributions. In Ubuntu, you can install Cmatrix using the command:

sudo apt install cmatrix

Fedora users should use:

sudo dnf install cmatrix

Arch Linux user can use pacman:

sudo pacman -S cmatrix

Basic cmatrix options

The cmatrix command alone provides several options, to change the appearance of the default output, that is the green character streams.

Bold characters

You can either toggle the bold characters on using -b option, where you will find occasional bold characters,

cmatrix -b
Cmatrix will show occasional bold letters if used with the small letter b option.
Cmatrix with Occasional Bold Characters

or, turn all the characters to bold using:

cmatrix -B
Cmatrix will show occasional bold letters if used with the capital letter B option.
All Bold Characters

Asynchronous scroll

The usual Cmatrix will create a display, where characters are falling down in a synchronous manner. In this mode, you can see a dynamic and visually engaging display, where the speed of the characters is varied.

To use Cmatrix in asynchronous scroll:

cmatrix -a

Change the speed of characters

Do you want to display the characters falling very fast, or very slow? You can do this in Cmatrix.

To make characters fall down fast, use:

cmatrix -u 2
Cmatrix with low value of update delay, so that the characters are moving fast.
Characters Moving Fast

Here, the default value of screen update delay is 4 and if you reduce it, the speed will be increased and vice versa. So, to run a slower cmatrix, use:

cmatrix -u 9
Cmatrix characters moving slowly because the value for screen update delay was set high.
Characters Moving Slow

Use different Colors

Go green! Or perhaps go purple?

You can run Cmatrix with a different color. For this, you can use the -C option.

cmatrix -C magenta
Running Cmatrix with a different color using the color option. Here, the magenta color is used.
The color is Magenta

The supported colors are green, red, blue, white, yellow, cyan, magenta and black.

Other Options

Option Function
cmatrix -o Old Style Scrolling
cmatrix -m Lambda Mode: Every character becomes a lambda
cmatrix -s Screensaver Mode: Exits on first keystroke
cmatrix -h Help

Cmatrix keystrokes during execution

Even if you don’t provide any option in Cmatrix, you can provide some input later on during execution. Those are listed below.

Change Color

Yes, you can change the color of characters while running. But you need to remember some keys and their corresponding color. What to do is, while running Cmatrix, press these keys and the color will change.

Color Keystroke
Red !
Green @
Yellow #
Blue $
Magenta %
Cyan ^
White &
Black )

Adjust update speed

While running, you can use the number keys from 0 through 9 to change the update speed.

There are other options also, which you can find from the man page of the command.

man cmatrix

Bonus: Cmatrix with lolcat

🚧

Cmatrix itself is CPU intensive. So use the other commands with caution.

You can use Cmatrix, in combination with the lolcat command, to make it look more interesting. In Ubuntu, you can install lolcat using:

sudo apt install lolcat

Now, just pipe Cmatrix to lolcat so that you will get a rainbow effect.

cmatrix | lolcat
Piping the Cmatrix command to lolcat, to display rainbow color effect.
Cmatrix with Lolcat

Also, try all the above functions of Cmatrix, while piping into lolcat.

Or, you can use an inclined stripe for a rainbow effect, giving another type of experience.

cmatrix | lolcat -p 100

Additionally, you can just invert the background and foreground colors so that your terminal will be filled with colors.

cmatrix | lolcat -i
Inverting the background and foreground color in lolcat. The output of Cmatrix is piped to this inverted color option.
Cmatrix with Lolcat Inverted Color Option

More fun with terminal

I know this is not the most useful Linux command but it’s fun nonetheless and you can have some fun with your Linux system sometime, right?

Cowsay is another such command:

Using Cowsay Linux Command Like a ProThe cowsay is a fun little Linux command line utility that can be enjoyed in so many ways. Here are several examples.

And even more here:

13 Amusing Funny Linux CommandsSo, you think Linux terminal is all work and no fun? These funny Linux commands will prove you wrong.

I let you enjoy it now, Mr. Anderson.

Similar Posts