[NOTE: The duplicate linked by Mattdm offers the formula, however I'm not sure that actually answers the question you have asked, so here is some additional thought process and explanation that will hopefully answer the question.]
When it comes down to print size, "How many megapixels?" is not really the right question, at least not initially. Print size is a matter of print resolution and image dimensions (as indicated in the other answer). Your dimensions are fixed, given that you need to print A1 size, so the remaining question is "What print resolution?".
Resolution can be a funky thing, and you will get a lot of different opinions on the subject. You can go a few ways: for the least common denominator, for the average denominator, or for the most common denominator. To put that another way, print at a high resolution to ensure viewers with high visual acuity see as much detail as possible, print at a "standard" resolution to ensure viewers with average visual acuity see an adequate amount of detail, or print with the lowest resolution that will get you a print without requiring a lot of effort to bring out fine detail for the highest acuity viewers. We can associate three primary print resolutions with these classifications of print qualities (Canon/Epson resolutions):
- High Acuity/Fine Detail: 300ppi/360ppi
- Average Acuity/Average Detail: 150ppi/180ppi
- Low Acuity/Lesser Detail: 50ppi/60ppi
An A1 print is fairly large, and people will often view it from a good distance. One could argue that a low resolution "is all that is needed" for larger viewing distances of say 5-6 feet (that might be pushing it...A1 is big, but not necessarily huge). That would meet "classical" assumptions about human visual acuity, however some of those assumptions have come under fire these days with the advent of new high-resolution display technology like Apple's Retina Display (which many people can clearly see the pixels on at the recommended viewing distance), furthered scientific discovery about the nature of vision and acuity in various lighting (proper illumination can improve acuity), and facts about the widely varying nature of visual acuity amongst broad populations, anywhere from 1/40th of a degree to 1/90th of a degree (a bit less to a bit more than one arc minute or 1/60th of a degree, the standard "average" for visual acuity). Lets assume, for the sake of these discussions, that you want "native" print resolution, and therefor the ability to print an image in full detail "strait out of camera".
If we start with the bare minimum, enough resolution to produce an acceptable print at an average "comfortable" viewing distance, you would need 50ppi (or 60ppi with an Epson printer). With 50ppi at 23.39"x33.11" your image size would need to be 1170x1656 pixels. That would be an image of about 2 megapixels, and viewable from a distance of 5' or more.
At a 150ppi resolution, for A1 print dimensions, your image size would need to be 3509x4967 pixels. That would be an image of about 17.5mp, and would be sufficient for viewing at 2' away. Its certainly not impossible to find an 18mp camera these days...Canon has thoroughly saturated the market with 18mp and 18.1mp cameras the last few years, and both Nikon and Sony have or are releasing 24mp entry-level cameras.
At 300ppi resolution, for A1 print dimensions, your image size would need to be 7017x9933 pixels. That would be an image of about 70mp, and would be sufficient for viewing at a mere foot away.
So, what resolution do you need? Depends on two things:
- Do you feel satisfied with the detail when viewing it at a distance that is comfortable to you?
- Do you think that your most common viewers will be satisfied with the detail at viewing distances comfortable to them?
The first is, really, the more important...as we tend to be harder on and more demanding of ourselves than other people are. If you are comfortable with the detail you get out of a 50ppi print when viewed at greater than 5 feet, then its more likely than not that your viewers will also be quite happy. If you feel your viewers might be more demanding than the average viewer (i.e. such as in a gallery or exhibition setting), or feel that 5 feet is too far, etc. then you might want to opt for a higher resolution. At 150ppi, the minimum viewing distance shrinks to about two feet. That is more than sufficient to accommodate even more demanding viewers with average acuity, even if they step in for a closer look (which might bring them within 2-3 feet.) An 18mp APS-C sized camera sensor captures a lot of fine detail, so at this print resolution for that size print, you'll effectively be printing at "native" camera size, and therefor extracting full detail.
Beyond 150ppi, your into the realm where the print will contain more detail than is necessary for an A1 print even when examined more closely by viewers with average visual acuity. If someone with high visual acuity were to step in for a closer look at say 2.5 feet, you would need closer to 200ppi. So that begs the question: Is 300ppi overkill? For an A1 print, Yes and Possibly. Yes in that a camera capable of a native 70mp is going to be extremely expensive, even to rent, and you would need to make sure the scene you are photographing actually has enough intrinsic fine detail to make it worth while. Macro photos are usually ideal candidates for as much resolution as you can get your hands on. Landscapes can also benefit from high resolution. A lot of other photography, including much portraiture (especially wide-aperture soft-focus portraiture), architectural photography (as architecture tends to have large details but not much fine detail) does not need, or cannot even provide, that much detail. Possibly, as it depends on how precise you want your detail to be. A 200ppi image will need to be scaled 3x (an odd number) to print on a 600ppi native printer (or if you are using an Epson, a 240ppi image will need to be scaled 3x for the printers native 720ppi.) Odd-level scaling can have the tendency to blur a very small bit of detail when using a good scaling algorithm, where as even-level scaling (2x, 4x) tends not to (or at least, not as visibly so.) And every printer (or print driver), regardless of what you send to it, will scale to the devices native resolution before actually printing. It will usually do that scaling with a very cheap, fast form of scaling that can introduce artifacts, funky aliasing and edge chopping, etc. It would be better to manually scale an 18mp image to the necessary dimensions for a 300ppi print than to simply print at 200ppi, if you want to preserve a camera's native 200ppi worth of detail.
Personally, I would say an 18mp image would print fine for a gallery or other kind of exhibition where your viewers might be more demanding. I would also say that a 12mp photo should contain enough of detail to be scaled up to 18mp size, and printed at 150ppi, and be good enough for most viewers. I would say that a 50ppi print is probably too low for exhibition quality, however its probably a moot point anyway as it is likely harder to find a 2mp camera these days than a 6/8/10/12mp camera. If you really want to get the best quality you can, you might want to use a camera with more than 18mp worth of resolution, such as a 21mp full-frame camera or a 24mp APS-C camera, and scale the image down to the native print size. That should improve the clarity and sharpness of detail for an A1 print at 150ppi.