View License

Download apps, toolboxes, and other File Exchange content using Add-On Explorer in MATLAB.

» Watch video

Highlights from
Caesar Cipher

4.4 | 5 ratings Rate this file 28 Downloads (last 30 days) File Size: 1.86 KB File ID: #30429 Version: 1.4

Caesar Cipher


Nikesh Bajaj (view profile)


16 Feb 2011 (Updated )

This is Program for Caesar Cipher encryption Technique.

| Watch this File

File Information

This is one of the Classical encryption Algorithm, Not secure one but good for teaching.


This file inspired Caesar Cipher Encryption And Decryption With Matlab Gui Guide.

Required Products MATLAB
MATLAB release MATLAB 7.6 (R2008a)
MATLAB Search Path
Tags for This File   Please login to tag files.
Please login to add a comment or rating.
Comments and Ratings (8)
26 May 2015 sonny christian

its doesnt work sir, variable k>26 always error it said undifined variable k, what can i do?thanks

Comment only
11 Mar 2015 Chun Ho Tao

17 Oct 2014 Bebo Nassar

05 May 2012 Mayukh

Mayukh (view profile)

Sir I also created one but not a function like yours...preferred script file instead..but functions are still better to thanks Sir..:)

08 Oct 2011 Nikesh Bajaj

Nikesh Bajaj (view profile)

@min min: It is a function not a code, it will not work till you pass P and k to it in command window

@Tamir: It depends on what name you have used to save this file, will be called by that name only,
I have used this code to even encrypt 100 pages of text file, it is working fine
this is the result for what you asked
P='Hello World and Welcome to Matlab cryptogrpahy'
C=Khoor Zruog dqg Zhofrph wr Pdwode fubswrjusdkb

Comment only
07 Oct 2011 Tamir Suliman

What I did notice is when you extend it above 3 words it doesnt do the shift so its missing that part
try to run this code and you will understand what I meant :

P='Hello World and Welcome to Matlab cryptogrpahy'

Comment only
07 Oct 2011 Tamir Suliman

It should work if you use the caesar_E instead of caeasar I think the help files didnt express well how to use the function but its good try

12 Sep 2011 Mr Smart

didn`t work...sir

04 Nov 2013 1.3

Decryption file is updated, as it was giving error for some input

14 Nov 2014 1.4

Download as toolbox

Contact us