Skip to content
New issue

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

Infinite recursion when trying to multiply two objects of SparseStore<ComplexNumber> #360

Closed
asmisloff opened this issue Aug 9, 2021 · 4 comments

Comments

@asmisloff
Copy link

Test Case
public class test {

public static void main(String[] args) {
    final int N = 100;
    SparseStore<ComplexNumber> Z = SparseStore.makeComplex(N, N);
    for (int row = 0; row < N; ++row) {
        int col = ThreadLocalRandom.current().nextInt(N);
        Z.set(row, col,
                ComplexNumber.of(
                        ThreadLocalRandom.current().nextDouble(10),
                        ThreadLocalRandom.current().nextDouble(10))
        );

        Z.multiply(Z); //StackOverflowError here
    }
}

}

@apete
Copy link
Contributor

apete commented Aug 9, 2021

Thanks for reporting this problem. I'll fix it shortly.

@apete
Copy link
Contributor

apete commented Aug 10, 2021

https://github.com/optimatika/ojAlgo/tree/hotfix/GitHubIssue360

If you could give this a try to.

@asmisloff
Copy link
Author

asmisloff commented Aug 10, 2021

Works well for me. Thank you so much!

@asmisloff
Copy link
Author

Sorry for my english

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants