Heterogeneous models

Realistic models of porous media often feature spatially-varying material properties, especially porosity and permeability. There are several ways to introduce heterogeneity into the model in PorousFlow. In the following, we demonstrate how to create models with heterogeneous rock properties and use these properties in a simulation.

Regular grids

For regular structured grids that can be easily constructed using common meshing tools (or even the meshing capability built in to MOOSE), heterogeneity can simply be read from an external data file. In this example, we consider the 2D model of permeability heterogeneity presented as Case 1 of the tenth SPE comparative problem.

The permeability data for this model is read from an ASCII file containing coordinates and permeability values (in millidarcys):

# SPE 10 comparative problem - model 1
# Data from https://www.spe.org/web/csp/datasets/set01.htm

AXIS X
3.81 11.43 19.05 26.67 34.29 41.91 49.53 57.15 64.77 72.39 80.01 87.63 95.25 102.87 110.49 118.11 125.73 133.35 140.97 148.59 156.21 163.83 171.45 179.07 186.69 194.31 201.93 209.55 217.17 224.79 232.41 240.03 247.65 255.27 262.89 270.51 278.13 285.75 293.37 300.99 308.61 316.23 323.85 331.47 339.09 346.71 354.33 361.95 369.57 377.19 384.81 392.43 400.05 407.67 415.29 422.91 430.53 438.15 445.77 453.39 461.01 468.63 476.25 483.87 491.49 499.11 506.73 514.35 521.97 529.59 537.21 544.83 552.45 560.07 567.69 575.31 582.93 590.55 598.17 605.79 613.41 621.03 628.65 636.27 643.89 651.51 659.13 666.75 674.37 681.99 689.61 697.23 704.85 712.47 720.09 727.71 735.33 742.95 750.57 758.1

AXIS Y
0.381 1.143 1.905 2.667 3.429 4.191 4.953 5.715 6.477 7.239 8.001 8.763 9.525 10.287 11.049 11.811 12.573 13.335 14.097 14.859

DATA
6.944900e+01 8.446310e+01 2.182550e+01 2.538350e+01 4.799630e+01
3.121820e+01 5.146480e+01 6.141520e+01 3.539720e+01 2.750770e+01
3.121680e+01 6.920730e+01 4.219730e+01 4.549820e+01 8.205680e+01
8.073110e+01 6.855150e+01 8.571610e+01 5.206950e+01 9.381740e+01
5.922440e+01 7.002914e+02 5.715565e+02 5.447281e+02 9.911849e+02
5.420923e+02 7.968679e+02 8.456119e+02 6.601896e+02 7.836548e+02
6.226988e+02 5.228158e+02 6.808698e+02 8.247515e+02 9.648132e+02
8.967670e+02 2.250000e-02 6.726000e-01 2.551000e-01 3.372000e-01
7.100000e-01 9.568000e-01 4.220000e-02 2.752000e-01 7.695000e-01
2.416000e-01 7.637000e-01 8.430000e-01 9.130000e-01 1.180000e-01
9.831000e-01 3.513000e-01 6.616000e-01 4.706000e-01 7.887000e-01
6.177000e-01 7.800000e-01 9.137000e-01 2.325000e-01 4.112000e-01
7.171000e-01 2.297000e-01 7.668000e-01 8.844000e-01 4.170000e-02
8.016000e-01 6.857000e-01 1.590000e-02 8.775000e-01 5.292136e+02
7.785096e+02 5.200872e+02 6.739397e+02 9.535383e+02 8.321105e+02
9.478826e+02 5.029753e+02 5.856386e+02 4.416000e-01 6.536000e-01
2.761000e-01 3.040000e-02 9.105000e-01 9.574000e-01 8.878000e-01
4.527000e-01 1.224000e-01 4.641000e-01 3.199000e-01 6.395000e-01
6.702110e+01 4.205240e+01 3.834640e+01 5.660020e+01 7.788050e+01
5.065010e+01 9.177820e+01 9.028590e+01 4.257580e+01 2.789530e+01
6.309900e+00 1.613740e+01 8.674400e+00 1.511640e+01 3.086600e+00
7.620000e-02 2.619000e-01 6.920000e-02 9.041000e-01 2.058000e-01
3.042000e-01 9.327000e-01 9.188000e-01 3.570000e-01 3.152000e-01
8.696000e-01 1.230000e-02 7.226000e-01 2.729000e-01 5.287000e-01
8.275000e-01 7.064000e-01 5.368000e-01 8.624000e-01 9.877000e-01
1.089000e-01 3.690000e-02 3.168000e-01 2.772000e-01 3.142000e-01
4.577000e-01 5.064576e+02 9.142116e+02 7.402499e+02 7.150742e+02
9.710854e+02 6.581536e+02 8.633879e+02 8.585419e+02 5.734941e+02
5.692402e+02 6.588336e+02 6.997136e+02 9.558577e+02 8.031951e+02
9.267200e+02 2.244100e+00 1.903880e+01 3.509300e+00 9.679600e+00
1.995980e+01 1.219750e+01 4.162000e-01 9.605000e-01 3.618000e-01
9.645000e-01 6.332000e-01 9.550000e-02 3.896000e-01 1.998000e-01
6.227000e-01 6.746000e-01 5.725000e-01 5.963000e-01 7.460000e-02
7.873000e-01 8.457000e-01 8.244000e-01 7.713460e+01 9.844220e+01
8.208120e+01 2.854110e+01 5.975890e+01 5.596970e+01 7.997900e+01
5.260730e+01 8.305580e+01 3.794510e+01 3.277500e+01 1.276950e+01
1.153620e+01 7.783400e+00 1.227060e+01 1.527450e+01 1.146540e+01
3.092200e+00 1.368600e+00 3.200000e+00 1.064080e+01 3.725200e+00
1.955970e+01 1.081960e+01 7.038500e+00 1.433360e+01 1.545520e+01
9.302500e+00 5.295700e+00 1.624530e+01 1.260880e+01 5.276000e+00
1.461390e+01 8.267500e+00 4.830400e+00 1.049480e+01 1.196830e+01
1.168898e+02 2.432404e+02 2.623387e+02 3.218745e+02 1.090790e+01
9.354200e+01 1.847480e+01 3.372431e+02 2.889694e+02 4.344256e+02
3.472262e+02 4.949615e+02 6.808610e+01 1.393731e+02 1.617475e+02
4.373103e+02 3.153680e+02 9.963580e+01 2.145350e+01 6.118320e+01
3.931650e+01 5.701000e+01 9.830700e+01 2.696840e+01 9.666340e+01
7.326900e+01 8.802940e+01 8.032440e+01 2.879760e+01 2.959320e+01
6.045340e+01 4.942370e+01 4.691880e+01 2.495000e-01 3.369000e-01
6.588000e-01 2.659000e-01 3.236000e-01 1.903000e-01 1.723000e-01
4.486000e-01 3.978000e-01 3.073000e-01 2.061000e-01 3.003000e-01
2.489000e-01 2.604000e-01 7.491000e-01 3.510000e-02 3.121000e-01
8.895000e-01 4.196000e-01 6.034000e-01 6.197000e-01 2.432000e-01
3.984000e-01 6.329000e-01 7.386000e-01 5.097000e-01 3.713000e-01
3.622000e-01 7.069000e-01 9.610000e-01 5.703390e+01 6.626440e+01
9.773070e+01 9.101430e+01 3.426220e+01 6.468970e+01 4.619260e+01
6.281910e+01 4.685060e+01 2.024230e+01 8.817320e+01 2.345470e+01
2.054970e+01 9.795030e+01 8.766520e+01 5.056620e+01 5.634460e+01
1.687120e+01 1.558150e+01 6.529800e+00 2.295500e+00 4.530800e+00
4.284000e+00 5.089900e+00 6.779400e+00 1.621250e+01 1.338680e+01
5.625400e+00 8.104448e+02 7.834398e+02 8.831865e+02 5.226963e+02
8.922433e+02 7.295800e+00 7.588700e+00 7.454200e+00 1.927970e+01
2.137700e+00 3.009400e+00 1.877820e+01 9.759700e+00 1.578320e+01
1.709060e+01 1.356870e+01 1.207950e+01 5.905200e+00 2.940000e-01
6.096000e-01 1.457000e-01 3.347000e-01 5.271000e-01 2.770000e-01
1.656000e-01 5.887000e-01 6.747000e-01 2.534000e-01 5.515000e-01
4.150000e-02 5.979000e-01 9.089000e-01 7.895000e-01 8.341000e-01
5.780000e-01 8.390000e-02 6.297000e-01 9.234000e-01 5.900000e-03
7.689000e-01 7.737000e-01 7.631000e-01 6.660000e-02 8.021000e-01
5.640000e-01 9.927000e-01 4.297000e-01 5.498000e-01 6.690000e-01
1.284000e-01 9.359000e-01 5.957000e-01 7.724000e-01 2.438000e-01
2.852000e-01 4.298000e-01 2.609000e-01 6.648000e-01 7.201000e-01
1.343000e-01 9.079000e-01 6.536000e-01 7.201000e-01 2.340600e+00
1.179040e+01 2.804500e+00 1.398710e+01 1.184820e+01 1.729430e+01
4.546000e+00 1.274750e+01 1.278530e+01 1.707900e+01 3.362600e+00
1.672010e+01 1.139170e+01 1.511590e+01 1.602400e+01 1.235160e+01
1.448240e+01 1.209240e+01 9.406400e+00 5.695860e+01 4.076211e+02
4.014820e+01 3.011918e+02 4.953825e+02 2.729345e+02 2.482050e+02
8.617241e+02 6.643846e+02 5.461154e+02 9.890477e+02 3.817790e+01
3.002670e+01 2.730804e+02 2.185039e+02 1.870318e+02 3.205371e+02
3.192442e+02 1.286495e+02 3.652104e+02 3.948677e+02 1.034615e+02
3.464130e+01 6.364950e+01 9.585850e+01 8.538430e+01 8.539900e+00
1.679500e+01 8.749200e+00 1.177050e+01 1.772900e+00 5.359300e+00
1.380060e+01 5.430200e+00 7.281200e+00 8.045600e+00 4.682100e+00
4.252300e+00 6.811500e+00 9.434800e+00 9.703400e+00 1.232000e+00
6.064400e+00 1.301490e+01 9.284200e+00 2.928200e+00 5.007100e+00
1.149350e+01 1.267300e+00 1.877560e+01 6.185900e+00 1.411060e+01
9.230800e+00 1.239740e+01 4.038800e+00 1.695090e+01 1.480060e+01
4.918000e+00 6.719080e+01 6.318440e+01 3.247570e+01 4.642090e+01
7.832260e+01 6.100360e+01 7.211420e+01 5.592410e+01 7.034930e+01
2.796200e+01 3.973670e+01 5.027880e+01 7.328900e+01 7.601150e+01
6.141630e+01 7.686650e+01 9.801970e+01 3.671330e+01 2.158530e+01
4.017820e+01 9.127820e+01 5.623810e+01 7.803560e+01 5.681430e+01
6.916313e+02 8.147874e+02 7.307380e+02 9.405273e+02 7.476498e+02
8.717890e+02 6.733963e+02 7.937977e+02 8.905142e+02 5.224857e+02
6.148839e+02 8.082030e+02 8.713152e+02 7.331783e+02 5.628835e+02
7.027299e+02 6.340151e+02 2.148600e+00 1.343830e+01 5.400400e+00
2.299500e+00 9.314300e+00 1.008700e+01 1.331250e+01 3.197000e+00
4.861600e+00 1.502100e+01 1.851450e+01 2.517900e+00 8.513700e+00
4.925000e-01 4.719000e-01 7.673000e-01 9.225000e-01 1.542000e-01
3.048000e-01 5.567000e-01 1.000000e+00 9.268000e-01 4.542000e-01
4.319146e+02 4.634601e+02 7.026350e+01 2.711288e+02 4.096455e+02
3.765088e+02 3.088911e+02 2.434264e+02 3.243710e+02 8.846900e+00
1.569400e+01 1.239640e+01 6.001200e+00 1.188690e+01 9.226800e+00
1.933900e+01 1.806600e+01 1.557200e+01 5.201300e+00 1.028470e+01
1.603940e+01 5.947600e+00 1.325970e+01 1.750800e+01 5.175600e+00
1.490770e+01 1.908600e+00 1.641310e+01 8.374300e+00 9.757600e+00
1.608150e+01 5.096800e+00 1.274320e+01 1.077600e+01 9.700900e+00
7.910500e+00 1.116050e+01 9.485450e+01 2.101600e+01 2.851940e+01
4.036770e+01 9.442940e+01 2.122620e+01 2.414360e+01 6.581230e+01
2.441190e+01 8.364680e+01 8.014320e+01 3.201890e+01 5.237420e+01
7.145520e+01 9.123860e+01 7.618840e+01 8.393520e+01 9.962590e+01
5.769710e+01 3.481870e+01 9.776040e+01 6.993000e+01 2.033300e+01
9.870440e+01 8.056280e+01 8.593580e+01 7.550730e+01 2.793700e+01
4.210170e+01 8.000503e+02 8.132996e+02 6.681563e+02 5.636469e+02
9.269298e+02 9.790616e+02 7.455859e+02 7.853846e+02 7.862292e+02
5.504670e+02 7.692834e+02 8.589748e+02 5.076710e+02 9.559443e+02
9.097429e+02 8.590861e+02 9.509583e+02 9.398402e+02 6.143140e+02
9.731805e+02 7.995247e+02 6.561693e+02 8.636200e+00 4.620000e+00
6.862800e+00 1.096980e+01 1.817470e+01 1.694600e+01 5.840500e+00
1.495000e+00 8.895400e+00 2.315700e+00 1.756570e+01 1.443950e+01
3.973460e+01 8.335010e+01 9.176690e+01 7.074750e+01 9.130400e+01
8.809220e+01 9.616430e+01 6.483110e+01 4.738400e+01 2.542580e+01
4.656100e+01 7.137254e+02 6.762387e+02 8.447753e+02 9.190479e+02
9.181106e+02 8.778388e+02 7.022164e+02 9.106199e+02 8.982864e+02
7.021514e+02 6.392467e+02 5.598434e+02 8.325289e+02 5.534047e+02
8.465935e+02 9.982412e+02 5.412038e+02 7.826042e+02 6.414489e+02
5.384890e+02 9.555171e+02 6.562830e+02 9.362197e+02 6.431645e+02
5.862642e+02 8.252511e+02 7.072778e+02 8.934979e+02 9.881290e+01
6.693540e+01 9.419360e+01 9.329950e+01 6.011070e+01 8.178930e+01
5.457070e+01 2.989130e+01 1.706120e+01 9.356400e+00 1.791440e+01
1.826270e+01 1.955600e+00 7.457300e+00 3.682300e+00 1.539610e+01
1.992940e+01 1.390880e+01 1.695730e+01 2.567600e+00 7.601800e+00
2.119300e+00 8.487800e+00 3.979200e+00 1.030390e+01 8.787500e+00
1.814080e+01 2.029000e+00 9.891300e+00 1.871430e+01 2.713600e+00
1.212420e+01 1.855630e+01 3.340000e-02 2.506000e-01 2.373000e-01
3.470000e-02 2.605000e-01 1.764000e-01 5.525779e+02 7.223422e+02
6.226007e+02 5.512582e+02 9.196593e+02 6.068054e+02 8.189436e+02
8.217141e+02 7.870434e+02 8.719709e+02 5.215972e+02 8.633409e+02
9.346907e+02 7.786270e+01 9.680080e+01 6.268290e+01 7.179430e+01
2.487400e+01 7.746190e+01 5.485450e+01 1.311000e-01 8.255000e-01
6.115000e+00 3.751100e+00 1.925120e+01 1.855540e+01 8.368500e+00
1.554880e+01 2.799600e+00 8.927300e+00 1.818290e+01 8.451600e+00
1.530760e+01 6.198200e+00 1.927280e+01 9.624400e+00 9.452000e-01
3.136000e-01 3.587000e-01 8.330000e-01 6.799000e-01 1.745081e+02
3.828823e+02 2.248239e+02 1.742886e+02 3.065220e+02 1.192568e+02
2.723676e+02 3.504470e+01 2.916000e-01 8.289000e-01 9.110000e-01
6.460000e-01 4.918000e-01 7.306000e-01 4.831000e-01 6.787000e-01
1.633000e-01 8.532000e-01 6.260000e-01 7.539900e+00 5.031400e+00
7.924100e+00 8.072800e+00 2.585300e+00 1.543740e+01 5.031370e+01
5.096601e+02 5.739052e+02 9.351724e+02 6.241254e+02 9.079681e+02
6.440509e+02 5.743970e+02 5.220818e+02 8.254075e+02 5.532900e+01
6.166620e+01 5.603900e+01 7.918580e+01 5.357350e+01 8.989570e+01
8.786960e+01 4.507800e+01 6.760940e+01 9.624430e+01 6.193880e+01
4.435470e+01 6.718650e+01 2.403590e+01 4.858240e+01 3.600000e-02
9.622000e-01 6.911000e-01 5.075000e-01 9.048000e-01 8.948000e-01
3.207000e-01 1.015000e-01 7.840000e-02 8.813000e-01 9.923000e-01
9.206000e-01 1.706000e-01 4.152000e-01 5.289219e+02 5.461179e+02
9.687099e+02 8.372683e+02 9.250586e+02 8.169490e+01 9.707620e+01
3.715720e+01 4.988750e+01 8.645870e+01 4.764720e+01 7.195340e+01
9.928890e+01 6.395920e+01 5.069450e+01 4.747640e+01 2.891260e+01
6.392000e-01 2.006000e-01 2.989000e-01 9.415000e-01 9.514000e-01
1.192000e-01 8.433000e-01 1.259000e-01 5.061000e-01 3.299000e-01
4.277000e-01 8.690000e-02 9.284070e+01 9.506170e+01 2.939690e+01
2.047180e+01 4.410150e+01 6.494270e+01 3.812870e+01 8.364030e+01
8.215960e+01 8.115920e+01 7.997560e+01 1.112140e+01 1.692500e+01
1.043950e+01 1.623680e+01 1.809730e+01 1.665790e+01 1.111600e+01
5.710000e-02 6.217000e-01 3.512000e-01 9.058000e-01 1.812000e-01
9.010000e-01 7.473000e-01 3.500000e-01 2.758000e-01 9.297457e+02
7.472554e+02 8.658759e+02 6.554756e+02 9.861875e+02 8.314070e+02
7.472529e+02 7.831816e+02 7.534412e+02 6.740524e+02 5.450044e+02
5.323538e+02 9.799125e+02 5.552132e+02 7.094402e+02 2.096190e+01
5.960040e+01 5.289520e+01 4.139860e+01 3.875740e+01 5.045750e+01
2.405370e+01 7.963350e+01 6.926510e+01 5.418030e+01 1.250480e+01
1.473770e+01 1.116410e+01 9.063400e+00 1.745860e+01 6.109500e+00
6.764400e+00 1.199900e+01 6.219600e+00 2.660700e+00 1.245240e+01
1.908870e+01 7.872300e+00 1.916510e+01 1.852360e+01 1.804440e+01
4.501600e+00 4.100800e+00 1.993080e+01 1.043830e+01 1.550620e+01
2.730650e+01 3.790364e+02 4.995957e+02 2.391900e+02 3.754240e+01
4.019516e+02 3.682595e+02 1.400424e+02 1.139920e+01 1.911800e+01
4.438900e+00 1.802310e+01 1.085920e+01 1.247980e+01 3.032490e+01
3.486240e+01 2.773860e+01 8.443210e+01 8.985590e+01 2.946180e+01
4.218550e+01 4.831240e+01 9.601570e+01 7.031660e+01 2.821590e+01
8.374780e+01 8.470000e-02 2.356000e-01 8.866000e-01 5.691000e-01
5.915000e-01 3.355000e-01 7.464000e-01 2.101940e+02 1.566854e+02
3.015045e+02 1.049475e+02 2.986597e+02 1.650847e+02 4.267773e+02
3.471421e+02 2.691598e+02 3.140700e+00 1.529790e+01 1.898260e+01
5.150500e+00 1.893900e+00 1.311800e+00 1.847080e+01 7.847800e+00
3.894400e+00 1.161420e+01 4.292900e+00 1.977340e+01 1.891450e+01
1.125000e+00 1.211430e+01 1.624820e+01 1.915300e+01 4.456600e+00
3.808200e+00 6.566500e+00 1.879830e+01 6.476300e+00 4.018600e+00
1.855910e+01 1.590300e+00 5.491690e+02 7.032129e+02 6.619758e+02
9.837734e+02 5.709899e+02 6.787145e+02 7.353895e+02 6.239078e+02
9.465972e+02 6.725285e+02 9.405856e+02 6.667349e+02 9.789313e+02
8.780981e+02 8.986198e+02 9.167819e+02 3.693997e+02 3.905278e+02
3.129095e+02 1.539433e+02 3.823693e+02 1.049452e+02 6.611070e+01
3.122027e+02 4.967832e+02 4.286442e+02 8.904920e+01 4.697773e+02
2.085293e+02 1.232596e+02 3.719976e+02 8.971830e+01 4.788272e+02
4.548210e+02 7.368540e+01 9.074042e+02 8.595211e+02 8.999980e+02
5.724507e+02 7.372502e+02 6.958818e+02 9.476288e+02 8.520172e+02
8.454602e+02 7.355391e+02 9.713585e+02 6.634134e+02 5.014053e+02
8.823000e-01 9.982000e-01 1.143340e+01 7.151500e+00 2.281700e+00
5.641100e+00 1.015250e+01 4.468000e+00 1.121800e+01 1.858990e+01
4.316000e-01 9.676000e-01 2.423000e-01 5.372000e-01 5.860000e-02
3.155000e-01 7.865000e-01 8.399000e-01 6.509000e-01 5.983000e-01
3.767000e-01 8.036000e-01 6.460000e-02 8.919070e+01 7.996110e+01
6.318610e+01 7.231810e+01 8.210380e+01 2.932260e+01 3.938230e+01
3.752590e+01 6.339670e+01 2.771290e+01 2.980230e+01 9.671586e+02
9.304909e+02 8.275388e+02 6.742039e+02 6.452677e+02 9.271449e+02
5.213193e+02 9.906512e+02 5.157437e+02 5.035541e+02 8.654402e+02
9.568268e+02 5.456811e+02 5.519838e+02 6.753847e+02 9.032283e+02
7.661391e+02 5.833516e+02 8.149756e+02 5.133809e+02 7.408919e+02
6.959777e+02 6.651258e+02 7.925868e+02 5.351783e+02 5.443343e+02
5.925878e+02 5.366760e+02 6.844524e+02 8.077961e+02 9.187042e+02
8.007554e+02 6.631325e+02 6.593901e+02 8.881572e+02 8.679597e+02
8.533522e+02 7.345458e+02 6.377191e+02 7.182006e+02 5.137100e+02
5.998449e+02 6.650017e+02 9.969172e+02 7.480188e+02 7.217714e+02
7.972070e+02 9.677000e-01 9.482000e-01 8.711000e-01 3.204000e-01
3.343500e+00 1.590800e+01 1.671130e+01 6.534400e+00 8.029000e+00
4.524360e+01 3.655586e+02 1.170251e+02 1.512191e+02 1.664517e+02
1.479847e+02 2.950639e+02 4.425796e+02 1.101701e+02 4.365779e+02
1.004290e+01 8.767900e+00 9.847800e+00 6.625300e+00 9.487000e+00
9.313500e+00 1.052920e+01 8.765800e+00 1.140590e+01 4.521900e+00
1.197640e+01 7.698600e+00 7.404400e+00 1.527280e+01 9.347500e+00
1.167700e+01 1.845940e+01 1.670830e+01 5.204100e+00 5.262310e+01
7.045320e+01 5.071920e+01 3.083450e+01 9.079980e+01 7.845260e+01
4.901280e+01 3.267560e+01 4.400130e+01 2.685120e+01 4.862210e+01
7.752530e+01 9.666480e+01 8.866070e+01 4.457040e+01 5.085600e+01
8.814970e+01 4.696500e+00 4.396900e+00 1.152410e+01 7.587500e+00
1.831790e+01 1.351290e+01 3.543500e+00 1.753690e+01 4.502300e+00
1.691460e+01 5.521100e+00 1.238840e+01 5.453500e+00 1.809580e+01
1.749490e+01 3.790500e+00 1.309400e+00 1.637550e+01 1.246880e+01
5.748400e+00 1.820520e+01 1.996030e+01 6.474800e+00 9.685900e+00
8.335500e+00 2.007100e+00 1.463590e+01 1.650850e+01 1.501730e+01
8.685500e+00 7.228300e+00 1.166550e+01 1.475180e+01 1.240400e+00
1.774420e+01 1.621270e+01 6.287500e+00 2.054000e+00 3.953900e+00
4.874900e+00 4.682400e+00 1.270910e+01 1.296860e+01 1.410830e+01
1.636650e+01 8.051000e+00 1.747000e-01 1.147000e-01 6.953000e-01
6.250300e+00 1.493720e+01 1.914550e+01 7.558200e+00 5.865300e+00
1.380100e+00 1.081500e+00 1.734860e+01 1.790430e+01 4.731200e+00
1.977800e+00 1.311940e+01 2.795160e+01 6.523450e+01 6.583370e+01
6.935056e+02 7.508029e+02 9.108607e+02 5.539916e+02 9.637279e+02
6.817706e+02 6.456551e+02 6.638174e+02 6.577520e+02 9.759457e+02
9.592768e+02 8.125668e+02 7.119716e+02 9.529004e+02 8.181488e+02
7.209353e+02 5.525266e+02 5.391407e+02 7.878152e+02 5.759270e+02
7.024850e+01 9.789700e+01 6.027060e+01 5.993670e+01 2.934920e+01
3.482730e+01 4.077010e+01 2.285430e+01 9.896690e+01 8.360950e+01
4.024112e+02 2.209388e+02 3.079902e+02 9.996100e+01 6.872740e+01
5.465000e-01 6.203000e-01 1.712000e-01 1.870000e-01 5.994000e-01
6.119000e-01 6.694000e-01 4.350000e-01 8.743000e-01 3.181000e-01
9.670000e-02 1.236000e-01 5.244000e-01 1.769000e-01 7.646000e-01
7.183000e-01 1.341000e-01 5.430000e-01 1.409000e-01 8.232000e-01
1.580000e-01 1.274000e-01 2.779000e-01 6.143000e-01 3.208353e+02
2.851541e+02 3.718524e+02 3.613364e+02 3.777106e+02 4.083400e+02
1.891340e+02 2.758667e+02 2.468433e+02 1.072281e+02 9.034440e+01
1.762594e+02 2.729677e+02 1.304835e+02 1.831570e+02 1.405251e+02
2.720092e+02 4.557747e+02 1.870621e+02 3.663031e+02 3.123349e+02
7.102460e+01 2.146160e+02 4.521119e+02 2.063950e+01 5.909450e+01
9.156930e+01 7.142420e+01 6.159780e+01 4.210230e+01 2.900350e+01
5.363360e+01 9.079070e+01 8.467020e+01 4.128290e+01 5.610560e+01
4.571690e+01 5.216800e+01 7.848600e+00 1.442220e+01 1.489010e+01
8.899000e-01 9.090000e-01 3.297000e-01 4.383000e-01 9.113000e-01
5.500000e-03 8.187000e-01 1.925000e-01 5.123000e-01 4.967000e-01
7.366000e-01 5.544000e-01 4.661000e-01 3.488837e+02 1.091616e+02
4.604566e+02 1.529478e+02 1.697717e+02 5.237100e+01 3.825801e+02
2.730123e+02 3.423101e+02 2.768210e+02 2.052621e+02 5.246000e-01
7.062000e-01 4.211000e-01 9.994000e-01 3.941000e-01 1.536000e-01
6.073000e-01 7.967000e-01 4.491000e-01 4.690000e-02 7.862000e-01
9.758000e-01 1.613000e-01 3.330000e-02 9.171000e-01 3.836000e-01
2.740000e-01 2.041000e-01 3.259000e-01 9.019000e-01 9.906000e-01
6.355700e+00 1.790440e+01 1.318870e+01 4.111600e+00 1.639740e+01
5.385100e+00 3.365000e+00 1.010030e+01 7.424100e+00 1.805180e+01
9.999800e+00 1.325210e+01 1.256390e+01 1.154340e+01 1.240330e+01
1.202090e+01 1.519950e+01 4.269500e+00 8.421600e+00 1.241230e+01
9.531200e+00 4.972400e+00 1.799970e+01 1.254620e+01 4.139000e+00
1.629010e+01 1.074340e+01 6.219200e+00 6.545400e+00 1.931850e+01
4.482500e+00 5.467200e+00 7.777800e+00 1.517420e+01 1.183250e+01
6.127900e+00 4.930900e+00 9.556600e+00 5.757900e+00 1.040320e+01
4.729300e+00 1.631070e+01 1.813420e+01 1.142180e+01 8.090100e+00
3.989500e+00 1.031060e+01 1.580160e+01 1.368520e+01 1.341650e+01
9.672200e+00 9.212300e+00 2.503700e+00 9.248100e+00 1.820310e+01
9.223020e+01 2.274500e+01 6.078160e+01 8.389020e+01 8.765400e+01
3.798900e+01 9.430350e+01 6.226640e+01 3.493520e+01 8.099350e+01
9.884720e+01 5.533110e+01 8.777390e+01 8.817330e+01 3.535000e-01
5.080000e-02 7.359000e-01 5.464000e-01 1.603000e-01 6.802000e-01
6.859000e-01 6.802000e-01 9.276000e-01 4.118000e-01 3.931000e-01
8.118000e-01 1.070190e+01 1.268800e+00 7.686900e+00 4.003200e+00
1.581400e+00 1.784630e+01 1.613680e+01 1.112380e+01 1.649370e+01
9.961124e+02 8.171333e+02 6.418367e+02 6.683672e+02 8.986476e+02
6.923024e+02 6.150169e+02 5.735157e+02 6.043514e+02 5.586876e+02
6.009000e-01 8.177000e-01 5.117000e-01 3.902000e-01 9.705000e-01
8.755000e-01 3.058000e-01 1.838000e-01 2.001000e-01 7.416000e-01
4.439000e-01 8.419000e-01 3.689000e-01 8.336342e+02 9.848239e+02
5.048399e+02 8.588350e+02 8.367659e+02 5.277287e+02 2.159608e+02
2.077528e+02 2.567273e+02 3.115080e+01 2.135357e+02 3.300166e+02
2.618555e+02 7.188820e+01 4.037247e+02 7.212400e+00 1.228210e+01
1.983500e+01 1.325630e+01 1.615350e+01 6.864500e+00 8.622600e+00
3.582300e+00 8.506000e-01 5.470000e-01 9.595000e-01 7.955000e-01
3.693000e-01 6.270000e-01 2.935000e-01 6.162000e-01 9.567000e-01
1.999000e-01 7.183000e-01 3.904000e-01 8.784000e-01 1.837000e-01
1.811000e-01 6.471000e-01 9.940000e-01 7.030000e-01 1.905000e-01
3.439820e+01 3.489760e+01 3.721470e+01 8.547170e+01 4.684720e+01
7.432510e+01 6.374050e+01 7.887280e+01 9.833460e+01 5.800930e+01
2.278330e+01 6.132730e+01 9.767290e+01 7.333660e+01 9.374120e+01
5.268270e+01 4.859600e+01 8.636560e+01 9.843420e+01 9.895840e+01
2.476010e+01 1.449620e+01 4.824800e+00 1.699450e+01 1.162640e+01
1.836620e+01 1.012370e+01 6.036600e+00 1.217300e+01 1.223930e+01
6.807700e+00 1.883090e+01 1.645790e+01 3.417600e+00 9.484700e+00
1.279520e+01 1.102520e+01 1.670040e+01 1.315070e+01 8.684540e+01
4.668560e+01 6.819550e+01 4.211140e+01 6.467210e+01 8.669630e+01
7.320660e+01 2.735010e+01 9.236650e+01 4.535250e+01 3.657350e+01
8.807210e+01 8.532290e+01 5.568510e+01 2.740150e+01 2.289420e+01
8.010740e+01 9.564710e+01 6.346770e+01 6.285530e+01 4.945800e+01
4.311310e+01 8.622100e+01 4.641610e+01 3.728480e+01 5.087990e+01
9.578230e+01 3.445910e+01 5.366940e+01 4.166600e+01 4.594430e+01
4.528890e+01 3.740000e-01 7.891000e-01 4.902000e-01 1.213000e-01
4.168000e-01 2.855000e-01 1.149952e+02 8.977760e+01 2.339588e+02
3.552959e+02 1.224970e+01 4.133074e+02 4.847619e+02 3.960113e+02
4.564395e+02 4.229421e+02 3.821592e+02 4.964773e+02 2.786380e+01
1.785953e+02 4.129442e+02 4.888310e+01 3.387280e+01 4.437940e+02
3.690862e+02 4.771559e+02 1.651176e+02 7.006700e+00 1.984870e+01
1.549850e+01 2.633500e+00 7.222000e+00 1.055400e+01 8.106700e+00
9.543000e+00 8.188200e+00 2.811700e+00 1.679300e+01 1.699980e+01
9.954900e+00 1.812320e+01 1.439320e+01 2.083800e+00 5.053700e+00
1.274110e+01 1.521250e+01 1.154790e+01 3.141800e+00 1.674680e+01
7.338600e+00 1.813040e+01 1.315300e+00 9.363400e+00 1.795380e+01
4.867400e+00 1.142100e+01 3.268200e+00 7.647600e+00 1.140530e+01
1.136920e+01 1.490480e+01 1.172950e+01 9.313400e+00 1.044630e+01
1.579630e+01 1.554070e+01 5.396400e+00 9.804000e-01 8.347000e-01
9.878000e-01 5.797000e-01 1.002000e-01 9.845000e-01 5.138000e-01
8.610000e-01 9.220000e-01 2.627000e-01 3.066000e-01 6.232000e-01
9.174000e-01 8.710000e-02 4.499000e-01 5.080723e+02 6.968469e+02
8.497282e+02 6.683080e+01 3.871930e+01 9.483480e+01 6.840300e+01
4.804880e+01 9.591580e+01 8.727110e+01 2.034420e+01 8.515040e+01
8.004770e+01 6.477980e+01 3.875160e+01 9.329050e+01 6.664130e+01
3.044560e+01 3.645590e+01 9.223360e+01 3.458190e+01 1.908590e+02
8.032970e+01 1.165408e+02 2.430340e+02 2.241612e+02 2.476543e+02
1.585423e+02 3.947287e+02 3.195416e+02 2.715688e+02 2.770910e+02
4.954243e+02 9.248610e+01 3.628963e+02 4.592500e+01 5.943979e+02
7.297025e+02 6.479113e+02 7.087760e+02 5.040027e+02 5.266553e+02
5.295231e+02 6.271413e+02 5.711511e+02 5.036870e+02 8.684793e+02
4.446296e+02 5.447110e+01 2.631990e+01 6.731440e+01 2.130350e+01
4.430090e+01 9.313310e+01 5.525880e+01 8.350960e+01 3.950380e+01
6.842540e+02 8.519227e+02 8.213070e+02 9.397925e+02 5.594230e+01
3.227130e+01 9.398020e+01 5.397360e+01 1.849060e+01 5.573600e+00
7.708900e+00 1.743620e+01 1.032460e+01 6.383900e+00 4.392600e+00
3.787800e+00 1.003200e+00 1.339930e+01 8.174700e+00 7.898800e+00
1.255850e+01 1.925690e+01 1.695690e+01 1.890860e+01 1.965270e+01
5.739100e+00 1.155230e+01 1.688330e+01 1.014030e+01 4.336500e+00
8.420010e+01 7.633040e+01 4.791890e+01 3.604190e+01 4.680160e+01
2.842620e+01 9.179250e+01 8.212020e+01 6.558840e+01 7.462320e+01
7.560810e+01 6.276540e+01 8.196060e+01 4.817710e+01 8.041430e+01
5.775670e+01 4.036520e+01 5.914030e+01 7.780650e+01 3.116980e+01
6.329620e+01 2.936220e+01 2.492710e+01 8.637770e+01 6.629440e+01
2.748900e+01 6.216578e+02 8.815621e+02 9.559203e+02 6.497747e+02
9.666068e+02 6.384572e+02 9.368089e+02 9.126683e+02 5.892847e+02
2.095080e+01 8.180230e+01 3.271480e+01 6.768050e+01 2.800300e+01
2.641410e+01 4.986140e+01 6.471860e+01 4.816710e+01 6.950000e+01
4.509720e+01 5.082340e+01 5.559720e+01 7.988200e+01 8.284980e+01
6.196550e+01 2.874410e+01 6.442910e+01 7.934360e+01 7.966210e+01
4.535560e+01 2.305690e+01 5.759970e+01 4.597750e+01 5.747640e+01
1.000000e-03 9.436000e-01 2.400000e-03 1.580000e-02 2.650000e-02
1.810000e-01 9.792310e+01 8.543770e+01 7.301460e+01 3.322180e+01
7.056200e+01 7.775640e+01 7.163840e+01 4.740670e+01 8.998730e+01
2.125570e+01 8.186730e+01 4.644820e+01 7.089510e+01 7.053410e+01
8.788960e+01 8.881220e+01 8.571570e+01 2.667420e+01 6.912790e+01
7.694840e+01 3.774125e+02 2.984794e+02 1.547556e+02 1.731793e+02
2.156930e+02 4.606700e+02 2.430335e+02 3.108780e+02 3.814086e+02
4.008700e+00 3.632487e+02 2.796491e+02 2.910099e+02 3.221187e+02
7.565040e+01 4.020711e+02 3.135750e+01 1.743459e+02 1.265232e+02
1.320701e+02 3.909721e+02 2.170093e+02 4.794367e+02 8.616980e+01
3.912849e+02 3.464990e+01 3.464958e+02 8.804140e+01 4.913810e+01
7.259490e+01 6.486560e+01 7.867930e+01 5.971530e+01 7.413730e+01
3.573680e+01 9.143590e+01 8.390020e+01 9.000980e+01 9.394060e+01
3.360500e+01 7.920140e+01 2.262320e+01 7.647790e+01 8.146470e+01
2.086170e+01 8.087280e+01 7.558370e+01 3.527730e+01 5.685840e+01
5.513820e+01 3.372750e+01 4.393800e+00 1.689500e+00 3.917300e+00
1.017060e+01 1.328660e+01 1.464260e+01 1.303100e+01 1.956750e+01
1.283300e+01 9.705800e+00 4.584200e+00 1.895430e+01 4.505400e+00
3.246500e+00 6.492000e-01 5.539000e-01 3.972000e-01 4.069000e-01
2.994000e-01 7.859000e-01 2.494000e-01 8.147000e-01 8.171000e-01
5.000000e+02 6.969910e+02 9.906108e+02 5.312515e+02 9.491307e+02
9.989154e+02 6.765117e+02 7.689616e+02 7.588500e+00 8.443600e+00
8.662630e+01 3.287030e+01 7.655060e+01 4.386060e+01 3.877180e+01
6.039210e+01 9.337100e+01 7.818872e+02 8.966949e+02 8.056482e+02
5.903506e+02 9.231628e+02 9.261812e+02 8.383217e+02 8.264461e+02
3.485304e+02 2.246142e+02 1.298528e+02 4.356608e+02 3.614165e+02
2.443892e+02 3.140622e+02 1.349121e+02 6.708000e+00 2.363923e+02
3.206070e+02 2.029255e+02 3.948556e+02 3.746730e+02 8.480300e+00
1.163070e+01 1.955170e+01 1.770740e+01 1.547910e+01 8.550000e-01
2.503000e-01 8.446000e-01 3.060000e-02 7.860000e-01 6.188000e-01
4.986000e-01 7.301000e-01 4.234000e-01 9.833000e-01 8.010000e-01
5.230000e-02 2.890000e-01 2.440000e-01 9.900000e-03 5.264000e-01
4.540000e-02 9.840000e-01 3.629000e-01 7.156000e-01 1.815000e-01
1.663000e-01 7.718000e-01 8.992000e-01 7.011000e-01 8.090000e-01
5.063000e-01 7.623000e-01 8.111000e-01 6.848000e-01 8.802000e-01
8.280000e-02 6.073000e-01 1.998270e+01 1.891070e+01 8.912400e+00
1.546830e+01 2.589600e+00 4.095700e+00 1.603810e+01 5.034400e+00
2.530200e+00 3.252300e+00 8.370500e+00 1.713300e+01 7.048890e+01
3.464520e+01 3.835920e+01 3.609120e+01 6.506500e+01 3.707900e+01
8.961540e+01 2.999440e+01 6.632730e+01 3.901500e+01 2.654400e+01
(modules/porous_flow/examples/reservoir_model/spe10_case1.data)

