Group Abstract Group Abstract

Message Boards Message Boards

0
|
1.4K Views
|
1 Reply
|
0 Total Likes
View groups...
Share
Share this post:

[?] Replace product of unknown variables with a single variable?

Posted 6 years ago

I am trying to replace a group of a variable like (L^4)*(lm^4) by a single variable B. PLease suggest how to do it.

POSTED BY: Prakhar Swarnkar
Posted 6 years ago

Can you provide a specific example? Maybe this?

Hold[(L^4)*(lm^4) + 3 ((L^4)*(lm^4)) + ((L^4)*(lm^4))^2] /. ((L^4)*(lm^4)) -> B // ReleaseHold
(* 4 B + B^2 *)

The Hold is required to prevent the expression from being simplified before the replacement.

POSTED BY: Rohit Namjoshi
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard