123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110 |
- from scattnlay import scattcoeffs
- import numpy as np
- import example
- size = np.arange(0.25, 100.25, 0.25)
- x = np.ones((len(size), 5), dtype = np.float64)
- x[:, 0] = 0.1**(1.0/3.0)*size
- x[:, 1] = 0.36**(1.0/3.0)*size
- x[:, 2] = 0.404**(1.0/3.0)*size
- x[:, 3] = 0.7706**(1.0/3.0)*size
- x[:, 4] = size
- m = np.ones((len(size), 5), dtype = np.complex128)
- m[:, 0] *= 1.8 + 1.7j
- m[:, 1] *= 0.8 + 0.7j
- m[:, 2] *= 1.2 + 0.09j
- m[:, 3] *= 2.8 + 0.2j
- m[:, 4] *= 1.5 + 0.4j
- nmax=105
- an2 = np.zeros((len(size),nmax), dtype = np.complex128)
- bn2 = np.zeros((len(size),nmax), dtype = np.complex128)
- for _ in range(300):
- for i in range(len(size)):
- terms1, an2[i,:], bn2[i,:] = example.scattcoeffs(x[i,:], m[i,:], nmax=nmax)
-
|