A PiecewiseMultilinear function is used to interpolate the permeability to the mesh.

[Functions<<<{"href": "../../syntax/Functions/index.html"}>>>]
  [perm_md_fcn]
    type = PiecewiseMultilinear<<<{"description": "PiecewiseMultilinear performs linear interpolation on 1D, 2D, 3D or 4D data.  The data_file specifies the axes directions and the function values.  If a point lies outside the data range, the appropriate end value is used.", "href": "../../source/functions/PiecewiseMultilinear.html"}>>>
    data_file<<<{"description": "File holding data for use with PiecewiseMultiInterpolation.  Format: any empty line and any line beginning with # are ignored, all other lines are assumed to contain relevant information.  The file must begin with specification of the grid.  This is done through lines containing the keywords: AXIS X; AXIS Y; AXIS Z; or AXIS T.  Immediately following the keyword line must be a space-separated line of real numbers which define the grid along the specified axis.  These data must be monotonically increasing.  After all the axes and their grids have been specified, there must be a line that is DATA.  Following that line, function values are given in the correct order (they may be on individual lines, or be space-separated on a number of lines).  When the function is evaluated, f[i,j,k,l] corresponds to the i + j*Ni + k*Ni*Nj + l*Ni*Nj*Nk data value.  Here i>=0 corresponding to the index along the first AXIS, j>=0 corresponding to the index along the second AXIS, etc, and Ni = number of grid points along the first AXIS, etc."}>>> = spe10_case1.data
  []
