Replies: 3 comments 2 replies
-
Sometimes it helps to write things down. or I can also use please correct me if I am wrong Cheers, |
Beta Was this translation helpful? Give feedback.
-
Thank you Eirik! dump_grid_bucket_to_file(gb, 'gb_file_name') but did not find any function to load the set of files that were created. Thanks |
Beta Was this translation helpful? Give feedback.
-
Oh, that is an old function that was intended for other usage. It's been a while since I saved a One warning: If you save an object with pickle, update PorePy, and then try to load the object again, it may not work because pickle notes that the underlying code has changed in the meantime (ore something like that). A better way of storing the state of a problem have been on our wishlist for a long while, but so far, we have not found the time to do so. |
Beta Was this translation helpful? Give feedback.
-
Hello all,
I am new to PorePy and am trying to upscale permeability after solving the single phase pressure equation on a simple box setting dirichlet pressure boundary conditions on two opposite sides. I want to include fractures into this box later, thus I am using a grid bucket structure for the box. gb = pp.meshing.cart_grid([], [3, 3, 3], physdims=[1, 1, 1])
I set the permeability to 1Darcy = 9.86923e-13 and pressure gradient dP to 1Pa (I did not find the conventions on units, but I assume SI units are used). The visualisation of the resulting pressure field after solving the system shows linear pressure distribution and looks fine to me.
Now for the perm upscaling I need to solve the following equation k=q_in*L/A/dP, where q_in is the flux through the inlet boundary, L=1m length of the box, A=1m^2 the inlet area. Now the question is, how do I get the flux through the inlet boundary?
I tried the following:
data = d['discretization_matrices']['flow']['flux']
q = np.sum(data[bool_inflow_faces])
k = q*L/A/dP
But what I am getting back is not k=1Darcy but 6Darcy.
Any idea where my mistake could be? Is d['discretization_matrices']['flow']['flux'] the right place to get the boundary fluxes?
Thank you for your help
Christine
Beta Was this translation helpful? Give feedback.
All reactions