double precision
Dear friends,
I am dealing with a simple hydrodynamic problem of water flow in milichannels. my simulation is transient and as it is obvious, with relatively small dimensions. I checked with the documentation to see whether it is recommended to use double precision for calculations when you are dealing with small dimensions and I saw nothing. Do you think I should use double precision? my domain is a duct, 1mm long with a 0.3mm*0.3mm cross section... thank you. 
Hello,
you should use double precision for all calculations. A double precision calculation use a 64 bit floating point number. A not double precision calc. use a 32 bit floating point number. Today, our FPU (floating poitn unit) deals with 11xbits (normaly). 64 bit numbers increase the robustness and stability of your calculation. 
I do not agree that you should use double precision for all calculations. I routinely use single precision for MEMS simulations where the domain size is around 10um by 10um.
The key thing is the range of scales. If everything is small then single precision is probably OK. If some thing are small and some large then you probably need double. If you just want to be sure and don't mind about longer run times and have lots of memory then just use double anyway. 
Quote:
Ok, next. If the domain is 10 by 10 um and the velocity of the fluid is 10 m/s. What you are use? A question. How big is the difference of time cost by our cases? 
By default CFX uses SI units internally (mkgsK). But it can use any internally consistent set of units.
What do you mean by "What you are use?" Double precision generally adds about 50% to the simulation time and memory requirements providing the equivalent single precision simulation converges equivalently. If the double precision simulation improves convergence (that is, numerical accuracy was a problem for the single precision run) then the double precision run may be faster. 
thank you ghorrocks and Siassei. I believe that double precision should be used when you are dealing with high aspect ratios. Thus what Siassei is pointing out is that: for example when your velocity is 1m/s but your smallest dimension is 0.1mm, the ratio of these two is 10e4 which is high(?) and we should use double precision... is my conclusion right, Siassei?

You cannot take a ratio of velocity and distance to give a meaningful number. The important ratio is of the largest and smallest important dimension, or the largest and smallest velocity or the largest and smallest pressure (relative to the reference pressure).

All times are GMT 4. The time now is 20:27. 