[]
(modules/porous_flow/examples/reservoir_model/regular_grid.i)

Constant Monomial AuxVariables are used to store the permeability read from the data file:

[AuxVariables<<<{"href": "../../syntax/AuxVariables/index.html"}>>>]
  [temperature]
    initial_condition<<<{"description": "Specifies a constant initial condition for this variable"}>>> = 50
  []
  [xnacl]
    initial_condition<<<{"description": "Specifies a constant initial condition for this variable"}>>> = 0.1
  []
  [porosity]
    family<<<{"description": "Specifies the family of FE shape functions to use for this variable"}>>> = MONOMIAL
    order<<<{"description": "Specifies the order of the FE shape function to use for this variable (additional orders not listed are allowed)"}>>> = CONSTANT
    initial_condition<<<{"description": "Specifies a constant initial condition for this variable"}>>> = 0.2
  []
  [perm_md]
    family<<<{"description": "Specifies the family of FE shape functions to use for this variable"}>>> = MONOMIAL
    order<<<{"description": "Specifies the order of the FE shape function to use for this variable (additional orders not listed are allowed)"}>>> = CONSTANT
  []
  [perm]
    family<<<{"description": "Specifies the family of FE shape functions to use for this variable"}>>> = MONOMIAL
    order<<<{"description": "Specifies the order of the FE shape function to use for this variable (additional orders not listed are allowed)"}>>> = CONSTANT
  []
