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

In IPython terminal (not Jupyter) list brackets for solution lists misplaced #31

Open
gutow opened this issue Jan 11, 2024 · 2 comments
Assignees
Labels
bug Something isn't working

Comments

@gutow
Copy link
Owner

gutow commented Jan 11, 2024

V1.0.0

Get following in IPython terminal:

In[5]: algwsym_config.output.solve_to_list = True
In[6]: solve([e1, e2], [wn, xi])
Out[6]: omega_n = sqrt(16*T_p**2 + pi**2*T_s**2)/(T_p*T_s)
xi = 4*T_p/sqrt(16*T_p**2 + pi**2*T_s**2)
[, ]

When should get the following:

In[5]: algwsym_config.output.solve_to_list = True
In[6]: solve([e1, e2], [wn, xi])
Out[6]: [omega_n = sqrt(16*T_p**2 + pi**2*T_s**2)/(T_p*T_s), xi = 4*T_p/sqrt(16*T_p**2 + pi**2*T_s**2)]

This appears to be an issue with using command line overrides in IPython terminal when latex output is not available. It is unclear why things are fine for straight command line, but not here.

@gutow gutow added the bug Something isn't working label Jan 11, 2024
@gutow gutow self-assigned this Jan 11, 2024
@gutow
Copy link
Owner Author

gutow commented Jan 27, 2024

Behavior on straight command line:

>>> solve([e1, e2], [xi, wn])
{xi = 4*T_p/sqrt(16*T_p**2 + pi**2*T_s**2), omega_n = sqrt(16*T_p**2 + pi**2*T_s**2)/(T_p*T_s)}
>>> algwsym_config.output.solve_to_list = True
>>> solve([e1, e2], [xi, wn])
[Equation(xi, 4*T_p/sqrt(16*T_p**2 + pi**2*T_s**2)), Equation(omega_n, sqrt(16*T_p**2 + pi**2*T_s**2)/(T_p*T_s))]

There is some inconsistency on whether equations are displayed as human readable or code. Should it default to code when in solve list mode?

@gutow
Copy link
Owner Author

gutow commented Jan 27, 2024

In solve_to_list mode to be consistent Equations should not be rendered as human readable.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant