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

Why square Jacobians? #371

Closed
gaperez64 opened this issue Oct 15, 2024 · 4 comments
Closed

Why square Jacobians? #371

gaperez64 opened this issue Oct 15, 2024 · 4 comments

Comments

@gaperez64
Copy link
Contributor

Is there a particular reason why you insist on Jacobian matrices being square?

@assert length(vf) == numVars

The usual definition allows for nonsquare Jacobians. Also, in the context of ODEs, if you have a time variable t then you'll end up with more variables than equations, right?

@lbenet
Copy link
Member

lbenet commented Oct 15, 2024

Thanks for opening this issue, and good catch! There is no real reason... If you have some time, please, open a PR solving this.

@gaperez64
Copy link
Contributor Author

gaperez64 commented Oct 15, 2024

Sure, I'll do that soon. But while on the topic, I am wondering if jacobian is the best name for this function since you are evaluating the matrix on a point. For me the Jacobian is a matrix of functions, and to obtain this using your API I instead need to feed it as evaluation point an array of variables, e.g.:

TaylorSeries.jacobian(g, [x, y])

@lbenet
Copy link
Member

lbenet commented Oct 17, 2024

I think jacobian is used in both contexts: as a matrix of the derivatives of a vector of functions, or as that matrix evaluated at a given point, which is what we consider. If you have a better name, I'm open for suggestions, which the could allow us to have it exported (the reason it is not exported is to avoid naming collisions with other packages).

@lbenet
Copy link
Member

lbenet commented Oct 17, 2024

Closed by #372

@lbenet lbenet closed this as completed Oct 17, 2024
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