[]
(modules/porous_flow/examples/reservoir_model/regular_grid.i)

A FunctionAux AuxKernel is used to populate the AuxVariables.

In this example, the permeability in the data file is in millidarcys. As PorousFlow expects permeability in SI units of m, we multiply each permeability value by and save these values in a new AuxVariable:

[AuxKernels<<<{"href": "../../syntax/AuxKernels/index.html"}>>>]
  [perm_md]
    type = FunctionAux<<<{"description": "Auxiliary Kernel that creates and updates a field variable by sampling a function through space and time.", "href": "../../source/auxkernels/FunctionAux.html"}>>>
    function<<<{"description": "The function to use as the value"}>>> = perm_md_fcn
    variable<<<{"description": "The name of the variable that this object applies to"}>>> = perm_md
    execute_on<<<{"description": "The list of flag(s) indicating when this object should be executed. For a description of each flag, see https://mooseframework.inl.gov/source/interfaces/SetupInterface.html."}>>> = initial
  []
  [perm]
    type = ParsedAux<<<{"description": "Sets a field variable value to the evaluation of a parsed expression.", "href": "../../source/auxkernels/ParsedAux.html"}>>>
    variable<<<{"description": "The name of the variable that this object applies to"}>>> = perm
    coupled_variables<<<{"description": "Vector of coupled variable names"}>>> = perm_md
    expression<<<{"description": "Parsed function expression to compute"}>>> = '9.869233e-16*perm_md'
    execute_on<<<{"description": "The list of flag(s) indicating when this object should be executed. For a description of each flag, see https://mooseframework.inl.gov/source/interfaces/SetupInterface.html."}>>> = initial
  []
