-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathfrect1.i
More file actions
370 lines (352 loc) · 7.52 KB
/
frect1.i
File metadata and controls
370 lines (352 loc) · 7.52 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
# Cold water injection into one side of the fracture network, and production from the other side
injection_rate = 0.1 #25 # kg/s
endTime = 3.16e8
[Mesh]
uniform_refine = 0
[single_frac]
type = FileMeshGenerator
file = 'rect_100_10_medium.e'
[]
[injection_node]
type = BoundingBoxNodeSetGenerator
input = single_frac
bottom_left = '-5 -55 -5'
top_right = '5 -45 5'
new_boundary = injection_node
[]
[]
[GlobalParams]
PorousFlowDictator = dictator
gravity = '0 0 -9.81'
[]
[Variables]
[frac_P]
[]
[frac_T]
[]
[]
[ICs]
[frac_P]
type = FunctionIC
variable = frac_P
function = insitu_pp
[]
[frac_T]
type = FunctionIC
variable = frac_T
function = insitu_T
[]
[]
[PorousFlowFullySaturated]
coupling_type = ThermoHydro
porepressure = frac_P
temperature = frac_T
fp = true_water
pressure_unit = Pa
[]
[Kernels]
[toMatrix]
type = PorousFlowHeatMassTransfer
variable = frac_T
v = transferred_matrix_T
transfer_coefficient = heat_transfer_coefficient
save_in = joules_per_s
[]
[]
[AuxVariables]
[transferred_matrix_T]
initial_condition = 363
[]
[heat_transfer_coefficient]
family = MONOMIAL
order = CONSTANT
initial_condition = 0.0
[]
[joules_per_s]
[]
[aperture]
family = MONOMIAL
order = CONSTANT
[]
[perm_times_app]
family = MONOMIAL
order = CONSTANT
[]
[density]
family = MONOMIAL
order = CONSTANT
[]
[viscosity]
family = MONOMIAL
order = CONSTANT
[]
[insitu_pp]
[]
[normal_dirn_x]
family = MONOMIAL
order = CONSTANT
[]
[normal_dirn_y]
family = MONOMIAL
order = CONSTANT
[]
[normal_dirn_z]
family = MONOMIAL
order = CONSTANT
[]
[enclosing_element_normal_length]
family = MONOMIAL
order = CONSTANT
[]
[enclosing_element_normal_thermal_cond]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[normal_dirn_x_auxk]
type = PorousFlowElementNormal
variable = normal_dirn_x
component = x
[]
[normal_dirn_y]
type = PorousFlowElementNormal
variable = normal_dirn_y
component = y
[]
[normal_dirn_z]
type = PorousFlowElementNormal
variable = normal_dirn_z
component = z
[]
[heat_transfer_coefficient_auxk]
type = ParsedAux
variable = heat_transfer_coefficient
coupled_variables = 'enclosing_element_normal_length enclosing_element_normal_thermal_cond'
constant_names = h_s
constant_expressions = 1E3 #This is the value being assigned to h_s. Should be much bigger than thermal_conductivity / L ~ 1
expression = 'if(enclosing_element_normal_length = 0, 0, h_s * enclosing_element_normal_thermal_cond * 2 * enclosing_element_normal_length / (h_s * enclosing_element_normal_length * enclosing_element_normal_length + enclosing_element_normal_thermal_cond * 2 * enclosing_element_normal_length))'
[]
[insitu_pp]
type = FunctionAux
execute_on = initial
variable = insitu_pp
function = insitu_pp
[]
[aperture]
type = PorousFlowPropertyAux
variable = aperture
property = porosity
[]
[perm_times_app]
type = PorousFlowPropertyAux
variable = perm_times_app
property = permeability
row = 0
column = 0
[]
[density]
type = PorousFlowPropertyAux
variable = density
property = density
phase = 0
[]
[viscosity]
type = PorousFlowPropertyAux
variable = viscosity
property = viscosity
phase = 0
[]
[]
[BCs]
[inject_heat]
type = DirichletBC
boundary = injection_node
variable = frac_T
value = 303
[]
[]
[DiracKernels]
[inject_fluid]
type = PorousFlowPointSourceFromPostprocessor
mass_flux = ${injection_rate}
point = '0 -50 0'
variable = frac_P
[]
[withdraw_fluid]
type = PorousFlowPeacemanBorehole
SumQuantityUO = kg_out_uo
bottom_p_or_t = 30.6e6
character = 1
line_length = 1
point_file = production_single_fracture.xyz
unit_weight = '0 0 0'
fluid_phase = 0
use_mobility = true
variable = frac_P
[]
[withdraw_heat]
type = PorousFlowPeacemanBorehole
SumQuantityUO = J_out_uo
bottom_p_or_t = 30.6e6
character = 1
line_length = 1
point_file = production_single_fracture.xyz
unit_weight = '0 0 0'
fluid_phase = 0
use_mobility = true
use_enthalpy = true
variable = frac_T
[]
[]
[UserObjects]
[kg_out_uo]
type = PorousFlowSumQuantity
[]
[J_out_uo]
type = PorousFlowSumQuantity
[]
[]
[FluidProperties]
[true_water]
type = Water97FluidProperties
[]
# [water]
# type = TabulatedFluidProperties
# fp = true_water
# temperature_min = 275 # K
# temperature_max = 600
# interpolated_properties = 'density viscosity enthalpy internal_energy'
# fluid_property_file = water97_tabulated.csv
# []
[]
[Materials]
[porosity]
type = PorousFlowPorosityLinear
porosity_ref = 1E-4
P_ref = insitu_pp
P_coeff = 3e-10
porosity_min = 1E-5
[]
[permeability]
type = PorousFlowPermeabilityKozenyCarman
k0 = 1E-15
poroperm_function = kozeny_carman_phi0
m = 0
n = 3
phi0 = 1E-4
[]
[internal_energy]
type = PorousFlowMatrixInternalEnergy
density = 2700
specific_heat_capacity = 0
[]
[aq_thermal_conductivity]
type = PorousFlowThermalConductivityIdeal
dry_thermal_conductivity = '0.6E-4 0 0 0 0.6E-4 0 0 0 0.6E-4'
[]
[]
[Functions]
[kg_rate]
type = ParsedFunction
vals = 'dt kg_out'
vars = 'dt kg_out'
value = 'kg_out/dt'
[]
[insitu_pp]
type = ParsedFunction
value = '9.81*1000*(3000 - z)'
[]
[insitu_T]
type = ParsedFunction
value = '363'
[]
[]
[Postprocessors]
[dt]
type = TimestepSize
outputs = 'none'
[]
[kg_out]
type = PorousFlowPlotQuantity
uo = kg_out_uo
[]
[kg_per_s]
type = FunctionValuePostprocessor
function = kg_rate
[]
[J_out]
type = PorousFlowPlotQuantity
uo = J_out_uo
[]
[TK_in]
type = PointValue
variable = frac_T
point = '0 -50 0'
[]
[TK_out]
type = PointValue
variable = frac_T
point = '0 50 0'
[]
[P_out]
type = PointValue
variable = frac_P
point = '0 50 0'
[]
[P_in]
type = PointValue
variable = frac_P
point = '0 -50 0'
[]
[]
[VectorPostprocessors]
[heat_transfer_rate]
type = NodalValueSampler
outputs = none
sort_by = id
variable = joules_per_s
[]
[]
[Preconditioning]
[./superlu]
type = SMP
full = true
petsc_options_iname = '-ksp_type -pc_type -pc_factor_mat_solver_package'
petsc_options_value = 'gmres lu superlu_dist'
[../]
[]
[Executioner]
type = Transient
solve_type = NEWTON
dt = 0.1e7
end_time = ${endTime}
line_search = 'none'
automatic_scaling = true
l_max_its = 20
l_tol = 8e-3
nl_forced_its = 1
nl_max_its = 20
nl_rel_tol = 5e-04
nl_abs_tol = 1e-09
[]
[Outputs]
print_linear_residuals = false
exodus = false
csv = true
# [fracCSV]
# type = CSV
# sync_times = '100 200 300 400 500 600 700 800 900
# 1000 2000 3000 4000 5000 6000 7000 8000 9000
# 1000e1 2000e1 3000e1 4000e1 5000e1 6000e1 7000e1 8000e1 9000e1
# 1000e2 2000e2 3000e2 4000e2 5000e2 6000e2 7000e2 8000e2 9000e2
# 1000e3 2000e3 3000e3 4000e3 5000e3 6000e3 7000e3 8000e3 9000e3
# 1000e4 2000e4 3000e4 4000e4 5000e4 6000e4 7000e4 8000e4 9000e4
# 1000e5 2000e5 3000e5 4000e5 5000e5 6000e5 7000e5 8000e5 9000e5'
# sync_only = true
# []
[exodus_all_time]
type = Exodus
file_base = result_time_step_tf
[]
[]