Skip to content

Convenient interface for broadcast #11

@szabo137

Description

@szabo137

Description

Currently, we pass the omega and q values as a tuple to all sorts of functions, e.g., the dynamic structure factor. This is very inconvenient, when it comes to broadcast over vectors of q and omega. Therefore, we should replace the tuple input just by two arguments, omega and q.

Validation and testing

ne = 1.0e21u"cm^(-3)"
temp = 10.0u"keV"
om_arr = range(0.1,1.0,100)
q = 0.1

esys  = IdealElectronSystem(ne,temp)
old_res = [dynamic_structure_factor(esys,(om,q)) for om in om_arr]
new_res = dynamic_structure_factor.(esys,om_arr,q) 

@assert old_res == new_res

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions