Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

Prime Number Calculator, Numbers, Mac?

I am very frustrated, as I can't seem to find a way of calculating if a certain number is prime or not, as you can easily do in Microsoft Excel. I hope somebody has an answer to this question, as Numbers is supposed to be a Mac alternative for Microsoft Excel, and therefore should live up to it's expectations. I also have another problem where, in the number tutorial, when you first open your new Mac, it shows that you can make a bar graph with all different colours like soUser uploaded filebut it only appears like this when I do the exact same thing.User uploaded filethis makes me very angry. Please solve this problem

MacBook Air, OS X Yosemite (10.10.2), null

Posted on Mar 5, 2015 7:44 PM

Reply
5 replies

Mar 6, 2015 7:22 AM in response to HelloAppleHelp

We're fellow users here. Why be angry? You can communicate with Apple via Numbers > Provide Numbers Feedback in your menu.


The common solution given in Excel to determine whether a number is prime involves array formulas. Numbers doesn't have array formulas, an advanced spreadsheet feature that most people rarely use (though they can be handy for problems such as this).


As for your chart problem, have you tried clicking the chart, then Edit Data References, and then (lower left) Plot Rows as Series?


User uploaded file


SG

Mar 6, 2015 8:15 PM in response to HelloAppleHelp

The Excel array formula wouldn't work in Numbers even if Numbers had array formulas. It relies on the monolithic tables of Excel (you need X-1 rows to test the primeness of number X) whereas in Numbers you make tables the size you need for your information. I have to say it is a clever use of an array formula to make it check for primeness.


You could probably write an Applescript that would run the same algorithm which is basically testing with each and every number from 2 to the square root of X. It would require selecting the cell(s) then running the script. Or you could write a specifically crafted script for your document that would test specific cells without have to first select them.


Numbers does not claim to be an Excel clone, it is an Excel alternative. Use the tool that works best for you, be it Excel, Numbers, or one of the open source clones of Excel.

Prime Number Calculator, Numbers, Mac?

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple ID.