Maple für Professional
Maple für Akademiker
Maple für Studenten
Maple Personal Edition
Maple Player
Maple Player für iPad
MapleSim für Professional
MapleSim für Akademiker
Maple T.A. - Testen & beurteilen
Maple T.A. MAA Placement Test Suite
Möbius - Online-Courseware
Machine Design / Industrial Automation
Luft- und Raumfahrt
Fahrzeugtechnik
Robotics
Energiebranche
System Simulation and Analysis
Model development for HIL
Anlagenmodelle für den Regelungsentwurf
Robotics/Motion Control/Mechatronics
Other Application Areas
Mathematikausbildung
Technik
Allgemein- und berufsbildende Schulen
Testen und beurteilen
Studierende
Finanzmodelle
Betriebsforschung
Hochleistungsrechnen
Physik
Live-Webinare
Aufgezeichnete Webinare
Geplante Veranstaltungen
MaplePrimes
Maplesoft-Blog
Maplesoft-Mitgliedschaft
Maple Ambassador Program
MapleCloud
Technische Whitepapers
E-Mail Newsletters
Maple-Bücher
Math Matters
Anwendungs-Center
MapleSim Modell-Galerie
Anwenderberichte
Exploring Engineering Fundamentals
Lehrkonzepte mit Maple
Maplesoft Welcome-Center
Resource-Center für Lehrer
Help-Center für Studierende
The profile Function
Calling Sequence
profile(procedure1, procedure2, ...)
Parameters
procedure1, procedure2, ...
-
any number of valid Maple procedures that have not already been profiled with profile
Description
The procedure profile alters the given procedures to record runtime information on the procedures. If profile is successful, it returns NULL on exit.
The profiling information is printed using the showprofile() function as shown in the examples below. For more options and examples see ?showprofile. To stop collecting profiling information on a function, use unprofile(). To reset the profiler to begin a new profile use resetprofile().
Use of profile() increases memory usage and slows down computations, sometimes dramatically. In addition, profile may not work properly with procedures that have special evaluation rules.
A closely related function, exprofile(), can be used to profile all Maple functions at once.
Examples
fib:=proc(n) option remember; if n<2 then n else fib(n-1)+fib(n-2) end if; end proc:
function depth calls time time% bytes bytes% --------------------------------------------------------------------------- fib 5 9 0.000 0.00 6168 100.00 --------------------------------------------------------------------------- total: 5 9 0.000 0.00 6168 100.00
function depth calls time time% bytes bytes% --------------------------------------------------------------------------- gcd 1 1 0.011 91.67 552280 84.89 randpoly 1 3 0.001 8.33 74504 11.45 expand 1 8 0.000 0.00 6160 0.95 divide 1 6 0.000 0.00 17656 2.71 --------------------------------------------------------------------------- total: 4 18 0.012 100.00 650600 100.00
function depth calls time time% bytes bytes% --------------------------------------------------------------------------- gcd 1 1 0.005 71.43 253256 69.59 divide 1 6 0.002 28.57 110656 30.41 content 0 0 0.000 0.00 0 0.00 --------------------------------------------------------------------------- total: 2 7 0.007 100.00 363912 100.00
See Also
exprofile, kernelopts, showprofile, unprofile
Download Help Document