Sponsored links: Algebra eBooks
 

Help Index

A

B

C

D

E

F

G

H

I

J

K

L

M

N

O

P

Q

R

S

T

U

V

W

X

Y

Z

The Maxima on-line user's manual

Algebra Calculator

Search:

Reverse

Function: reverse (<list>) Reverses the order of the members of the <list> (not the members themselves). reverse also works on general expressions, e.g. reverse(a=b); gives b=a.

:lisp (defun enum-interval (low high &optional p)  (let* ((result nil)         (end-result 0))    (do* ((low low (+ low 1)))      ((> low high) (if (not p) end-result (values-list end-result)))      (setf end-result (reverse (push low result))))));
:lisp (defun group (source n)  (if (zerop n) (error "zero length"))  (labels ((rec (source acc)             (let ((rest (nthcdr n source)))               (if (consp rest)                   (rec rest (cons (subseq source 0 n) acc))                   (nreverse (cons source acc))))))    (if source (rec source nil) nil)));
:lisp (defun row-sum (min max n)  (let ((list (enum-interval min max)) (result))    (values-list     (dotimes (i (length (group list n)) (values (nreverse result)))       (push        (list (mapcan (lambda (x) (if (numberp x) (list x)))              (nth i (group list n)))              (format nil "sum: ~a" (reduce

There are also some inexact matches for reverse. Try ?? reverse to see them.

(%o1)                                true
(%i2) 

Related Examples

reverse-rreduce

f(x,y):=x+10*y;

rreduce(f,reverse([1,...

Calculate

reverse-sort

eq1:[10,2,55,4,5];

eq2:[5,6,7,8,9];

eq1 = sort(eq1);

Calculate

reverse-rreduce

f(x,y):=x+10*y;

rreduce(f,reverse([13...

Calculate

reverse-sort

eq1:[10,2,55,4,5];

eq2:[5,6,7,8,9];

eq1: sort(eq1);

Calculate

reverse-rreduce

f(x,y):=x+10*y;

rreduce(f,reverse([13...

Calculate

reverse-rreduce

f(x,y):=x+10*y;

rreduce(f,reverse([1,...

Calculate

reverse-sort

eq1:[10,2,55,4,5];

eq2:[5,6,7,8,9];

eq1 = sort(eq1);

Calculate

reverse-rreduce

rreduce(f,reverse([1,...

Calculate

reverse-rreduce

rreduce(f,reverse([1,...

Calculate