[]
(modules/porous_flow/examples/reservoir_model/regular_grid.i)

As this interpolation and multiplication is only required at the beginning of the simulation, we set the execute_on parameter to initial only.

Finally, the heterogeneous permeability (in m) can be used in the calculation using a PorousFlowPermeabilityConstFromVar material.

[Materials<<<{"href": "../../syntax/Materials/index.html"}>>>]
  [permeability]
    type = PorousFlowPermeabilityConstFromVar<<<{"description": "This Material calculates the permeability tensor given by the input variables", "href": "../../source/materials/PorousFlowPermeabilityConstFromVar.html"}>>>
    perm_xx<<<{"description": "The xx component of the permeability tensor"}>>> = perm
    perm_yy<<<{"description": "The yy component of the permeability tensor"}>>> = perm
    perm_zz<<<{"description": "The zz component of the permeability tensor"}>>> = perm
  []
[]
(modules/porous_flow/examples/reservoir_model/regular_grid.i)

The above steps create the following heterogeneous model that can then be used in a simulation:

Figure 1: Heterogeneous permeability for SPE comparative problem case 1

Although this example is for a two-dimensional mesh, the procedure for producing a three-dimensional mesh is identical.

Reservoir models

Often geological models are created using a modelling package to create realistic interpretations of the geology. In this case, some pre-processing of the geological model is often required before it can be used in PorousFlow.

