• Nenhum resultado encontrado

geodesic grids and a consistent alternative Accuracy analysis of mimetic finite volume operators on Journal of Computational Physics

N/A
N/A
Protected

Academic year: 2022

Share "geodesic grids and a consistent alternative Accuracy analysis of mimetic finite volume operators on Journal of Computational Physics"

Copied!
34
0
0

Texto

(1)

Contents lists available atScienceDirect

Journal of Computational Physics

www.elsevier.com/locate/jcp

Accuracy analysis of mimetic finite volume operators on geodesic grids and a consistent alternative

Pedro S. Peixoto

a,b,1

aCollegeofEngineering,MathematicsandPhysicalSciences, UniversityofExeter,UK bInstitutodeMatemáticaeEstatística, Universidade de São Paulo,Brazil

a r t i c l e i n f o a b s t r a c t

Articlehistory:

Received11August2015

Receivedinrevisedform1November2015 Accepted17December2015

Availableonline14January2016 Keywords:

Shallowwatermodel Finitevolume StaggeredCgrid SphericalVoronoigrid Mimeticdiscretization

Many newly developed climate, weather and ocean global models are basedon quasi- uniform spherical polygonal grids, aiming for high resolution and better scalability.

Thuburnet al. (2009)and Ringleret al. (2010)developed aC staggered finite volume/

differencemethodforarbitrarypolygonalsphericalgridssuitableforthesenextgeneration dynamicalcores.Thismethodhasmanydesirablemimeticpropertiesandbecamepopular, being adopted in some recent models, in spite of being known to possess low order of accuracy.In thiswork, we show that,for the nonlinearshallow water equations on non-uniform grids, the methodhas potentially 3 main sources ofinconsistencies (local truncationerrorsnot convergingtozero as thegrid isrefined):(i) thedivergenceterm of the continuity equation, (ii) the perpendicular velocity and (iii) the kinetic energy termsofthevectorinvariantformofthemomentumequations.Althoughsomeofthese inconsistencieshavenot impactedtheconvergenceonsomestandardshallow watertest casesupuntilnow,theymayconstituteapotentialproblemforhighresolution3Dmodels.

Based onouranalysis,we proposemodificationsfor themethodthat willmake it first orderaccurateinthemaximumnorm.Itpreservesmanyofthemimeticproperties,albeit havingnon-steadygeostrophicmodesonthef-sphere.Experimentalresultsshowthatthe resulting model is a moreaccurate alternative to the existing formulationsand should providemeansofhavingaconsistent,computationallycheapandscalableatmosphericor oceanmodelonCstaggeredVoronoigrids.

©2016ElsevierInc.All rights reserved.

1. Introduction

Aimingforvery highresolution scalablemodels,severalnewly developedglobalatmospheric modelsare usingquasi- uniform sphericalgrids [1].InThuburn etal.[2]andRingler etal.[3],afinite volume/differencenumerical schemewith very robust characteristics was developed for arbitraryorthogonal C grids, and later it was extended to non-orthogonal grids[4,5].Thedevelopedscheme,hereafter namedTRSK,possessesmanydesirablepropertiesthat mimicthecontinuous equations[1].Italsousesverycompactstencilsanddoesnotrequireamassmatrixorthesolutionofgloballinearsystems.

Forthesereasons, itbecamepopular amongresearchers,beingused inmodels such astheNCAR/Los Alamos Laboratory ModelforPredictionAcrossScales(MPAS)fortheatmosphere[6]andocean[7],intheDYNAMICOmodel[8],andinmany other studies[5,9–12]. Althoughthemethodology isproving tobe adequateforweather andclimateglobalmodelling, it

E-mailaddress:[email protected].

1 Tel.:+551130916136;fax:+551130916131.

http://dx.doi.org/10.1016/j.jcp.2015.12.058 0021-9991/©2016ElsevierInc.All rights reserved.

(2)

presentslowaccuracyorder.Apparently,increasingtheaccuracyorderofthemodelisnotpossiblewithoutbreakingsome ofitsproperties.Theaimofthisworkistoanalysetheaccuracypropertiesofthismethodandtoproposeamoreaccurate method that preservesas manyof the mimetic properties aspossible. The methodology is mostly suitable fororthogo- nal grids,andwe willadopta similarframeworkasusedinMPAS,withquasi-uniform sphericalVoronoigridsformedby hexagonsandpentagons,withdualgridformedbytriangles.

There aremanypropertiesthat anumericalmethodforglobalmodelsare desiredto have[1].Tostart with,it should be consistentwiththecontinuous equations(thediscrete systemshouldapproximatethecontinuous onewithincreasing resolution) and stable. In addition, it is desirable to mimic conservation properties, such as of mass, energy and axial angularmomentum.Moreover,themodelshouldbeabletoaccuratelyrepresentbalancedflowsandadjustmentprocesses.

Onashallowwatersystem,theTRSKschemehasmanyoftheseproperties,andsomeothers,e.g.

1. Massconservation.

2. Accuraterepresentationoffastwavesandadjustment(Cstaggering).

3. Curl-freepressuregradient(Discreteversionof∇ × ∇ψ=0).

4. Energyconservationofpressureterms(Discreteanalogueofv· ∇h+h∇ · v= ∇ ·(hv)).

5. EnergyconservingCoriolisterm(Discreteanalogueofv· v=0).

6. Conservationoftotalenergy.

7. Steadygeostrophicmodes(onthef-sphere).

8. CompatiblediscretizationofpotentialvorticitywithitsLagrangianbehaviour.

Property2deals withtheaccuraterepresentationoffastwaves,suchastheinertial-gravityones, whichforwellresolved Rossby radius scenarios has direct implications on the models ability to represent correctly the process of geostrophic adjustment[13].Properties3,4and5relyonhavingdiscreteanaloguesofcertaincontinuous relations.Totalenergycon- servationisobtainedwithintimetruncationerrors.Properties7and8areinterconnectedandrelatedtotheabilityofthe modeltoaccuratelyrepresentgeostrophicallybalancedflowsandtheevolutionofthepotentialvorticity.

The TRSK methodology issecond order accurate onregular hexagonsand rectanglesfor theshallow waterequations.

It also has a smallconstant of proportionality betweenaccuracy andresolution dueto the mimetic andother desirable numericalproperties.Inaddition,itshowssecond orderaccuracyinthemeanerrornorm(L2)inmostshallowwatertest cases[3,5].Nevertheless,some testcasesshow thatthemethodfailstoconvergeinthemaximumnorm,andthislackof convergencecanbecarriedtothe3Dmodel,whichhappens,forexample,intheMPASmodel(Skamarock,2015,personal communication).

Although consistency is not a necessary condition for convergence (since supraconvergence may occur, e.g. [14]), it is nonethelesshighly desirable tohavea consistent scheme,which,ifstable, wouldthen implyconvergence.Consistency analysisalsoprovidesmeansoftrackingsourcesofconvergenceproblems.Wewilldiscussinthisworkthat,foronashallow watersystemwithinputdatagivenpoint-wisely,severaldiscreteoperatorsofTRSKfailtoapproximatethecontinuousones withincreasing resolutionin themaximumnorm.The mainproblems occuron thehorizontaldivergence,kinetic energy andCoriolisterms.

