Wrap a long syms equations

wraps a long syms equation so that it becomes more readable.
711 Downloads
Updated 28 May 2009

View License

WRAP_string(string1) rewrites a long syms equation and wraps
it so that it becomes more readable. It automatically divides the expression into individual lines with three dots "..." at the end of each line. Moreover, it detects the existence of operators +,-,*,/ so that it doesn't cut a long name of a variable (such as Lamda_w).

Inputs:
string1: An expression written in syms
n_columns: users can change the maximum width of each line

Cite As

Mohannad Hakeem (2024). Wrap a long syms equations (https://www.mathworks.com/matlabcentral/fileexchange/24273-wrap-a-long-syms-equations), MATLAB Central File Exchange. Retrieved .

MATLAB Release Compatibility
Created with R14SP2
Compatible with any release
Platform Compatibility
Windows macOS Linux
Categories
Find more on Symbolic Math Toolbox in Help Center and MATLAB Answers

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!
Version Published Release Notes
1.1.0.0

this file was updated so that it ends each line on a mathematical operator (+,-,*,/). in the previous edition, the code might end a line while cutting the name of a long variable (such as Lamda_w)

1.0.0.0