This pre-processing must be performed using software that can take a geological model and convert it into a form that PorousFlow can read. One example of a pre-processing code that may be used is em2ex. This code converts a reservoir model in either Eclipse format or cell centered csv format to an Exodus mesh that can used in PorousFlow.

The following example shows how to use an Exodus mesh created from a reservoir model in a PorousFlow simulation. For this example, we use publicly available data from the SAIGUP project to construct the heterogeneous reservoir model shown in Figure 2 using em2ex.

Figure 2: Heterogeneous permeability for SAIGUP model

The heterogeneous porosity and permeability can then be read from the grid and used in the calculations using the following steps:

First, the mesh (containing the heterogeneous reservoir properties) is read into PorousFlow:

[Mesh<<<{"href": "../../syntax/Mesh/index.html"}>>>]
  type = FileMesh
  file = field.e
[]
(modules/porous_flow/examples/reservoir_model/field_model.i)

Constant monomial AuxVariables are then created. As the reservoir model again contains permeability in millidarcys, additional AuxVariables are also declared to hold the permeability in SI units (m).

The values of the AuxVariables for porosity and the components of permeability in millidarcys are set using the initial_from_file_var parameter. These AuxVariables are not modified throughout the simulation, so represent the initial heterogeneity of the model.

[AuxVariables<<<{"href": "../../syntax/AuxVariables/index.html"}>>>]
  [temperature]
    initial_condition<<<{"description": "Specifies a constant initial condition for this variable"}>>> = 50
  []
  [xnacl]
    initial_condition<<<{"description": "Specifies a constant initial condition for this variable"}>>> = 0.1
  []
  [porosity]
    family<<<{"description": "Specifies the family of FE shape functions to use for this variable"}>>> = MONOMIAL
    order<<<{"description": "Specifies the order of the FE shape function to use for this variable (additional orders not listed are allowed)"}>>> = CONSTANT
    initial_from_file_var<<<{"description": "Gives the name of a variable for which to read an initial condition from a mesh file"}>>> = poro
  []
  [permx_md]
    family<<<{"description": "Specifies the family of FE shape functions to use for this variable"}>>> = MONOMIAL
    order<<<{"description": "Specifies the order of the FE shape function to use for this variable (additional orders not listed are allowed)"}>>> = CONSTANT
    initial_from_file_var<<<{"description": "Gives the name of a variable for which to read an initial condition from a mesh file"}>>> = permX
  []
  [permy_md]
    family<<<{"description": "Specifies the family of FE shape functions to use for this variable"}>>> = MONOMIAL
    order<<<{"description": "Specifies the order of the FE shape function to use for this variable (additional orders not listed are allowed)"}>>> = CONSTANT
    initial_from_file_var<<<{"description": "Gives the name of a variable for which to read an initial condition from a mesh file"}>>> = permY
  []
  [permz_md]
    family<<<{"description": "Specifies the family of FE shape functions to use for this variable"}>>> = MONOMIAL
    order<<<{"description": "Specifies the order of the FE shape function to use for this variable (additional orders not listed are allowed)"}>>> = CONSTANT
    initial_from_file_var<<<{"description": "Gives the name of a variable for which to read an initial condition from a mesh file"}>>> = permZ
  []
  [permx]
    family<<<{"description": "Specifies the family of FE shape functions to use for this variable"}>>> = MONOMIAL
    order<<<{"description": "Specifies the order of the FE shape function to use for this variable (additional orders not listed are allowed)"}>>> = CONSTANT
  []
  [permy]
    family<<<{"description": "Specifies the family of FE shape functions to use for this variable"}>>> = MONOMIAL
    order<<<{"description": "Specifies the order of the FE shape function to use for this variable (additional orders not listed are allowed)"}>>> = CONSTANT
  []
  [permz]
    family<<<{"description": "Specifies the family of FE shape functions to use for this variable"}>>> = MONOMIAL
    order<<<{"description": "Specifies the order of the FE shape function to use for this variable (additional orders not listed are allowed)"}>>> = CONSTANT
  []