Lack of accuracy offinite volume/differencediscretizations on quasi-uniform spherical grids is usually caused by grid relatedproblems[11,15].Toimprovecertaingridproperties,gridoptimizationshavebeenproposed(see[16]forareview).

Twoofthemwillbeofmajorinterestinouranalysis:(i)SphericalCentroidalVoronoiTesselations(SCVT),whichoptimize the grid by iteratively moving the cell centres to their mass centroids, and (ii) an optimization that approximates the midpoints of primal (hexagonal/pentagonal cells) and dual (triangles) edge midpoints, due to Heikes and Randall [17], hereafter HR95optimization. We willshowthat thecommonfinitevolumediscretization ofthe divergenceandcurl may lead toinconsistentschemeswithrespecttothemaximumnorm,withfirstorderaccuracybeingattainedonlyifaHR95 likeoptimizationisused.Ontheotherhand,theuseofSCVToptimizationimprovestheaccuracyofsomeotheroperators, asforexample,inthetreatmentoftheCoriolistermwiththeTRSKscheme.

Based onpreviousanalyses ofPeixotoandBarros[18],wewillproposeseveralmodificationsto theTRSKscheme.The mainmodificationsinvolvesadifferentlocationofthenormalvelocitiesonthegrid(preservingtheC-staggeringonVoronoi Cells), adifferentreconstructionalgorithmforthevelocitiesandtheuseofa barycentricsecondorderlinearinterpolation ofscalarfields.Thismodifiedschemeisafirstorderaccuratemethodinthemaximumnorm,whichhassimilarproperties tothoseofTRSK,exceptthat,

(i) totalenergywillnolongerbeconserved,duesolelytoadifferentdiscretizationofthekineticenergyterm,

(ii) thegeostrophicmodeswillnolongerbesteadyonthef-sphere,dueadifferentdiscretizationoftheCoriolisterm,and, forthesamereason,

(iii) thepotentialvorticitydiscretizationwillnolongerbecompatiblewithitsLagrangianbehaviour.

We willdiscusshowthesemodifications impactthemodelscharacteristics,concludingthatthemodifiedschemeprovides agoodtradeoffinlosingsomepropertiesofTRSKinordertoobtainfirstorderaccuracy.

Summarizing, the main goals ofthis paperare asfollows.First, we wish to presentan in depthanalysis ofthe local truncationerrors oftheTRSKscheme,inorderto provideawarenessofits strengthsandweaknesses.Also, wewillshow

(3)

Fig. 1.Delaunay triangulations and/or Voronoi cells are shown on different levels (indicated by each grid) for icosahedral grids.

severalpossiblemodifications totheexisting formulationstoachieve consistencyon eachdiscrete operator.Thesecan be interpretedoperator-wisely,improvingonlycertain aspectsoftheexisting schemes,oradoptedasawhole,consideringall thealternativeapproachessuggested–toformthehereproposedconsistentscheme.

Insection2wedescribethebasicframeworkofthemodelandgrid,within ashallowwatersystem.Section 3isdedi- catedtoadetailedanalysisoftheaccuracyofeachdiscreteoperator,andofpossiblemodificationstoensurebetteraccuracy.

Insection 4,results fromseveralshallowwatertestscasesare presented,comparingTRSK withthemodified schemeon differentgrids. Wealso discussaboutsome ofthe TRSKpropertieswhich arelost. Wefinishthe paperwithasummary, discussingtheproposedmodificationsandtheattainedresultsinsection5.

2. Modeldescription 2.1. Shallowwaterequations

Thenonlinearshallowwaterequationscanbewrittenforthesphereinvectorinvariantformas[3],

h

t

+ ∇ · (

h

u

) =

0

,

(1)

u

t

+

qh

u

= −

g

(

h

+

b

) − ∇

K

,

(2)

wherehistheheightorthicknessofthefluidlayer,u isthefluidvelocity, whichisassumedtobe tangenttothesphere, b isthebottomtopography, g isthegravityconstant, q=

η

/histhepotential vorticity,where

η

istheabsolutevorticity, definedas

η =

k

· ∇ ×

u

+

f

,

(3)

wherek isthe unit vector pointingin thelocal verticaldirection (suchthat k· u=0), u= k× u and f is the Coriolis parameter. K isthekineticenergyperunitmass,definedas

K

=

u

·

u

2

.

(4)

2.2. Gridspecifications

We will adoptan icosahedral based geodesic grid, refined by bisectingthe spherical triangles edges (see Fig. 1). The trianglesformaDelaunaytriangulationofthesphereandtheirverticeswillbesetasgridnodes.Thesetofnodesmaybe usedasgenerators ofa sphericalVoronoitessellation.Eachspherical Voronoipolygonwill beviewed asa computational cellrelativetoitsnode.TheresultinggridwillbeformedbyanarbitrarynumberofhexagonalVoronoicells(dependingon thenumberofrefinements done)and12pentagonal Voronoicells (primalgrid), withan underlyingtriangulargrid (dual grid).

Weusetheconventionthatthegridlevel0istheoriginalgridobtainedfromtheicosahedron(ithasdistancebetween nodes of approximately7054 km). The mean distance betweenVoronoi cell centres on the finer grids is approximately

(4)

Fig. 2.HC grid variable collocation points.

Fig. 3.GridpropertiesforSCVTandHR95optimizedicosahedralgrids.Left:Minimumdistancebetweentwonodesdividedbymaximumdistancebetween nodes.Right:MaximumoftheratioofdistancebetweenedgemidpointsandtheVoronoiedgelength.

60 kmforthegridlevel7(with163,842cells),30 kmforgridlevel8(with655,362cells)and15 kmforgridlevel9(with 2,621,442cells).

WewilluseaCgridstaggering,wherethescalarfield(fluidheight)isstoredattheVoronoicellnodesandthevelocities arestoredattheedges,butonlythecomponentnormaltotheVoronoicelledge.Here,twopointsmustbemadeclear,as thesewillgreatlyinfluencetheanalysisthatwillfollow:

(i) thenodesthatgeneratethecellnodesarenotnecessarilythecentroids(masscentres)oftheVoronoicells,

(ii) themidpoints oftheVoronoicelledges andthetrianglecelledgesdonotcoincide(see Fig. 2foranexampleofhow theedgemidpointsmighthappentobepositioned).

AsshowninPeixotoandBarros[15],theissuenumber(i)tendstoreducetheorderofaccuracyofcertaindiscreteoperators, such asthedivergence,curlorLaplacian.Toavoidthisproblem,it ispossibletooptimizethepositionofthenodesposi- tioning inordertoobtain agridwiththepropertyofhavingVoronoinodescoincidingwiththecellcentroids–theseare knownasSphericalCentroidalVoronoiTessellations(SCVT),see[19] and[20] fordetails.Withrespecttotopic(ii),Heikes andRandall [17]showedthatit causestheusualdiscretizationoftheLaplaciantobe inconsistent.Toenable aconsistent scheme,they propose agrid optimizationinwhichthe midpointsofthe triangleedgesconvergeto themidpoints ofthe Voronoicelledgeswithgridrefinement–wewilladdressthisoptimizedgridasaHR95grid.Anotherpossibleoptimization appliedtothiskindofgridisthe“springdynamics”optimization[21],whichreducesgriddistortions,butdoesnotimprove theaboveissuesassignificantlyasthepurposespecifictwoabovementionedoptimizations.

