emsig / empymod

Full 3D electromagnetic modeller for 1D VTI media
https://empymod.emsig.xyz
Apache License 2.0
85 stars 22 forks source link

Add example for original Cole-Cole model #193

Closed efinden closed 1 year ago

efinden commented 1 year ago

Included an example function for a Cole-Cole permittivity and a constant conductivity. https://github.com/emsig/empymod/commit/02893a985832f77b27018177fe4d39fa5efa413b

prisae commented 1 year ago

Hi @efinden! Thanks for this contribution. It looks generally good. Currently, there are several tests failing (only style) - do you want to fix them, or shall I do it? Either is fine by me.

If you want to have a crack at it: You can test these things locally, by running make flake8 in the empymod directory. This will run the flake8 tests on your files.

Also, to be more inline with the other examples, I think it would be good to rephrase

1j*2*np.pi*np.transpose(matlib.repmat(p_dict['freq'],2,1))*epsilonH

and remove the numpy.matlib import.

Again, you can have a crack at it or I can do it, whatever you prefer!

as

np.outer(2j*np.pi*p_dict['freq'], epsilonH)
efinden commented 1 year ago

Thank's! Glad to finally contribute to this great tool. I am happy to try to run the make file, it is good for learning. I fully agree to use the more inline functions.

prisae commented 1 year ago

Btw, it would also be nice if you could include the new function in the figure!

efinden commented 1 year ago

Sure, a figure will be nice! It may take me some days before I have time to finish it.

efinden commented 1 year ago

I installed a local repo with git now, therefore I pushed a new PR from a local branch. This PR can therefor be closed.

prisae commented 1 year ago

Moved to #194