We are preparing to convert some models from OpenMDAO v0.13 to v1.1.1. In our previous model we relied on the ability to connect single outputs of components to specific array entries of another components input. However, I read in the conversion guide that this functionality is no longer supported. We have a large number of components of the same component class that each need to provide their result to another component. The only solution I have come up with is to connect each of the inputs separately and combine them inside the final component. This would require an extra 70+ connections (number would vary depending on application case).
Can you recommend a better solution?
One option would be to make the down-stream component have scalar inputs instead of one large array. This would be the same number of connections as you had before and would avoid adding a mux component in between them. But if you wanted the input in array format for computational efficiency, then you would have to copy them into an array inside your component, which is a little messy.
Adding a mux-component would handle this for you, but of course you would just be moving things around then. Since on the upstream side of the mux you would still have to have single variables.
There might be one other option, which would be to combine all 70 of the upstream components together into a single component. Even if you wanted to run this in parallel you still could. It would just require a small amount of extra coding inside the upstream component to make it all work.
answered 15 Oct '15, 18:04