The analysisofMiura[16] showsthat twooftheabovementionedoptimizations,SCVT andHR95,seemtobe antago- nistic,andapparentlyonecouldnotobtainbothpropertiessimultaneously.WeshowinFig. 3twoimportantpropertiesof thesekindsofoptimizedgrids:

(5)

(i) Theratiobetweenthemaximumandminimumdistancebetweentwoneighbournodes,whichisrelatedtothedegree ofuniformityofthegrid.

(ii) The maximumratio betweenthe distancefrom thetriangle edge midpointto the Voronoicell edge midpoint (edge midpointdisplacement)andtheactualVoronoiedgelength.

Thefirstpoint showsthat thedegreeofuniformityoftheSCVT gridisbeinggradually lostwithincreasingresolution, whereastheHR95gridpreservesthegriduniformitywithincreasingresolution(seeleftpanelofFig. 3).Werecallthatour initialgoalofgoingtonon-structuredgrids istouseagridasuniformaspossibleonthesphere,toavoidconcentrationof points(singularities)ashappensinlatitude–longitudegrids.

Thesecondpointshowsthattheedgedisplacement(distancebetweenedgemidpoints)isconvergingtozerofasterthan theedgelengthwithincreasingresolutionontheHR95grid(seerightpanelofFig. 3).Thisisamainpropertyofthisgrid optimization, andwillbe usedlatertoshowthat itisanimportantrequisitetoobtainconsistent finitedifference/volume methodson astaggeredC gridsfortheshallowwaterequations.OntheSCVT grid,thedistancebetweenedge midpoints convergestozeroatthesamerateastheedge lengthgoestozero.Forafullcomparisonofgridoptimizationproperties, see[16].

OurgridanddiscretizationnotationwillcloselyfollowtheonesusedinRingleretal.[3],butourplacementofvariables willbeslightlydifferent.Itispossibletopositionthevelocitiesintwodifferent(andrelevant)points oftheedges:(i)the midpointsoftheedgesoftheVoronoicells–wewillcallthispositioningHCm,and(ii)themidpointofthetriangleedges, which representsa point on theVoronoi cell edgethat intersects the triangleedges –we will callthis positioning HCt.

The latteris whatis used inthe TRSKscheme [3]. We pointout that the velocity informationstoredis justthe normal componentrelative tothe Voronoicell edgein bothcases (seeFig. 2).Interestingly, we willshow that thisdifferencein positioninghasalotofimpactovertheaccuracyofthediscreteschemes.

Intheanalysisthatfollowswewillinvestigatethetwoicosahedraloptimizedgridsdiscussed,SCVTandHR95,eachone withtwopossiblevariablepositionings,HCmorHCt,resultingin4possibleconfigurations.OnaHR95optimizedgrid,these twopositionings(HCmandHCt)willasymptoticallyconvergetoeachother,sincetheedgemidpointdisplacementwillbe reducedveryfastwithresolution.Therefore,theresultsforHCtandHCmgridpositioningstendtobesimilariftheHR95 optimizationisused.However,since theHR95optimizationdoesnot ensureexactmatchingoftheedgemidpoints, some differencemightstillberelevantandwillbeanalysed.

VariablesstoredinVoronoicellnodes(trianglevertices) willbedenotedusingtheindexi.Variablesstoredintriangle circumcentres (Voronoicellvertices)willbedenotedusingtheindexv,andvariablesstoredonedgeswillbedenotedusing theindexe.

2.3. Modelinitializationandinterpretationofthedegreesoffreedom

Ouranalysiswillbe basedonpointwisespecificationofthe height(hi) andwind (ue)asinitial conditions,relativeto theirexactpositionsonthegrid.Forgiveninputwindfields,onlythenormalcomponentsofthepointwisevelocitiesrelative totheedgesareusedintheinitialization.Themainreasonforanalysingtheproblemthiswayisthat,innon-idealized(real) atmosphericandoceanmodels,the variables(suchaswindandpressure) areusually interpolatedpoint-wiselyintotheir gridpositions.

Ascommoninfinitevolumeschemes,thevariablesmaybethoughtintermsofcellaveragesandmeanflux/circulation.

Therefore,hi maybethoughtasthemeancellheight average,andue themeanedgevelocity normalto theedge.Thisis closelyrelatedtheframeworkproposedbyThuburnandCotter[4].InThuburnandCotter,theysuggestconsideringthecell integratedheight(geopotentialintheirnotation)and2possibilitiesforthevelocitydegreesoffreedom:

(i) Thecirculationalongthedualedge(triangleedge), i.e.theintegralalongthedualedgeofthevelocitytangenttothis edge.

(ii) Thevolumefluxacrosstheprimaledge(Voronoiedge),i.e.theintegralalongtheprimaledgeofthevelocitynormalto thisedge.

Consideringtheseinterpretationsofthedegreesoffreedomasthemeanintegrals(integralsdividedbytheirrespective edge lengths), then we can directly relate these withthe HCtand HCm positionings as follows.The velocity degree of freedomconsideringthemeancirculationmaybepointwiselyapproximatedtothemidpointofthetriangleedgewith2nd orderaccuracyusingthemidpointintegrationrule.Themidpointofthetriangleedgeisthereferencevelocitypointforthe HCtpositioning,andtherefore,theHCtpositioning isasecond orderapproximation tothe meancirculationintegral.The HCm positioningwouldlead toafirst orderonlyapproximation tothemean circulation.On theother hand,thevelocity degreeoffreedomconsideringthemeanvolumefluxmaybepointwiselyapproximatedtotheVoronoiedgemidpointwith 2ndorderaccuracyusingthemidpointrule.ThisimpliesthattheHCmpositioningisasecondorderapproximationforthe meanvolumeflux,andHCtwouldbeonlyafirstorderapproximationofthemeanvolumeflux.

InThuburnandCotter[4]theyrecommendthecirculationinterpretationfortheprognosticvelocitydegreeoffreedom.

InRingleretal.[3]theyusetheHCtpositioning,whichwediscussedtobeasecondorderapproximationtotheedgemean

(6)

circulation.Here, wewill openroom fortheHCm positioning(mean volumeflux interpretation),whichwe willlater see thatcanhelptoenhancetheaccuracyofcertainoperators.

Whenintegral formsareconsideredforthedegreesoffreedom,theinitializationprocessrequiressomecare.Forprob- lems with knownanalytical stream function,the model canbe initialized with theexact integral values considering the pointwisestream functionvaluesatthe endsoftheedges. Whenno streamfunctionis knownanalyticallyfortheinitial conditions, these integrals need to be approximated. A natural approximation to initialize the model would be to con- sider thesecond orderapproximationsusingHCtorHCm pointwiseinput data(respectivelyapproximationsto themean circulationalongthedualedgeorthemeanfluxacrosstheprimaledges).

Alternatively,onemightbegivenexactmassfluxes(hu) asinitialconditions.Inthiscase,dividingthefluxbytheedge length wouldgive theaverage edgeflux,which isrepresentedwithsecond orderattheedge midpoint,andissimilar to whatwearecallingHCmgrid.Iftheequationsweretobewrittenfullyinfluxform(havinghuasunknown),andtheinitial data were tobe givenasfluxes, thenit wouldnot matter werethe velocity ispositioned within theedge,buta natural placewouldbeattheedgemidpoint(whatwecallingHCmgrid).

2.4. Discreteshallowwatersystem

