Array formula to check if a number is prime [just for fun]

I am math-geek-wannabe, if there ever is such a category. During my 3rd year of graduation I went and purchased the volume 2 of Donald Knuth’s Art of Computer Programming and thus began my love with all things random and prime. I never really became the math-geek I always wanted to, instead I became an insurance expert with tons of passion for data and visualization. But when I get a chance to poke with randomness or numbers, I always lap it up with joy. And that brings us to an interesting array formula trick to check if a number is prime or not.

(assuming the number is in the cell B2) type the below formula and

=IF(MIN(MOD($B$5,ROW(INDIRECT(“2:”&INT(SQRT($B$5))))))=0,”not prime”,”prime”)

hit ctrl+shift+enter and bingo, it tells you if the number is prime or not. Read on to find how it works

Intraday Candlestick Charting [Stock Charts]

Gene asks me in an email, “I’m trying to graph candlestick charts in Excel for 10 minute candles. Excel seems to allow daily only with its stock templates. Can you point me to any resources for creating intraday candle charts?”. Of course, you can create intraday candlestick charts just the way you would create normal candlesticks, just change the axis options once you are done. Read the post to find more.

Excel Tips Submitted by You [Part 1]

The first installment of “your week @ PHD” features 4 excel tips shared by our readers: (1) A macro to unhide all sheets (2) a KPI Dashboard with VBA and Charts (3) Using Excel’s Find to Save time at work (4) An Array Formula to Solve a Tricky Problem.

Announcing “Your Week” @ PHD

That is right. Next week is your week on this blog. I will post content that is shared by you. So go ahead and share your tips and tricks with us. Read more to find out how you can share your tips with the community.

Using Credit Card Numbers in Excel

Do you know that it is not so straight forward to use credit card numbers in excel. Yes, excel uses a precision of 15 digits and thus when you enter a credit card number (16 digits) it is converted in to scientific format and the details are lost. Read on to learn the work around.

Highlight Top 10 Values using Excel Conditional Formatting

In excel conditional formatting basics article, we have learned the basics of excel conditional formatting. In this article we will learn how to highlight top 5 or 10 values in a list using excel as shown aside. We will use LARGE excel formula and conditional formatting to do this.