Adept Scientific - English
The world's best software for research, science and engineering.
flag arrow
clearclear
 

 Adept Store | register Join My Adept | Flags  
Adept Scientific | Amor Way | Letchworth Garden City | Herts | SG6 1ZA | Tel: +44 (0)1462 480055  
UKusdedksvnofi
Home
Products
Training
Consultancy
 Buy Online
Downloads
Education
Support
My Adept
International |  About Us |  Contact Us |  Press Room |  Jobs


The Next Steps

• Ask us a question
• Maple Product Tour
• Buy Maple Now
• View Maple Pricing
• Find out about Online Training
• Download a Brochure
• Request a Brochure
• Download a Demo
• Request a Demo
• Meet Our Team
• Read our RSS Feeds

Learn More

Maple Home
Maple 11 Professional
Maple 11 Academic
Maple 11 Student Use
Recorded Online Seminars
FREE Training Resources


MapleNet
Maple T.A.
MapleConnect
BlockImporter for Simulink
BlockBuilder for Simulink
Maple Toolboxes
Maple Rave Reviews
Maple Study Guides
Books about Maple
System Requirements

View Maple 10 in Action
Product Comparison Chart

Latest Information

New Features: Professional
New Features: Academic
The Maple Reporter
The Maple Reporter Online
Numerical Algorithms Group
(NAG)


Service & Support

Maple 10 Training Videos
MaplePrimes, blogs, forums
Elite Maintenance Program
Application Centre
Powertools
Maple User Group (MUG)
Join the Maple User Group
(MUG)

Search the Knowledge Base
Technical Support request

List Archives >  Maple User Group List Archive >  Archive by date >  This Month By Date >  This Month By Topic

[MUG] Re: Optimize tryhard

Search email archive for  

[MUG] Re: Optimize tryhard
Author: Maple User Group    Posted: Fri, 29 Nov 2002 09:10:55 -0500

>> From: Maple User Group "maple_gr"

-=*=-=*=-=*=-=*=-=*=-=*=-=*=-=*=-=*=-=*=-=*=-=*=-=*=-=*=-=*=-=*=-=*=-=*=-=*=-

From: Gaston Gonnet "gonnet"
Date: Wed, 27 Nov 2002 17:53:49 +0100 (MET)
To: "maple-list"
Subject: Optimize tryhard

Yes, I have some information about tryhard, I have coded it some
time ago. I coded it because I was doing molecular dynamics at
the time, and that requires hundreds of hours of computation, hence
optimization time is not very relevant, but quality of the optimization
is.

optimize/tryhard is unique to that piece of code, all the rest of
codegen or Maple do not utilize it.

I never had the time to write a paper about it.... apologies....

Is there anything in particular you would like to know about it?

Best wishes, Gaston Gonnet.


-=*=-=*=-=*=-=*=-=*=-=*=-=*=-=*=-=*=-=*=-=*=-=*=-=*=-=*=-=*=-=*=-=*=-=*=-=*=-

Date: Wed, 27 Nov 2002 18:11:28 -0500 (EST)
From: Carl Devore "devore"
To: "maple-list"
Subject: Optimize tryhard



On Tue, 26 Nov 2002, Moore, Brian wrote:
> I'm looking for information on the algorithm used in the optimize with
> tryhard option in the codegen package.

It is all in procedures `codegen/optimize/tryhard/frontend` and its
subsidiaries. Just read the procedures with showstat.

> Actually, the optimize tryhard seems to generate very efficient code,
> but it takes a long time to generate the code.

Yeah, it is pretty good. With a tiny bit of tweaking, it can also be used
as an expression simplifier. For lengthy algebraic number expressions, it
often gives significantly more simplification than the other
simplification commands. Here is the tweaking:

Tryhard:= proc(expr)
local _E;
subs(
pow= `^`
,codegen[optimize](subs(_E= expr, ()-> _E), tryhard)
)()
end proc:

Show that is does something potentially useful:

_EnvExplicit:= true:
p:= randpoly([x,y], degree= 4, dense);
root1:= solve(p, y)[1];
# Root is 11 screens long on my computer
simplify(root1);
# Still 11 screens long
r:= Tryhard(root1);
# 2 1/2 screens long, and it only took twice as long as the simplify.

The actual procedure returned by codegen[optimize] in this case is only
1/3 of a screen long. So, looking at that procedure can give a deeper
understanding of the internal structure of root1 than can be obtained by
looking at the 2 1/2 screens.

Test validity:

simplify(eval(p, y= r));
0

So people who collect such things can file that in their Maple trick bag.

[View Complete Thread]



Previous by date: [MUG] Re: convolution operator, Maple User Group
Next by date: [MUG] two bugs i found, A Prashanth Pg Ee
Previous thread: [MUG] HOWTO solve system where solution is piecewise?
Next thread: [MUG] two bugs i found, A Prashanth Pg Ee



Ready to buy?

Maple - single user licence
Add to shopping basket
$ 1,895.00
Upgrade to Maple 12 from v11
Add to shopping basket
$ 995.00
Upgrade to Maple 12 from v10 & below
Add to shopping basket
$ 1,395.00

Featured Downloads

Maple White Paper: Technical Knowledge - An Asset You Can Afford to Lose?
Maple in Electronics Application Pack
Maple in Robotics & Aerospace Application Pack
Maple in Finance Application Pack

Product Reviews

"Without the Maple software, we would have to spend weeks generating the equations of motion for every experiment. Then the chances that we did it right would basically be near zero. There would always be a mistake somewhere. It is very difficult to set up a dynamic motion model by hand."
- Jean-Claude PiedBeouf, Ph.D Manager of Robotics, Canadian Space Agency

"Its very good - highly accurate and easy to use. The speed of Maple allows me to change equations and quickly reintegrate them into the application, so more possibilities can be explored to achieve the precise effect desired."
Shawn Neely, Senior R & D Director for PDI/Dreamworks
adept

Top of the Page

Our Privacy and Terms and Conditions Statement
All Trademarks Recognised. Copyright © 2007, Adept Scientific plc.
Site designed and maintained by Adeptise

Adept Scientific | Amor Way | Letchworth Garden City | Herts | SG6 1ZA | Tel: +44 (0)1462 480055