Skip to content

Commit

Permalink
Cohesion needs to be negative in SeisSol
Browse files Browse the repository at this point in the history
  • Loading branch information
uphoffc committed Nov 13, 2019
1 parent a6d097e commit e665cd3
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
6 changes: 3 additions & 3 deletions examples/f_16_scec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,10 @@ components: !SCECFile
s_xx: 0.0
s_zz: 0.0
s_xz: 0.0
[s_yy, s_xy, s_yz]: !FunctionMap
[s_yy, s_xy, s_yz, cohesion]: !FunctionMap
map:
s_yy: return -s_normal;
cohesion: return -cohesion;
s_xy: return s_strike;
s_yz: return s_dip;
[mu_s, mu_d, d_c, cohesion, forced_rupture_time]: !IdentityMap {}
[s_normal, s_strike, s_dip]: !IdentityMap {}
[mu_s, mu_d, d_c, forced_rupture_time]: !IdentityMap {}
10 changes: 5 additions & 5 deletions tests/f_16_scec.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -55,21 +55,21 @@ void model(double x, double z, double params[9]) {

if (x <= 0.0 && z <= 0.0) {
params[3] = 2.509795E+07; // s_xy
params[9] = 4.000000E+06; // cohesion
params[9] = -4.000000E+06; // cohesion
} else if (x <= 75.0 && z <= 0.0) {
double xi = x / 75.0;
params[3] = 2.509795E+07 * (1.0-xi) + 2.523141E+07 * xi; // s_xy
params[9] = 4.000000E+06; // cohesion
params[9] = -4.000000E+06; // cohesion
} else if (x >= 75.0 && x <= 150.0 && z >= 150.0 && z <= 225.0) {
double xi = (x- 75.0) / 75.0;
double eta = (z-150.0) / 75.0;
params[3] = (2.444593E+07 * (1.0-eta) + 2.445351E+07 * eta) * (1.0 - xi)
+ (2.488395E+07 * (1.0-eta) + 2.498051E+07 * eta) * xi; // s_xy
params[9] = (3.800000E+06 * (1.0-eta) + 3.700000E+06 * eta) * (1.0 - xi)
+ (3.800000E+06 * (1.0-eta) + 3.700000E+06 * eta) * xi; // cohesion
params[9] = -((3.800000E+06 * (1.0-eta) + 3.700000E+06 * eta) * (1.0 - xi)
+ (3.800000E+06 * (1.0-eta) + 3.700000E+06 * eta) * xi); // cohesion
} else {
params[3] = 2.498051E+07; // s_xy
params[9] = 3.700000E+06; // cohesion
params[9] = -3.700000E+06; // cohesion
}
}

Expand Down

0 comments on commit e665cd3

Please sign in to comment.