WewillconsiderasimilardiscretesystemastheonedescribedinRingleretal.[3],thatmaybeconciselystatedas,

hi

t

= −

Di

,

ue

t

= −

Qe

Ge

,

where Di,Ge and Qearerespectivelydiscretizationsofthedivergencetermofthemassequation(∇ ·(hu)),gradientterm (∇(g(h+b)+K))andCoriolisterm(qhu)ofthemomentumequation.

Thediscretizationswilldependonthekindofpositioningused(HCtorHCm)andwillbedescribedinthenextsection, togetherwithanaccuracyanalysisofthediscreteoperators.

3. Accuracyanalysisofdiscreteoperators

In what follows,we will analysethe local truncationerrors ofeach operator involvedin the horizontaldiscretization of the shallowwaterequations. We willadopt themaximum errornorm to labelthe consistency orderof theoperator.

Therefore,whenstatingthatamethoddefinesafirstorsecondorderapproximation,wewillingeneralbeconsideringthis inthe maximumnorm.Amethodwillbecalledinconsistentifthemaximumlocaltruncationerrordoesnot convergeto zerowithincreasingresolution.

It is important topoint out that, forstableschemes, the order ofthe local truncationerror (consistency order) does not necessarilylead to thesameconvergenceorder. Supraconvergence maytake placetoenable larger convergencerates than whatisobservedintheconsistencyanalysis(foranexamplereferto [14]).Nevertheless,theconsistencyordergives apotentialinsighttowhatmightbecausingamodeltoloseconvergence.Therefore,althoughwewillshowthattheTRSK schemeisinconsistentwithrespecttocertainoperators,thiswouldnotruleoutthepossibilityofitstillbeingconvergent.

Also, asdiscussedintheprevioussection,onemightinterpretthevariablesasintegralquantities.Theanalysisthatfol- lowsdirectlyappliestothesecasesbyconsideringtheanalogybetweenthemeanedgecirculationwiththeHCtpositioning, andthemeanedgefluxwiththeHCmpositioning.

3.1. Divergenceterm

TobuildthediscretedivergenceDi,thatapproximatesthedivergenceofhu,twostepsarerequired.Firstthefluidheight (h)mustbeinterpolatedtotheedges,asitlivesonthecentreofthecells.Second,thedivergencemaybeestimatedusing adiscreteversionofthedivergencetheorem.

Interpolationofheight

InterpolationoffluidheighttotheedgesisstraightforwardontheHCtgrid,as,duetotheorthogonality,theinformation lays exactly onthe endsof thetriangleedges andthe interpolation pointis preciselythe midpointof thetriangleedge.

Therefore,asimpleaverageofthetwovaluesoffluidheightfromthetwocellsthatsharetheedgewillgiveasecondorder approximationofthefluidheightonthedesirededgepoint,

he

= (

hi

+

hj

)/

2

,

(5)

withiand jindexesoftheVoronoicellsthatsharetheedge.

Ona HCmgrid,thesimpleaveragingwill resultina firstorderapproximationonly.Toobtaina secondorderinterpo- lation,we canusealinearinterpolationusingbarycentric coordinates(see[18] fordetails),whichleads tominimal extra computationaleffortandveryaccurateresultsonHCmpositioning.

(7)

Fig. 4.Areas used in the barycentric coordinates (left) and for the compatible TRSK scheme (right).

Theformulasforbarycentriccoordinateinterpolation areasfollows.Assume thatthepointofinterpolation xe belongs to the triangle Tk,which has verticeswhich we will indicate usingthe index i, then, theinterpolated value he maybe expressedas

he

=

i

λ

i

(

xe

)

hi

,

(6)

withtheweightsgivenby

λ

i

(

xe

) =

ai

(

xe

)

Ak

,

(7)

whereai(xe)is thearea ofthetriangleformed bythe twoverticesof thetriangleopposite i andthe interpolationpoint for he, and Ak is the area of the triangle Tk. This is a second order approximation on the sphere and we can usethe sphericalareastoobtainλi (seeFig. 4ontheleft).Itmustbeclearthatthisinterpolationisdifferentfromtheoneusedin Ringleretal.[3]tointerpolatescalarvaluestotrianglecircumcentres.Theyusetheareasrelativetotheintersectionsofthe primal anddualgridsasweightintheinterpolation(seeFig. 4ontheright).Theirapproachisfirstorderaccurateandis non-interpolatory(iftheinterpolationpointisonavertex,itdoesnotresultinthevaluegivenatthevertex).

WepointoutthatifthemidpointsoftheVoronoicelledgeandthetriangleedgewheretomatchexactly,thenthelinear interpolationofequation(6)wouldbeequivalenttothesimpleaverageofequation(5).

Divergencecalculation

Oncethefluidheightisknownattheedgepoints,thedivergenceofhuonaVoronoicellnodei canbeestimatedas Di

=

1

Ai

e

heueneile

,

(8)

wherele isthelengthoftheVoronoiedgee,ue isthenormalcomponentofthevelocity(relativetotheVoronoiedge)and nei isacorrectiontermthatis1 ifthenormalvectortotheedgene pointsoutward,and−1 ifitpointsinwardwithrespect tothecell.Thesummationvariesovertheedges(e)oftheVoronoicellandAi istheareaofthecell.

InPeixoto andBarros[15] severalpropertiesofthisdiscreteoperator wereanalysed.In particular,firstorderaccuracy in the maximum norm will be obtainedwhen: (i) the values of heue are known with (at least) second order accuracy, (ii)the edgepoint usedisthe midpointofthe Voronoicell(HCmpositioning)and(iii)the gridisnot toodistorted(e.g.

all triangleshavetheir circumcentre inside them). Forasecond orderapproximation ofthedivergence (inthe maximum norm),additionalgeometricconditionsshouldbemet(alignmentofthecelledges)andthevaluesofheue mustbeknown with greater accuracy (at leastthird order). Fortriangular cells, second order accuracy cannot be ensured (see example in[15]).

WithaHCtgrid,thenormalvelocitiesarenotatthemidpointoftheVoronoicelledges,andtherefore,thisdiscretization isingeneralinconsistent(inthemaximumnorm),asshowninAppendix A.However,withtheHR95gridoptimization,first orderisattainable,sincethediscretizationerrorwillbe oftheorderofthedistancebetweentheedge midpointsdivided bytheVoronoiedgelength,andthisconvergeslinearlytozeroonHR95grids,butnotonSCVTgrids.

Using the HCm grid withbarycentric interpolation fulfils the requirements forthe discrete operator to be first order accurateinthemaximumnorm.ThebarycentriccoordinatesinterpolationontheHCmdoesnotaffectthemimeticproper- tiesofthediscrete divergence(theproductrule),includingenergyconservation,sincethesameflux isusedonbothcells sharinganedge.

(8)

Fig. 5.MaximumandRMSerrorsofdiscreteoperatorsontestcase2initialconditions.Toplineshowsthedivergenceerrors(relativetoDi),middleline showsthepotentialvorticityerrors(relativetoqv),andthebottomlineshowsthekineticenergyerrors(relativetoKi)varyingwithresolution.Seetext foradescriptionofthemethodsused.Greylinesindicatefirstandsecondorderreferenceconvergencerates.

