예제 #1
0
class TestGaussLorentzGel(unittest.TestCase):
    """
    Unit tests for GuinierPorod Model function
    """
    def setUp(self):
        from sas.models.GaussLorentzGelModel import GaussLorentzGelModel
        self.model = GaussLorentzGelModel()

    def test1D(self):
        # the values are from Igor pro calculation
        # the different digits are due to precision of q values
        self.assertAlmostEqual(self.model.run(0.001), 149.481, 3)
        self.assertAlmostEqual(self.model.run(0.105363), 9.1903, 4)
        self.assertAlmostEqual(self.model.runXY(0.441623), 0.632811, 5)
예제 #2
0
class TestGaussLorentzGel(unittest.TestCase):
    """
    Unit tests for GuinierPorod Model function
    """
    def setUp(self):
        from sas.models.GaussLorentzGelModel import GaussLorentzGelModel
        self.model= GaussLorentzGelModel()
        
    def test1D(self):        
        # the values are from Igor pro calculation  
        # the different digits are due to precision of q values  
        self.assertAlmostEqual(self.model.run(0.001), 149.481, 3)
        self.assertAlmostEqual(self.model.run(0.105363), 9.1903, 4)
        self.assertAlmostEqual(self.model.runXY(0.441623), 0.632811, 5)
예제 #3
0
 def setUp(self):
     from sas.models.GaussLorentzGelModel import GaussLorentzGelModel
     self.model = GaussLorentzGelModel()
예제 #4
0
 def setUp(self):
     from sas.models.GaussLorentzGelModel import GaussLorentzGelModel
     self.model= GaussLorentzGelModel()