diff --git a/docs/ocean/design_docs/tides/ametsoc.bst b/docs/ocean/design_docs/tides/ametsoc.bst new file mode 100644 index 0000000000..195e831238 --- /dev/null +++ b/docs/ocean/design_docs/tides/ametsoc.bst @@ -0,0 +1,1741 @@ +%% +%% This is file `ametsoc.bst', +%% generated with the docstrip utility. +%% +%% The original source files were: +%% +%% merlin.mbs (with options: `,ay,nat,nm-rev1,nmdash,dt-beg,note-yr,vol-bf,vnum-x,volp-com,pp-last,bkpg-x,pg-bk,pre-pub,url,url-nl,edby,edbyy,blk-tit,au-col,in-x,pp,ed,xedn,jabr,em-it') +%% ---------------------------------------- +%% *** Lakshman (Nov. 1999), for American Meteorological Society publications *** +%% +%% Copyright 1994-1999 Patrick W Daly + % =============================================================== + % IMPORTANT NOTICE: + % This bibliographic style (bst) file has been generated from one or + % more master bibliographic style (mbs) files, listed above. + % + % This generated file can be redistributed and/or modified under the terms + % of the LaTeX Project Public License Distributed from CTAN + % archives in directory macros/latex/base/lppl.txt; either + % version 1 of the License, or any later version. + % =============================================================== + % Name and version information of the main mbs file: + % \ProvidesFile{merlin.mbs}[1999/03/18 3.88 (PWD)] + % For use with BibTeX version 0.99a or later + %------------------------------------------------------------------- + % This bibliography style file is intended for texts in ENGLISH + % This is an author-year citation style bibliography. As such, it is + % non-standard LaTeX, and requires a special package file to function properly. + % Such a package is natbib.sty by Patrick W. Daly + % The form of the \bibitem entries is + % \bibitem[Jones et al.(1990)]{key}... + % \bibitem[Jones et al.(1990)Jones, Baker, and Smith]{key}... + % The essential feature is that the label (the part in brackets) consists + % of the author names, as they should appear in the citation, with the year + % in parentheses following. There must be no space before the opening + % parenthesis! + % With natbib v5.3, a full list of authors may also follow the year. + % In natbib.sty, it is possible to define the type of enclosures that is + % really wanted (brackets or parentheses), but in either case, there must + % be parentheses in the label. + % The \cite command functions as follows: + % \citet{key} ==>> Jones et al. (1990) + % \citet*{key} ==>> Jones, Baker, and Smith (1990) + % \citep{key} ==>> (Jones et al., 1990) + % \citep*{key} ==>> (Jones, Baker, and Smith, 1990) + % \citep[chap. 2]{key} ==>> (Jones et al., 1990, chap. 2) + % \citep[e.g.][]{key} ==>> (e.g. Jones et al., 1990) + % \citep[e.g.][p. 32]{key} ==>> (e.g. Jones et al., p. 32) + % \citeauthor{key} ==>> Jones et al. + % \citeauthor*{key} ==>> Jones, Baker, and Smith + % \citeyear{key} ==>> 1990 + %--------------------------------------------------------------------- + +ENTRY + { address + author + booktitle + chapter + edition + editor + howpublished + institution + journal + doi + key + month + note + number + organization + pages + publisher + school + series + title + type + url + volume + year + } + {} + { label extra.label sort.label short.list } + +INTEGERS { output.state before.all mid.sentence after.sentence after.block } + +FUNCTION {init.state.consts} +{ #0 'before.all := + #1 'mid.sentence := + #2 'after.sentence := + #3 'after.block := +} + +STRINGS { s t } + +FUNCTION {output.nonnull} +{ 's := + output.state mid.sentence = + { ", " * write$ } + { output.state after.block = + { add.period$ write$ + newline$ + "\newblock " write$ + } + { output.state before.all = + 'write$ + { add.period$ " " * write$ } + if$ + } + if$ + mid.sentence 'output.state := + } + if$ + s +} + +FUNCTION {output} +{ duplicate$ empty$ + 'pop$ + 'output.nonnull + if$ +} + +FUNCTION {output.check} +{ 't := + duplicate$ empty$ + { pop$ "empty " t * " in " * cite$ * warning$ } + 'output.nonnull + if$ +} + +FUNCTION {fin.entry} +{ add.period$ + write$ + newline$ +} + +FUNCTION {new.block} +{ output.state before.all = + 'skip$ + { after.block 'output.state := } + if$ +} + +FUNCTION {new.sentence} +{ output.state after.block = + 'skip$ + { output.state before.all = + 'skip$ + { after.sentence 'output.state := } + if$ + } + if$ +} + +FUNCTION {add.blank} +{ " " * before.all 'output.state := +} + +FUNCTION {add.colon} +{ duplicate$ empty$ + 'skip$ + { ":" * add.blank } + if$ +} + +FUNCTION {date.block} +{ + skip$ +} + +FUNCTION {not} +{ { #0 } + { #1 } + if$ +} + +FUNCTION {and} +{ 'skip$ + { pop$ #0 } + if$ +} + +FUNCTION {or} +{ { pop$ #1 } + 'skip$ + if$ +} + +FUNCTION {new.block.checkb} +{ empty$ + swap$ empty$ + and + 'skip$ + 'new.block + if$ +} + +FUNCTION {field.or.null} +{ duplicate$ empty$ + { pop$ "" } + 'skip$ + if$ +} + +FUNCTION {emphasize} +{ duplicate$ empty$ + { pop$ "" } + { "{\it " swap$ * "\/}" * } + if$ +} + +FUNCTION {bolden} +{ duplicate$ empty$ + { pop$ "" } + { "{\bf " swap$ * "}" * } + if$ +} + +FUNCTION {capitalize} +{ "u" change.case$ "t" change.case$ } + +FUNCTION {space.word} +{ " " swap$ * " " * } + + % Here are the language-specific definitions for explicit words. + % Each function has a name bbl.xxx where xxx is the English word. + % The language selected here is ENGLISH +FUNCTION {bbl.and} +{ "and"} + +FUNCTION {bbl.etal} +{ "et~al." } + +FUNCTION {bbl.editors} +{ "eds." } + +FUNCTION {bbl.editor} +{ "ed." } + +FUNCTION {bbl.edby} +{ "edited by" } + +FUNCTION {bbl.edition} +{ "edition" } + +FUNCTION {bbl.volume} +{ "volume" } + +FUNCTION {bbl.of} +{ "of" } + +FUNCTION {bbl.number} +{ "number" } + +FUNCTION {bbl.nr} +{ "no." } + +FUNCTION {bbl.in} +{ "in" } + +FUNCTION {bbl.pages} +{ "pp." } + +FUNCTION {bbl.page} +{ "p." } + +FUNCTION {bbl.chapter} +{ "chapter" } + +FUNCTION {bbl.techrep} +{ "Technical Report" } + +FUNCTION {bbl.mthesis} +{ "Master's thesis" } + +FUNCTION {bbl.phdthesis} +{ "Ph.D. thesis" } + +MACRO {jan} {"January"} + +MACRO {feb} {"February"} + +MACRO {mar} {"March"} + +MACRO {apr} {"April"} + +MACRO {may} {"May"} + +MACRO {jun} {"June"} + +MACRO {jul} {"July"} + +MACRO {aug} {"August"} + +MACRO {sep} {"September"} + +MACRO {oct} {"October"} + +MACRO {nov} {"November"} + +MACRO {dec} {"December"} + + + %------------------------------------------------------------------- + % Begin module: + % \ProvidesFile{physjour.mbs}[1999/02/24 2.0d (PWD)] +MACRO {ar} {"Atmos. Res."} + +MACRO {aa}{"Astron. \& Astrophys."} +MACRO {aasup}{"Astron. \& Astrophys. Suppl. Ser."} +MACRO {aph} {"Acta Phys."} +MACRO {advp} {"Adv. Phys."} +MACRO {ajp} {"Amer. J. Phys."} +MACRO {ajm} {"Amer. J. Math."} +MACRO {amsci} {"Amer. Sci."} +MACRO {anofd} {"Ann. Fluid Dyn."} +MACRO {am} {"Ann. Math."} +MACRO {ap} {"Ann. Phys. (NY)"} +MACRO {adp} {"Ann. Phys. (Leipzig)"} +MACRO {ao} {"Appl. Opt."} +MACRO {apl} {"Appl. Phys. Lett."} +MACRO {app} {"Astroparticle Phys."} +MACRO {apj} {"Astrophys. J."} +MACRO {apjsup} {"Astrophys. J. Suppl. Ser."} +MACRO {baps} {"Bull. Amer. Phys. Soc."} +MACRO {cmp} {"Comm. Math. Phys."} +MACRO {cpam} {"Commun. Pure Appl. Math."} +MACRO {cppcf} {"Comm. Plasma Phys. \& Controlled Fusion"} +MACRO {cpc} {"Comp. Phys. Comm."} +MACRO {cqg} {"Class. Quant. Grav."} +MACRO {cra} {"C. R. Acad. Sci. A"} +MACRO {fed} {"Fusion Eng. \& Design"} +MACRO {ft} {"Fusion Tech."} +MACRO {grg} {"Gen. Relativ. Gravit."} +MACRO {ieeens} {"IEEE Trans. Nucl. Sci."} +MACRO {ieeeps} {"IEEE Trans. Plasma Sci."} +MACRO {ijimw} {"Interntl. J. Infrared \& Millimeter Waves"} +MACRO {ip} {"Infrared Phys."} +MACRO {irp} {"Infrared Phys."} +MACRO {jap} {"J. Appl. Phys."} +MACRO {jasa} {"J. Acoust. Soc. America"} +MACRO {jcp} {"J. Comp. Phys."} +MACRO {jetp} {"Sov. Phys.--JETP"} +MACRO {jfe} {"J. Fusion Energy"} +MACRO {jfm} {"J. Fluid Mech."} +MACRO {jmp} {"J. Math. Phys."} +MACRO {jne} {"J. Nucl. Energy"} +MACRO {jnec} {"J. Nucl. Energy, C: Plasma Phys., Accelerators, Thermonucl. Res."} +MACRO {jnm} {"J. Nucl. Mat."} +MACRO {jpc} {"J. Phys. Chem."} +MACRO {jpp} {"J. Plasma Phys."} +MACRO {jpsj} {"J. Phys. Soc. Japan"} +MACRO {jsi} {"J. Sci. Instrum."} +MACRO {jvst} {"J. Vac. Sci. \& Tech."} +MACRO {nat} {"Nature"} +MACRO {nature} {"Nature"} +MACRO {nedf} {"Nucl. Eng. \& Design/Fusion"} +MACRO {nf} {"Nucl. Fusion"} +MACRO {nim} {"Nucl. Inst. \& Meth."} +MACRO {nimpr} {"Nucl. Inst. \& Meth. in Phys. Res."} +MACRO {np} {"Nucl. Phys."} +MACRO {npb} {"Nucl. Phys. B"} +MACRO {nt/f} {"Nucl. Tech./Fusion"} +MACRO {npbpc} {"Nucl. Phys. B (Proc. Suppl.)"} +MACRO {inc} {"Nuovo Cimento"} +MACRO {nc} {"Nuovo Cimento"} +MACRO {pf} {"Phys. Fluids"} +MACRO {pfa} {"Phys. Fluids A: Fluid Dyn."} +MACRO {pfb} {"Phys. Fluids B: Plasma Phys."} +MACRO {pl} {"Phys. Lett."} +MACRO {pla} {"Phys. Lett. A"} +MACRO {plb} {"Phys. Lett. B"} +MACRO {prep} {"Phys. Rep."} +MACRO {pnas} {"Proc. Nat. Acad. Sci. USA"} +MACRO {pp} {"Phys. Plasmas"} +MACRO {ppcf} {"Plasma Phys. \& Controlled Fusion"} +MACRO {phitrsl} {"Philos. Trans. Roy. Soc. London"} +MACRO {prl} {"Phys. Rev. Lett."} +MACRO {pr} {"Phys. Rev."} +MACRO {physrev} {"Phys. Rev."} +MACRO {pra} {"Phys. Rev. A"} +MACRO {prb} {"Phys. Rev. B"} +MACRO {prc} {"Phys. Rev. C"} +MACRO {prd} {"Phys. Rev. D"} +MACRO {pre} {"Phys. Rev. E"} +MACRO {ps} {"Phys. Scripta"} +MACRO {procrsl} {"Proc. Roy. Soc. London"} +MACRO {rmp} {"Rev. Mod. Phys."} +MACRO {rsi} {"Rev. Sci. Inst."} +MACRO {science} {"Science"} +MACRO {sciam} {"Sci. Am."} +MACRO {sam} {"Stud. Appl. Math."} +MACRO {sjpp} {"Sov. J. Plasma Phys."} +MACRO {spd} {"Sov. Phys.--Doklady"} +MACRO {sptp} {"Sov. Phys.--Tech. Phys."} +MACRO {spu} {"Sov. Phys.--Uspeki"} + % End module: physjour.mbs + %------------------------------------------------------------------- + % Begin module: + % \ProvidesFile{geojour.mbs}[1999/02/24 2.0e (PWD)] +MACRO {aisr} {"Adv. Space Res."} +MACRO {ag} {"Ann. Geophys."} +MACRO {anigeo} {"Ann. Geofis."} +MACRO {angl} {"Ann. Glaciol."} +MACRO {andmet} {"Ann. d. Meteor."} +MACRO {andgeo} {"Ann. d. Geophys."} +MACRO {andphy} {"Ann. d. Phys."} +MACRO {afmgb} {"Arch. Meteor. Geophys. Bioklimatol."} +MACRO {atph} {"Atm\'osphera"} +MACRO {aao} {"Atmos.-Ocean"} +MACRO {ass}{"Astrophys. Space Sci."} +MACRO {atenv} {"Atmos. Environ."} +MACRO {aujag} {"Aust. J. Agric. Res."} +MACRO {aumet} {"Aust. Meteor. Mag."} +MACRO {blmet} {"Bound.-Layer Meteor."} +MACRO {bams} {"Bull. Amer. Meteor. Soc."} +MACRO {cch} {"Clim. Change"} +MACRO {cdyn} {"Climate Dyn."} +MACRO {cbul} {"Climatol. Bull."} +MACRO {cap} {"Contrib. Atmos. Phys."} +MACRO {dsr} {"Deep-Sea Res."} +MACRO {dhz} {"Dtsch. Hydrogr. Z."} +MACRO {dao} {"Dyn. Atmos. Oceans"} +MACRO {eco} {"Ecology"} +MACRO {empl}{"Earth, Moon and Planets"} +MACRO {envres} {"Environ. Res."} +MACRO {envst} {"Environ. Sci. Technol."} +MACRO {ecms} {"Estuarine Coastal Mar. Sci."} +MACRO {expa}{"Exper. Astron."} +MACRO {geoint} {"Geofis. Int."} +MACRO {geopub} {"Geofys. Publ."} +MACRO {geogeo} {"Geol. Geofiz."} +MACRO {gafd} {"Geophys. Astrophys. Fluid Dyn."} +MACRO {gfd} {"Geophys. Fluid Dyn."} +MACRO {geomag} {"Geophys. Mag."} +MACRO {georl} {"Geophys. Res. Lett."} +MACRO {grl} {"Geophys. Res. Lett."} +MACRO {ga} {"Geophysica"} +MACRO {gs} {"Geophysics"} +MACRO {ieeetap} {"IEEE Trans. Antennas Propag."} +MACRO {ijawp} {"Int. J. Air Water Pollut."} +MACRO {ijc} {"Int. J. Climatol."} +MACRO {ijrs} {"Int. J. Remote Sensing"} +MACRO {jam} {"J. Appl. Meteor."} +MACRO {jaot} {"J. Atmos. Ocean. Technol."} +MACRO {jatp} {"J. Atmos. Terr. Phys."} +MACRO {jce} {"J. Climate"} +MACRO {jcam} {"J. Climate Appl. Meteor."} +MACRO {jcm} {"J. Climate Meteor."} +MACRO {jcy} {"J. Climatol."} +MACRO {jgr} {"J. Geophys. Res."} +MACRO {jga} {"J. Glaciol."} +MACRO {jh} {"J. Hydrol."} +MACRO {jmr} {"J. Mar. Res."} +MACRO {jmrj} {"J. Meteor. Res. Japan"} +MACRO {jm} {"J. Meteor."} +MACRO {jpo} {"J. Phys. Oceanogr."} +MACRO {jra} {"J. Rech. Atmos."} +MACRO {jaes} {"J. Aeronaut. Sci."} +MACRO {japca} {"J. Air Pollut. Control Assoc."} +MACRO {jas} {"J. Atmos. Sci."} +MACRO {jmts} {"J. Mar. Technol. Soc."} +MACRO {jmsj} {"J. Meteor. Soc. Japan"} +MACRO {josj} {"J. Oceanogr. Soc. Japan"} +MACRO {jwm} {"J. Wea. Mod."} +MACRO {lao} {"Limnol. Oceanogr."} +MACRO {mwl} {"Mar. Wea. Log"} +MACRO {mau} {"Mausam"} +MACRO {meteor} {"``Meteor'' Forschungsergeb."} +MACRO {map} {"Met. Atmos. Phys."} +MACRO {metmag} {"Meteor. Mag."} +MACRO {metmon} {"Meteor. Monogr."} +MACRO {metrun} {"Meteor. Rundsch."} +MACRO {metzeit} {"Meteor. Z."} +MACRO {metgid} {"Meteor. Gidrol."} +MACRO {mwr} {"Mon. Wea. Rev."} +MACRO {nwd} {"Natl. Wea. Dig."} +MACRO {nzjmfr} {"N. Z. J. Mar. Freshwater Res."} +MACRO {npg} {"Nonlin. Proc. Geophys."} +MACRO {om} {"Oceanogr. Meteor."} +MACRO {ocac} {"Oceanol. Acta"} +MACRO {oceanus} {"Oceanus"} +MACRO {paleoc} {"Paleoceanography"} +MACRO {pce} {"Physics and Chemistry of the Earth"} +MACRO {pmg} {"Pap. Meteor. Geophys."} +MACRO {ppom} {"Pap. Phys. Oceanogr. Meteor."} +MACRO {physzeit} {"Phys. Z."} +MACRO {pps} {"Planet. Space Sci."} +MACRO {pss} {"Planet. Space Sci."} +MACRO {pag} {"Pure Appl. Geophys."} +MACRO {qjrms} {"Quart. J. Roy. Meteor. Soc."} +MACRO {quatres} {"Quat. Res."} +MACRO {rsci} {"Radio Sci."} +MACRO {rse} {"Remote Sens. Environ."} +MACRO {rgeo} {"Rev. Geophys."} +MACRO {rgsp} {"Rev. Geophys. Space Phys."} +MACRO {rdgeo} {"Rev. Geofis."} +MACRO {revmeta} {"Rev. Meteor."} +MACRO {sgp}{"Surveys in Geophys."} +MACRO {sp} {"Solar Phys."} +MACRO {ssr} {"Space Sci. Rev."} +MACRO {tellus} {"Tellus"} +MACRO {tac} {"Theor. Appl. Climatol."} +MACRO {tagu} {"Trans. Am. Geophys. Union (EOS)"} +MACRO {wrr} {"Water Resour. Res."} +MACRO {weather} {"Weather"} +MACRO {wafc} {"Wea. Forecasting"} +MACRO {ww} {"Weatherwise"} +MACRO {wmob} {"WMO Bull."} +MACRO {zeitmet} {"Z. Meteor."} + % End module: geojour.mbs +%% Copyright 1994-1999 Patrick W Daly + +MACRO {acmcs} {"ACM Comput. Surv."} + +MACRO {acta} {"Acta Inf."} + +MACRO {cacm} {"Commun. ACM"} + +MACRO {ibmjrd} {"IBM J. Res. Dev."} + +MACRO {ibmsj} {"IBM Syst.~J."} + +MACRO {ieeese} {"IEEE Trans. Softw. Eng."} + +MACRO {ieeetc} {"IEEE Trans. Comput."} + +MACRO {ieeetcad} + {"IEEE Trans. Comput.-Aided Design Integrated Circuits"} + +MACRO {ipl} {"Inf. Process. Lett."} + +MACRO {jacm} {"J.~ACM"} + +MACRO {jcss} {"J.~Comput. Syst. Sci."} + +MACRO {scp} {"Sci. Comput. Programming"} + +MACRO {sicomp} {"SIAM J. Comput."} + +MACRO {tocs} {"ACM Trans. Comput. Syst."} + +MACRO {tods} {"ACM Trans. Database Syst."} + +MACRO {tog} {"ACM Trans. Gr."} + +MACRO {toms} {"ACM Trans. Math. Softw."} + +MACRO {toois} {"ACM Trans. Office Inf. Syst."} + +MACRO {toplas} {"ACM Trans. Prog. Lang. Syst."} + +MACRO {tcs} {"Theoretical Comput. Sci."} + +FUNCTION {write.url} +{ url empty$ + { skip$ } + { "\newline\urlprefix\url{" url * "}" * write$ newline$ } + if$ +} + +FUNCTION {format.doi} +{ doi empty$ + { "" } + { "doi:" doi * } + if$ +} + +INTEGERS { nameptr namesleft numnames } + +FUNCTION {format.names} +{ 's := + #1 'nameptr := + s num.names$ 'numnames := + numnames 'namesleft := + { namesleft #0 > } + { nameptr #1 > + { s nameptr "{f.~}{vv~}{ll}{, jj}" format.name$ } + { s nameptr "{vv~}{ll}{, f.}{, jj}" format.name$ } + if$ + 't := + nameptr #1 > + { + namesleft #1 > + { ", " * t * } + { + numnames #2 > + { "," * } + 'skip$ + if$ + s nameptr "{ll}" format.name$ duplicate$ "others" = + { 't := } + { pop$ } + if$ + t "others" = + { + " " * bbl.etal * + } + { bbl.and + space.word * t * + } + if$ + } + if$ + } + 't + if$ + nameptr #1 + 'nameptr := + namesleft #1 - 'namesleft := + } + while$ +} +FUNCTION {format.names.ed} +{ 's := + #1 'nameptr := + s num.names$ 'numnames := + numnames 'namesleft := + { namesleft #0 > } + { s nameptr + "{f.~}{vv~}{ll}{, jj}" + format.name$ + 't := + nameptr #1 > + { + namesleft #1 > + { ", " * t * } + { + numnames #2 > + { "," * } + 'skip$ + if$ + s nameptr "{ll}" format.name$ duplicate$ "others" = + { 't := } + { pop$ } + if$ + t "others" = + { + + " " * bbl.etal * + } + { bbl.and + space.word * t * + } + if$ + } + if$ + } + 't + if$ + nameptr #1 + 'nameptr := + namesleft #1 - 'namesleft := + } + while$ +} + +FUNCTION {format.key} +{ empty$ + { key field.or.null } + { "" } + if$ +} + +FUNCTION {format.authors} +{ author empty$ + { "" } + { author format.names } + if$ +} + +FUNCTION {format.editors} +{ editor empty$ + { "" } + { editor format.names + editor num.names$ #1 > + { ", " * bbl.editors * } + { ", " * bbl.editor * } + if$ + } + if$ +} + +FUNCTION {format.in.editors} +{ editor empty$ + { "" } + { editor format.names.ed + } + if$ +} + +FUNCTION {format.book.pages} +{ pages empty$ + { "" } + { pages " " * bbl.pages * } + if$ +} + +FUNCTION {format.note} +{ + note empty$ + { "" } + { note #1 #1 substring$ + duplicate$ "{" = + 'skip$ + { output.state mid.sentence = + { "l" } + { "u" } + if$ + change.case$ + } + if$ + note #2 global.max$ substring$ * + } + if$ +} + +FUNCTION {format.title} +{ title empty$ + { "" } + { title "t" change.case$ + } + if$ +} + +FUNCTION {format.full.names} +{'s := + #1 'nameptr := + s num.names$ 'numnames := + numnames 'namesleft := + { namesleft #0 > } + { s nameptr + "{vv~}{ll}" format.name$ + 't := + nameptr #1 > + { + namesleft #1 > + { ", " * t * } + { + numnames #2 > + { "," * } + 'skip$ + if$ + s nameptr "{ll}" format.name$ duplicate$ "others" = + { 't := } + { pop$ } + if$ + t "others" = + { + " " * bbl.etal * + } + { bbl.and + space.word * t * + } + if$ + } + if$ + } + 't + if$ + nameptr #1 + 'nameptr := + namesleft #1 - 'namesleft := + } + while$ +} + +FUNCTION {author.editor.key.full} +{ author empty$ + { editor empty$ + { key empty$ + { cite$ #1 #3 substring$ } + 'key + if$ + } + { editor format.full.names } + if$ + } + { author format.full.names } + if$ +} + +FUNCTION {author.key.full} +{ author empty$ + { key empty$ + { cite$ #1 #3 substring$ } + 'key + if$ + } + { author format.full.names } + if$ +} + +FUNCTION {editor.key.full} +{ editor empty$ + { key empty$ + { cite$ #1 #3 substring$ } + 'key + if$ + } + { editor format.full.names } + if$ +} + +FUNCTION {make.full.names} +{ type$ "book" = + type$ "inbook" = + or + 'author.editor.key.full + { type$ "proceedings" = + 'editor.key.full + 'author.key.full + if$ + } + if$ +} + +FUNCTION {output.bibitem} +{ newline$ + "\bibitem[{" write$ + label write$ + ")" make.full.names duplicate$ short.list = + { pop$ } + { * } + if$ + "}]{" * write$ + cite$ write$ + "}" write$ + newline$ + "" + before.all 'output.state := +} + +FUNCTION {n.dashify} +{ + 't := + "" + { t empty$ not } + { t #1 #1 substring$ "-" = + { t #1 #2 substring$ "--" = not + { "--" * + t #2 global.max$ substring$ 't := + } + { { t #1 #1 substring$ "-" = } + { "-" * + t #2 global.max$ substring$ 't := + } + while$ + } + if$ + } + { t #1 #1 substring$ * + t #2 global.max$ substring$ 't := + } + if$ + } + while$ +} + +FUNCTION {word.in} +{ "" } + +FUNCTION {format.date} +{ year duplicate$ empty$ + { "empty year in " cite$ * "; set to ????" * warning$ + pop$ "????" } + 'skip$ + if$ + extra.label * +} + +FUNCTION {format.btitle} +{ title emphasize +} + +FUNCTION {tie.or.space.connect} +{ duplicate$ text.length$ #3 < + { "~" } + { " " } + if$ + swap$ * * +} + +FUNCTION {either.or.check} +{ empty$ + 'pop$ + { "can't use both " swap$ * " fields in " * cite$ * warning$ } + if$ +} + +FUNCTION {format.bvolume} +{ volume empty$ + { "" } + { bbl.volume volume tie.or.space.connect + series empty$ + 'skip$ + { bbl.of space.word * series emphasize * } + if$ + "volume and number" number either.or.check + } + if$ +} + +FUNCTION {format.number.series} +{ volume empty$ + { number empty$ + { series field.or.null } + { output.state mid.sentence = + { bbl.number } + { bbl.number capitalize } + if$ + number tie.or.space.connect + series empty$ + { "there's a number but no series in " cite$ * warning$ } + { bbl.in space.word * series * } + if$ + } + if$ + } + { "" } + if$ +} + + +FUNCTION {format.edition} +{ edition empty$ + { "" } + { output.state mid.sentence = + { edition "l" change.case$ " " * bbl.edition * } + { edition "t" change.case$ " " * bbl.edition * } + if$ + } + if$ +} + +INTEGERS { multiresult } + +FUNCTION {multi.page.check} +{ 't := + #0 'multiresult := + { multiresult not + t empty$ not + and + } + { t #1 #1 substring$ + duplicate$ "-" = + swap$ duplicate$ "," = + swap$ "+" = + or or + { #1 'multiresult := } + { t #2 global.max$ substring$ 't := } + if$ + } + while$ + multiresult +} + +FUNCTION {format.pages} +{ pages empty$ + { "" } + { pages multi.page.check + { pages n.dashify } + { pages } + if$ + } + if$ +} + +FUNCTION {format.journal.pages} +{ pages empty$ + 'skip$ + { duplicate$ empty$ + { pop$ format.pages } + { + ", " * + pages n.dashify * + } + if$ + } + if$ +} + +FUNCTION {format.vol.num.pages} +{ volume field.or.null + bolden +} + +FUNCTION {format.chapter.pages} +{ chapter empty$ + { "" } + { type empty$ + { bbl.chapter } + { type "l" change.case$ } + if$ + chapter tie.or.space.connect + } + if$ +} + +FUNCTION {format.in.ed.booktitle} +{ booktitle empty$ + { "" } + { editor empty$ + { word.in booktitle emphasize * } + { word.in booktitle emphasize * + ", " * + format.in.editors * + ", " * + editor num.names$ #1 > + { bbl.editors } + { bbl.editor } + if$ + * + } + if$ + } + if$ +} + +FUNCTION {format.thesis.type} +{ type empty$ + 'skip$ + { pop$ + type "t" change.case$ + } + if$ +} + +FUNCTION {format.tr.number} +{ type empty$ + { bbl.techrep } + 'type + if$ + number empty$ + { "t" change.case$ } + { number tie.or.space.connect } + if$ +} + +FUNCTION {format.article.crossref} +{ + word.in + " \cite{" * crossref * "}" * +} + +FUNCTION {format.book.crossref} +{ volume empty$ + { "empty volume in " cite$ * "'s crossref of " * crossref * warning$ + word.in + } + { bbl.volume capitalize + volume tie.or.space.connect + bbl.of space.word * + } + if$ + " \cite{" * crossref * "}" * +} + +FUNCTION {format.incoll.inproc.crossref} +{ + word.in + " \cite{" * crossref * "}" * +} + +FUNCTION {format.org.or.pub} +{ 't := + "" + address empty$ t empty$ and + 'skip$ + { + t empty$ + { address empty$ + 'skip$ + { address * } + if$ + } + { t * + address empty$ + 'skip$ + { ", " * address * } + if$ + } + if$ + } + if$ +} + +FUNCTION {format.publisher.address} +{ publisher empty$ + { "empty publisher in " cite$ * warning$ + "" + } + { publisher } + if$ + format.org.or.pub +} + +FUNCTION {format.organization.address} +{ organization empty$ + { "" } + { organization } + if$ + format.org.or.pub +} + +STRINGS {oldname} + +FUNCTION {name.or.dash} +{ 's := + oldname empty$ + { s 'oldname := s } + { s oldname = + { "---" add.blank } + { s 'oldname := s } + if$ + } + if$ +} + +FUNCTION {article} +{ output.bibitem + format.authors "author" output.check + author format.key output + name.or.dash + format.date "year" output.check + add.colon + date.block + format.title "title" output.check + new.sentence + crossref missing$ + { journal + emphasize + "journal" output.check + format.vol.num.pages output + } + { format.article.crossref output.nonnull + format.pages output + } + if$ + format.journal.pages + format.doi output + format.note output + fin.entry + write.url +} + +FUNCTION {book} +{ output.bibitem + author empty$ + { format.editors "author and editor" output.check + editor format.key output + name.or.dash + } + { format.authors output.nonnull + name.or.dash + crossref missing$ + { "author and editor" editor either.or.check } + 'skip$ + if$ + } + if$ + format.date "year" output.check + add.colon + date.block + format.btitle "title" output.check + crossref missing$ + { format.bvolume output + new.sentence + format.number.series output + format.publisher.address output + } + { + new.sentence + format.book.crossref output.nonnull + } + if$ + format.edition output + format.book.pages output + format.note output + fin.entry + write.url +} + +FUNCTION {booklet} +{ output.bibitem + format.authors output + author format.key output + name.or.dash + format.date "year" output.check + add.colon + date.block + format.title "title" output.check + new.sentence + howpublished output + address output + format.book.pages output + format.note output + fin.entry + write.url +} + +FUNCTION {inbook} +{ output.bibitem + author empty$ + { format.editors "author and editor" output.check + editor format.key output + name.or.dash + } + { format.authors output.nonnull + name.or.dash + crossref missing$ + { "author and editor" editor either.or.check } + 'skip$ + if$ + } + if$ + format.date "year" output.check + add.colon + date.block + format.btitle "title" output.check + crossref missing$ + { + format.publisher.address output + format.bvolume output + format.chapter.pages "chapter and pages" output.check + new.sentence + format.number.series output + } + { + format.chapter.pages "chapter and pages" output.check + new.sentence + format.book.crossref output.nonnull + } + if$ + format.edition output + format.pages "pages" output.check + format.note output + fin.entry + write.url +} + +FUNCTION {incollection} +{ output.bibitem + format.authors "author" output.check + author format.key output + name.or.dash + format.date "year" output.check + add.colon + date.block + format.title "title" output.check + new.sentence + crossref missing$ + { format.in.ed.booktitle "booktitle" output.check + format.publisher.address output + format.bvolume output + format.number.series output + format.chapter.pages output + format.edition output + } + { format.incoll.inproc.crossref output.nonnull + format.chapter.pages output + } + if$ + format.pages "pages" output.check + format.note output + fin.entry + write.url +} + +FUNCTION {inproceedings} +{ output.bibitem + format.authors "author" output.check + author format.key output + name.or.dash + format.date "year" output.check + add.colon + date.block + format.title "title" output.check + new.sentence + crossref missing$ + { format.in.ed.booktitle "booktitle" output.check + publisher empty$ + { format.organization.address output } + { organization output + format.publisher.address output + } + if$ + format.bvolume output + format.number.series output + format.pages output + } + { format.incoll.inproc.crossref output.nonnull + format.pages output + } + if$ + format.note output + fin.entry + write.url +} + +FUNCTION {conference} { inproceedings } + +FUNCTION {manual} +{ output.bibitem + format.authors output + author format.key output + name.or.dash + format.date "year" output.check + add.colon + date.block + format.btitle "title" output.check + new.sentence + organization output + address output + format.edition output + format.note output + fin.entry + write.url +} + +FUNCTION {mastersthesis} +{ output.bibitem + format.authors "author" output.check + author format.key output + name.or.dash + format.date "year" output.check + add.colon + date.block + format.btitle "title" output.check + new.sentence + bbl.mthesis format.thesis.type output.nonnull + school "school" output.check + address output + format.book.pages output + format.note output + fin.entry + write.url +} + +FUNCTION {misc} +{ output.bibitem + format.authors output + author format.key output + name.or.dash + format.date "year" output.check + add.colon + date.block + format.title output + new.sentence + howpublished output + format.note output + fin.entry + write.url +} + +FUNCTION {phdthesis} +{ output.bibitem + format.authors "author" output.check + author format.key output + name.or.dash + format.date "year" output.check + add.colon + date.block + format.btitle "title" output.check + new.sentence + bbl.phdthesis format.thesis.type output.nonnull + school "school" output.check + address output + format.book.pages output + format.note output + fin.entry + write.url +} + +FUNCTION {proceedings} +{ output.bibitem + format.editors output + editor format.key output + name.or.dash + format.date "year" output.check + add.colon + date.block + format.btitle "title" output.check + format.bvolume output + format.number.series output + publisher empty$ + { format.organization.address output } + { organization output + format.publisher.address output + } + if$ + format.note output + fin.entry + write.url +} + +FUNCTION {techreport} +{ output.bibitem + format.authors "author" output.check + author format.key output + name.or.dash + format.date "year" output.check + add.colon + date.block + format.title "title" output.check + new.sentence + format.tr.number output.nonnull + institution "institution" output.check + address output + format.note output + fin.entry + write.url +} + +FUNCTION {unpublished} +{ output.bibitem + format.authors "author" output.check + author format.key output + name.or.dash + format.date "year" output.check + add.colon + date.block + format.title "title" output.check + format.note "note" output.check + fin.entry + write.url +} + +FUNCTION {default.type} { misc } + +READ + +FUNCTION {sortify} +{ purify$ + "l" change.case$ +} + +INTEGERS { len } + +FUNCTION {chop.word} +{ 's := + 'len := + s #1 len substring$ = + { s len #1 + global.max$ substring$ } + 's + if$ +} + +FUNCTION {format.lab.names} +{ 's := + s #1 "{vv~}{ll}" format.name$ + s num.names$ duplicate$ + #2 > + { pop$ + " " * bbl.etal * + } + { #2 < + 'skip$ + { s #2 "{ff }{vv }{ll}{ jj}" format.name$ "others" = + { + " " * bbl.etal * + } + { bbl.and space.word * s #2 "{vv~}{ll}" format.name$ + * } + if$ + } + if$ + } + if$ +} + +FUNCTION {author.key.label} +{ author empty$ + { key empty$ + { cite$ #1 #3 substring$ } + 'key + if$ + } + { author format.lab.names } + if$ +} + +FUNCTION {author.editor.key.label} +{ author empty$ + { editor empty$ + { key empty$ + { cite$ #1 #3 substring$ } + 'key + if$ + } + { editor format.lab.names } + if$ + } + { author format.lab.names } + if$ +} + +FUNCTION {editor.key.label} +{ editor empty$ + { key empty$ + { cite$ #1 #3 substring$ } + 'key + if$ + } + { editor format.lab.names } + if$ +} + +FUNCTION {calc.short.authors} +{ type$ "book" = + type$ "inbook" = + or + 'author.editor.key.label + { type$ "proceedings" = + 'editor.key.label + 'author.key.label + if$ + } + if$ + 'short.list := +} + +FUNCTION {calc.label} +{ calc.short.authors + short.list + "(" + * + year duplicate$ empty$ + { pop$ "????" } + 'skip$ + if$ + * + 'label := +} + +FUNCTION {sort.format.names} +{ 's := + #1 'nameptr := + "" + s num.names$ 'numnames := + numnames 'namesleft := + { namesleft #0 > } + { s nameptr + "{vv{ } }{ll{ }}{ f{ }}{ jj{ }}" + format.name$ 't := + nameptr #1 > + { + " " * + namesleft #1 = t "others" = and + { "zzzzz" * } + { t sortify * } + if$ + } + { t sortify * } + if$ + nameptr #1 + 'nameptr := + namesleft #1 - 'namesleft := + } + while$ +} + +FUNCTION {sort.format.title} +{ 't := + "A " #2 + "An " #3 + "The " #4 t chop.word + chop.word + chop.word + sortify + #1 global.max$ substring$ +} + +FUNCTION {author.sort} +{ author empty$ + { key empty$ + { "to sort, need author or key in " cite$ * warning$ + "" + } + { key sortify } + if$ + } + { author sort.format.names } + if$ +} + +FUNCTION {author.editor.sort} +{ author empty$ + { editor empty$ + { key empty$ + { "to sort, need author, editor, or key in " cite$ * warning$ + "" + } + { key sortify } + if$ + } + { editor sort.format.names } + if$ + } + { author sort.format.names } + if$ +} + +FUNCTION {editor.sort} +{ editor empty$ + { key empty$ + { "to sort, need editor or key in " cite$ * warning$ + "" + } + { key sortify } + if$ + } + { editor sort.format.names } + if$ +} + +FUNCTION {presort} +{ calc.label + label sortify + " " + * + type$ "book" = + type$ "inbook" = + or + 'author.editor.sort + { type$ "proceedings" = + 'editor.sort + 'author.sort + if$ + } + if$ + #1 entry.max$ substring$ + 'sort.label := + sort.label + * + " " + * + title field.or.null + sort.format.title + * + #1 entry.max$ substring$ + 'sort.key$ := +} + +ITERATE {presort} + +SORT + +STRINGS { last.label next.extra } + +INTEGERS { last.extra.num number.label } + +FUNCTION {initialize.extra.label.stuff} +{ #0 int.to.chr$ 'last.label := + "" 'next.extra := + #0 'last.extra.num := + #0 'number.label := +} + +FUNCTION {forward.pass} +{ last.label label = + { last.extra.num #1 + 'last.extra.num := + last.extra.num int.to.chr$ 'extra.label := + } + { "a" chr.to.int$ 'last.extra.num := + "" 'extra.label := + label 'last.label := + } + if$ + number.label #1 + 'number.label := +} + +FUNCTION {reverse.pass} +{ next.extra "b" = + { "a" 'extra.label := } + 'skip$ + if$ + extra.label 'next.extra := + extra.label + duplicate$ empty$ + 'skip$ + { "{\natexlab{" swap$ * "}}" * } + if$ + 'extra.label := + label extra.label * 'label := +} + +EXECUTE {initialize.extra.label.stuff} + +ITERATE {forward.pass} + +REVERSE {reverse.pass} + +FUNCTION {bib.sort.order} +{ sort.label + " " + * + year field.or.null sortify + * + " " + * + title field.or.null + sort.format.title + * + #1 entry.max$ substring$ + 'sort.key$ := +} + +ITERATE {bib.sort.order} + +SORT + +FUNCTION {begin.bib} +{ preamble$ empty$ + 'skip$ + { preamble$ write$ newline$ } + if$ + "\begin{thebibliography}{" number.label int.to.str$ * "}" * + write$ newline$ + "\expandafter\ifx\csname natexlab\endcsname\relax\def\natexlab#1{#1}\fi" + write$ newline$ + "\expandafter\ifx\csname url\endcsname\relax" + write$ newline$ + " \def\url#1{{\tt #1}}\fi" + write$ newline$ + "\expandafter\ifx\csname urlprefix\endcsname\relax\def\urlprefix{URL }\fi" + write$ newline$ + "\expandafter\ifx\csname doiprefix\endcsname\relax\def\doiprefix{doi:}\fi" + write$ newline$ +} + +EXECUTE {begin.bib} + +EXECUTE {init.state.consts} + +ITERATE {call.type$} + +FUNCTION {end.bib} +{ newline$ + "\end{thebibliography}" write$ newline$ +} + +EXECUTE {end.bib} +%% End of customized bst file +%% +%% End of file `ametsoc.bst'. diff --git a/docs/ocean/design_docs/tides/tides.bib b/docs/ocean/design_docs/tides/tides.bib new file mode 100644 index 0000000000..6655ecd5ff --- /dev/null +++ b/docs/ocean/design_docs/tides/tides.bib @@ -0,0 +1,35 @@ + +@incollection{chassignet_primer_2018, + title = {A {Primer} on {Global} {Internal} {Tide} and {Internal} {Gravity} {Wave} {Continuum} {Modeling} in {HYCOM} and {MITgcm}}, + isbn = {978-1-72054-997-0}, + url = {http://purl.flvc.org/fsu/fd/FSU_libsubv1_scholarship_submission_1536242074_55feafcc}, + language = {en}, + urldate = {2018-10-23}, + booktitle = {New {Frontiers} in {Operational} {Oceanography}}, + publisher = {GODAE OceanView}, + author = {Arbic, Brian K. and Alford, Matthew H. and Ansong, Joseph K. and Buijsman, Maarten C. and Ciotti, Robert B. and Farrar, J. Thomas and Hallberg, Robert W. and Henze, Christopher E. and Hill, Christopher N. and Luecke, Conrad A. and Menemenlis, Dimitris and Metzger, E. Joseph and Müeller, Malte and Nelson, Arin D. and Nelson, Bron C. and Ngodock, Hans E. and Ponte, Rui M. and Richman, James G. and Savage, Anna C. and Scott, Robert B. and Shriver, Jay F. and Simmons, Harper L. and Souopgui, Innocent and Timko, Patrick G. and Wallcraft, Alan J. and Zamudio, Luis and Zhao, Zhongxiang}, + editor = {Chassignet, Eric P. and Pascual, Ananda and Tintoré, Joaquin and Verron, Jacques}, + month = aug, + year = {2018}, + doi = {10.17125/gov2018.ch13}, + file = {Arbic et al. - 2018 - A Primer on Global Internal Tide and Internal Grav.pdf:/Users/pwolfram/Zotero/storage/TEDRP9CP/Arbic et al. - 2018 - A Primer on Global Internal Tide and Internal Grav.pdf:application/pdf} +} + +@article{Luettich1992ADCIRC, + author={Luettich, R.A. and Westerink, J.J. and Scheffner, N.W.}, + title = {{ADCIRC}: {An} {Advanced} {Three}-{Dimensional} {Circulation} {Model} for {Shelves}, {Coasts}, and {Estuaries}. {Report} 1. {Theory} and {Methodology} of {ADCIRC-2DDI} and {ADCIRC-3DL}.}, + language = {en}, + pages = {143}, + year={1992} +} + +@article{arbic2004accuracy, + title={The accuracy of surface elevations in forward global barotropic and baroclinic tide models}, + author={Arbic, Brian K and Garner, Stephen T and Hallberg, Robert W and Simmons, Harper L}, + journal={Deep Sea Research Part II: Topical Studies in Oceanography}, + volume={51}, + number={25-26}, + pages={3069--3101}, + year={2004}, + publisher={Elsevier} +} diff --git a/docs/ocean/design_docs/tides/tides.tex b/docs/ocean/design_docs/tides/tides.tex new file mode 100644 index 0000000000..aa436f37b7 --- /dev/null +++ b/docs/ocean/design_docs/tides/tides.tex @@ -0,0 +1,359 @@ +ss[11pt]{report} + +\usepackage{epsf,amsmath,amsfonts} +\usepackage{graphicx} +\usepackage{booktabs} +\usepackage{color} +\usepackage{natbib} + +\setlength{\textwidth}{6.5in} +\setlength{\oddsidemargin}{0in} +\setlength{\evensidemargin}{0in} +\setlength{\textheight}{8in} +\setlength{\topmargin}{0.5in} + +\newcommand{\ds}{\displaystyle} +\setlength{\parskip}{1.2ex} +\setlength{\parindent}{0mm} +\newcommand{\bea}{\begin{eqnarray}} +\newcommand{\eea}{\end{eqnarray}} +\newcommand{\nn}{\nonumber} + +\usepackage{minted} + +\def\Mark#1{{\textcolor{red}{\bf \textit{By Mark: } #1}}} % new text +\def\Phillip#1{{\textcolor{cyan}{\bf \textit{By PhilW: } #1}}} % new text +\def\Steven#1{{\textcolor{blue}{\bf \textit{By Steven: } #1}}} % new text +\def\Luke#1{{\textcolor{green}{\bf \textit{By Luke: } #1}}} % new text +\def\Comment#1{{\textcolor{magenta}{\bf \textit{Comment: } #1}}} % new text +\begin{document} + +\title{MPAS-O Ocean Tides Design Document} +\author{Phillip Wolfram, Brian Arbic} + + + +\maketitle +\tableofcontents + +%----------------------------------------------------------------------- + +\chapter{Summary} + +Extract information from \url{https://acme-climate.atlassian.net/wiki/spaces/NGDW/pages/830701637/E3SM+Tidal+process+scoping} + +Tides are an ubiquitous contributor to global ocean flows, with effects on local sea level rise and coupled climate interactions on air-sea fluxes and ocean-sea ice processes. They operate at large time scales and have periodicity from approximately 3-6 hrs to 19 years and occur on long wave lengths in the global ocean but in estuaries can be modified to be limited to smaller scales, e.g., tidal river networks. + +Tides fundamentally are a gravity wave process arising from a variety of forcing mechanisms including: +\begin{enumerate} +\item Astronomical forcing via gravity (e.g., sun and moon) +\item Gravitational self-attraction +\item Loading of the solid earth +\item Shallow-water wave transport and interactions +\item Coriolis "forcing" +\item Basin dynamics (e.g., land constraining the flow) +\item Wind effects +\item Storm surge interactions +\item River and wind wave forcing +\end{enumerate} + +\section{MPAS-O contributions} +\begin{enumerate} +\item barotropic tide +\item regional sea level rise contribution due to regional tides +\item baroclinic tide +\item momentum dissipation due to tides (e.g., in CVmix) +\item strongly affects transport, mixing, inundation due to hurricanes, and geomorphology in inland and coastal waters +\end{enumerate} + +\section{MPAS-Sea ice contributions} +\begin{enumerate} + \item Gradients of tidal currents cause periodic convergence / divergence of ice pack for an "ice accordion" for net ice production in fall and net ice loss in spring / summer (Koentopp et al., 2005 cited in Padman et al, (2018): Ocean Tide Influences on the Antarctic and Greenland Ice Sheets) + \item Hibler et al. 2006 - Moderate resolution M2 baroatropic tidal modeling the Arctic Ocean + Holloway and Proshutinsky, 2007 - General description on how tides affect the ice-ocean component of the Arctic + \item Kagan and Sofina, 2010 - Impact of sea ice on tides in the Arctic + \item Killett et al, 2011 - Observations of Arctic Ocean tides + \item Kowalik and Proshutinsky, 1994 - The classic Arctic tides book chapter + \item Lindsay, 2002 - Tidal signature from in-situ SHEBA observations + \item Roberts et al. 2015 - High-frequency ice-ocean coupling (the rotary wavelet analysis applied here would be used in our work) + \item St.Laurent et al. 2008 - Tides in Hudson Bay + \item Zhang et al, 2010 -Tides included, but not analyzed, in Bering Strait through-flow + \item Lyard, 1997 - Finite element modeling of Arctic Ocean tides +\end{enumerate} + +\section{MALI} +Brief summary from Padman et al, (2018): Ocean Tide Influences on the Antarctic and Greenland Ice Sheets: +\begin{enumerate} +\item tides modify water properties coming in contact with ice shelf +\item seaward of grounding zone, ice shelves float hydrostatically and respond instantaneously to the tide +\item current variance under Ross Ice Shelf accounted for approximately half its variance (Arzeno et al, 2014), e.g., modulating melt flux a diurnal tidal period and spring-neap scale of 2 weeks +\item can periodically unground ice shelf in grounding zone +\item contribute to ice flexure to alter subglacial hydrological connections +\item contribute to crevasse formation +\item influence sediment flowing across grounding line to form grounding zone wedges +\item modify time-averaged backstress resisting outflow of glacial ice +\item feedbacks that require inclusion for accurate modeling: +\begin{itemize} +\item tide height changes due to ice dynamics +\item tidal currents effect on ocean mixing and ice shelf basal melting +\end{itemize} +\item Some of these processes would require a Stokes stress balance to include accurately +\item Tides can also induce elastic response in the ice shelf/sheet which current models ignore +\item Tidal time scales are shorter than typical ice sheet time steps, even at high resolution, but ice sheet models could be run with shorter time steps (for correspondingly increased cost) +\end{enumerate} + +%The purpose of this section is to summarize what capability is to be added to the MPAS system through this design process. It should be clear what new code will do that the current code does not. Summarizing the primary challenges with respect to software design and implementation is also appropriate for this section. Finally, this statement should contain general statement with regard to what is ``success.'' + +%figure template +%\begin{figure} +% \center{\includegraphics[width=14cm]{./Figure1.pdf}} +% \caption{A graphical representation of the discrete boundary.} +% \label{Figure1} +%\end{figure} + +\section{Science Questions} +\begin{enumerate} + \item Climate change of barotropic tide at century scale + \item Regional sea level rise impacts + \item Role of regional coastal drag on affecting regional tides + \item Estuarine dynamics and comparison with observations with the Surface Water Ocean Topography (SWOT) mission + \item Tidal effects on sea ice and ice shelves in a changing climate + +\end{enumerate} + + +%----------------------------------------------------------------------- + +\chapter{Requirements} + +\section{Requirement: Simulate barotropic tidal signature and compare against altimetry observations} +Date last modified: 2018/10/10 \\ +Contributors: Phillip Wolfram and Brian Arbic\\ + +Validate global tidal simulation against accurate altimeter-constrained tide models such as TPXO or others. + +\section{Requirement: Simulate five largest harmonic constituents M2, S2, N2, K1, O1 from astronomical forcing} +Date last modified: 2018/10/23 \\ +Contributors: Phillip Wolfram and Brian Arbic\\ + +Five largest tidal constituents need to be included in MPAS-O to represent the bulk of the energy and the energy dissipation of the barotropic tide. + + +%----------------------------------------------------------------------- + +\chapter{Algorithmic Formulations} + +\section{Astronomical forcing} + +The Newtonian equilibrium tidal potential is given by $\eta_{EQ}$. For the three largest semidiurnal tidal constituents, $\eta_{EQ}$ is given by equation (5) from \citet{chassignet_primer_2018} for $i=$ M$_{2}$, S$_{2}$, N$_{2}$ (applied 3 times and summed together), viz: +\begin{equation} +\eta_{EQ,i} = Af(t_{ref})(1+k_2-h_2)\cos^2(\phi)\cos\left[\omega(t-t_{ref}) + \chi(t_{ref}) + \nu(t_{ref}) + 2\lambda\right], +\label{eq:Eq5} +\end{equation} + +where the tidal amplitude is $A$, $f(t_{ref})$ is the the nodal factor accounting for the small modulations of amplitude (computed about once per year), $f(t_{ref})$ is slow modulation of amplitude (computed about once per year), the Love numbers $k_2$ and $h_2$ respectively account for the deformation of the solid earth due to the astronomical tidal forcing and the perturbation gravitational potential due to this deformation, $\phi$ is latitude, $\omega$ is tidal frequency, $t_{ref}$ is a reference time (often taken to be the beginning of a model run), $\chi(t_{ref})$ is the astronomical argument, and $\nu(t_ref)$ is the nodal factor accounting for the small modulations of phase, and $\lambda$ is longitude. + +For the diurnal constituents, the equilibrium tide is given by equation (6) of \citet{chassignet_primer_2018}, applied twice for $j=$ K$_{1}$ and O$_{1}$, viz: + +\begin{equation} +\eta_{EQ,j} = A f(t_{ref}) (1+k_2-h_2)\sin(2\phi)\cos\left[\omega(t-t_{ref}) + \chi(t_{ref}) + \nu(t_{ref}) + \lambda \right]. +\label{eq:Eq6} +\end{equation} + +Nodal factors +$\chi$, $f$, and $\nu$ are detailed in subsection \ref{sec:AstrArg}. +%(Book chapter doesn't give astronomical arguments, but Brian has matlab code for nodal factors and astronomical arguments Ask Richard for most recent code for nodal factors?) +Precision on decimals in Table \ref{tab:astronimcalFactors}, which gives the values of $\omega$, $A$, $1+k_2-h_2$, and period for the ten largest tidal consitutents, is deemed of acceptable accuracy to start (personal communication with Brian Arbic). + +\begin{table} +\begin{tabular}{|c|c|c|c|c|} +\hline +Constituent & $\omega\;\left(10^{-4}\,s^{-1}\right)$ & $A\;\left(\textrm{cm}\right)$ & $1+k_{2}-h_{2}$ & Period (solar days)\tabularnewline +\hline +\hline +$\textrm{M}_{m}$ & 0.026392 & 2.2191 & 0.693 & 27.5546\tabularnewline +\hline +$\textrm{M}_{f}$ & 0.053234 & 4.2041 & 0.693 & 13.6608\tabularnewline +\hline +$\textrm{Q}_{1}$ & 0.6495854 & 1.9273 & 0.695 & 1.1195\tabularnewline +\hline +$\textrm{O}_{1}$ & 0.6759774 & 10.0661 & 0.695 & 1.0758\tabularnewline +\hline +$\textrm{P}_{1}$ & 0.7252295 & 4.6848 & 0.706 & 1.0027\tabularnewline +\hline +$\textrm{K}_{1}$ & 0.7292117 & 14.1565 & 0.736 & 0.9973\tabularnewline +\hline +$\textrm{N}_{2}$ & 1.378797 & 4.6397 & 0.693 & 0.5274\tabularnewline +\hline +$\textrm{M}_{2}$ & 1.405189 & 24.2334 & 0.693 & 0.5175\tabularnewline +\hline +$\textrm{S}_{2}$ & 1.454441 & 11.2743 & 0.693 & 0.5000\tabularnewline +\hline +$\textrm{K}_{2}$ & 1.458423 & 3.0684 & 0.693 & 0.4986\tabularnewline +\hline +\end{tabular} +\label{tab:astronimcalFactors} +\caption{Constituent-dependent frequencies $\omega$, astronomical forcing amplitudes A, and Love number combinations $1 + k_2 − h_2$ used to compute equilibrium tide $\eta_{EQ}$. The periods $2\pi/\omega$ are also given. Reproduced from Table 1 of \citet{chassignet_primer_2018, +arbic2004accuracy}.} +\end{table} + +An efficient computation can be obtained by computing +maps of $\cos^2(\phi)$ and $\sin(2\phi)$ as static in time maps at model initialization. Static maps of $\sin \lambda$, $\cos \lambda$, $\sin 2\lambda$, and $\cos 2 \lambda$ should also be computed. One can see that all of these static maps are needed, through application of trigonometric identities to Equations \ref{eq:Eq5} and \ref{eq:Eq6}. + + +\subsection{Astronomical arguments} +\label{sec:AstrArg} + +Brian's matlab code has been provided for calculating $\chi$, $f$, and $\nu$ given ephemerides in code listings \ref{listing:ephermides} and \ref{listing:RayArgs}. +$\chi$ is the astronomical argument computed from $t_{ref}$ for each constituent, and is typically updated once a year). Physically, the $\chi$ factors are related to the positions of the Sun and Moon at a particular time. + +The recommend formulation is the one by Ray, e.g., in Code Listing \ref{listing:RayArgs} for $\nu$, $f$, and $\chi$; $s$,$h$,$p$, and $N$ essentially correspond to locations of Sun and Moon. + +%Code for $A$, $\xi$, $\nu$ can be provided. + +\begin{listing}[t] +\begin{minted}[mathescape, + linenos, + numbersep=5pt, + frame=lines, + framesep=2mm]{matlab} + + +% Compute ephemerides for 5 constituents (units degrees) + + [h0,s0,p0,N0,T0,time_mjd0]=ray_arguments(dummy_year,1); + clear dummy_year + + chi_m2=2*h0-2*s0; + chi_s2=0; + chi_n2=2*h0-3*s0+p0; + chi_k1=h0+90; + chi_o1=h0-2*s0-90; + + % Compute nodal factors for 5 constituents: + + f_m2=1.000-0.037*cosd(N0); + f_s2=1; + f_n2=f_m2; + f_k1=1.006+0.115*cosd(N0); + f_o1=1.009+0.187*cosd(N0); + + nu_m2=-2.1*sind(N0); + nu_s2=0; + nu_n2=u_m2; + nu_k1=-8.9*sind(N0); + nu_o1=10.8*sind(N0); + + % best to use Ray (write before publication to make sure + % it is the most recent version, don't use + % schwiderski_arguments from 1980 + % (polynomial fits, so this makes sense) +\end{minted} +\caption{Computation of ephemerides} +\label{listing:ephermides} +\end{listing} + +\begin{listing}[b] +\begin{minted}[mathescape, + linenos, + numbersep=5pt, + frame=lines, + framesep=2mm]{matlab} +function [h,s,p,N,T,time_mjd]=ray_arguments(y,d); + +% y = year number (i.e. 2003) +% d = day number (1-366) + +inty=floor((y-1857)/4)-1; + +time_mjd=365*(y-1858)+inty-(31+28+31+30+31+30+31+31+30+31+17) + 1; + +T=time_mjd-51544.4993; + +s=218.3164+13.17639648*T; + +h=280.4661+0.98564736*T; + +p=83.3535+0.11140353*T; + +N=125.0445 - 0.05295377*T; + +%s,h,p,N essentially correspond to locations of +% sun / moon (but with complexity). +% compare_arguments.m does a comparison. +\end{minted} +\caption{Ray arguments computation} +\label{listing:RayArgs} +\end{listing} + +\section{Self-attraction and loading} + +Self-attraction and loading (SAL) constituent static file maps should be derived for SAL amplitude and phase from FES, for $k=$ M$_2$, S$_2$, N$_2$, K$_1$, and O$_1$. The maps can be used to compute $\eta_{SAL}$ as a sum, e.g., equation (12) from \citet{chassignet_primer_2018}, + +\begin{equation} + \eta_{k,SAL}(\phi,\lambda) = A_m(\phi,\lambda)f(t_{ref})\cos\left[\omega (t-t_{ref}) + \chi(t_{ref}) + \nu(t_{ref}) - \phi_p(\phi,\lambda)}\right], +\label{eq:SAL} +\end{equation} +where $A_m(\phi,\lambda)$ is the amplitude of the SAL of the $k$ constituent as a function of latitude ($\lambda$) and longitude ($\phi$) and $\phi_p(\phi,\lambda)$ is the phase of SAL as function of lat/lon. +Equation \ref{eq:SAL} takes amplitude and phase maps that provide a prediction with amplitude and phase using nodal factors and astronomical arguments (see section \ref{sec:AstrArg}). + +The self-attraction and loading harmonic constituents $A_m$ and $\phi_p$ can be derived from a harmonic analysis of self-attraction and loading maps produced by global tidal models, e.g., TPXO (\url{http://volkov.oce.orst.edu/tides/global.html}) or TUGO-m (\url{http://sirocco.obs-mip.fr/ocean-models/tugo/}). + +% TPXO data not clear, but Brian Arbic has some of the self-attraction and loading files. Jay or Alan from HYCOM. + +State of the art tidal models worthy for consideration for use of self-attraction and loading maps: + +\begin{enumerate} +\item Richard Ray has state of the art (GOT model) +\item Egbert and Erofeeva +\item FES +\item TPXO +\end{enumerate} + +Brian Arbic can also provide self-attraction and loading maps from older versions of the GOT model. These should be perfectly adequate to begin, since barotropic tide models were quite accurate in early versions of GOT. + +Once $\eta_{EQ}$ and $\eta_{SAL}$ are obtained, they can be used in an ocean model. For instance, in a shallow water model, we replace the term $\nabla \eta$ in the momentum equation with a gradient of $\eta$ referenced to the equilibrium tide and self-attraction and loading terms, viz: + +\begin{equation} + \nabla\eta \rightarrow \nabla\left( \eta - \eta_{EQ} - \eta_{SAL}\right) +\end{equation} + +In essence, the equilibrium tide and self-attraction and loading terms reset the reference against which pressure gradients are computed. + + +%----------------------------------------------------------------------- + +\chapter{Design and Implementation} + + +%----------------------------------------------------------------------- + +\chapter{Testing} + +\section{Testing and Validation} + +Validation between the model and observational datasets can be performed via a tidal harmonic analysis. For example, from \citep{chassignet_primer_2018} equations 13 to 16, if + +\begin{equation} + D^2 = \left< (\eta_{model} - \eta_{obs})^{2} \right> +\end{equation} +where $\left< \cdot \right>$ is a time average over an integer number of tidal periods, then +\begin{equation} + D^2 = \frac{1}{2}\left(A_{model}^2 + A_{obs}^2\right) - A_{model}A_{obs}\cos\left(\phi_{model} - \phi_{obs}\right), +\end{equation} +where $A_{model}$ and $A_{obs}$ are the model and observational amplitudes and $\phi_{model}$ and $\phi_{obs}$ are the model and observational phases, respectively. + +Area-weighted versions, e.g., equation 16 in \citep{chassignet_primer_2018}, are computed as +\begin{equation} + D^2 = \frac{\int \int \left< \left(\eta_{model} - \eta_{obs}\right)^2\right>dA}{\int \int dA} +\end{equation} + +Observations should be compared to tidal altimetry data. +%----------------------------------------------------------------------- +\bibliographystyle{unsrtnat} +\bibliography{tides} + + +\end{document} + + diff --git a/src/core_ocean/Registry.xml b/src/core_ocean/Registry.xml index abae39de24..4e1397a381 100644 --- a/src/core_ocean/Registry.xml +++ b/src/core_ocean/Registry.xml @@ -95,6 +95,10 @@ description="Number of forcing groups" definition="4" /> + @@ -853,6 +857,56 @@ possible_values="Any positive real number." /> + + + + + + + + + + + + + + + @@ -3171,6 +3226,60 @@ description="surface pressure forcing due to weight of frazil ice" packages="frazilIce" /> + + + + + + + + + + + + + + + btrvel_tempField % array + ! Subtract tidal potential from ssh, if needed + ! Subtract the tidal potential from the current and new subcycle ssh and store and a work arrays. + ! Then point sshSubcycleCur and ssh SubcycleNew to the work arrays so the tidal potential terms + ! are included in the grad operator inside the edge loop. + if (config_use_tidal_potential_forcing) then + call mpas_pool_get_array(forcingPool,'sshSubcycleCurWithTides', sshSubcycleCurWithTides) + call mpas_pool_get_array(forcingPool,'sshSubcycleNewWithTides', sshSubcycleNewWithTides) + call mpas_pool_get_array(forcingPool, 'tidalPotentialEta', tidalPotentialEta) + call mpas_pool_get_dimension(block % dimensions, 'nCells', nCellsPtr) + + nCells = nCellsPtr + do iCell = 1, nCells + sshSubcycleCurWithTides(iCell) = sshSubcycleCur(iCell) - tidalPotentialEta(iCell) & + - config_self_attraction_and_loading_beta * sshSubcycleCur(iCell) + sshSubcycleNewWithTides(iCell) = sshSubcycleNew(iCell) - tidalPotentialEta(iCell) & + - config_self_attraction_and_loading_beta * sshSubcycleNew(iCell) + end do + + call mpas_pool_get_array(forcingPool,'sshSubcycleCurWithTides', sshSubcycleCur) + call mpas_pool_get_array(forcingPool,'sshSubcycleNewWithTides', sshSubcycleNew) + end if + ! Need to initialize btr_vel_temp over the one more halo than we're computing over nEdges = nEdgesPtr diff --git a/src/core_ocean/shared/Makefile b/src/core_ocean/shared/Makefile index a5f83f4817..3feefaeb80 100644 --- a/src/core_ocean/shared/Makefile +++ b/src/core_ocean/shared/Makefile @@ -66,13 +66,14 @@ OBJS = mpas_ocn_init_routines.o \ mpas_ocn_sea_ice.o \ mpas_ocn_framework_forcing.o \ mpas_ocn_time_varying_forcing.o \ - mpas_ocn_wetting_drying.o + mpas_ocn_wetting_drying.o \ + mpas_ocn_tidal_potential_forcing.o all: $(OBJS) mpas_ocn_init_routines.o: mpas_ocn_constants.o mpas_ocn_diagnostics.o mpas_ocn_gm.o mpas_ocn_forcing.o mpas_ocn_surface_land_ice_fluxes.o -mpas_ocn_tendency.o: mpas_ocn_high_freq_thickness_hmix_del2.o mpas_ocn_tracer_surface_restoring.o mpas_ocn_thick_surface_flux.o mpas_ocn_tracer_short_wave_absorption.o mpas_ocn_tracer_advection.o mpas_ocn_tracer_hmix.o mpas_ocn_tracer_nonlocalflux.o mpas_ocn_surface_bulk_forcing.o mpas_ocn_surface_land_ice_fluxes.o mpas_ocn_tracer_surface_flux_to_tend.o mpas_ocn_tracer_interior_restoring.o mpas_ocn_tracer_exponential_decay.o mpas_ocn_tracer_ideal_age.o mpas_ocn_tracer_TTD.o mpas_ocn_vmix.o mpas_ocn_constants.o mpas_ocn_frazil_forcing.o mpas_ocn_tidal_forcing.o mpas_ocn_tracer_ecosys.o mpas_ocn_tracer_DMS.o mpas_ocn_tracer_MacroMolecules.o mpas_ocn_diagnostics.o mpas_ocn_wetting_drying.o +mpas_ocn_tendency.o: mpas_ocn_high_freq_thickness_hmix_del2.o mpas_ocn_tracer_surface_restoring.o mpas_ocn_thick_surface_flux.o mpas_ocn_tracer_short_wave_absorption.o mpas_ocn_tracer_advection.o mpas_ocn_tracer_hmix.o mpas_ocn_tracer_nonlocalflux.o mpas_ocn_surface_bulk_forcing.o mpas_ocn_surface_land_ice_fluxes.o mpas_ocn_tracer_surface_flux_to_tend.o mpas_ocn_tracer_interior_restoring.o mpas_ocn_tracer_exponential_decay.o mpas_ocn_tracer_ideal_age.o mpas_ocn_tracer_TTD.o mpas_ocn_vmix.o mpas_ocn_constants.o mpas_ocn_frazil_forcing.o mpas_ocn_tidal_forcing.o mpas_ocn_tracer_ecosys.o mpas_ocn_tracer_DMS.o mpas_ocn_tracer_MacroMolecules.o mpas_ocn_diagnostics.o mpas_ocn_wetting_drying.o mpas_ocn_tidal_potential_forcing.o mpas_ocn_diagnostics_routines.o: mpas_ocn_constants.o @@ -200,6 +201,8 @@ mpas_ocn_time_varying_forcing.o: mpas_ocn_wetting_drying.o: mpas_ocn_diagnostics.o mpas_ocn_gm.o +mpas_ocn_tidal_potential_forcing.o: mpas_ocn_constants.o + clean: $(RM) *.o *.i *.mod *.f90 diff --git a/src/core_ocean/shared/mpas_ocn_tendency.F b/src/core_ocean/shared/mpas_ocn_tendency.F index e3a05ae37b..661e625a6a 100644 --- a/src/core_ocean/shared/mpas_ocn_tendency.F +++ b/src/core_ocean/shared/mpas_ocn_tendency.F @@ -59,6 +59,7 @@ module ocn_tendency use ocn_vel_forcing use ocn_vmix use ocn_wetting_drying + use ocn_tidal_potential_forcing implicit none private @@ -213,7 +214,7 @@ subroutine ocn_tend_vel(tendPool, statePool, forcingPool, diagnosticsPool, meshP type (mpas_pool_type), intent(inout) :: tendPool !< Input/Output: Tendency structure type (mpas_pool_type), intent(in) :: statePool !< Input: State information - type (mpas_pool_type), intent(in) :: forcingPool !< Input: Forcing information + type (mpas_pool_type), intent(inout) :: forcingPool !< Input: Forcing information type (mpas_pool_type), intent(in) :: diagnosticsPool !< Input: Diagnostic information type (mpas_pool_type), intent(in) :: meshPool !< Input: Mesh information real (kind=RKIND), intent(in) :: dt @@ -223,6 +224,7 @@ subroutine ocn_tend_vel(tendPool, statePool, forcingPool, diagnosticsPool, meshP type (mpas_pool_type), pointer :: tracersPool real (kind=RKIND), dimension(:), pointer :: surfaceStress, surfaceStressMagnitude, surfaceFluxAttenuationCoefficient, ssh + real (kind=RKIND), dimension(:), pointer :: tidalPotentialEta real (kind=RKIND), dimension(:,:), pointer :: & layerThicknessEdge, normalVelocity, tangentialVelocity, density, potentialDensity, zMid, pressure, & layerThickness, & @@ -230,18 +232,23 @@ subroutine ocn_tend_vel(tendPool, statePool, forcingPool, diagnosticsPool, meshP normalizedRelativeVorticityEdge, normalizedPlanetaryVorticityEdge, & montgomeryPotential, vertAleTransportTop, divergence, vertViscTopOfEdge, & inSituThermalExpansionCoeff, inSituSalineContractionCoeff + real (kind=RKIND), dimension(:,:), pointer :: tidalPotentialZMid real (kind=RKIND), dimension(:,:), pointer :: wettingVelocity real (kind=RKIND), dimension(:,:,:), pointer :: activeTracers integer :: timeLevel - integer :: err, iEdge, iCell + integer :: err, iEdge, iCell, k integer, pointer :: indexTemperature, indexSalinity, nEdges, nCells + integer, dimension(:), pointer :: maxLevelCell logical, pointer :: config_disable_vel_all_tend logical, pointer :: config_use_wetting_drying logical, pointer :: config_prevent_drying + logical, pointer :: config_use_tidal_potential_forcing character (len=StrKIND), pointer :: config_pressure_gradient_type + character (len=StrKIND), pointer :: config_time_integrator + real (kind=RKIND), pointer :: config_self_attraction_and_loading_beta if (present(timeLevelIn)) then timeLevel = timeLevelIn @@ -253,6 +260,9 @@ subroutine ocn_tend_vel(tendPool, statePool, forcingPool, diagnosticsPool, meshP call mpas_pool_get_config(ocnConfigs, 'config_pressure_gradient_type', config_pressure_gradient_type) call mpas_pool_get_config(ocnConfigs, 'config_use_wetting_drying', config_use_wetting_drying) call mpas_pool_get_config(ocnConfigs, 'config_prevent_drying', config_prevent_drying) + call mpas_pool_get_config(ocnConfigs, 'config_use_tidal_potential_forcing', config_use_tidal_potential_forcing) + call mpas_pool_get_config(ocnConfigs, 'config_self_attraction_and_loading_beta',config_self_attraction_and_loading_beta) + call mpas_pool_get_config(ocnConfigs, 'config_time_integrator', config_time_integrator) call mpas_pool_get_dimension(meshPool, 'nEdges', nEdges) call mpas_pool_get_dimension(meshPool, 'nCells', nCells) @@ -326,6 +336,31 @@ subroutine ocn_tend_vel(tendPool, statePool, forcingPool, diagnosticsPool, meshP ! call ocn_vel_vadv_tend(meshPool, normalVelocity, layerThicknessEdge, vertAleTransportTop, tend_normalVelocity, err) + ! + ! velocity tendency: tidal potential (if needed) + ! For RK4, subtract the tidal potential from the zMid array and store in a work array, + ! Then point zMid to work array so the tidal potential terms are included inside the grad computed in ocn_vel_pressure_grad_tend + ! zMid is pointed back to the typical value afterward, so the work array is not used in place of zMid elsewhere. + ! + if (config_use_tidal_potential_forcing) then + call ocn_compute_tidal_potential_forcing(meshPool, forcingPool, diagnosticsPool, err) + end if + + if (config_use_tidal_potential_forcing .and. config_time_integrator == 'RK4') then + call mpas_pool_get_array(forcingPool, 'tidalPotentialZMid', tidalPotentialZMid) + call mpas_pool_get_array(forcingPool, 'tidalPotentialEta', tidalPotentialEta) + call mpas_pool_get_array(meshPool, 'maxLevelCell', maxLevelCell) + + do iCell = 1, nCells + do k = 1, maxLevelCell(iCell) + tidalPotentialZMid(k,iCell) = zMid(k,iCell) - tidalPotentialEta(iCell) & + - config_self_attraction_and_loading_beta * zMid(k,iCell) + end do + end do + + call mpas_pool_get_array(forcingPool, 'tidalPotentialZMid', zMid) + end if + ! ! velocity tendency: pressure gradient ! @@ -342,6 +377,11 @@ subroutine ocn_tend_vel(tendPool, statePool, forcingPool, diagnosticsPool, meshP inSituThermalExpansionCoeff,inSituSalineContractionCoeff) endif + if (config_use_tidal_potential_forcing .and. config_time_integrator == 'RK4') then + ! point zMid back to usual array, to be safe + call mpas_pool_get_array(diagnosticsPool, 'zMid', zMid) + end if + ! ! velocity tendency: del2 dissipation, \nu_2 \nabla^2 u ! computed as \nu( \nabla divergence + k \times \nabla relativeVorticity ) diff --git a/src/core_ocean/shared/mpas_ocn_tidal_potential_forcing.F b/src/core_ocean/shared/mpas_ocn_tidal_potential_forcing.F new file mode 100644 index 0000000000..69e8e87d0b --- /dev/null +++ b/src/core_ocean/shared/mpas_ocn_tidal_potential_forcing.F @@ -0,0 +1,665 @@ +! Copyright (c) 2013, Los Alamos National Security, LLC (LANS) +! and the University Corporation for Atmospheric Research (UCAR). +! +! Unless noted otherwise source code is licensed under the BSD license. +! Additional copyright and license information can be found in the LICENSE file +! distributed with this code, or at http://mpas-dev.github.com/license.html +! +!||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||| +! +! ocn_tidal_potential_forcing +! +!> \brief MPAS ocean tidal potential forcing module +!> \author Steven Brus +!> \date September 2019 +!> \details +!> This module contains routines for the tidal potential forcing. +!> Design document located in : +!> MPAS-Model/docs/ocean/design_docs +! +!----------------------------------------------------------------------- + +module ocn_tidal_potential_forcing + + use mpas_kind_types + use mpas_constants + use mpas_derived_types + use mpas_pool_routines + use mpas_timekeeping + use mpas_timer + use ocn_constants + + implicit none + private + save + + !-------------------------------------------------------------------- + ! + ! Public parameters + ! + !-------------------------------------------------------------------- + + !-------------------------------------------------------------------- + ! + ! Public member functions + ! + !-------------------------------------------------------------------- + + public :: ocn_compute_tidal_potential_forcing, & + ocn_tidal_potential_forcing_init + + !-------------------------------------------------------------------- + ! + ! Private module variables + ! + !-------------------------------------------------------------------- + + logical :: tidalPotentialOn + type :: char_array + character(:), allocatable :: constituent + end type + type(char_array), dimension(37) :: constituentList + + +!*********************************************************************** + +contains + +!*********************************************************************** +! +! routine ocn_tidal_potential_forcing_layer_thickness +! +!> \brief Computes equilibrium tidal potential +!> \author Steven Brus +!> \date September 2019 +!> \details +!> This routine computes the equilibrium tidal potential due to all +!> tidal constituents +! +!----------------------------------------------------------------------- + + subroutine ocn_compute_tidal_potential_forcing(meshPool, forcingPool, diagnosticsPool, err)!{{{ + + !----------------------------------------------------------------- + ! + ! input variables + ! + !----------------------------------------------------------------- + type (mpas_pool_type), intent(in) :: meshPool !< Input: mesh information + type (mpas_pool_type), intent(in) :: diagnosticsPool + + !----------------------------------------------------------------- + ! + ! input/output variables + ! + !----------------------------------------------------------------- + type (mpas_pool_type), intent(inout) :: forcingPool + + !----------------------------------------------------------------- + ! + ! output variables + ! + !----------------------------------------------------------------- + + integer, intent(out) :: err !< Output: Error flag + + !----------------------------------------------------------------- + ! + ! local variables + ! + !----------------------------------------------------------------- + + integer, pointer :: nCells + real (kind=RKIND), pointer :: tidalPotentialRamp + real (kind=RKIND), dimension(:), pointer :: lonCell + integer, dimension(:), pointer :: maxLevelCell + + integer, pointer :: nTidalConstituents + real (kind=RKIND), dimension(:), pointer :: amplitude, frequency, loveNumbers + real (kind=RKIND), dimension(:), pointer :: nodalFactorAmplitude, nodalFactorPhase, astronomicalArgument + real (kind=RKIND), dimension(:,:), pointer :: latitudeFunction + integer, dimension(:), pointer :: constituentType + real (kind=RKIND), dimension(:), pointer :: eta + real (kind=RKIND), dimension(:,:), pointer :: zMid, tidalPotentialZMid + real (kind=RKIND), pointer :: daysSinceStartOfSim + + integer :: iCell + integer :: jCon, conType + real (kind=RKIND) :: lon,tArg,ramp,t + real (kind=RKIND) :: nCycles,period + + err = 0 + + if ( .not. tidalPotentialOn ) return + + call mpas_pool_get_config(ocnConfigs, 'config_tidal_potential_ramp', tidalPotentialRamp) + call mpas_pool_get_dimension(meshPool, 'nCells', nCells) + call mpas_pool_get_array(meshPool, 'lonCell', lonCell) + call mpas_pool_get_array(forcingPool, 'nTidalPotentialConstituents', nTidalConstituents) + call mpas_pool_get_array(forcingPool, 'tidalPotentialConstituentAmplitude', amplitude) + call mpas_pool_get_array(forcingPool, 'tidalPotentialConstituentFrequency', frequency) + call mpas_pool_get_array(forcingPool, 'tidalPotentialConstituentLoveNumbers', loveNumbers) + call mpas_pool_get_array(forcingPool, 'tidalPotentialConstituentNodalAmplitude', nodalFactorAmplitude) + call mpas_pool_get_array(forcingPool, 'tidalPotentialConstituentAstronomical', astronomicalArgument) + call mpas_pool_get_array(forcingPool, 'tidalPotentialConstituentNodalPhase', nodalFactorPhase) + call mpas_pool_get_array(forcingPool, 'tidalPotentialConstituentType', constituentType) + call mpas_pool_get_array(forcingPool, 'tidalPotentialLatitudeFunction', latitudeFunction) + call mpas_pool_get_array(forcingPool, 'tidalPotentialEta', eta) + call mpas_pool_get_array(diagnosticsPool, "daysSinceStartOfSim", daysSinceStartOfSim) + + ramp = tanh((2.0_RKIND*daysSinceStartOfSim)/tidalPotentialRamp) + t = daysSinceStartOfSim*86400.0_RKIND + + do iCell = 1, nCells + eta(iCell) = 0.0_RKIND + end do + + do jCon = 1, nTidalConstituents + period = 2.0_RKIND*pii/frequency(jCon) + nCycles = real(int(t/period),RKIND) + targ = frequency(jCon)*(t - nCycles*period) + nodalFactorPhase(jCon) + astronomicalArgument(jCon) + conType = constituentType(jCon) + do iCell = 1, nCells + lon = lonCell(iCell) + eta(iCell) = eta(iCell) + ramp & + * amplitude(jCon) & + * nodalFactorAmplitude(jCon) & + * loveNumbers(jCon) & + * latitudeFunction(iCell,conType+1) & + * cos(tArg + real(conType,RKIND)*lon) + end do + + end do + + end subroutine ocn_compute_tidal_potential_forcing!}}} + + +!*********************************************************************** +! +! routine ocn_tidal_potential_forcing_init +! +!> \brief Initializes ocean tidal protential forcing module. +!> \author Steven Brus +!> \date September 2019 +!> \details +!> This routine initializes the ocean tidal potential forcing module +!> and variables. +! +!----------------------------------------------------------------------- + + subroutine ocn_tidal_potential_forcing_init(domain,err)!{{{ + + type (domain_type), intent(inout) :: domain + integer, intent(out) :: err !< Output: error flag + + logical, pointer :: config_use_tidal_potential_forcing + logical, pointer :: config_use_tidal_potential_forcing_M2 + logical, pointer :: config_use_tidal_potential_forcing_S2 + logical, pointer :: config_use_tidal_potential_forcing_N2 + logical, pointer :: config_use_tidal_potential_forcing_K2 + logical, pointer :: config_use_tidal_potential_forcing_K1 + logical, pointer :: config_use_tidal_potential_forcing_O1 + logical, pointer :: config_use_tidal_potential_forcing_Q1 + logical, pointer :: config_use_tidal_potential_forcing_P1 + character (len=StrKIND), pointer :: config_tidal_potential_reference_time + + type (block_type), pointer :: block_ptr + type (mpas_pool_type), pointer :: forcingPool + type (mpas_pool_type), pointer :: meshPool + type (mpas_pool_type), pointer :: diagnosticsPool + integer, pointer :: nTidalConstituents + integer, pointer :: nCells + real (kind=RKIND), dimension(:), pointer :: tidalConstituentAmplitude + real (kind=RKIND), dimension(:), pointer :: tidalConstituentFreqency + real (kind=RKIND), dimension(:), pointer :: tidalConstituentLoveNumbers + real (kind=RKIND), dimension(:), pointer :: tidalConstituentNodalAmplitude + real (kind=RKIND), dimension(:), pointer :: tidalConstituentAstronomical + real (kind=RKIND), dimension(:), pointer :: tidalConstituentNodalPhase + real (kind=RKIND), dimension(:), pointer :: latCell + real (kind=RKIND), dimension(:), pointer :: eta + real (kind=RKIND), dimension(:,:), pointer :: latitudeFunction + integer, dimension(:), pointer :: tidalConstituentType + type (MPAS_Time_Type) :: refTime + integer :: iCell,iCon + real (kind=RKIND) :: lat + + + err = 0 + + call mpas_pool_get_config(ocnConfigs, 'config_use_tidal_potential_forcing', config_use_tidal_potential_forcing) + call mpas_pool_get_config(ocnConfigs, 'config_use_tidal_potential_forcing_M2', config_use_tidal_potential_forcing_M2) + call mpas_pool_get_config(ocnConfigs, 'config_use_tidal_potential_forcing_S2', config_use_tidal_potential_forcing_S2) + call mpas_pool_get_config(ocnConfigs, 'config_use_tidal_potential_forcing_N2', config_use_tidal_potential_forcing_N2) + call mpas_pool_get_config(ocnConfigs, 'config_use_tidal_potential_forcing_K2', config_use_tidal_potential_forcing_K2) + call mpas_pool_get_config(ocnConfigs, 'config_use_tidal_potential_forcing_K1', config_use_tidal_potential_forcing_K1) + call mpas_pool_get_config(ocnConfigs, 'config_use_tidal_potential_forcing_O1', config_use_tidal_potential_forcing_O1) + call mpas_pool_get_config(ocnConfigs, 'config_use_tidal_potential_forcing_Q1', config_use_tidal_potential_forcing_Q1) + call mpas_pool_get_config(ocnConfigs, 'config_use_tidal_potential_forcing_P1', config_use_tidal_potential_forcing_P1) + call mpas_pool_get_config(ocnConfigs, 'config_tidal_potential_reference_time', config_tidal_potential_reference_time) + + block_ptr => domain % blocklist + do while(associated(block_ptr)) + call mpas_pool_get_subpool(block_ptr % structs, 'forcing', forcingPool) + call mpas_pool_get_subpool(block_ptr % structs, 'mesh', meshPool) + call mpas_pool_get_dimension(meshPool, 'nCells', nCells) + call mpas_pool_get_array(forcingPool, 'tidalPotentialEta', eta) + + do iCell = 1,nCells + eta(iCell) = 0.0_RKIND + end do + + block_ptr => block_ptr % next + end do + + tidalPotentialOn = .false. + if (config_use_tidal_potential_forcing) then + tidalPotentialOn = .true. + else + return + end if + + + block_ptr => domain % blocklist + do while(associated(block_ptr)) + + call mpas_pool_get_subpool(block_ptr % structs, 'forcing', forcingPool) + call mpas_pool_get_subpool(block_ptr % structs, 'mesh', meshPool) + call mpas_pool_get_subpool(block_ptr % structs, 'diagnostics', diagnosticsPool) + call mpas_pool_get_array(forcingPool, 'nTidalPotentialConstituents', nTidalConstituents) + call mpas_pool_get_array(forcingPool, 'tidalPotentialConstituentAmplitude', tidalConstituentAmplitude) + call mpas_pool_get_array(forcingPool, 'tidalPotentialConstituentFrequency', tidalConstituentFreqency) + call mpas_pool_get_array(forcingPool, 'tidalPotentialConstituentLoveNumbers', tidalConstituentLoveNumbers) + call mpas_pool_get_array(forcingPool, 'tidalPotentialConstituentNodalAmplitude', tidalConstituentNodalAmplitude) + call mpas_pool_get_array(forcingPool, 'tidalPotentialConstituentAstronomical', tidalConstituentAstronomical) + call mpas_pool_get_array(forcingPool, 'tidalPotentialConstituentNodalPhase', tidalConstituentNodalPhase) + call mpas_pool_get_array(forcingPool, 'tidalPotentialConstituentType', tidalConstituentType) + call mpas_pool_get_array(forcingPool, 'tidalPotentialLatitudeFunction', latitudeFunction) + call mpas_pool_get_array(meshPool, 'latCell', latCell) + call mpas_pool_get_dimension(meshPool, 'nCells', nCells) + + call mpas_set_time(refTime, dateTimeString=config_tidal_potential_reference_time) + + nTidalConstituents = 0 + if (config_use_tidal_potential_forcing_M2) then + nTidalConstituents = nTidalConstituents + 1 + constituentList(nTidalConstituents)%constituent = 'M2' + end if + + if (config_use_tidal_potential_forcing_S2) then + nTidalConstituents = nTidalConstituents + 1 + constituentList(nTidalConstituents)%constituent = 'S2' + end if + + if (config_use_tidal_potential_forcing_N2) then + nTidalConstituents = nTidalConstituents + 1 + constituentList(nTidalConstituents)%constituent = 'N2' + end if + + if (config_use_tidal_potential_forcing_K2) then + nTidalConstituents = nTidalConstituents + 1 + constituentList(nTidalConstituents)%constituent = 'K2' + end if + + if (config_use_tidal_potential_forcing_K1) then + nTidalConstituents = nTidalConstituents + 1 + constituentList(nTidalConstituents)%constituent = 'K1' + end if + + if (config_use_tidal_potential_forcing_O1) then + nTidalConstituents = nTidalConstituents + 1 + constituentList(nTidalConstituents)%constituent = 'O1' + end if + + if (config_use_tidal_potential_forcing_Q1) then + nTidalConstituents = nTidalConstituents + 1 + constituentList(nTidalConstituents)%constituent = 'Q1' + end if + + if (config_use_tidal_potential_forcing_P1) then + nTidalConstituents = nTidalConstituents + 1 + constituentList(nTidalConstituents)%constituent = 'P1' + end if + + call tidal_constituent_factors(constituentList,nTidalConstituents,refTime, & + tidalConstituentFreqency, & + tidalConstituentAmplitude, & + tidalConstituentLoveNumbers, & + tidalConstituentNodalAmplitude, & + tidalConstituentAstronomical, & + tidalConstituentNodalPhase, & + tidalConstituentType, & + err) + + do iCell = 1,nCells + lat = latCell(iCell) + latitudeFunction(iCell,1) = 3.0_RKIND*sin(lat)**2 - 1.0_RKIND + latitudeFunction(iCell,2) = sin(2.0_RKIND*lat) + latitudeFunction(iCell,3) = cos(lat)**2 + end do + + do iCon = 1,nTidalConstituents + call mpas_log_write('Constituent '//constituentList(iCon)%constituent) + call mpas_log_write(' Frequency $r', realArgs=(/ tidalConstituentFreqency(iCon) /)) + call mpas_log_write(' Amplitude $r', realArgs=(/ tidalConstituentAmplitude(iCon) /)) + call mpas_log_write(' LoveNumbers $r', realArgs=(/ tidalConstituentLoveNumbers(iCon) /)) + call mpas_log_write(' NodalAmplitude $r', realArgs=(/ tidalConstituentNodalAmplitude(iCon) /)) + call mpas_log_write(' Astronomical argument $r', realArgs=(/ tidalConstituentAstronomical(iCon) /)) + call mpas_log_write(' NodalPhase $r', realArgs=(/ tidalConstituentNodalPhase(iCon) /)) + call mpas_log_write(' Type $i', intArgs=(/ tidalConstituentType(iCon) /)) + call mpas_log_write(' ') + end do + + block_ptr => block_ptr % next + end do + + + end subroutine ocn_tidal_potential_forcing_init!}}} + + +!*********************************************************************** +! +! routine tidal_constituent_factors +! +!> \brief Initialized tidal constituent factors +!> \author Steven Brus +!> \date September 2019 +!> \details +!> This routine initializes the ampiltude, frequency, love numbers, +!> astronomical argument and nodal factors for each tidal constituent +!> Nodal factor equations are from: +!> "Manual of Harmonic Analysis and Prediction of Tides" +!> by Paul Schureman, Special Publication #98, US Coast +!> and Geodetic Survey, Department of Commerce (1958). +! +!----------------------------------------------------------------------- + + subroutine tidal_constituent_factors(constituentList,nTidalConstituents,refTime, & + tidalConstituentFreqency, & + tidalConstituentAmplitude, & + tidalConstituentLoveNumbers, & + tidalConstituentNodalAmplitude, & + tidalConstituentAstronomical, & + tidalConstituentNodalPhase, & + tidalConstituentType, & + iErr) !{{{ + + type(char_array), dimension(:), intent(in) :: constituentList + integer, intent(in) :: nTidalConstituents + type (MPAS_Time_Type), intent(in) :: refTime + real (kind=RKIND), dimension(:), intent(out) :: tidalConstituentAmplitude + real (kind=RKIND), dimension(:), intent(out) :: tidalConstituentFreqency + real (kind=RKIND), dimension(:), intent(out) :: tidalConstituentLoveNumbers + real (kind=RKIND), dimension(:), intent(out) :: tidalConstituentNodalAmplitude + real (kind=RKIND), dimension(:), intent(out) :: tidalConstituentAstronomical + real (kind=RKIND), dimension(:), intent(out) :: tidalConstituentNodalPhase + integer, dimension(:), intent(out) :: tidalConstituentType + integer, intent(out) :: iErr + + integer :: j + integer :: refDay + integer :: refYear + integer :: refHour + !integer :: inty,time_mjd + !real (kind=RKIND) :: T,s,h,p,N + real (kind=RKIND) :: deg2rad + real (kind=RKIND) :: s,p,h,p1,n,I,nu,xi,nup,nup2,pc,T + + iErr = 0 + + call mpas_get_time(refTime, YYYY=refYear,DoY=refDay,H=refHour) + refDay = refDay + 1 + + ! Calculate locations of sun and moon + call orbit(refYear,refDay,refHour, & + s,p,h,p1,N,I,nu,xi,nup,nup2,pc) + + + !! From tide design doc + !inty = floor((real(refYear,RKIND)-1857.0_RKIND)/4.0_RKIND) - 1 + !time_mjd = 365*(refYear-1858)+inty-(31+28+31+30+31+30+31+31+30+31+17) + 1 + !T =real(time_mjd,RKIND)-51544.4993_RKIND; + !s = 218.3164_RKIND + 13.17639648_RKIND*T; + !h = 280.4661_RKIND + 0.98564736_RKIND*T; + !p = 83.3535_RKIND + 0.11140353_RKIND*T; + !N = 125.0445_RKIND - 0.05295377_RKIND*T; + !N = N*pii/180.0_RKIND + + !! M2 + !tidalConstituentAstronomical(j) = 2.0_RKIND*h - 2.0_RKIND*s + !tidalConstituentNodalPhase(j) = -2.1_RKIND*sin(N) + !tidalConstituentNodalAmplitude(j) = 1.0_RKIND - 0.037_RKIND*cos(N) + + !! S2 + !tidalConstituentAstronomical(j) = 0.0_RKIND + !tidalConstituentNodalPhase(j) = 0.0_RKIND + !tidalConstituentNodalAmplitude(j) = 1.0_RKIND + + !! N2 + !tidalConstituentAstronomical(j) = 2.0_RKIND*h - 3.0_RKIND*s + p + !tidalConstituentNodalPhase(j) = -2.1_RKIND*sin(N) + !tidalConstituentNodalAmplitude(j) = 1.0_RKIND - 0.037_RKIND*cos(N) + + !! K1 + !tidalConstituentAstronomical(j) = h + 90.0_RKIND + !tidalConstituentNodalPhase(j) = -8.9_RKIND*sin(N) + !tidalConstituentNodalAmplitude(j) = 1.006_RKIND + 0.115_RKIND*cos(N) + + !! O1 + !tidalConstituentAstronomical(j) = h - 2.0_RKIND*s - 90.0_RKIND + !tidalConstituentNodalPhase(j) = 10.8_RKIND*sin(N) + !tidalConstituentNodalAmplitude(j) = 1.009_RKIND + 0.187_RKIND*cos(N) + + + deg2rad = pii/180.0_RKIND + T = adjust_angle(180.0_RKIND + real(refHour,RKIND)*(360.0_RKIND/24.0_RKIND)) + + do j = 1,nTidalConstituents + if (constituentList(j)%constituent == 'M2') then + tidalConstituentAmplitude(j) = 0.242334_RKIND + tidalConstituentFreqency(j) = 1.405189e-4_RKIND + tidalConstituentLoveNumbers(j) = 0.693_RKIND + tidalConstituentAstronomical(j) = 0.0_RKIND + tidalConstituentNodalAmplitude(j) = cos(0.5_RKIND*I*deg2rad)**4/0.91544_RKIND + tidalConstituentNodalPhase(j) = 2.0_RKIND*(T-s+h) + 2.0_RKIND*(xi-nu) + tidalConstituentType(j) = 2 + + else if (constituentList(j)%constituent == 'S2') then + tidalConstituentAmplitude(j) = 0.112743_RKIND + tidalConstituentFreqency(j) = 1.454441e-4_RKIND + tidalConstituentLoveNumbers(j) = 0.693_RKIND + tidalConstituentAstronomical(j) = 0.0_RKIND + tidalConstituentNodalAmplitude(j) = 1.0_RKIND + tidalConstituentNodalPhase(j) = 2.0_RKIND*T + tidalConstituentType(j) = 2 + + else if (constituentList(j)%constituent == 'N2') then + tidalConstituentAmplitude(j) = 0.046397_RKIND + tidalConstituentFreqency(j) = 1.378797e-4_RKIND + tidalConstituentLoveNumbers(j) = 0.693_RKIND + tidalConstituentAstronomical(j) = 0.0_RKIND + tidalConstituentNodalAmplitude(j) = cos(0.5_RKIND*I*deg2rad)**4/0.91544_RKIND + tidalConstituentNodalPhase(j) = 2.0_RKIND*(T+h) - 3.0_RKIND*s+p + 2.0_RKIND*(xi-nu) + tidalConstituentType(j) = 2 + + else if (constituentList(j)%constituent == 'K2') then + tidalConstituentAmplitude(j) = 0.030684_RKIND + tidalConstituentFreqency(j) = 1.458423e-4_RKIND + tidalConstituentLoveNumbers(j) = 0.693_RKIND + tidalConstituentAstronomical(j) = 0.0_RKIND + tidalConstituentNodalAmplitude(j) = 0.001_RKIND+sqrt(19.0444_RKIND*sin(I*deg2rad)**4 + & + 2.7702_RKIND*sin(I*deg2rad)**2*cos(2.0_RKIND*nu*deg2rad) + & + 0.0981_RKIND) + tidalConstituentNodalPhase(j) = 2.0_RKIND*(T+h) - 2.0_RKIND*nup2 + tidalConstituentType(j) = 2 + + else if (constituentList(j)%constituent == 'K1') then + tidalConstituentAmplitude(j) = 0.141565_RKIND + tidalConstituentFreqency(j) = 0.7292117e-4_RKIND + tidalConstituentLoveNumbers(j) = 0.736_RKIND + tidalConstituentAstronomical(j) = 0.0_RKIND + tidalConstituentNodalAmplitude(j) = sqrt(0.8965_RKIND*sin(2.0_RKIND*I*deg2rad)**2 + & + 0.6001_RKIND*sin(2.0_RKIND*I*deg2rad) * & + cos(nu*deg2rad) + 0.1006_RKIND) + tidalConstituentNodalPhase(j) = T + h - 90.0_RKIND - nup + tidalConstituentType(j) = 1 + + else if (constituentList(j)%constituent == 'O1') then + tidalConstituentAmplitude(j) = 0.100661_RKIND + tidalConstituentFreqency(j) = 0.6759774e-4_RKIND + tidalConstituentLoveNumbers(j) = 0.695_RKIND + tidalConstituentAstronomical(j) = 0.0_RKIND + tidalConstituentNodalAmplitude(j) = sin(I*deg2rad)*cos(0.5_RKIND*I*deg2rad)**2/0.37988_RKIND + tidalConstituentNodalPhase(j) = T - 2.0_RKIND*s + h + 90.0_RKIND + 2.0_RKIND*xi - nu + tidalConstituentType(j) = 1 + + else if (constituentList(j)%constituent == 'Q1') then + tidalConstituentAmplitude(j) = 0.019273_RKIND + tidalConstituentFreqency(j) = 0.6495854e-4_RKIND + tidalConstituentLoveNumbers(j) = 0.695_RKIND + tidalConstituentAstronomical(j) = 0.0_RKIND + tidalConstituentNodalAmplitude(j) = sin(I*deg2rad)*cos(0.5_RKIND*I*deg2rad)**2/0.37988_RKIND + tidalConstituentNodalPhase(j) = T - 3.0_RKIND*s + h + p + 90.0_RKIND + 2.0_RKIND*xi - nu + tidalConstituentType(j) = 1 + + else if (constituentList(j)%constituent == 'P1') then + tidalConstituentAmplitude(j) = 0.046848_RKIND + tidalConstituentFreqency(j) = 0.7252295e-4_RKIND + tidalConstituentLoveNumbers(j) = 0.706_RKIND + tidalConstituentAstronomical(j) = 0.0_RKIND + tidalConstituentNodalAmplitude(j) = 1.0_RKIND + tidalConstituentNodalPhase(j) = T - h + 90.0_RKIND + tidalConstituentType(j) = 1 + + else + call mpas_log_write( 'Validation failed for tidal potential.' & + // 'Not given a usable value for constituent name.',MPAS_LOG_CRIT) + iErr = 1 + end if + + tidalConstituentNodalPhase(j) = adjust_angle(tidalConstituentNodalPhase(j)) + tidalConstituentNodalPhase(j) = tidalConstituentNodalPhase(j)*deg2rad + tidalConstituentAstronomical(j) = tidalConstituentAstronomical(j)*deg2rad + end do + + + end subroutine tidal_constituent_factors!}}} + +!*********************************************************************** +! +! routine orbit +! +!> \brief Computes orbital factors +!> \author Steven Brus +!> \date September 2019 +!> \details +!> Computes factors related to the orbits of the sun and moon for +!> calculating the nodal factors in the tidal potential. +!> Adapted from tide_fac.f which can be found here: +!> http://adcirc.org/home/related-software/adcirc-utility-programs/ +! +!----------------------------------------------------------------------- + subroutine orbit(year,julianDay,hour, & + s,p,h,p1,N,I,nu,xi,nup,nup2,pc) !{{{ + implicit none + integer, intent(in) :: year + integer, intent(in) :: julianDay + integer, intent(in) :: hour + real (kind = RKIND), intent(out) :: s + real (kind = RKIND), intent(out) :: p + real (kind = RKIND), intent(out) :: h + real (kind = RKIND), intent(out) :: p1 + real (kind = RKIND), intent(out) :: N + real (kind = RKIND), intent(out) :: I + real (kind = RKIND), intent(out) :: nu + real (kind = RKIND), intent(out) :: xi + real (kind = RKIND), intent(out) :: nup + real (kind = RKIND), intent(out) :: nup2 + real (kind = RKIND), intent(out) :: pc + + integer :: x + real (kind=RKIND) :: yr,day,hr + real (kind=RKIND) :: deg2rad,rad2deg + real (kind=RKIND) :: NRad,pRad,IRad,nuRad,xiRad,nupRad,nup2Rad + + deg2rad = pii/180.0_RKIND + rad2deg = 180.0_RKIND/pii + + x = int((real(year,RKIND)-1901.0_RKIND)/4.0_RKIND) + yr = real(year,RKIND) - 1900.0_RKIND + day = real(julianDay,RKIND) + real(x,RKIND) - 1.0_RKIND + hr = real(hour,RKIND) + + ! N is the longitude of the moon's node (capital N, Table 1, Schureman) + N = 259.1560564_RKIND - 19.328185764_RKIND*yr - .0529539336_RKIND*day - .0022064139_RKIND*hr + N = adjust_angle(N) + NRad = N*deg2rad + + ! p is the lunar perigee (small p, Table 1) + p = 334.3837214_RKIND + 40.66246584_RKIND*yr + .111404016_RKIND*day + .004641834_RKIND*hr + p = adjust_angle(p) + pRad = p*deg2rad + + IRad = ACOS(.9136949_RKIND - .0356926_RKIND*COS(NRad)) + I = adjust_angle(IRad*rad2deg) + + nuRad = ASIN(.0897056*SIN(NRad)/SIN(IRad)) + nu = nuRad*rad2deg + + xiRad = NRad-2.0_RKIND*ATAN(.64412_RKIND*TAN(NRad/2.0_RKIND))-nuRad + xi = xiRad*rad2deg + + pc = adjust_angle(p-xi) + + ! h is the mean longitude of the sun (small h, Table 1) + h = 280.1895014_RKIND - 0.238724988_RKIND*yr + 0.9856473288_RKIND*day + 0.0410686387_RKIND*hr + h = adjust_angle(h) + + ! p1 is the solar perigee (small p1, Table 1) + p1 = 281.2208569_RKIND + 0.01717836_RKIND*yr + 0.000047064_RKIND*day + 0.000001961_RKIND*hr + p1 = adjust_angle(p1) + + ! s is the mean longitude of the moon (small s, Table 1) + s = 277.0256206_RKIND + 129.38482032_RKIND*yr + 13.176396768_RKIND*day + 0.549016532_RKIND*hr + s = adjust_angle(s) + + nupRad = ATAN(SIN(nuRad)/(COS(nuRad) + 0.334766_RKIND/SIN(2.0_RKIND*IRad))) + nup = nupRad*rad2deg + + nup2Rad = ATAN(SIN(2.0_RKIND*nuRad)/(COS(2.0_RKIND*nuRad) + 0.0726184_RKIND/SIN(IRad)**2))/2.0_RKIND + nup2 = nup2Rad*rad2deg + + end subroutine orbit!}}} + +!*********************************************************************** +! +! function adjust_angle +! +!> \brief Puts angles into the 0-360 degree range +!> \author Steven Brus +!> \date September 2019 +!> \details +! +!----------------------------------------------------------------------- + function adjust_angle(arg) result(angle) !{{{ + + implicit none + + real (kind=RKIND), intent(in) :: arg + real (kind=RKIND) :: angle + + integer :: cycles + + cycles = int(arg/360.0_RKIND) + angle = arg - real(cycles,RKIND)*360.0_RKIND + if (angle < 0.0_RKIND) then + angle = angle + 360.0_RKIND + end if + END + + +!*********************************************************************** + +end module ocn_tidal_potential_forcing!}}} + +!||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||| +! vim: foldmethod=marker diff --git a/testing_and_setup/compass/ocean/hurricane/USDEQU120at30cr10rr2/sandy/config_forward.xml b/testing_and_setup/compass/ocean/hurricane/USDEQU120at30cr10rr2/sandy/config_forward.xml index d8d9f0920c..7de26d5ce6 100644 --- a/testing_and_setup/compass/ocean/hurricane/USDEQU120at30cr10rr2/sandy/config_forward.xml +++ b/testing_and_setup/compass/ocean/hurricane/USDEQU120at30cr10rr2/sandy/config_forward.xml @@ -6,81 +6,21 @@ - - - +