InFig. 5,toplayer, weshow theerrorsassociatedwiththediscretizationofthedivergenceoperator(Di)usingasolid body rotation vector field with the fluid height defined in geostrophic balance with the velocities, as in test case 2 of Williamson etal.[22].Themaximumandrootmeansquare (RMS)errorsareshown, wherethemaximumerrorissimply themaximumabsolutedifferencebetweenthenumerical(h)andtheanalyticalsolution(h),andRMSerrorsareasdescribed in[3],

ERMS

=

i

(

hi

hi

)

2Ai

ih2iAi

,

(9)

where i isvarying overthegrid cellsand Ai representtheir areas.Themaximumerrorwas not normalizedatthisstage (asrequested intypical testcases[22]),astheabsoluteerrorswillprovideinformationabouttheoverallerrordominance intheshallowwaterequations.

(9)

Fourpossibilitieswereusedtoinvestigatetheinterpolationandpositioningerrorsrelativetothedivergencediscretiza- tionshown inthetop lineofFig. 5: Thesimple averageofh withHCtpositioningandSCVT orHR95grids (respectively labelledasTRSK-HCT-SCVT andTRSK-HCT-HR95), andthelinearinterpolated h withHCmpositioning andSCVT orHR95 grids (respectively MODF-HCM-SCVT and MODF-HCM-HR95). All 4 methods were used together with the usual discrete divergencediscretizationofequation(8).

ItisclearthatwiththeHCtpositioningonSCVT,consistencycannotbeachieved(withrespecttothemaximumnorm), and that the HR95 grid optimization makes the method first order accurate, as discussed before. The HCm positioning providesthemostaccurateresultsforthedivergence,sincethevelocitiesareknowninthecorrectpositionforthemethod tobefirstorderaccurate,withouthavingtorelyontheHR95optimization.Thetwo differentpositionings(HCtandHCm) testedwiththeHR95griddonotresultinthesameaccuracy,sincethemidpointsoftheedges donotmatchexactly(the differenceisoftheorderoftheedgedisplacement).

WhereasthediscretizationontheHCtSCVTgridisinconsistentandneedstheHR95optimizationtobecomefirstorder accurate,onanHCmgrid,theSCVToptimizationgivesthemostaccurateresultsinthemeanerrornorm,almostachieving second order inthe maximumnorm. Thiscould be mainlydue tothe fact that on thisgrid thecell nodes are approxi- matelythecell masscentroid,whichisa necessaryconditionforthe methodtobesecond orderaccurate (see[15] fora comprehensivediscussiononthismatter).

3.2. Vorticity

In thissection we start analysing the accuracy ofthe discretization of the potential vorticity (PV), which is required forthe perpendicular term (Qe) of themomentum equation. The potential vorticity (q=

η

/h) dependson the absolute vorticity(relativevorticityplus f)andonthefluidheight.

Relativevorticity

The discretizationoftherelative vorticity dependson thecurl operator(k· ∇ × u) whichmaybe approximatedusing Gauss’s Theorem in thesame wayas thedivergence operator is obtained. The resultingdiscrete scheme forthe relative vorticityζ atthetrianglesis

ζ

v

=

1 Av

e

uetevde

,

(10)

wherede isthelengthofthetriangleedgee,thesummationvariesovertheedges(e)ofthetrianglev and Av isthearea ofthetriangle.ue isstill thenormalcomponentofthevelocity(relativetotheVoronoiedge),butnoticethatnow,dueto theorthogonality,itmaybeviewedasatangentcomponentofthewindrelativetothetriangleedge(seeFig. 2).Theterm tei is1 ifthenormalvectoroftheVoronoiedgene pointsinthecounterclockwisedirectionrelativetothetriangleand−1 otherwise.

Thevorticity isnaturallypositionedatthetrianglecircumcentres[3],butcanalsobethoughtinsimilarwaytoliveat theedges, ifcalculatedfrompairs oftriangles(see [23]).The latterisequivalent to theformerifthe vorticityis linearly interpolatedfromthetrianglestoedge.

The accuracy analysis of[15] naturally extends to the curl operator, under the same hypothesis, but now given the informationofthetangentcomponents.Itfollowsthatontriangularcellsthisdiscretizationisfirstorder,providedthatthe tangentcomponents ofthevelocitiesare atleastsecondorderaccurately calculatedatthe midpointsoftheedges ofthe triangles.ThismeansthatontheHCtgrid,inwhichthevelocitiesareknowatthemidpointsofthetriangleedges,wehave afirstorderapproximationfortherelativevorticity.OntheHCmgrid,thenormalvelocitiesatthemidpointsoftheVoronoi cells donot directlyrepresentthetangents atthemidpoints ofthetriangleedges(see Fig. 2).Thiswillingeneralleadto aninconsistentdiscretization(seeAppendix Afordetails).WithaHR95gridoptimizationtheHCmgridpositioningofthe velocitytangentcomponentsapproachthatoftheHCtgridandfirstorderaccuracyisobtained.Themimeticpropertiesof thecurloperatorarepreservedintheHCmgrid.

As an overallview ofthe divergenceandcurl operators, wehave thateither oneof themwill beinconsistent onthe HCmorHCtgrids,iftheHR95optimizationisnot used.OnHCtgrids,theproblemwilloccuronthedivergence,whereas fortheHCmgrids,itwillbeinthevorticity.Itistobeexpectedthat,ingeneral, thedivergencewillbemoreaccurateon HCmpositioningandthevorticityonHCtpositioning,evenonaHR95grid,sincetheoptimizationdoesnotmatchexactly themidpointsoftheedges.

Considering the degrees of freedoms to be known in the mean integral forms (circulation or flux) leads to similar conclusions.The divergenceisbetterrepresentedifthedegreeoffreedomadoptedisthemeanvolumeflux, whereasthe vorticityisbetterrepresentediftheadopteddegreeoffreedomisthemeanedgecirculation.Inthiscase,givenoneofthe interpretations,iftheotherisobtainedusingadiagonalmatrixwithvaluesrelativetotheprimalanddualedgelengths[4], thentheyaresimilarlysusceptibletotheinconsistenciesdiscussedfortheHCmandHCtpositionings.

Finally,withtheHR95optimizationboththediscretedivergenceandcurloperatorsareconsistentwithfirstorderaccu- racy.

(10)

Potentialvorticity

Toobtainthe potentialvorticity,thefluidheight isneededatthetrianglecircumcentres.InRingler etal.[3],theyuse theareasoftheintersectionoftheprimal(Voronoi)anddual(triangular)cells asinterpolationweights.Thelayerdepthh iscalculatedatthetrianglecentresas

hv

=

1 Ak

i

aivhi

,

(11)

withareasasshowninFig. 4(rightpanel).

Asmentionedbefore,thisactuallyleadstoanon-interpolatoryfirstorderapproximation.Thebenefitsofthisformulais thatitplaysanimportantroletoensuretheexistenceofcompatiblefluidheightandpotentialvorticityauxiliaryequations onthedualgrid.Amoreaccuratechoiceistouselinearbarycentriccoordinatesinterpolation,asdescribedbeforeforthe divergenceoperator(butnowweinterpolatetothetrianglecircumcentre),resultingina secondorderapproximation.The finalformofthepotentialvorticitywillbegivenby

qv

= η

v

+

fv

hv

,

(12)

where fv iftheCoriolisparametercalculatedatthecellvertices(trianglecircumcentres).

