EDUCBA Logo

EDUCBA

MENUMENU
  • Explore
    • EDUCBA Pro
    • PRO Bundles
    • Featured Skills
    • New & Trending
    • Fresh Entries
    • Finance
    • Data Science
    • Programming and Dev
    • Excel
    • Marketing
    • HR
    • PDP
    • VFX and Design
    • Project Management
    • Exam Prep
    • All Courses
  • Blog
  • Enterprise
  • Free Courses
  • Log in
  • Sign Up
Home Data Science Data Science Tutorials Matlab Tutorial Simplify Matlab
 

Simplify Matlab

Priya Pedamkar
Article byPriya Pedamkar

Simplify Matlab

Introduction to Simplify Matlab

MATLAB is a programming environment that is interactive and is used in scientific computing. It is extensively used in a lot of technical fields where problem-solving, data analysis, algorithm development, and experimentation is required. The discipline-specific software is extensively written using MATLAB. In this topic, we are going to learn about Simplify Matlab.

 

 

MATLAB provides us with a lot of mathematical functions, useful in various computational problems. In this article, we will studytheMATLAB function used for simplification of expressions; ‘simplify’

Watch our Demo Courses and Videos

Valuation, Hadoop, Excel, Mobile Apps, Web Development & many more.

As the name suggests, the Simplify function helps us in getting an algebraic expression in its simplest form. Though simplification is subjective, i.e. it could mean different to different users, the objective of a simplifying function is to put the expression in the best possible form.

An expression might look simplified to one user whereas the other might find it not that simplified.

Syntax of Simplify Matlab

Let us understand the Syntax of Simplify function in MATLAB

A = simplify (expression)

Description of Simplify Function in Matlab:

A = simplify (expression)

  • simplify (expression) function will perform the simplification of algebraic expression passed as an argument
  • If the expression is symbolic matrix or vector, simplify function will simplify every element of the expression

Examples of Simplify Matlab

Let us understand simplify (expression) with a couple of examples:

Example #1

First, let us take a simple algebraic expression as the input

Expression = (1 – x^2)/((1 - x)* (1 + x))

We know that 1 – x^2 in algebra gives (1 – x) * (1 + X)

So, our simplified output must be 1.

Syntax:

syms x[initializing x] simplify ((1 – x^2)/((1 - x) * (1 + x)))[passing the input expression]

Input:

syms x
simplify ((1 - x^2)/((1 - x) * (1 + x)))

Output:

Simplify Matlab output 1

As we can clearly see in the output, our algebraic expression is simplified, and the output is as expected by us, i.e. 1

Example #2

Let us now take another example with more complicated calculations and higher powers.

Expression = (1 – x^2) /((1 - x) * (1 + x)^4)

If we simplify this manually, the output will be 1/(x + 1)^3

Syntax:

syms x y[initializing x] simplify((1 – x^2) /((1 - x) * (1 + x)^4))[passing the input expression]

Input:

syms x y
simplify((1 - x^2) /((1 - x) * (1 + x)^4))

Output:

Simplify Matlab output 2

As we can see in the output, our algebraic expression is simplified, and the output is as expected by us,i.e1/(x + 1)^3.

Example #3

Next, let us take a trigonometric expression for simplification

Expression = (cos(x)^2 – sin(x)^2) * (x^2 - 1)

If we simplify this manually, the output will be cos(2*x)*(x^2 – 1)

Syntax:

syms x [initializing x] simplify((cos(x)^2 – sin(x)^2) * (1 – x^2))[passing the input expression]

Input:

syms x
simplify((cos(x)^2 - sin(x)^2) * (1 - x^2))

Output :

output 3.1

output 3.2

As we can clearly see in the output, our algebraic expression is simplified, and the output is as expected by us,i.ecos(2 * x) * (x ^ 2 – 1)

Example #4

Next, let us take an expression which has both trigonometric & algebraic expression

Expression = (sin(x)^2 + cos(x)^2)*(x^2 + x + 1)*(x^2 + 1)*(x^2 - x + 1) * (x^4 – x^2 + 1)

If we simplify this manually, the output will be x^10 + x^8 + x^6 + x^4 + x^2 + 1

Syntax:

syms x[initializing x] simplify((sin(x)^2 + cos(x)^2)*(x^2 + x + 1)*(x^2 + 1)*(x^2 - x + 1) * (x^4 – x^2 + 1))[passing the input expression]

Input:

syms x
simplify((sin(x)^2 + cos(x)^2)*(x^2 + x + 1)*(x^2 + 1)*(x^2 - x + 1) * (x^4 - x^2 + 1))

Output:

output 4.1

output 4.2

As we can see in the output, our algebraic expression is simplified, and the output is as expected by us, i.ex^10 + x^8 + x^6 + x^4 + x^2 + 1

Conclusion

So, in this article, we learned how the Simplify function works in MATLAB. We can use the simplified function to obtain the simplified version of expression passed in the input array.

Simplify function can be used on algebraic expressions and also on the trigonometric expressions.

Recommended Articles

This is a guide to Simplify Matlab. Here we discuss How the Simplify function works in MATLAB along with programming examples. You may also have a look at the following articles to learn more –

  1. Fzero Matlab
  2. Matlab Line Style
  3. Matlab Plot Circle
  4. Matlab stem()

Primary Sidebar

Footer

Follow us!
  • EDUCBA FacebookEDUCBA TwitterEDUCBA LinkedINEDUCBA Instagram
  • EDUCBA YoutubeEDUCBA CourseraEDUCBA Udemy
APPS
EDUCBA Android AppEDUCBA iOS App
Blog
  • Blog
  • Free Tutorials
  • About us
  • Contact us
  • Log in
Courses
  • Enterprise Solutions
  • Free Courses
  • Explore Programs
  • All Courses
  • All in One Bundles
  • Sign up
Email
  • [email protected]

ISO 10004:2018 & ISO 9001:2015 Certified

© 2025 - EDUCBA. ALL RIGHTS RESERVED. THE CERTIFICATION NAMES ARE THE TRADEMARKS OF THEIR RESPECTIVE OWNERS.

EDUCBA

*Please provide your correct email id. Login details for this Free course will be emailed to you
Loading . . .
Quiz
Question:

Answer:

Quiz Result
Total QuestionsCorrect AnswersWrong AnswersPercentage

Explore 1000+ varieties of Mock tests View more

EDUCBA

*Please provide your correct email id. Login details for this Free course will be emailed to you
EDUCBA
Free Data Science Course

Hadoop, Data Science, Statistics & others

By continuing above step, you agree to our Terms of Use and Privacy Policy.
*Please provide your correct email id. Login details for this Free course will be emailed to you
EDUCBA

*Please provide your correct email id. Login details for this Free course will be emailed to you

EDUCBA Login

Forgot Password?

🚀 Limited Time Offer! - 🎁 ENROLL NOW