Пример #1
0
 def __cell_ref(self, cell_ptr):
     if self.is_RFT():
         return EclRFTCell.createCReference(cell_ptr, self)
     elif self.is_PLT():
         return EclPLTCell.createCReference(cell_ptr, self)
     else:
         raise NotImplementedError("Only RFT and PLT cells are implemented")
Пример #2
0
 def __cell_ref( self , cell_ptr ):
     if self.is_RFT():
         return EclRFTCell.createCReference( cell_ptr , self )
     elif self.is_PLT():
         return EclPLTCell.createCReference( cell_ptr , self )
     else:
         raise NotImplementedError("Only RFT and PLT cells are implemented")
Пример #3
0
    def test_RFT_cell(self):
        i = 10
        j = 8
        k = 100
        depth = 100
        pressure = 65
        swat = 0.56
        sgas = 0.10
        cell = EclRFTCell(i, j, k, depth, pressure, swat, sgas)

        self.assertEqual(i, cell.get_i())
        self.assertEqual(j, cell.get_j())
        self.assertEqual(k, cell.get_k())

        self.assertFloatEqual(pressure, cell.pressure)
        self.assertFloatEqual(depth, cell.depth)
        self.assertFloatEqual(swat, cell.swat)
        self.assertFloatEqual(sgas, cell.sgas)
        self.assertFloatEqual(1 - (sgas + swat), cell.soil)
Пример #4
0
    def test_RFT_cell(self):
        i = 10
        j = 8
        k = 100
        depth = 100
        pressure = 65
        swat = 0.56
        sgas = 0.10
        cell = EclRFTCell(i, j, k, depth, pressure, swat, sgas)

        self.assertEqual(i, cell.get_i())
        self.assertEqual(j, cell.get_j())
        self.assertEqual(k, cell.get_k())

        self.assertFloatEqual(pressure, cell.pressure)
        self.assertFloatEqual(depth, cell.depth)
        self.assertFloatEqual(swat, cell.swat)
        self.assertFloatEqual(sgas, cell.sgas)
        self.assertFloatEqual(1 - (sgas + swat), cell.soil)