In Fig. 5 we show the errors obtainedforthe potential vorticity (qv) calculation of theinitial conditions oftest case 2 of [22] for 4 approaches: The first order interpolation of h (eq. (11)), with HCt positioning and SCVT or HR95 grids (TRSK-HCT-SCVTandTRSK-HCT-HR95),andthesecondorderlinearinterpolatedh,usingbarycentriccoordinates,withHCm positioningandSCVTorHR95grids(MODF-HCM-SCVTandMODF-HCM-HR95).All4methodswereusedtogetherwiththe usualdiscretecurldiscretizationofequation(10).

ExceptwiththeHCmSCVTgrid,allother methodsresultinsimilaraccuracywithfirstorderconvergence(inthemax- imum norm).Themain problemwiththeHCmSCVT approachisthatthe relativevorticitywill beinconsistent.Although the vorticity is expectedto be moreaccurately calculated on HCtpositioning, we see that because ofthe second order interpolation ofh,themodified MODF-HCm-HR95presentsthebestresults.Ofcoursethebarycentric interpolationcould becombinedwiththeHCtpositioningfromTRSK,whichshouldimproveitsaccuracy.

3.3. Kineticenergy

Forthegradientterm(Ge)thekineticenergyisrequiredatthecellnodes.Ringleretal.[3]suggestsadiscretizationthat leadstototalenergyconservation,defining

Ki

=

1 4Ai

e

ledeu2e

,

(13)

whereevarieswithintheedgesoftheVoronoicelli andde andle aredefinedasbeforeasthetriangleandVoronoiedge lengths, respectively. Energy conservingdiscretizations forthekinetic energyare possibleifdeduced fromdifferentways of calculatingthe massflux (see [8]). Forthe massflux definedin section 3.1,the formgivenabove isunique (see [3]).

In general, thisdiscrete version ofthekinetic energymaynot be consistent withtheanalytic kinetic energyinarbitrary non-regularVoronoicells.

Perot[24] showedthat thisdiscretizationisfirstorderaccurate (inthemaximumnorm)ontriangularstaggeredgrids, whenthedualgridedgecrossesthetriangleedgeatitsmidpoint.TheanalysisfortheVoronoistaggeredgridfollowsfrom thefactthatforaconstantvectorfield(u0),thekineticenergycanberepresentedexactlyby

1

2u

0

·

u0

=

1 2Ai

e

u0e

(

u0

· (

xe

xi

))

le

,

(14)

where xe is the midpointof theVoronoi cell edgeand u0e= u0· ne.If themidpoints of theVoronoi andtriangular cell edgescoincide,then,u·(xexi)=uede/2,resultingintheformulaeshownin(13).ThisindicatestheimportanceofaHR95 optimization toobtain a first orderaccurate approximation ofthe kinetic energy.We show an example ofthisin Fig. 5, for a solid body rotationvelocity field, wherefor a gridoptimized withSCVT andthiskinetic energy scheme(indicated as TRSK-HCT-SCVT),noconvergence isobtainedinthe maximumerror, whereasfora HR95 optimizedgrid (indicatedas TRSK-HCT-HR95),firstorderisobservedeveninthemaximumerror.

Toobtain aconsistent kineticenergyapproximation ingeneral, theue valuesshould becombinedtakingintoaccount cell geometry features. Notice that ue carries only partial informationaboutthe vector field andthat the kinetic energy dependsonthefull vectordefinedonthecell node.Severalpossibilitiesofreconstructing thefullvelocitiestocell nodes wereinvestigatedinPeixotoandBarros[18].Forinstance,Perot’smethodmaybeusedtofirstreconstructthevelocitiesat cellnodes,

ui

=

1

Ai

e

(

xe

xi

)

uele

,

(15)

(11)

andthenthekineticenergyatthenodescanbeobtainedas

Ki

=

1

2u

i

·

ui

.

(16)

OnaHCtgrid,oronagridwithcoincidingedgemidpoints,(xexi)= nede/2,and

ui

=

1

Ai

e

uelede

ne

/

2

.

(17)

TheresultingexpressionwillingeneralnotsimplifytotheenergyconservingKishownbefore.

An important point is that Perot’s reconstruction is only accurate (first order in the maximum norm) if the normal velocitiesare givenatthemidpoints ofthe Voronoiedges (HCmpositioning). Thisiscrucial,andusingHCtgrids greatly deterioratesitsaccuracy,soitshouldratherbeusedwithaHCmgridoratleastwithHR95optimizedgrids.Althoughthe methodisformallyfirstorderaccurateonly, asshownin[24],itissecondorderaccurateonspeciallyshapedcells, called alignedcells,asshownin[18].Infact,itattainssecondorderexceptinaminorityofVoronoigridcells(e.g.thepentagons).

ThiscanbeseeninFig. 5,bottomline,wherethismodifiedscheme(indicatedasMODF-HCM-SCVTandMODF-HCM-HR95, forthe2typesofgridoptimizationsSCVTandHR95)revealsbetteraccuracythantheschemedevelopedin[3],inspiteof notconservingtotalenergy.

3.4. Gradientterm

Thegradientterm(Ge)canbeapproximateddirectlyonorthogonalgridsatthemidpointofatriangleedge,as

Ge

=

g de

(

hi

+

bi

hj

bj

) +

1 de

(

Ki

Kj

),

(18)

where i indicates the index of the Voronoi cell which the reference normal edge vector points to, and j indicates the oppositecell.OnorthogonalVoronoigrids,thisdifferencing operationiscentredandthereforeissecond orderaccurate at the midpointof thetriangleedge (which is thecaseforHCt grids).It isonly firstorder accurate ifthemidpoint ofthe Voronoicelledgeandofthetriangledonotcoincide(whichisthecaseforgeneralHCmgrids).

Ontheevaluationof thegradientterm, thefirst termonthe righthandsideof equation(18)is accuratelycalculated becausehi isknownattheVoronoicellnodesandnoapproximationisrequired.Theaccuracyofthesecond termonthe righthandsidealsodependsonhowthekineticenergyiscalculated.Ifitiscomputedinconsistently,onecanevenobserve anaccuracyoforder−1 forthegradientterm,duetothedivisionbyagridlength scale(de),that is,theerrormaygrow withincreasingresolution.Wecanverifythisnumericallyfortheenergyconservingversionofthekineticenergycalculation (givenin(13))whentheSCVTgridisused,asshowninFig. 6forthemaximumerrors(indicatedwithTRSK-HCT-SCVT).If theenergyconservingschemeisusedwithaHR95optimization,thekineticenergywillbefirstorderaccurateinthemax- imumnorm,butonecanstillobtainaninconsistentgradient,asseeninFig. 6forthemethodindicatedasTRSK-HCT-HR95.

Inordertoguaranteeafirstorderdiscretizationofthisgradientterm,thekineticenergyshouldbecalculatedwithsecond orderaccuracy.

On a HCm positioning, Perot’s method is almost second order accurate. Using it together witha HR95 optimization, where the gradient differencing will alsoapproach second order,the accuracy of thisterm improves, ascan be seen in Fig. 6underthenameMODF-HCM-HR95scheme.Theattainedaccuracyismorethan4ordersofmagnitudebetterinthis testthan withtheenergyconservingschemeonan SCVTgridonfinergrids and3ordersofmagnitudebetterthan with HR95gridoptimization.

AlthoughPerot’s vectorreconstruction schemepresents second orderaccuracyon thegreat majorityof thehexagonal cells,theschememaystillbeonlyfirstorderaccurateonthemaximumnormdependingonthetestcaseselected(see[18]

foranexample).As adrawback,thegradient termwouldbeprone tobeinglocallyinconsistent wherethe reconstruction isonlyfirst orderaccurate.Weinvestigatedthe useofsecondorderaccurate reconstructionschemes suchasin[18],but wehaveseenlittleimpactinglobalaccuracy,atapriceoflargerstencilsforthereconstruction.Weanalysedalinearleast squaresmethodandthehybridschemeproposed in[18],andeventhoughthehydridschemehaslittleoverhead,wedid notnoticemuchadvantageinusingthesemethods.Forthisreason,wedidnotemploythesemethodsfurtherintheshallow watermodels.However, they wouldberequiredto ensurea firstorderaccurate localtruncationofthegradient termfor anyvelocityfield.

Consideringtheintegralinterpretationofthedegreesoffreedom, asin[4],thegradientisconsidered inintegral form.

Therefore,afirstorderaccuratekinetic energywouldbe enoughtoobtainafirst orderaccurate integralofgradient.Nev- ertheless, once the integral form is normalizedto ensure the correct velocity physicalunits, which isdone dividingthe integralsbyreferenceedgelengths(inthecaseofthevelocitydegreesoffreedom),weseethatitwouldbedesiredtohave theintegralofthegradienthavingsecondorderaccuracytoensurethatinphysicalvelocityunitsthemethodisconsistent.

(12)

Fig. 6.MaximumandRMSerrorsofdiscreteoperatorsontestcase2initialconditions.Toplineshowstheperpendicularoperatorerrors(relativetoQe), middlelineshowsthegradienterrors(relativetoGe),andthebottomlineshowstheoverallmomentumtendencyerrors(relativetoute)varyingwith resolution.Seetextforadescriptionofthemethodsused.Greylinesindicatefirstandsecondorderreferenceconvergencerates.

3.5. Coriolisterm

Here we willanalyse severalaspects ofthediscretization oftheperpendicular term(Q).We willstart investigating theconsistencyconditionsforthetangentialvelocity reconstruction(u).Thenwe willshowthereconstructionproposed byThuburnetal.[2]andanalyseits(in)consistency.Thenecessaryconditionsforenergyconservationaretheninvestigated and,finally,wewillshowanalternativeenergyconservingdiscretizationfortheperpendicularterm.

Generaltheoryforconsistency

Tobeginwith,weconsideranarbitraryplanarC-grid,withthenormalvelocitycomponentsstoredattheedgemidpoints.

Foranedgeeofthegrid,wedenoteasne aunitvectornormaltotheedge(inanarbitrarydirection),andte theunitvector tangenttotheedge,suchthatte= k× ne andne= te× k,wherekisaunitvectornormaltotheplane and×istheusual cross product. Fora vector field v, theavailable informationis the velocity component ue= v(pe)· ne, where pe is the midpointoftheedgee.

(13)

Forareconstructionmethodtobeatleastfirstorderaccurate,itissufficient(anddesirable)that itreproducesexactly constant vector fieldsonthe plane. Thismeans thatifit isknown onlyon 2edges, andtheseare not parallel,then the vector field is uniquely defined. The key point is to notice that the normal data given atan edge (ue) plays a role in reconstructingthetangentcomponent(ue),althoughtheyaredefinedfororthogonalvectors, asillustratedinAppendix B.

Thisisaconsequenceofhavingonlypartialinformationgiven(onlythenormalcomponentsofthevectorfieldknown).

Ifweimposeinitiallythatthereconstructedtangentvectorcomponentwillbeobtaineddirectlyas[2], ue

=

eNB(e)

weeue

,

(19)

forsome (yet)unknown weights wee relative to a set ofneighbour edges NB(e), then,since for a constant vector field

v=uene+vete,wemusthaveve=ue (giventhevaluesofue= v· ne),thefollowingconditionresults,

v

·

te

=

ue

=

eNB(e)

weev

·

ne

=

v

·

eNB(e) ween

e

,

andtherefore,

te

=

eNB(e)

ween

e

.

(20)

Thisconditiondefinesa uniquesolutionforatriangularCgridcasewhenonly2edgeinformationsareusedtocalculate a reconstructed tangent component for the remaining edge, as we have only 2 unknown weights. As it is unique, the constantreconstructedvectorfieldisthesameobtainedfromalowestorder(0thorder)Raviart–Thomaselement(see[18]

for details).The triangular C-grid case hasbeen well analysed, forexample, in [25,26] and[27],and further details are providedinAppendix B.

Amethodsatisfyingtheconditionderivedabovemaybecombinedconsistentlyatanedgecommontocellsi and j as

ue

=

ae,iue,i

+

ae,jue,j

,

(21)

whereue,iandue,jarethereconstructionsatedgeeusingthei-thand j-thVoronoicellssetofedges.Theweightsae,iand ae,j are positiveandshould addto 1 topreserve consistency.Thisdescription isappropriate toclarify certain properties, buttheseweights maybe absorbedinthe reconstructionweightsandthemethodcanbeequivalently viewedasa single stencilmethod.

Asshownin[15],sphericalpolygonscanbelocallyapproximatedbyplanarpolygonstangenttothesphere.Proceeding asin[15],wecanextendtheconsistencyconditionsderivedabove(firstorderconditions)forthetangentreconstructionon thesphere.The sphericalcompactstencilsmaybe statedastheonesintheplanar grid,butnowconsideringthenormal andtangentvectorsasvectorsin R3 tangenttothesphere,andsubstitutingtheedgelengthsandpolygonalareasbythe geodesicones.

TRSKscheme

TheTRSK scheme,proposed inThuburnetal.[2],uses twoarbitraryVoronoicellstodefine thereconstructionstencil.

Themethoddefines

ue

=

ue,i

+

ue,j

,

(22)

withi and j beingtwo neighbourVoronoi cellssharing theedgee,withue,i (andrespectivelyue,j) calculatedusingthe followingweights,

wee

=

ceele

de

1

2

v

Aiv

Ai

nei

,

(23)

where Aiv isthearea ofthequadrilateraldefinedbythecelli centre,thevertex v andtwo adjacentcelledgemidpoints (whichisalsotheoverlappingareabetweentheVoronoicellandthedualtriangularcell),thesumiswithintheverticesv betweenedgeeande andthereisasigncorrectionforthenormalcomponents,suchthattheypointoutward(nei= ±1) anda generalsign correction (cee = ±1) relative to the orientation of the tangent vector at e with respectto the dual triangularcell(see[2]or[11]fordetails).

Althoughthe scheme isconsistent forrectangles andregular hexagons,in general, it doesnot satisfy theconsistency conditions.Onsphericalgeodesic grids,it isnotpossibleto obtainonlyregular Voronoicells,andthemethodis afterall inconsistentinthemaximumnorm.Onthesphere,theedgelengthsandareasaregeodesic.

Toanalysewhetherthemethodobeystheconsistencycondition,we calculatethe numericaltangent (tne) vector(using theweights(23)oncondition(20))andcompareitwiththeactualtangentvector (te),definingforeachedgean inconsis- tencyindex

χ

e= tnete,withtheusualEuclideannorminR3.Onaplanargrid,consistencyshouldbeachievedif, and

