How To: Secure Android Apps with Mathematical Expressions on Your Galaxy S4

Secure Android Apps with Mathematical Expressions on Your Galaxy S4

Security is a priority for many when they first set up their mobile devices. Nobody wants to have a stranger or nosey friend go through their phone and discover risqué photos or embarrassing text messages. These days, the closet is gone—everyone keeps their skeletons in their phones.

Conventional lock methods are fine, but they can be easily uncovered by someone peering over your shoulder. And if someone grabs your device while it's unlocked, you'll wish you had secured some of your apps.

We've previously shown you how to change your lock screen PIN to change every minute with TimePIN, and although this was an effective passcode method, this offered very little in terms of individual application security.

To really secure your device and apps, use a new technique that utilizes a formula-based method, brought to you by developer Vijay Rathinaswamy, called Dynamic pin.

How Dynamic Pin Works

Instead of remembering numbers, Dynamic pin is dependent on you remembering a mathematical expression with variables, much like we learned in high school.

You set up an expression, like A+B, then when unlocking an app, a grid is displayed with various values assigned to letters A through P. To unlock, enter the sum of your expression.

Example: If your expression is A+B, look for the values displayed for A and B. Using the grid below (where A=2 and B=5), the value of our expression is 2+5, which equals 7, so your pin will be 0007.

The values for the variables will change every time, so it's important that you remember the expression you set up.

Setting Up Your Dynamic Pin

In the app's setting, start by enabling Application Lock, then head to Select Applications to choose which you'd like to lock up.

Your default expression is A+B, and can be changed to A+C. Two in-app purchases will allow you to expand on the amount of variables and types of formulas you can use. The ability to also enable screen lock is available, although at this point that feature is a bit buggy (at least, for me it was).

Using Your Dynamic Pin to Unlock Apps

Now, every time you want to use a locked app, solving the expression will be required, with the value equated to each letter changed with every use of the app. The PIN must be four digits, so place zeros before the sum, like 0014.

Dynamic pin is definitely a new take on app security, and after refreshing your rudimentary math skills, you'll realize how easy it is to use while being difficult to figure out for snoops.

What Happens if You Forget Your Dynamic Pin?

There is no limit to how many failed attempts you can have, which may or may not be a good thing for you. With seemingly unlimited attempts, a snoop's chances of getting increase, but that's why it's important to make the answer to your problem as difficult as possible.

In the off chance that you actually forget the expression you set up, you'll want to use one of the two recovery choices included in the settings, either Show expression after 3rd attempt or Show expression in encrypted text after 3rd attempt. I recommend the latter.

The Show expression after 3rd attempt feature is pretty simple to comprehend and works as it should. After the third failed attempt, you'll receive a small toast notification with the expression displayed. This is obviously not good if you're trying to keep people out of your apps, so you should use the next method.

The encrypted method will encrypt your expression with new values that must either be saved to your storage or emailed to you. After three failed attempts, you will receive the encrypted expression that you will then apply the saved values to. Just be aware that this method has its issues and may not work on all devices, but is likely to improve as development continues.

If all else fails, you can always uninstall the application or clear its data to remove the PINs from your apps. It's not an ideal solution, especially if someone has gotten past your lock screen already. Then, they would just have to delete Dynamic pin and they've got full access.

More Features Available in Paid Versions

The basic Basic Expressions pack offers unlimited application locks and also enables operations among the matrix elements using +, -(~), *, /, %, ^.


  • (AxD)+5 — Multiply corner elements of the first row and add 5.
  • (A+D+M+P) — Add corner elements of the matrix.

In addition to Basic pack features, the Advanced Expressions pack enables MIN (A,B) and MAX (M,P) functions along with the basic pack. More functions are planned for future releases, but in my opinion, that's a bit of overkill.


  • MIN(A,D) - Minimum value between A and D.
  • MAX(A,B) - Maximum value between A and B.

Either way you go—Free, Basic, or Advanced—you'll have a very innovative way to keep your apps secure. It may not keep master hackers from breaking into your apps, but it's surely enough to keep your nosey, mathematically-inept, friends out.

Let us know what you think in the comments below.

Just updated your iPhone? You'll find new features for Podcasts, News, Books, and TV, as well as important security improvements and fresh wallpapers. Find out what's new and changed on your iPhone with the iOS 17.5 update.

Be the First to Comment

Share Your Thoughts

  • Hot
  • Latest