## [Maxima-bugs] [ maxima-Bugs-900860 ] Simplifications involving abs

 [Maxima-bugs] [ maxima-Bugs-900860 ] Simplifications involving abs From: SourceForge.net - 2005-02-21 20:03:18 ```Bugs item #900860, was opened at 2004-02-19 22:53 Message generated for change (Comment added) made by macrakis You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=104933&aid=900860&group_id=4933 Category: None Group: None Status: Open Resolution: None Priority: 5 Submitted By: Stavros Macrakis (macrakis) Assigned to: Nobody/Anonymous (nobody) Summary: Simplifications involving abs Initial Comment: abs(q)/q^2 and q^2/abs(q) currently don't simplify. These should simplify to 1/abs(q) and abs(q). This is especially useful since things like sqrt(q^2) simplify to abs(q). It would be even nicer if GCD understood this case, but I can understand that that would be harder, e.g. gcd(abs(q)+q^2,abs(q)) => 1+abs(q) This seems practically justifiable; is there any theoretical reason it might not be justifiable? ---------------------------------------------------------------------- >Comment By: Stavros Macrakis (macrakis) Date: 2005-02-21 15:03 Message: Logged In: YES user_id=588346 abs(x)^(2*n+1) should simplify to x^(2*n)*abs(x), extending the current case where abs(x)^(2*n) simplifies to x^(2*n). This simple change makes (e.g.) abs(x)^3/x simplify with no further work. ---------------------------------------------------------------------- Comment By: Stavros Macrakis (macrakis) Date: 2004-02-22 16:16 Message: Logged In: YES user_id=588346 With declare(q,complex), q/abs(q) should presumably simplify to carg(q), except for the problems with that (620246, 902290). Assuming definition by continuity, q/abs(q) and carg (q) even have the same 'value' (ind) at q=0. With *real* r, r/abs(r) = signum(r) *except* at r=0, where the first is undefined, but the second is well-defined (=0). ---------------------------------------------------------------------- Comment By: Barton Willis (willisbl) Date: 2004-02-22 15:35 Message: Logged In: YES user_id=895922 When 'domain' is complex or q has been declared complex, the simplification abs(q) / q^2 --> 1/abs(q) shouldn't happen. Barton ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=104933&aid=900860&group_id=4933 ```

 [Maxima-bugs] [ maxima-Bugs-900860 ] Simplifications involving abs From: SourceForge.net - 2004-02-20 04:00:50 ```Bugs item #900860, was opened at 2004-02-19 22:53 Message generated for change (Tracker Item Submitted) made by Item Submitter You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=104933&aid=900860&group_id=4933 Category: None Group: None Status: Open Resolution: None Priority: 5 Submitted By: Stavros Macrakis (macrakis) Assigned to: Nobody/Anonymous (nobody) Summary: Simplifications involving abs Initial Comment: abs(q)/q^2 and q^2/abs(q) currently don't simplify. These should simplify to 1/abs(q) and abs(q). This is especially useful since things like sqrt(q^2) simplify to abs(q). It would be even nicer if GCD understood this case, but I can understand that that would be harder, e.g. gcd(abs(q)+q^2,abs(q)) => 1+abs(q) This seems practically justifiable; is there any theoretical reason it might not be justifiable? ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=104933&aid=900860&group_id=4933 ```
 [Maxima-bugs] [ maxima-Bugs-900860 ] Simplifications involving abs From: SourceForge.net - 2004-02-22 20:44:46 ```Bugs item #900860, was opened at 2004-02-19 21:53 Message generated for change (Comment added) made by willisbl You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=104933&aid=900860&group_id=4933 Category: None Group: None Status: Open Resolution: None Priority: 5 Submitted By: Stavros Macrakis (macrakis) Assigned to: Nobody/Anonymous (nobody) Summary: Simplifications involving abs Initial Comment: abs(q)/q^2 and q^2/abs(q) currently don't simplify. These should simplify to 1/abs(q) and abs(q). This is especially useful since things like sqrt(q^2) simplify to abs(q). It would be even nicer if GCD understood this case, but I can understand that that would be harder, e.g. gcd(abs(q)+q^2,abs(q)) => 1+abs(q) This seems practically justifiable; is there any theoretical reason it might not be justifiable? ---------------------------------------------------------------------- >Comment By: Barton Willis (willisbl) Date: 2004-02-22 14:35 Message: Logged In: YES user_id=895922 When 'domain' is complex or q has been declared complex, the simplification abs(q) / q^2 --> 1/abs(q) shouldn't happen. Barton ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=104933&aid=900860&group_id=4933 ```
 [Maxima-bugs] [ maxima-Bugs-900860 ] Simplifications involving abs From: SourceForge.net - 2004-02-22 21:26:12 ```Bugs item #900860, was opened at 2004-02-19 22:53 Message generated for change (Comment added) made by macrakis You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=104933&aid=900860&group_id=4933 Category: None Group: None Status: Open Resolution: None Priority: 5 Submitted By: Stavros Macrakis (macrakis) Assigned to: Nobody/Anonymous (nobody) Summary: Simplifications involving abs Initial Comment: abs(q)/q^2 and q^2/abs(q) currently don't simplify. These should simplify to 1/abs(q) and abs(q). This is especially useful since things like sqrt(q^2) simplify to abs(q). It would be even nicer if GCD understood this case, but I can understand that that would be harder, e.g. gcd(abs(q)+q^2,abs(q)) => 1+abs(q) This seems practically justifiable; is there any theoretical reason it might not be justifiable? ---------------------------------------------------------------------- >Comment By: Stavros Macrakis (macrakis) Date: 2004-02-22 16:16 Message: Logged In: YES user_id=588346 With declare(q,complex), q/abs(q) should presumably simplify to carg(q), except for the problems with that (620246, 902290). Assuming definition by continuity, q/abs(q) and carg (q) even have the same 'value' (ind) at q=0. With *real* r, r/abs(r) = signum(r) *except* at r=0, where the first is undefined, but the second is well-defined (=0). ---------------------------------------------------------------------- Comment By: Barton Willis (willisbl) Date: 2004-02-22 15:35 Message: Logged In: YES user_id=895922 When 'domain' is complex or q has been declared complex, the simplification abs(q) / q^2 --> 1/abs(q) shouldn't happen. Barton ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=104933&aid=900860&group_id=4933 ```
 [Maxima-bugs] [ maxima-Bugs-900860 ] Simplifications involving abs From: SourceForge.net - 2005-02-21 20:03:18 ```Bugs item #900860, was opened at 2004-02-19 22:53 Message generated for change (Comment added) made by macrakis You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=104933&aid=900860&group_id=4933 Category: None Group: None Status: Open Resolution: None Priority: 5 Submitted By: Stavros Macrakis (macrakis) Assigned to: Nobody/Anonymous (nobody) Summary: Simplifications involving abs Initial Comment: abs(q)/q^2 and q^2/abs(q) currently don't simplify. These should simplify to 1/abs(q) and abs(q). This is especially useful since things like sqrt(q^2) simplify to abs(q). It would be even nicer if GCD understood this case, but I can understand that that would be harder, e.g. gcd(abs(q)+q^2,abs(q)) => 1+abs(q) This seems practically justifiable; is there any theoretical reason it might not be justifiable? ---------------------------------------------------------------------- >Comment By: Stavros Macrakis (macrakis) Date: 2005-02-21 15:03 Message: Logged In: YES user_id=588346 abs(x)^(2*n+1) should simplify to x^(2*n)*abs(x), extending the current case where abs(x)^(2*n) simplifies to x^(2*n). This simple change makes (e.g.) abs(x)^3/x simplify with no further work. ---------------------------------------------------------------------- Comment By: Stavros Macrakis (macrakis) Date: 2004-02-22 16:16 Message: Logged In: YES user_id=588346 With declare(q,complex), q/abs(q) should presumably simplify to carg(q), except for the problems with that (620246, 902290). Assuming definition by continuity, q/abs(q) and carg (q) even have the same 'value' (ind) at q=0. With *real* r, r/abs(r) = signum(r) *except* at r=0, where the first is undefined, but the second is well-defined (=0). ---------------------------------------------------------------------- Comment By: Barton Willis (willisbl) Date: 2004-02-22 15:35 Message: Logged In: YES user_id=895922 When 'domain' is complex or q has been declared complex, the simplification abs(q) / q^2 --> 1/abs(q) shouldn't happen. Barton ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=104933&aid=900860&group_id=4933 ```
 [Maxima-bugs] [ maxima-Bugs-900860 ] Simplifications involving abs From: SourceForge.net - 2006-07-23 18:38:56 ```Bugs item #900860, was opened at 2004-02-19 20:53 Message generated for change (Comment added) made by robert_dodier You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=104933&aid=900860&group_id=4933 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. >Category: Lisp Core - Simplification Group: None Status: Open Resolution: None Priority: 5 Submitted By: Stavros Macrakis (macrakis) Assigned to: Nobody/Anonymous (nobody) Summary: Simplifications involving abs Initial Comment: abs(q)/q^2 and q^2/abs(q) currently don't simplify. These should simplify to 1/abs(q) and abs(q). This is especially useful since things like sqrt(q^2) simplify to abs(q). It would be even nicer if GCD understood this case, but I can understand that that would be harder, e.g. gcd(abs(q)+q^2,abs(q)) => 1+abs(q) This seems practically justifiable; is there any theoretical reason it might not be justifiable? ---------------------------------------------------------------------- >Comment By: Robert Dodier (robert_dodier) Date: 2006-07-23 12:38 Message: Logged In: YES user_id=501686 Observed in 5.9.3cvs. ---------------------------------------------------------------------- Comment By: Stavros Macrakis (macrakis) Date: 2005-02-21 13:03 Message: Logged In: YES user_id=588346 abs(x)^(2*n+1) should simplify to x^(2*n)*abs(x), extending the current case where abs(x)^(2*n) simplifies to x^(2*n). This simple change makes (e.g.) abs(x)^3/x simplify with no further work. ---------------------------------------------------------------------- Comment By: Stavros Macrakis (macrakis) Date: 2004-02-22 14:16 Message: Logged In: YES user_id=588346 With declare(q,complex), q/abs(q) should presumably simplify to carg(q), except for the problems with that (620246, 902290). Assuming definition by continuity, q/abs(q) and carg (q) even have the same 'value' (ind) at q=0. With *real* r, r/abs(r) = signum(r) *except* at r=0, where the first is undefined, but the second is well-defined (=0). ---------------------------------------------------------------------- Comment By: Barton Willis (willisbl) Date: 2004-02-22 13:35 Message: Logged In: YES user_id=895922 When 'domain' is complex or q has been declared complex, the simplification abs(q) / q^2 --> 1/abs(q) shouldn't happen. Barton ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=104933&aid=900860&group_id=4933 ```
 [Maxima-bugs] [ maxima-Bugs-900860 ] Simplifications involving abs From: SourceForge.net - 2010-02-13 20:15:04 ```Bugs item #900860, was opened at 2004-02-20 04:53 Message generated for change (Comment added) made by crategus You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=104933&aid=900860&group_id=4933 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: Lisp Core - Simplification Group: None >Status: Closed >Resolution: Fixed Priority: 5 Private: No Submitted By: Stavros Macrakis (macrakis) Assigned to: Nobody/Anonymous (nobody) Summary: Simplifications involving abs Initial Comment: abs(q)/q^2 and q^2/abs(q) currently don't simplify. These should simplify to 1/abs(q) and abs(q). This is especially useful since things like sqrt(q^2) simplify to abs(q). It would be even nicer if GCD understood this case, but I can understand that that would be harder, e.g. gcd(abs(q)+q^2,abs(q)) => 1+abs(q) This seems practically justifiable; is there any theoretical reason it might not be justifiable? ---------------------------------------------------------------------- >Comment By: Dieter Kaiser (crategus) Date: 2010-02-13 21:15 Message: The suggested simplifications have been implemented in simp.lisp revision 1.101. Closing this bug report as fixed. Dieter Kaiser ---------------------------------------------------------------------- Comment By: Robert Dodier (robert_dodier) Date: 2006-07-23 20:38 Message: Logged In: YES user_id=501686 Observed in 5.9.3cvs. ---------------------------------------------------------------------- Comment By: Stavros Macrakis (macrakis) Date: 2005-02-21 21:03 Message: Logged In: YES user_id=588346 abs(x)^(2*n+1) should simplify to x^(2*n)*abs(x), extending the current case where abs(x)^(2*n) simplifies to x^(2*n). This simple change makes (e.g.) abs(x)^3/x simplify with no further work. ---------------------------------------------------------------------- Comment By: Stavros Macrakis (macrakis) Date: 2004-02-22 22:16 Message: Logged In: YES user_id=588346 With declare(q,complex), q/abs(q) should presumably simplify to carg(q), except for the problems with that (620246, 902290). Assuming definition by continuity, q/abs(q) and carg (q) even have the same 'value' (ind) at q=0. With *real* r, r/abs(r) = signum(r) *except* at r=0, where the first is undefined, but the second is well-defined (=0). ---------------------------------------------------------------------- Comment By: Barton Willis (willisbl) Date: 2004-02-22 21:35 Message: Logged In: YES user_id=895922 When 'domain' is complex or q has been declared complex, the simplification abs(q) / q^2 --> 1/abs(q) shouldn't happen. Barton ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=104933&aid=900860&group_id=4933 ```