My Maple Cheat Sheet

Total Page:16

File Type:pdf, Size:1020Kb

My Maple Cheat Sheet my Maple cheat sheet Nasser M. Abbasi September 16, 2021 Compiled on September 16, 2021 at 12:15 Noon [public] Contents 17 How to use matrices in maple? 7 1 How to find a particular solution 18 How can maple return more to ODE? 1 than value from a procedure call? 9 2 How to find basis solutions for 19 How does maple handle proce- homogeneous ode? 1 dure arguments? 9 3 How to convert Mathematica ex- 20 How to define your own data pression to Maple? 1 types? 9 4 How to debug internal proce- 21 How to find max element in a ma- dures, such as dsolve? 2 trix and its position as same time? 10 5 How to display or print source 22 How to create a package? 10 code of a function or procedure in MAPLE? 2 23 How to convert from floating point to Hex? 12 6 How to display trace of a func- tion as it runs in maple? 3 24 How to find taylor series expan- sion of functions? 12 7 How to display a build in func- 25 How to print elements of a matrix? 12 tion code? 4 26 How to find determinant of ma- 8 How to build a LIST or a SET on trix? 13 the fly? 4 27 How to generate Hilber matrix? 13 9 How to make function display more information of what it is 28 How to plot matrix data? 13 doing? 4 29 How to catch an error from a 10 How to solve a differential equa- proc()? 13 tion with initial conditions? 5 30 How to convert 3456 to 3,456 ? 14 11 How to verify that the ODE so- lution given is correct? 5 31 How to use units ? 14 12 How to know the type of ODE? 6 32 On High precision. Using taylor to solve ODE 15 13 What packages to load for differ- ential equations? 6 33 How to evaluate catlan number and other sums? 15 14 How to plot solution of differen- tial equations? 6 34 How to write a text file that con- tains a package, and load it and 15 How to plot a function? 7 execute it? 15 16 How to run maple from com- 35 How to find what packages are mand line? 7 included in maple 16 1 2 36 How to plot the gradiant vector 59 Fourier series in maple 28 field? 16 60 How to plot graphs next to each 37 How to put the digits of Pi into others in a grid like fashion 29 a list? 17 61 How to generate Pi on X-axis 30 38 Digits of PI in maple and mma 17 62 How to make output from Func- 39 How to find where functions are? 19 tionAdvisor look better? 30 40 on maple data types 19 63 How to do partial fractions? 30 41 how to extract stuff from a list 64 How to generate sequence sum based on some selection? 20 symbolically 30 42 how to test if all elements of a 65 Nice plot from Maple 31 matrix are integers? 20 66 How to check if 2 expressions 43 how to use laplace transform? 20 are the same? 31 44 questions I have 21 67 converting series to factorials 31 45 3D plotting 21 68 How to find what new additions made to Maple? 32 46 How to raise each element in a list to a power? 21 69 Maple can’t solve laplace equa- 47 How to generate a sequence with tion and numerically 32 any increment? 21 70 Some Maple Matrix operations 32 48 What shortcuts are there for ma- trix manipulation? 21 71 How set diagonal elements to some value, say 1? 34 49 How to solve a set of equations for the derivative? 21 72 How to multiply roots of a poly- nomial? 35 50 How to solve a set of equations for differentials? 22 73 How to plot a surface in 3D? 35 51 How to plot binary tree 23 74 How to convert trigs to sinc func- tion in an expression 36 52 solving problem 12.4 chapter 4, Math 121A, Boas book. using 75 How to find NullSpace and maple 23 ColumnSpace of a matrix? 36 53 example of doing convergence 76 How to fix the interface to using test in maple 24 Maple notation for input? 37 54 Solving problem math 121A, ch 77 How to find all solutions using 14, 3.18, Boas book. contour inte- allvalues ? 37 gration 24 78 How to add one to only the ele- 55 How to find multiple roots to an ments of the diagonal of a matrix? 37 equation such as 푠푖푛(푥) = 0 24 79 How to search help for updates 56 Dr Basti Associated Legendre 25 on some package 37 57 Understanding conformal map- 80 How to work with groups in ping in maple 26 worksheet 37 58 Is there a way to keep the as- 81 How to read code into worksheet? 38 sumptions but not see the tilda character show up? 28 82 Code editors for Maple 38 3 83 How to find if package is mod- 106How to do pattern matching in ule or table? 38 Maple? 48 106.1Example 1 . 48 84 How to replace a string? 38 107How to find trig indetities? 48 85 How to use geometry and plot- tools ? 38 108How to find directional deriva- tive of scalar function? 49 86 How to simplify log expressions ? 39 109How to check if name is as- 87 How to simplify hyperbolic ex- signed a value? 49 pression ? 39 110How to use dsolve with Lie? 50 88 How to create text file and ap- pend string to it? 39 111How to select terms with sqrt or radical in them from an expression 50 89 How to search packages and li- braries? 39 112How to simplify 푒ln(푥)+ln(푦) 50 90 How to numerically solve a BVP 113How to find all csgn() and re- ode and plot the solution? 41 place them by 1 51 91 How to find the indicial equa- 114How to replace all abs(expr) by tion for an ODE? 42 expr 51 92 How to display on screen for spe- 115How to find basis for Null space, cific width? 42 Row space and column space of matrix? 51 93 Maple IDE links 42 116How to do Gaussian elimination 94 loading, remove and finding on a Matrix? 52 what packages loaded 43 117How to find Reduced Echelon 95 some rules of thumbs when us- form of a Matrix? 52 ing Maple 43 118How add a new row to bottom of 96 How to write derivative 43 matrix? 53 97 How to solve heat PDE in 1D in 119How to obtain list of all occu- Maple 2017? 43 rances of some function in an ex- pression? 53 98 How to make multiple assump- tions on a symbol? 45 120How to replace ln(|푥|) with ln(푥) in an expression? 54 99 How to make Maple display diff(y(x),x) as 푦′(푥) or as 푦′ ? 45 121How to find all signum func- tions in expression and simplify 100How to check if expression is an it? 54 equation? 45 122How to do change of variables 101How to check if expression is a on the dependent variable for an set? 45 ODE? 55 102How to set boundary conditions 123How to find the cofactor matrix for dsolve or pdsolve? 46 of a matrix? 55 103How to export a plot to PDF? 46 124How to make phase plot of sec- ond order ODE? 55 104How to find all roots of complex number 47 125How to normalize eigenvectors? 56 105How to convert matrix of matri- 126How to find if some function is ces to a matrix? 47 present in an expression 57 4 127How to find all functions in an 137How to write structured types to expression? 57 match some expressions? 61 137.1type for sin푚(푥) cos푛(푥) . 61 128How to find all functions in an expression but exclude all build 138How to use new object method in math functions? 57 calling in Maple 2021? 61 129How to obtain a list of all argu- 139How to make a constructor for ments of function? 58 an Object? 62 130How to obtain a list of all func- 140How to make different construc- tions in expression whose first tors for an Object? 63 argument is 푧? 58 141How to do OOP inheritance? 64 131How to obtain a list of all func- tions in expression whose sec- 142How to use object as user de- ond argument is 푡? 58 fined record inside a proc? 65 132How to typeset ℏ? 58 143Given an expression with in- 133How to find the Curl of a vector? 59 dexed variables, how to select only these variables? 66 134How to see all steps in finding RREF form of an augmented ma- 144How to show step by step for cal- trix? 59 culus problem? 66 135How to find column space of ma- 145How to obtain list of files with trix? 60 some extension in folder? 66 136How to use select with own type 146How to delete lines from text file to find subexpressions? 60 that contains some string? 67 1 How to find a particular solution to ODE? restart; ode:=diff(y(x),x)+y(x)^2*sin(x)-2*sin(x)/cos(x)^2 = 0; yp:=DETools:-particularsol(ode); To step into the code, do restart; ode:=diff(y(x),x)+y(x)^2*sin(x)-2*sin(x)/cos(x)^2 = 0; stopat(`DEtools/particularsol`); DETools:-particularsol(ode); To print it do print(`DEtools/particularsol`); 5 2 How to find basis solutions for homogeneous ode? Use the output=basis option ode:=diff(y(x),x$2)-x*diff(y(x),x)-x*y(x)=0; dsolve(ode,output=basis); 3 How to convert Mathematica expression to Maple? restart; with(MmaTranslator); #load the package FromMma(`Integrate[Cos[x],x]`); Or restart; with(MmaTranslator); #load the package convert(`Integrate[Cos[x],x]`, FromMma); 4 How to debug internal procedures, such as dsolve? f:=proc() eq:=x*diff(y(x),x)+y(x)=exp(2*x); dsolve(eq,y(x)); end proc; Then used the command stopat(f); then called the procedure f(); and now the de- bugger comes up.
Recommended publications
  • The Sagemanifolds Project
    Tensor calculus with free softwares: the SageManifolds project Eric´ Gourgoulhon1, Micha l Bejger2 1Laboratoire Univers et Th´eories (LUTH) CNRS / Observatoire de Paris / Universit´eParis Diderot 92190 Meudon, France http://luth.obspm.fr/~luthier/gourgoulhon/ 2Centrum Astronomiczne im. M. Kopernika (CAMK) Warsaw, Poland http://users.camk.edu.pl/bejger/ Encuentros Relativistas Espa~noles2014 Valencia 1-5 September 2014 Eric´ Gourgoulhon, Micha l Bejger (LUTH, CAMK) SageManifolds ERE2014, Valencia, 2 Sept. 2014 1 / 44 Outline 1 Differential geometry and tensor calculus on a computer 2 Sage: a free mathematics software 3 The SageManifolds project 4 SageManifolds at work: the Mars-Simon tensor example 5 Conclusion and perspectives Eric´ Gourgoulhon, Micha l Bejger (LUTH, CAMK) SageManifolds ERE2014, Valencia, 2 Sept. 2014 2 / 44 Differential geometry and tensor calculus on a computer Outline 1 Differential geometry and tensor calculus on a computer 2 Sage: a free mathematics software 3 The SageManifolds project 4 SageManifolds at work: the Mars-Simon tensor example 5 Conclusion and perspectives Eric´ Gourgoulhon, Micha l Bejger (LUTH, CAMK) SageManifolds ERE2014, Valencia, 2 Sept. 2014 3 / 44 In 1969, during his PhD under Pirani supervision at King's College, Ray d'Inverno wrote ALAM (Atlas Lisp Algebraic Manipulator) and used it to compute the Riemann tensor of Bondi metric. The original calculations took Bondi and his collaborators 6 months to go. The computation with ALAM took 4 minutes and yield to the discovery of 6 errors in the original paper [J.E.F. Skea, Applications of SHEEP (1994)] In the early 1970's, ALAM was rewritten in the LISP programming language, thereby becoming machine independent and renamed LAM The descendant of LAM, called SHEEP (!), was initiated in 1977 by Inge Frick Since then, many softwares for tensor calculus have been developed..
    [Show full text]
  • Using Macaulay2 Effectively in Practice
    Using Macaulay2 effectively in practice Mike Stillman ([email protected]) Department of Mathematics Cornell 22 July 2019 / IMA Sage/M2 Macaulay2: at a glance Project started in 1993, Dan Grayson and Mike Stillman. Open source. Key computations: Gr¨obnerbases, free resolutions, Hilbert functions and applications of these. Rings, Modules and Chain Complexes are first class objects. Language which is comfortable for mathematicians, yet powerful, expressive, and fun to program in. Now a community project Journal of Software for Algebra and Geometry (started in 2009. Now we handle: Macaulay2, Singular, Gap, Cocoa) (original editors: Greg Smith, Amelia Taylor). Strong community: including about 2 workshops per year. User contributed packages (about 200 so far). Each has doc and tests, is tested every night, and is distributed with M2. Lots of activity Over 2000 math papers refer to Macaulay2. History: 1976-1978 (My undergrad years at Urbana) E. Graham Evans: asked me to write a program to compute syzygies, from Hilbert's algorithm from 1890. Really didn't work on computers of the day (probably might still be an issue!). Instead: Did computation degree by degree, no finishing condition. Used Buchsbaum-Eisenbud \What makes a complex exact" (by hand!) to see if the resulting complex was exact. Winfried Bruns was there too. Very exciting time. History: 1978-1983 (My grad years, with Dave Bayer, at Harvard) History: 1978-1983 (My grad years, with Dave Bayer, at Harvard) I tried to do \real mathematics" but Dave Bayer (basically) rediscovered Groebner bases, and saw that they gave an algorithm for computing all syzygies. I got excited, dropped what I was doing, and we programmed (in Pascal), in less than one week, the first version of what would be Macaulay.
    [Show full text]
  • Singular Value Decomposition and Its Numerical Computations
    Singular Value Decomposition and its numerical computations Wen Zhang, Anastasios Arvanitis and Asif Al-Rasheed ABSTRACT The Singular Value Decomposition (SVD) is widely used in many engineering fields. Due to the important role that the SVD plays in real-time computations, we try to study its numerical characteristics and implement the numerical methods for calculating it. Generally speaking, there are two approaches to get the SVD of a matrix, i.e., direct method and indirect method. The first one is to transform the original matrix to a bidiagonal matrix and then compute the SVD of this resulting matrix. The second method is to obtain the SVD through the eigen pairs of another square matrix. In this project, we implement these two kinds of methods and develop the combined methods for computing the SVD. Finally we compare these methods with the built-in function in Matlab (svd) regarding timings and accuracy. 1. INTRODUCTION The singular value decomposition is a factorization of a real or complex matrix and it is used in many applications. Let A be a real or a complex matrix with m by n dimension. Then the SVD of A is: where is an m by m orthogonal matrix, Σ is an m by n rectangular diagonal matrix and is the transpose of n ä n matrix. The diagonal entries of Σ are known as the singular values of A. The m columns of U and the n columns of V are called the left singular vectors and right singular vectors of A, respectively. Both U and V are orthogonal matrices.
    [Show full text]
  • An Alternative Algorithm for Computing the Betti Table of a Monomial Ideal 3
    AN ALTERNATIVE ALGORITHM FOR COMPUTING THE BETTI TABLE OF A MONOMIAL IDEAL MARIA-LAURA TORRENTE AND MATTEO VARBARO Abstract. In this paper we develop a new technique to compute the Betti table of a monomial ideal. We present a prototype implementation of the resulting algorithm and we perform numerical experiments suggesting a very promising efficiency. On the way of describing the method, we also prove new constraints on the shape of the possible Betti tables of a monomial ideal. 1. Introduction Since many years syzygies, and more generally free resolutions, are central in purely theo- retical aspects of algebraic geometry; more recently, after the connection between algebra and statistics have been initiated by Diaconis and Sturmfels in [DS98], free resolutions have also become an important tool in statistics (for instance, see [D11, SW09]). As a consequence, it is fundamental to have efficient algorithms to compute them. The usual approach uses Gr¨obner bases and exploits a result of Schreyer (for more details see [Sc80, Sc91] or [Ei95, Chapter 15, Section 5]). The packages for free resolutions of the most used computer algebra systems, like [Macaulay2, Singular, CoCoA], are based on these techniques. In this paper, we introduce a new algorithmic method to compute the minimal graded free resolution of any finitely generated graded module over a polynomial ring such that some (possibly non- minimal) graded free resolution is known a priori. We describe this method and we present the resulting algorithm in the case of monomial ideals in a polynomial ring, in which situ- ation we always have a starting nonminimal graded free resolution.
    [Show full text]
  • Computations in Algebraic Geometry with Macaulay 2
    Computations in algebraic geometry with Macaulay 2 Editors: D. Eisenbud, D. Grayson, M. Stillman, and B. Sturmfels Preface Systems of polynomial equations arise throughout mathematics, science, and engineering. Algebraic geometry provides powerful theoretical techniques for studying the qualitative and quantitative features of their solution sets. Re- cently developed algorithms have made theoretical aspects of the subject accessible to a broad range of mathematicians and scientists. The algorith- mic approach to the subject has two principal aims: developing new tools for research within mathematics, and providing new tools for modeling and solv- ing problems that arise in the sciences and engineering. A healthy synergy emerges, as new theorems yield new algorithms and emerging applications lead to new theoretical questions. This book presents algorithmic tools for algebraic geometry and experi- mental applications of them. It also introduces a software system in which the tools have been implemented and with which the experiments can be carried out. Macaulay 2 is a computer algebra system devoted to supporting research in algebraic geometry, commutative algebra, and their applications. The reader of this book will encounter Macaulay 2 in the context of concrete applications and practical computations in algebraic geometry. The expositions of the algorithmic tools presented here are designed to serve as a useful guide for those wishing to bring such tools to bear on their own problems. A wide range of mathematical scientists should find these expositions valuable. This includes both the users of other programs similar to Macaulay 2 (for example, Singular and CoCoA) and those who are not interested in explicit machine computations at all.
    [Show full text]
  • Singular in Sage L-38 22November2019 1/40 Computing with Polynomials in Singular
    Computing with Polynomials in Singular 1 Polynomials, Resultants, and Factorization computer algebra for polynomial computations resultants to eliminate variables 2 Gröbner Bases and Multiplication Matrices ideals of polynomials and Gröbner bases normal forms and multiplication matrices multiplicity as the dimension of the local quotient ring 3 Formulas for the 4-bar Coupler Point formulation of the problem processing a Gröbner basis MCS 507 Lecture 38 Mathematical, Statistical and Scientific Software Jan Verschelde, 22 November 2019 Scientific Software (MCS 507) Singular in Sage L-38 22November2019 1/40 Computing with Polynomials in Singular 1 Polynomials, Resultants, and Factorization computer algebra for polynomial computations resultants to eliminate variables 2 Gröbner Bases and Multiplication Matrices ideals of polynomials and Gröbner bases normal forms and multiplication matrices multiplicity as the dimension of the local quotient ring 3 Formulas for the 4-bar Coupler Point formulation of the problem processing a Gröbner basis Scientific Software (MCS 507) Singular in Sage L-38 22November2019 2/40 Singular Singular is a computer algebra system for polynomial computations, with special emphasis on commutative and non-commutative algebra, algebraic geometry, and singularity theory, under the GNU General Public License. Singular’s core algorithms handle polynomial factorization and resultants characteristic sets and numerical root finding Gröbner, standard bases, and free resolutions. Its development is directed by Wolfram Decker, Gert-Martin Greuel, Gerhard Pfister, and Hans Schönemann, within the Dept. of Mathematics at the University of Kaiserslautern. Scientific Software (MCS 507) Singular in Sage L-38 22November2019 3/40 Singular in Sage Advanced algorithms are contained in more than 90 libraries, written in a C-like programming language.
    [Show full text]
  • What Can Computer Algebraic Geometry Do Today?
    What can computer Algebraic Geometry do today? Gregory G. Smith Wolfram Decker Mike Stillman 14 July 2015 Essential Questions ̭ What can be computed? ̭ What software is currently available? ̭ What would you like to compute? ̭ How should software advance your research? Basic Mathematical Types ̭ Polynomial Rings, Ideals, Modules, ̭ Varieties (affine, projective, toric, abstract), ̭ Sheaves, Divisors, Intersection Rings, ̭ Maps, Chain Complexes, Homology, ̭ Polyhedra, Graphs, Matroids, ̯ Established Geometric Tools ̭ Elimination, Blowups, Normalization, ̭ Rational maps, Working with divisors, ̭ Components, Parametrizing curves, ̭ Sheaf Cohomology, ঠ-modules, ̯ Emerging Geometric Tools ̭ Classification of singularities, ̭ Numerical algebraic geometry, ̭ ैक़௴Ь, Derived equivalences, ̭ Deformation theory,Positivity, ̯ Some Geometric Successes ̭ GEOGRAPHY OF SURFACES: exhibiting surfaces with given invariants ̭ BOIJ-SÖDERBERG: examples lead to new conjectures and theorems ̭ MODULI SPACES: computer aided proofs of unirationality Some Existing Software ̭ GAP,Macaulay2, SINGULAR, ̭ CoCoA, Magma, Sage, PARI, RISA/ASIR, ̭ Gfan, Polymake, Normaliz, 4ti2, ̭ Bertini, PHCpack, Schubert, Bergman, an idiosyncratic and incomplete list Effective Software ̭ USEABLE: documented examples ̭ MAINTAINABLE: includes tests, part of a larger distribution ̭ PUBLISHABLE: Journal of Software for Algebra and Geometry; www.j-sag.org ̭ CITATIONS: reference software Recent Developments in Singular Wolfram Decker Janko B¨ohm, Hans Sch¨onemann, Mathias Schulze Mohamed Barakat TU Kaiserslautern July 14, 2015 Wolfram Decker (TU-KL) Recent Developments in Singular July 14, 2015 1 / 24 commutative and non-commutative algebra, singularity theory, and with packages for convex and tropical geometry. It is free and open-source under the GNU General Public Licence.
    [Show full text]
  • Sage Tutorial (Pdf)
    Sage Tutorial Release 9.4 The Sage Development Team Aug 24, 2021 CONTENTS 1 Introduction 3 1.1 Installation................................................4 1.2 Ways to Use Sage.............................................4 1.3 Longterm Goals for Sage.........................................5 2 A Guided Tour 7 2.1 Assignment, Equality, and Arithmetic..................................7 2.2 Getting Help...............................................9 2.3 Functions, Indentation, and Counting.................................. 10 2.4 Basic Algebra and Calculus....................................... 14 2.5 Plotting.................................................. 20 2.6 Some Common Issues with Functions.................................. 23 2.7 Basic Rings................................................ 26 2.8 Linear Algebra.............................................. 28 2.9 Polynomials............................................... 32 2.10 Parents, Conversion and Coercion.................................... 36 2.11 Finite Groups, Abelian Groups...................................... 42 2.12 Number Theory............................................. 43 2.13 Some More Advanced Mathematics................................... 46 3 The Interactive Shell 55 3.1 Your Sage Session............................................ 55 3.2 Logging Input and Output........................................ 57 3.3 Paste Ignores Prompts.......................................... 58 3.4 Timing Commands............................................ 58 3.5 Other IPython
    [Show full text]
  • Prologue: General Remarks on Computer Algebra Systems
    Cambridge University Press 978-1-107-61253-2 - A First Course in Computational Algebraic Geometry Wolfram Decker and Gerhard Pfister Excerpt More information Prologue: General Remarks on Computer Algebra Systems Computer algebra algorithms allow us to compute in, and with, a multitude of mathematical structures. Accordingly, there is a large number of computer algebra systems suiting different needs, ranging from the general to the special purpose. Some well-known examples of the former are commercial, whereas many of the special purpose systems are open-source and can be downloaded from the internet for free. General purpose systems aim at providing basic functionality for a variety of different application areas. In addition to tools for symbolic computation, they usually offer tools for numerical computation and for visualization. Example P.1 MAPLE is a commercial general purpose system. To show a few of its commands at work, we start with examples from calculus, namely definite and indefinite integration: > int(sin(x), x=0..Pi); 2 > int(x/(x^2-1), x); 1/2 ln(x - 1) + 1/2 ln(x + 1) For linear algebra applications, we first load the corresponding package. Then we demonstrate how to perform Gaussian elimination and to compute eigen- values. with(LinearAlgebra); A := Matrix([[2, 1, 0], [1, 2, 1], [0, 1, 2]]); ⎡ ⎤ 210 ⎢ ⎥ ⎢ ⎥ ⎣ 121⎦ 012 GaussianElimination(A); 1 © in this web service Cambridge University Press www.cambridge.org Cambridge University Press 978-1-107-61253-2 - A First Course in Computational Algebraic Geometry Wolfram Decker and Gerhard Pfister Excerpt More information 2 Prologue: General Remarks on Computer Algebra Systems ⎡ ⎤ 21 0 ⎢ ⎥ ⎢ ⎥ ⎣ 03/21⎦ 004/3 Eigenvalues(A); ⎡ ⎤ 2 ⎢ √ ⎥ ⎢ ⎥ ⎣ 2 − 2 ⎦ √ 2 + 2 Next, we give an example of solving numerically1: > fsolve(2*x^5-11*x^4-7*x^3+12*x^2-4*x = 0); -1.334383488, 0., 5.929222024 Finally, we show one of the graphic functions at work: > plot3d(x*exp(-x^2-y^2),x = -2 .
    [Show full text]
  • CME292: Advanced MATLAB for Scientific Computing
    CME292: Advanced MATLAB for Scientific Computing Homework #2 NLA & Opt Due: Tuesday, April 28, 2015 Instructions This problem set will be combined with Homework #3. For this combined problem set, 2 out of the 6 problems are required. You are free to choose the problems you complete. Before completing problem set, please see HomeworkInstructions on Coursework for general homework instructions, grading policy, and number of required problems per problem set. Problem 1 A matrix A P Rmˆn can be compressed using the low-rank approximation property of the SVD. The approximation algorithm is given in Algorithm1. Algorithm 1 Low-Rank Approximation using SVD Input: A P Rmˆn of rank r and approximation rank k (k ¤ r) mˆn Output: Ak P R , optimal rank k approximation to A 1: Compute (thin) SVD of A “ UΣVT , where U P Rmˆr, Σ P Rrˆr, V P Rnˆr T 2: Ak “ Up:; 1 : kqΣp1 : k; 1 : kqVp:; 1 : kq Notice the low-rank approximation, Ak, and the original matrix, A, are the same size. To actually achieve compression, the truncated singular factors, Up:; 1 : kq P Rmˆk, Σp1 : k; 1 : kq P Rkˆk, Vp:; 1 : kq P Rnˆk, should be stored. As Σ is diagonal, the required storage is pm`n`1qk doubles. The original matrix requires mn storing mn doubles. Therefore, the compression is useful only if k ă m`n`1 . Recall from lecture that the SVD is among the most expensive matrix factorizations in numerical linear algebra. Many SVD approximations have been developed; a particularly interesting one from [1] is given in Algorithm2.
    [Show full text]
  • The Reesalgebra Package in Macaulay2
    Journal of Software for Algebra and Geometry The ReesAlgebra package in Macaulay2 DAVID EISENBUD vol 8 2018 JSAG 8 (2018), 49–60 The Journal of Software for dx.doi.org/10.2140/jsag.2018.8.49 Algebra and Geometry The ReesAlgebra package in Macaulay2 DAVID EISENBUD ABSTRACT: This note introduces Rees algebras and some of their uses, with illustrations from version 2.2 of the Macaulay2 package ReesAlgebra.m2. INTRODUCTION. A central construction in modern commutative algebra starts from an ideal I in a commutative ring R, and produces the Rees algebra R.I / VD R ⊕ I ⊕ I 2 ⊕ I 3 ⊕ · · · D∼ RTI tU ⊂ RTtU; where RTtU denotes the polynomial algebra in one variable t over R. For basics on Rees algebras, see[Vasconcelos 1994] and[Swanson and Huneke 2006], and for some other research, see[Eisenbud and Ulrich 2018; Kustin and Ulrich 1992; Ulrich 1994], and[Valabrega and Valla 1978]. From the point of view of algebraic geometry, the Rees algebra R.I / is a homo- geneous coordinate ring for the graph of a rational map whose total space is the blowup of Spec R along the scheme defined by I. (In fact, the “Rees algebra” is sometimes called the “blowup algebra”.) Rees algebras were first studied in the algebraic context by David Rees, in the now-famous paper[Rees 1958]. Actually, Rees mainly studied the ring RTI t; t−1U, now also called the extended Rees algebra of I. Mike Stillman and I wrote a Rees algebra script for Macaulay classic. It was aug- mented, and made into the[Macaulay2] package ReesAlgebra.m2 around 2002, to study a generalization of Rees algebras to modules described in[Eisenbud et al.
    [Show full text]
  • General Relativity Computations with Sagemanifolds
    General relativity computations with SageManifolds Eric´ Gourgoulhon Laboratoire Univers et Th´eories (LUTH) CNRS / Observatoire de Paris / Universit´eParis Diderot 92190 Meudon, France http://luth.obspm.fr/~luthier/gourgoulhon/ NewCompStar School 2016 Neutron stars: gravitational physics theory and observations Coimbra (Portugal) 5-9 September 2016 Eric´ Gourgoulhon (LUTH) GR computations with SageManifolds NewCompStar, Coimbra, 6 Sept. 2016 1 / 29 Outline 1 Computer differential geometry and tensor calculus 2 The SageManifolds project 3 Let us practice! 4 Other examples 5 Conclusion and perspectives Eric´ Gourgoulhon (LUTH) GR computations with SageManifolds NewCompStar, Coimbra, 6 Sept. 2016 2 / 29 Computer differential geometry and tensor calculus Outline 1 Computer differential geometry and tensor calculus 2 The SageManifolds project 3 Let us practice! 4 Other examples 5 Conclusion and perspectives Eric´ Gourgoulhon (LUTH) GR computations with SageManifolds NewCompStar, Coimbra, 6 Sept. 2016 3 / 29 In 1965, J.G. Fletcher developed the GEOM program, to compute the Riemann tensor of a given metric In 1969, during his PhD under Pirani supervision, Ray d'Inverno wrote ALAM (Atlas Lisp Algebraic Manipulator) and used it to compute the Riemann tensor of Bondi metric. The original calculations took Bondi and his collaborators 6 months to go. The computation with ALAM took 4 minutes and yielded to the discovery of 6 errors in the original paper [J.E.F. Skea, Applications of SHEEP (1994)] Since then, many softwares for tensor calculus have been developed... Computer differential geometry and tensor calculus Introduction Computer algebra system (CAS) started to be developed in the 1960's; for instance Macsyma (to become Maxima in 1998) was initiated in 1968 at MIT Eric´ Gourgoulhon (LUTH) GR computations with SageManifolds NewCompStar, Coimbra, 6 Sept.
    [Show full text]