comparison +scheme/Elastic2dVariable.m @ 738:aa4ef495f1fd feature/poroelastic

Set Dirichlet tuning as parameter in BC function in Elastic2dVariable.
author Martin Almquist <malmquist@stanford.edu>
date Tue, 01 May 2018 14:19:08 -0700
parents eebe24a636c7
children 1f6b2fb69225
comparison
equal deleted inserted replaced
736:d991f8a0b61c 738:aa4ef495f1fd
271 % boundary is a string specifying the boundary e.g. 'l','r' or 'e','w','n','s'. 271 % boundary is a string specifying the boundary e.g. 'l','r' or 'e','w','n','s'.
272 % type is a cell array of strings specifying the type of boundary condition for each component. 272 % type is a cell array of strings specifying the type of boundary condition for each component.
273 % data is a function returning the data that should be applied at the boundary. 273 % data is a function returning the data that should be applied at the boundary.
274 % neighbour_scheme is an instance of Scheme that should be interfaced to. 274 % neighbour_scheme is an instance of Scheme that should be interfaced to.
275 % neighbour_boundary is a string specifying which boundary to interface to. 275 % neighbour_boundary is a string specifying which boundary to interface to.
276 function [closure, penalty] = boundary_condition(obj, boundary, type, parameter) 276 function [closure, penalty] = boundary_condition(obj, boundary, type, tuning)
277 default_arg('type',{'free','free'}); 277 default_arg('type',{'free','free'});
278 default_arg('parameter', []); 278 default_arg('tuning', 1.2);
279 279
280 if ~iscell(type) 280 if ~iscell(type)
281 type = {type, type}; 281 type = {type, type};
282 end 282 end
283 283
306 switch type{k} 306 switch type{k}
307 307
308 % Dirichlet boundary condition 308 % Dirichlet boundary condition
309 case {'D','d','dirichlet','Dirichlet'} 309 case {'D','d','dirichlet','Dirichlet'}
310 310
311 tuning = 1.2;
312 phi = obj.phi{j}; 311 phi = obj.phi{j};
313 h = obj.h(j); 312 h = obj.h(j);
314 h11 = obj.H11{j}*h; 313 h11 = obj.H11{j}*h;
315 gamma = obj.gamma{j}; 314 gamma = obj.gamma{j};
316 315