Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

3
  • $\begingroup$ A very good and clear example. Thank you! But this code didn't work for this expression. f=Sin[\[Alpha]] Cos[\[Beta]] Sin[\[Gamma]] x^2 y + Sin[\[Beta]] Cos[\[Alpha]] Sin[\[Gamma]]^4 x^2 y + Sin[\[Alpha]]^2 Cos[\[Beta]] x y z + (Sin[\[Alpha]] Cos[\[Beta]] + 1) x^3 y^2 z^5. Terms with x^2 y not merged, although first we need to take this term out of the bracket $\endgroup$ Commented Jan 23, 2022 at 8:20
  • 1
    $\begingroup$ I think the edit does what you want; however, it is best to provide the desired output in addition to the input. $\endgroup$ Commented Jan 23, 2022 at 16:28
  • $\begingroup$ Bob, assembly (bracketing) can be done with a simpler command. Other than that, your vectorization code is perfectly functional. I accept it as an answer. Total@MonomialList[f, {x, y, z}] $\endgroup$ Commented Jan 23, 2022 at 16:43