Browse Source

small changes

Konstantin Ladutenko 10 years ago
parent
commit
0649d5cf56
2 changed files with 8 additions and 7 deletions
  1. 7 6
      go.sh
  2. 1 1
      tests/python/field-dielectric-sphere.py

+ 7 - 6
go.sh

@@ -93,12 +93,13 @@ time  ASAN_SYMBOLIZER_PATH=/usr/bin/llvm-symbolizer-3.4  $PROGRAM -l 5 0.4642 1.
 
 # ./$file.bin
 
-# ### Cython
-# rm scattnlay.so
-# export CFLAGS='-std=c++11'
-# python setup.py build_ext --inplace
-# cp scattnlay.so tests/python/
-# cd tests/python/
+### Cython
+rm scattnlay.so
+export CFLAGS='-std=c++11'
+python setup.py build_ext --inplace
+cp scattnlay.so tests/python/
+cd tests/python/
+./lfield.py
 # ./field-dielectric-sphere..py
 # ./field.py
 # ./test01.py

+ 1 - 1
tests/python/field-dielectric-sphere.py

@@ -66,7 +66,7 @@ terms, E, H = fieldnlay(x, m, coord)
 Er = np.absolute(E)
 
 # |E|/|Eo|
-#Eh = np.sqrt(Er[0, :, 0]**2 + Er[0, :, 1]**2 + Er[0, :, 2]**2)
+Eh = np.sqrt(Er[0, :, 0]**2 + Er[0, :, 1]**2 + Er[0, :, 2]**2)
 Eh = Er[0, :, 0]**2 + Er[0, :, 1]**2 + Er[0, :, 2]**2
 
 result = np.vstack((coordX, coordY, coordZ, Eh)).transpose()