|
| 1 | +AIR_SEA TOOLBOX, Version 2.0 - originally developed by Bob Beardsley and several others |
| 2 | + |
| 3 | +Translated from matlab to python |
| 4 | + |
| 5 | +Filipe P. A. Fernandes |
| 6 | + |
| 7 | +web: http://ocefpaf.tiddlyspot.com/ |
| 8 | +date: 26-Nov-2010 |
| 9 | +modified: 01-Dec-2010 |
| 10 | +obs: FIXME, TODO, NOTE (flags what needs attention) |
| 11 | + |
| 12 | +Matlab version readme: |
| 13 | + |
| 14 | +AIR_SEA: Introduction to the AIR_SEA TOOLBOX |
| 15 | + |
| 16 | + AIR_SEA TOOLBOX (version 2.0: 8/9/99) |
| 17 | + |
| 18 | +1) Introduction: Welcome to the AIR_SEA toolbox, a collection of MATLAB |
| 19 | +programs (m-files) which can be used to compute surface wind stress and |
| 20 | +heat flux components from buoy and shipboard atmospheric and near-surface |
| 21 | +oceanographic time series measurements. All m-files include a header |
| 22 | +which describes the mfile's function, input and output variables, and |
| 23 | +key references when important. They have been written for use with |
| 24 | +MATLAB 5. |
| 25 | + |
| 26 | +2) Conventions: While not required for many m-files, it is generally |
| 27 | +assumed that the input time series of measured variables are hourly |
| 28 | +averaged column or row vectors and the other input variables are scalars, |
| 29 | +all expressed in MKS units. Two time conventions are used: a) decimal |
| 30 | +Julian yearday where 0000 UT Jan 1 equals 0.0, and b) calender yearday |
| 31 | +where Jan 1 equals 1. The choice of which convention is used is |
| 32 | +internally consistent between m-files. |
| 33 | + |
| 34 | +3) Programs used to compute heat flux components: |
| 35 | + |
| 36 | + Shortwave flux: |
| 37 | + |
| 38 | + SWHF: computes net sw flux into ocean and albedo. Uses |
| 39 | + SORADNA1 and ALBEDO to compute solar altitude, no-sky |
| 40 | + insolation and albedo. |
| 41 | + |
| 42 | + SORADNA1: computes no-sky insolation and solar altitude at |
| 43 | + a given time and location. |
| 44 | + |
| 45 | + ALBEDO: computes ocean albedo following Payne (1972). |
| 46 | + |
| 47 | + Longwave flux: |
| 48 | + |
| 49 | + LWHF: computes net lw flux into ocean when downward |
| 50 | + lw radiation is measured, using Dickey et al (1994). |
| 51 | + |
| 52 | + BLWHF: computes net lw flux into the ocean when downward |
| 53 | + lw radiation is NOT measured. Uses SATVAP. Requires |
| 54 | + as input a cloudiness correction factor from CLOUDCOR. |
| 55 | + |
| 56 | + CLOUDCOR: cloudiness correction factor used in bulk formulae, |
| 57 | + based on estimated Cloud Fraction, which is either observed |
| 58 | + directly or estimated, using, e.g., REEDCF. |
| 59 | + |
| 60 | + REEDCF: computes daily average Cloud Fraction using formula of |
| 61 | + Reed (1977), who relates daily average cloudiness to the observed |
| 62 | + reduction in solar insolation from clear-sky values. |
| 63 | + |
| 64 | + Sensible and latent fluxes: |
| 65 | + |
| 66 | + HFBULKTC: uses a simplified version of Fairall et al (1996) |
| 67 | + TOGA/COARE code to compute sensible and latent heat |
| 68 | + fluxes into ocean. Present version includes a) Rogers' |
| 69 | + weighting factor for unstable conditions, b) the effects |
| 70 | + of gustiness, c) a constant marine boundary layer height, |
| 71 | + d) a limit of zr/L <=3.0 to ensure that the code converges |
| 72 | + to nonzero stress and heat flux values for strongly stable |
| 73 | + conditions, e) cool-skin effect, and f) Webb correction for |
| 74 | + latent heat flux. NOTE: both cool-skin and Webb correction |
| 75 | + are optional, and user must decide if they want these used, |
| 76 | + e.g., in SLHFTC. Warm layer effects are not included in this |
| 77 | + version. Uses VISCAIR and QSAT to compute air viscosity |
| 78 | + and saturation specific humidity, CDNTC the neutral drag |
| 79 | + coefficient, and PSIUTC and PSITTC to adjust the different |
| 80 | + transfer coefficients to the measurement heights for a |
| 81 | + given stability. Also returns related variables. |
| 82 | + |
| 83 | + SLHFTC: includes ocean surface current and HFBULKTC to comput |
| 84 | + sensible and latent heat fluxes into ocean. |
| 85 | + |
| 86 | + RAIN_FLUX: computes heat flux and momentum flux due to rain. |
| 87 | + |
| 88 | +4) Programs relating wind speed, height, and surface stress. |
| 89 | + |
| 90 | + Neutral conditions: |
| 91 | + |
| 92 | + CDNLP: computes neutral Cd, 10m wind following Large and Pond (1981). |
| 93 | + CDNTC: computes neutral Cd, 10m wind following Smith (1988). |
| 94 | + CDNVE: computes neutral Cd, 10m wind following Vera (1983). |
| 95 | + |
| 96 | + STRESSLP: computes the neutral wind stress using Large and Pond. |
| 97 | + STRESSTC: computes the neutral wind stress following Smith. |
| 98 | + STRESSVE: computes the neutral wind stress using Vera. |
| 99 | + |
| 100 | + SPSHFTLP: computes winds at another height using Large&Pond drag. |
| 101 | + SPSHFTTC: computes winds at another height using Smith drag. |
| 102 | + SPSHFTVE: computes winds at another height using Vera drag. |
| 103 | + |
| 104 | + Non-neutral conditions: |
| 105 | + |
| 106 | + HFBULKTC: uses simplified version of Fairall et al (1996) |
| 107 | + TOGA/COARE code to compute surface wind stress amplitude, |
| 108 | + (Uses Monin-Obukov similarity theory with surface rougness using |
| 109 | + Charnock approach, like Smith (1988)). |
| 110 | + |
| 111 | + SLHFTC: includes ocean surface current and HFBULKTC to |
| 112 | + compute surface wind stress vector as well as scalar parameters. |
| 113 | + |
| 114 | +5) Programs used to estimate wave effects on the measured wind speed: |
| 115 | + |
| 116 | + WAVEDIST: estimate true wind speed at 10-m height. |
| 117 | + WAVEDIS1: estimate true wind speed at measurement height. |
| 118 | + WAVEDIS2: plots wave effects at measurement height vs. wave height. |
| 119 | + OMEGALMC: estimates wave effect on wind log profile. |
| 120 | + CDNVE: computes neutral drag coefficient following Vera (1983). |
| 121 | + |
| 122 | + See WDNOTES for additional information. |
| 123 | + |
| 124 | +6) Other useful programs: |
| 125 | + |
| 126 | + AS_CONSTS: contains various constants used in the toolbox. |
| 127 | + |
| 128 | + DAVEALB: computes daily mean albedo. |
| 129 | + SUNRISE: computes GMT time of sunrise and sunset (uses SORADNA1). |
| 130 | + |
| 131 | + GREG2: converts decimal yearday into Julian calendar day. |
| 132 | + JULIANMD: converts Gregorian calendar dates to decimal Julian day |
| 133 | + for days beginning at midnight UT |
| 134 | + YEARDAY: converts calender month and day into yearday. |
| 135 | + |
| 136 | + DELQ: air-sea specific humidity difference. |
| 137 | + EP: net precipitation and evaporation accumulation. |
| 138 | + QSAT: saturation specific humidity. |
| 139 | + RELHUMID: relative humidity from wet/dry bulb thermometers. |
| 140 | + RHADJ: adjusts RH for values above 100. |
| 141 | + SATVAP: saturation vapour pressure. |
| 142 | + VAPOR: heat of evaporation. |
| 143 | + VISCAIR: viscosity of air at a given temperature. |
| 144 | + COOL_SKIN: computes cool-skin parameters. |
| 145 | + T_HFBULKTC: tests HFBULKTC with COARE data. |
| 146 | + |
| 147 | +7) See CONTENTS for listing of all m-files in this toolbox. |
| 148 | + |
| 149 | +8) History: |
| 150 | + |
| 151 | + Version 1.0: |
| 152 | + |
| 153 | + The initial assembly of this toolbox was a collaborative effort |
| 154 | + by Bob Beardsley (WHOI), Ed Dever (SIO), Steve Lentz (WHOI), Jim |
| 155 | + Edson (WHOI), and Dick Payne (WHOI), with additional input from |
| 156 | + Steve Anderson (WHOI), Jay Austin (WHOI), Chris Fairall (NOAA), |
| 157 | + Carl Friehe (UCI), Bill Large (NCAR), Dave Rogers (SIO), Rich |
| 158 | + Signell (USGS), and Bob Weller (WHOI). Their input was very useful. |
| 159 | + |
| 160 | + Version 1.1: |
| 161 | + |
| 162 | + Rich Pawlowicz (UBC) then converted the original version 1.0 |
| 163 | + (written for MATLAB 4) into a much improved version 1.1 (optimized |
| 164 | + for MATLAB 5) which included major coding improvements, the addition |
| 165 | + of some new m-files, and some corrections of existing m-files. |
| 166 | + |
| 167 | + Version 1.2: |
| 168 | + |
| 169 | + Ayal Anis (U. Dalhousie) then modified HFBULKTC to include the |
| 170 | + Fairall et al (1996) cool-skin effect and Webb correction to the |
| 171 | + latent heat flux, plus added files to test the code with COARE |
| 172 | + data. Ayal and R. Onken (NATO) also contributed several other files. |
| 173 | + |
| 174 | + Version 2.0: |
| 175 | + |
| 176 | + Bob Beardsley has added several m-files and made simple changes |
| 177 | + to the various m-files to standardize the format and documentation. |
| 178 | + |
| 179 | +9) Comments, Suggestions, and Improvements |
| 180 | + |
| 181 | + Please contact Bob Beardsley at [email protected] with questions |
| 182 | + and comments, especially concerning bugs (and their possible fixes), |
| 183 | + ideas for additional m-files, plus any m-files which you want to |
| 184 | + contribute to this toolbox. Your help in improving this toolbox will |
| 185 | + be greatly appreciated. |
| 186 | + |
| 187 | + As new or/or improved m-files are developed for this toolbox, they |
| 188 | + will be added to the AIR_SEA toolbox folder located at the SEA-MAT |
| 189 | + Web site (crusty.usgs.gov/sea-mat/). SEA-MAT is a collection of |
| 190 | + MATLAB mfiles for the display and analysis of oceanographic data. |
0 commit comments