(14)

Fig. 7.OnthetopleftitisshowntheerroronthevectorreconstructionofthetangentcomponentusingtheTRSKschemeonaHCtpositioningofasolid bodyrotationvectorfield(testcase2of[22])andonthetoprighttheinconsistencyindexforTRSKscheme.Theplotwascentredatlatitude65degrees andzerolongitudeandusedanicosahedralgridlevel6withoutoptimization.Onthebottomline,weshowconvergenceratesforthemaximumerror(left) andtheinconsistencyindex(right)fornon-optimizedgrids(ICOS),SCVTandHR95optimizedgrids.AHCtpositioningwasusedinallcases.

onlyif,

χ

e=0.Onthesphericalgrid,

χ

e shouldconvergetozeroforthemethodtobeconsistent.Therefore,itcanbeused tolocallyevaluatethepotentialaccuracyofthemethod.

InFig. 7wedisplay

χ

e onanicosahedralgridlevel6,withoutoptimization(toprightpanel)withclearpatternsofgrid imprinting.WecanalsoobserveinFig. 7(topleft)thattheinconsistencyisrelatedtotheerrorofthereconstructionofthe tangentvelocitycomponentofasimplesolidbodyrotationfromWilliamson[22]testcase2,presentinglargererrorswhere theapproximationoftangentvectorsisworse.

OnthebottomlineofFig. 7weshowhowtheerrorsofthetangentialreconstructionandthevaluesoftheinconsistency index vary on differentgrid levels. Inconsistency isclear forthe non-optimized (ICOS) andHR95 grids, but surprisingly, on theSCVT grids, themethodnot onlyconverges forthistest case,butthe inconsistencyindexindicates that itshould convergeforanysmoothvectorfield(atleastupuntilthegridleveltestedhere).ForthesetestsweusedaHCtpositioning, butsimilarresultswereobservedfortheHCmpositioning(notshown).

Energyconservationconditions

The discretesystemmustsatisfy ananalogousconditiontohu·(qhu)=0 toenable energyconservationwithrespect totheCoriolisterm.OnusualCgrids,thevelocityisknownontheedges,whileq andharenot.Becauseuneeds tobe calculatedfromneighbouredges,thisconditionscannotbefulfilledoneachedge.Nevertheless,theintegralofthequantity hu·(qhu)shouldvanishovertheentiregridtoensureenergyconservation.

Anaturalwayofconsideringthisintegraloverthediscretegridistoassumeconstantpiecewisevaluesoveredgeareas, resultinginthefollowingconditionforenergyconservation,

e

Aeqeh2eueue

=

0

,

(24)

(15)

where Ae isanareaassociatedwithedgee,andqe,he arerespectivelythepotential vorticityandfluiddepthattheedge, andthesumisoverallgridedges.

Usingareconstructionschemetocalculateue,leadstothefollowingcondition,

e

eNB(e)

weeAeqeh2eueue

=

0

.

(25)

Withtheabovecondition,itisclearthatue shouldnotparticipateinthecalculationofue,otherwiseau2e termwillappear andwillnotallowcancellationforarbitraryvectorfields.Asufficientconditiontosatisfyequation(25)is

weeAeqeh2e

= −

weeAeqeh2e

.

(26)

The fluiddepth isusually storedinthecell centreonC-grids, andthepotential vorticity willnaturally be definedon thedualgridcellcentres(primalgridcellvertices).Therefore,qe andhe havetobeapproximatedfromtheirgivenvalues totheedges.Since theweightsofthereconstruction(wee) shoulddependonlyonthegeometryofthegrid,thisimplies thattheapproximationofqandhattheedgeseandeshouldbeequalforanypairofedgesbelongingtosamestencil(or cell),whichleadstoaconstantq andhforallgridedges.

Analternativeistodefine

v

=

hqu

(27)

andrestatetheenergyconservationconditionfortheCoriolisforceas

e

Aeueheve

=

0

.

(28)

Sincehq isascalarfield,inthecontinuous casethesetwo conditionsare equivalent,butwillbedifferentonthediscrete system.Inthiscase, ve canbeestimatedanalogouslytoue as

ve

=

eNB(e)

weeqeeheue

,

(29)

whereqee referstothevalue ofq atedge eusedinthecalculation oftheirvaluesattheedgee,andhe refers tovalue usedinthecalculationofhatedgee(independentlyofe).Nowasufficientconditiontoconserveenergymaybegivenas

weeAeqee

= −

weeAeqee

.

(30)

Toobtainreconstructionweightsindependentofq,qee shouldbeequaltoqee.Thisiseasilyobtainedwithalinearcombi- nationofqe andqe,as

qee

=

qee

= γ

eqe

+ γ

eqe

,

(31)

with

γ

e+

γ

e=1 topreserveconsistency.Ringleretal.[3]use

γ

e=1/2.

Consequently,theconditionsforthereconstructionweightstoensureenergyconservationarethat

weeAe

= −

weeAe

.

(32)

Ifthe reconstruction methodis decomposedintwo stencils, witha reconstruction foreach celladjacent tothe edge, thenthisconditionmayberestatedas

ae,iweeAe

= −

ae,iweeAe

,

(33)

whichgivessomedegreesoffreedomtochooseae,i sothatthisconditionissatisfied.

ItisstraightforwardtoverifythattheTRSKschemeof[2,3]satisfiesthisconditioniftheperpendiculartermisdiscretized as

Qe

=

e

weeheueqee

,

(34)

withthesumovertherelevanteedgesofthetwoneighbourVoronoicellswithweightsgivenbyequation(23).qe canbe obtainedby linearinterpolationfromthecircumcentres ofthetrianglesthatdefinethisVoronoiedge.InRingleretal.[3], thisisdone usingequalweights (1/2), whichresultsinafirstorderinterpolationingeneral,sincetheinterpolationpoint doesnotcoincidewiththemidpointoftheedgeonHCtgrids,butsimplelinearinterpolationcouldbeusedinstead.Onthe otherhand,onHCmgrids,thiswillalwaysbesecondorderaccurate.

Referências

Documentos relacionados

arches in dorsal view of Liosomadoras oncinus, based on MZUSP 93497, 70.7 mm SL. Left side of dorsal branchial arches omitted for ease of understanding. Urohyal and branchiostegal

Despercebido: não visto, não notado, não observado, ignorado.. Não me passou despercebido

Caso utilizado em neonato (recém-nascido), deverá ser utilizado para reconstituição do produto apenas água para injeção e o frasco do diluente não deve ser

Este modelo permite avaliar a empresa como um todo e não apenas o seu valor para o acionista, considerando todos os cash flows gerados pela empresa e procedendo ao seu desconto,

Este relatório relata as vivências experimentadas durante o estágio curricular, realizado na Farmácia S.Miguel, bem como todas as atividades/formações realizadas

Com base nos parâmetros de comportamento do fogo (velocidade de propagação da frente de fogo e comprimento de chama) e na quantidade de material combustível consumido, foram feitas

Na hepatite B, as enzimas hepáticas têm valores menores tanto para quem toma quanto para os que não tomam café comparados ao vírus C, porém os dados foram estatisticamente

É nesta mudança, abruptamente solicitada e muitas das vezes legislada, que nos vão impondo, neste contexto de sociedades sem emprego; a ordem para a flexibilização como