We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
HyMD/hymd/field.py
Lines 39 to 63 in d3aff97
Can this snippet above be simplified with the following? Why do we need to copy arrays?
for t in range(config.n_types): hamiltonian.v_ext[t](phi).r2c(out=v_ext_fourier[t]) v_ext_fourier[t].apply(hamiltonian.H, out=Ellipsis) for d in range(3): def force_transfer_function(k, v, d=d): return -k[d] * 1j * v force_mesh_fourier = v_ext_fourier[t].apply(force_transfer_function) force_mesh_fourier.c2r(out=force_mesh[t][d]) if compute_potential: v_ext_fourier.c2r(out=v_ext[t])
where v_ext_fourier is simply
v_ext_fourier
v_ext_fourier = [pm.create("complex", value=0.0) for _ in range(config.n_types)]
The text was updated successfully, but these errors were encountered:
No branches or pull requests
HyMD/hymd/field.py
Lines 39 to 63 in d3aff97
Can this snippet above be simplified with the following? Why do we need to copy arrays?
where
v_ext_fourier
is simplyThe text was updated successfully, but these errors were encountered: