Changeset 1222 in lmdz_wrf for trunk/tools
- Timestamp:
- Oct 20, 2016, 1:34:29 PM (8 years ago)
- Location:
- trunk/tools
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tools/generic.py
r1221 r1222 74 74 ## e.g. # generic.py -o radius_dist -S 3,5,2,2 75 75 ## e.g. # generic.py -o rmNOnum -S LMD123IPSL 76 ## e.g. # generic.py -o significant_decomposition -S 3.576,-2 ,0@1@2@3@4@5@6@7@8@9@10@11@12@13@14,a@b@c@d@e,i@ii@iii,table.tex76 ## e.g. # generic.py -o significant_decomposition -S 3.576,-2 77 77 ## e.g. # generic.py -o table_tex_file -S '5,3,0@5@10@1@6@11@2@7@12@3@8@13@4@9@14,!@a@b@c@d@e,i@ii@iii,table.tex' 78 78 ## e.g. # generic.py -o unitsDate -S '19490101000000,19760217082932,second' -
trunk/tools/generic_tools.py
r1219 r1222 7282 7282 num= number to decompose 7283 7283 minpot= minumum potence to decompose 7284 >>> significant_decomposition(np.pi, 5)7284 >>> significant_decomposition(np.pi,-6) 7285 7285 7, [0.0, -1.0, -2.0, -3.0, -4.0, -5.0, -6.0], [3, 1, 4, 1, 5, 9, 2] 7286 7286 """ … … 7294 7294 iipot = 1 7295 7295 pot = np.floor(np.log10(anum)) 7296 if pot < minpot: 7297 print errormsg 7298 print ' ' + fname + ': required minimum potency:', minpot, 'is smaller ' + \ 7299 'than the potency of the value:', pot, '!!' 7300 print ' minimum value 10**minpot:', 10**(minpot), '>', anum 7301 print " reduce 'minpot'" 7302 quit(-1) 7303 7296 7304 while pot > minpot: 7297 7305 if diff >= 10.**(pot-1):
Note: See TracChangeset
for help on using the changeset viewer.