source: issm/oecreview/Archive/17802-17983/ISSM-17863-17864.diff@ 17986

Last change on this file since 17986 was 17986, checked in by Mathieu Morlighem, 11 years ago

New release

File size: 890 bytes
  • ../trunk-jpl/src/m/materials/paterson.py

     
    1515                raise RuntimeError("input temperature should be in Kelvin (positive)")
    1616
    1717        if numpy.ndim(temperature)==2:
    18                 T = temperature.reshape(-1,)-273.15
     18                #T = temperature.reshape(-1,)-273.15
     19                T = temperature.flatten()-273.15
     20        elif isinstance(temperature,float) or isinstance(temperature,int):
     21                T = numpy.array([temperature])-273.15
    1922        else:
    20                 T = numpy.array([temperature])-273.15
     23                T = temperature-273.15
    2124
    2225        #The routine below is equivalent to:
    2326
     
    7073        #Now make sure that rigidity is positive
    7174        pos=numpy.nonzero(rigidity<0)[0]
    7275        if len(pos):
    73                 rigidity[pos]=1**6
     76                rigidity[pos]=1.e6
    7477
    7578        return rigidity
    7679
Note: See TracBrowser for help on using the repository browser.