dev #275
| @@ -191,6 +191,18 @@ class PowerLawCross: | |||||||
|         return ret_val |         return ret_val | ||||||
|  |  | ||||||
|  |  | ||||||
|  | class Sinc: | ||||||
|  |     type = 'Basic' | ||||||
|  |     name = 'Sinc' | ||||||
|  |     equation = 'C * sinc((x-x_{0})/w)' | ||||||
|  |     params = ['C', 'x_{0}', 'w'] | ||||||
|  |  | ||||||
|  |     @staticmethod | ||||||
|  |     def func(x, c: float, x0: float, w: float): | ||||||
|  |         # numpy sinc is defined as sin(pi*x)/(pi*x) | ||||||
|  |         return c * np.sinc(((x-x0)/w)/np.pi) | ||||||
|  |  | ||||||
|  |  | ||||||
| class Sine: | class Sine: | ||||||
|     """ |     """ | ||||||
|     Wavy sine function |     Wavy sine function | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user