What should be the Winding at Primary and Secondary in Transformer?
There are transformer and complete transformer boards which will output the correct voltage. I strongly discourage the idea to build a transformer by yourself (which your questions for the right number of turns implies). Actually you should not touch main power supply at all if you have not a very good idea what is going on at those voltage levels. In the worst case you or somebody else might get severely hurt!

Furthermore your comment "Can If we convert 230V AC to Directly 5V 3A DC and supply it to Raspberry PI and then take this 5V 3A DC and Convert it to 5V 1A DC and Supply it to Arduino" is an indication of a missconcept regarding voltages and currents:
generelly speaking one has to make sure that a (voltage) supply give the right level of voltage (in your case 5V). Additionally the supply need to be potent enough to provide at least the maximum current required by your devices. Which means as long as the (maximum allowed) current rating of your supply is greater than the drawn current your will be fine. Considering the numbers you gave there any supply abled to supply 5V with a current rating greater than 3+1A should be fine to power your RPI and arduino in parallel.

To your question:
The ratio is for the transformer is actually computed via the formular N1/N2 as you figured it out. But one has to make sure that the number of turns on the primary side is not to low (to avoid heating due to high currents) or to high (low maximum power transfer). A source describing some parameters and formular for such an effort is http://engineerexperiences.com/design-calculations.html . But again: only do it if you know what you are dealing with.

Modern AC/DC converter (like the little power grid to USB thingy) actually use a far more advanced approach. There the AC is first rectified then chopped with a high frequency, transformed via a much small transformer and then rectified again (for details search for Switched-mode power supply). That is the reason why your design will mostlikely have the size of a shoes box while there are adapters out providing multiple usb ports with 5V/5A in size of an arduino. 

TL;DR Do not tamper with mains electricity voltages if you do not know what you are up to. Make sure that you got all the basics before trying to solve a problem by throwing more stuff unto it. Try to stick with out-of-the-box solution (if this is an option for you/do not intentionally want to make it harder as it could be).