Changeset 1314


Ignore:
Timestamp:
07/14/09 14:57:42 (16 years ago)
Author:
Eric.Larour
Message:

improved basal stress computation

File:
1 edited

Legend:

Unmodified
Added
Removed
  • issm/trunk/src/m/classes/public/basalstress.m

    r1 r1314  
    1 function [sx,sy,smag]=basalstress(md)
    2 %BASALSTRESS -  evaluates the basal stress
    3 %
    4 %   The basal stress is computed according to the following formula:
    5 %   sigma=drag^2*Neff^r*vel^s
    6 %   where:
    7 %    Neff is the effective pressure (Neff=rho_ice*g*thickness+rho_water*g*bed),
    8 %    r=q/p
    9 %    s=1/p
    10 %    p and q being friction coefficients found in the literature (Paterson).
     1function [bx by b]=basalstress(md,options_structure,width,i,type);
     2%BASALSTRESS - compute basal stress from basal drag and geometric information.
    113%
    124%   Usage:
    13 %      [Fx,Fy,Fmag]=basalstress(md)
     5%      basalstress(md,options_structure,width,i,type);
     6%
     7%   See also: plot_basaldrag
    148
    15 %Compute effective pressure
    16 Neff=md.rho_ice*md.g*md.thickness+md.rho_water*md.g*md.bed;
    17 Neff(find(Neff<0))=0.1;
    18 r=md.q./md.p;
    19 s=1./md.p;
    20 dragel=(md.drag(md.elements(:,1))+md.drag(md.elements(:,2))+md.drag(md.elements(:,3)))/3;
    21 Neffel=(Neff(md.elements(:,1))+Neff(md.elements(:,2))+Neff(md.elements(:,3)))/3;
    22 velel=(md.vel(md.elements(:,1))+md.vel(md.elements(:,2))+md.vel(md.elements(:,3)))/3/md.yts;
    23 vxel=(md.vx(md.elements(:,1))+md.vx(md.elements(:,2))+md.vx(md.elements(:,3)))/3/md.yts;
    24 vyel=(md.vy(md.elements(:,1))+md.vy(md.elements(:,2))+md.vy(md.elements(:,3)))/3/md.yts;
     9%check layer
     10if strcmpi(md.type,'3d')
     11        if options_structure.layer~=1,
     12                disp('plot_basaldrag warning: basal drag is displayed in the lower layer')
     13                options_structure.layer=1;
     14        end
     15end
    2516
    26 sx=dragel.^2.*Neffel.^r.*velel.^(s-1).*vxel;
    27 sy=dragel.^2.*Neffel.^r.*velel.^(s-1).*vyel;
    28 smag=sqrt(sx.^2+sy.^2);
     17%compute exponents
     18s=averaging(md,1./md.p,0);
     19r=averaging(md,md.p./md.q,0);
     20
     21%compute horizontal velocity
     22ub=sqrt(md.vx.^2+md.vy.^2)/md.yts;
     23ubx=md.vx/md.yts;
     24uby=md.vy/md.yts;
     25
     26%compute basal drag
     27bx=(md.g*(md.rho_ice*md.thickness+md.rho_water*md.bed)).^r.*(md.drag).^2.*ubx.^s;
     28by=(md.g*(md.rho_ice*md.thickness+md.rho_water*md.bed)).^r.*(md.drag).^2.*uby.^s;
     29b=(md.g*(md.rho_ice*md.thickness+md.rho_water*md.bed)).^r.*(md.drag).^2.*ub.^s;
Note: See TracChangeset for help on using the changeset viewer.