[]
(modules/porous_flow/examples/reservoir_model/field_model.i)

Like the previous example, the permeability can be converted to SI units using a ParsedAux AuxKernel for each component.

[AuxKernels<<<{"href": "../../syntax/AuxKernels/index.html"}>>>]
  [permx]
    type = ParsedAux<<<{"description": "Sets a field variable value to the evaluation of a parsed expression.", "href": "../../source/auxkernels/ParsedAux.html"}>>>
    variable<<<{"description": "The name of the variable that this object applies to"}>>> = permx
    coupled_variables<<<{"description": "Vector of coupled variable names"}>>> = permx_md
    expression<<<{"description": "Parsed function expression to compute"}>>> = '9.869233e-16*permx_md'
    execute_on<<<{"description": "The list of flag(s) indicating when this object should be executed. For a description of each flag, see https://mooseframework.inl.gov/source/interfaces/SetupInterface.html."}>>> = initial
  []
  [permy]
    type = ParsedAux<<<{"description": "Sets a field variable value to the evaluation of a parsed expression.", "href": "../../source/auxkernels/ParsedAux.html"}>>>
    variable<<<{"description": "The name of the variable that this object applies to"}>>> = permy
    coupled_variables<<<{"description": "Vector of coupled variable names"}>>> = permy_md
    expression<<<{"description": "Parsed function expression to compute"}>>> = '9.869233e-16*permy_md'
    execute_on<<<{"description": "The list of flag(s) indicating when this object should be executed. For a description of each flag, see https://mooseframework.inl.gov/source/interfaces/SetupInterface.html."}>>> = initial
  []
  [permz]
    type = ParsedAux<<<{"description": "Sets a field variable value to the evaluation of a parsed expression.", "href": "../../source/auxkernels/ParsedAux.html"}>>>
    variable<<<{"description": "The name of the variable that this object applies to"}>>> = permz
    coupled_variables<<<{"description": "Vector of coupled variable names"}>>> = permz_md
    expression<<<{"description": "Parsed function expression to compute"}>>> = '9.869233e-16*permz_md'
    execute_on<<<{"description": "The list of flag(s) indicating when this object should be executed. For a description of each flag, see https://mooseframework.inl.gov/source/interfaces/SetupInterface.html."}>>> = initial
  []
[]
(modules/porous_flow/examples/reservoir_model/field_model.i)

The heterogeneous porosity and permeabilities can then be used in the calculations:

[Materials<<<{"href": "../../syntax/Materials/index.html"}>>>]
  [porosity]
    type = PorousFlowPorosityConst<<<{"description": "This Material calculates the porosity assuming it is constant", "href": "../../source/materials/PorousFlowPorosityConst.html"}>>>
    porosity<<<{"description": "The porosity (assumed indepenent of porepressure, temperature, strain, etc, for this material).  This should be a real number, or a constant monomial variable (not a linear lagrange or other kind of variable)."}>>> = porosity
  []
[]
(modules/porous_flow/examples/reservoir_model/field_model.i)
[Materials<<<{"href": "../../syntax/Materials/index.html"}>>>]
  [permeability]
    type = PorousFlowPermeabilityConstFromVar<<<{"description": "This Material calculates the permeability tensor given by the input variables", "href": "../../source/materials/PorousFlowPermeabilityConstFromVar.html"}>>>
    perm_xx<<<{"description": "The xx component of the permeability tensor"}>>> = permx
    perm_yy<<<{"description": "The yy component of the permeability tensor"}>>> = permy
    perm_zz<<<{"description": "The zz component of the permeability tensor"}>>> = permz
  []
[]
(modules/porous_flow/examples/reservoir_model/field_model.i)

Using this process, complex geological models with heterogeneous reservoir properties can be used in PorousFlow.