This is the cl-iterative Reference Manual, version 0.1.0, generated automatically by Declt version 4.0 beta 2 "William Riker" on Sun Dec 15 05:03:14 2024 GMT+0.
The main system appears first, followed by any subsystem dependency.
cl-iterative
Generic iterative algorithm with multiple controls
Alexey Cherkaev (mobius-eng)
LGPLv3
0.1.0
alexandria
(system).
optima
(system).
package.lisp
(file).
iterator.lisp
(file).
cl-iterative.lisp
(file).
iteratorex.lisp
(file).
cl-iterative-ex.lisp
(file).
Files are sorted by type and then listed depth-first from the systems components trees.
cl-iterative/cl-iterative.asd
cl-iterative/package.lisp
cl-iterative/iterator.lisp
cl-iterative/cl-iterative.lisp
cl-iterative/iteratorex.lisp
cl-iterative/cl-iterative-ex.lisp
cl-iterative/iterator.lisp
package.lisp
(file).
cl-iterative
(system).
->continue
(function).
->failed
(function).
->finished
(function).
bind
(function).
change-status
(function).
continue
(function).
continue-p
(function).
failed
(function).
failed-p
(function).
finished
(function).
finished-p
(function).
fmap
(function).
iterator
(function).
iterator
(class).
print-object
(method).
replace-value
(function).
status
(reader method).
(setf status)
(writer method).
update-value
(function).
value
(reader method).
(setf value)
(writer method).
iterator-p
(function).
status-p
(function).
cl-iterative/cl-iterative.lisp
iterator.lisp
(file).
cl-iterative
(system).
alter-value
(function).
alter-value
(class).
apply-control
(generic function).
combine-controls
(function).
control
(function).
control
(class).
control-apply-function
(reader method).
(setf control-apply-function)
(writer method).
control-init-function
(reader method).
(setf control-init-function)
(writer method).
converged-number
(function).
converged-number
(class).
converged-value
(function).
converged-value
(class).
define-simple-constructor
(macro).
failed-value
(function).
failed-value
(class).
finished-value
(function).
finished-value
(class).
fixed-point
(function).
fixed-point-result-indicator
(generic function).
init-control
(generic function).
iterate
(function).
limit-iterations
(function).
limit-iterations
(class).
log-computation
(function).
log-computation
(class).
alter-value-function
(reader method).
change-status
(class).
change-status-final
(reader method).
change-status-pred
(reader method).
change-status-target
(reader method).
converged-number-last
(reader method).
(setf converged-number-last)
(writer method).
converged-number-tolerance
(reader method).
converged-value-close-p
(reader method).
converged-value-copy
(reader method).
converged-value-final
(reader method).
converged-value-last
(reader method).
(setf converged-value-last)
(writer method).
limit-iterations-final
(reader method).
limit-iterations-max
(reader method).
limit-iterations-performed
(reader method).
(setf limit-iterations-performed)
(writer method).
log-function
(reader method).
reduce-list
(function).
reduced
(function).
reduced-p
(function).
reduced-value
(function).
cl-iterative/iteratorex.lisp
cl-iterative.lisp
(file).
cl-iterative
(system).
change-class
(method).
info
(method).
info
(reader method).
(setf info)
(writer method).
iteratorex
(class).
print-object
(method).
upgrade
(function).
cl-iterative/cl-iterative-ex.lisp
iteratorex.lisp
(file).
cl-iterative
(system).
add-info
(function).
add-info
(class).
apply-control
(method).
apply-control
(method).
apply-control
(method).
control-id
(method).
control-id
(reader method).
control-with-id
(class).
converged-number-with-id
(function).
converged-number-with-id
(class).
converged-value-with-id
(function).
converged-value-with-id
(class).
failed-value-with-id
(function).
failed-value-with-id
(class).
finished-value-with-id
(function).
finished-value-with-id
(class).
fixed-point-result-indicator
(method).
init-info
(reader method).
limit-iterations-with-id
(function).
limit-iterations-with-id
(class).
push-info-p
(method).
push-info-p
(reader method).
Packages are listed by definition order.
cl-iterative
Control of computation flow and iterative algorithm
common-lisp
.
optima
.
alter-value
(function).
alter-value
(class).
apply-control
(generic function).
combine-controls
(function).
control
(function).
control
(class).
control-apply-function
(generic reader).
(setf control-apply-function)
(generic writer).
control-init-function
(generic reader).
(setf control-init-function)
(generic writer).
converged-number
(function).
converged-number
(class).
converged-value
(function).
converged-value
(class).
define-simple-constructor
(macro).
failed-value
(function).
failed-value
(class).
finished-value
(function).
finished-value
(class).
fixed-point
(function).
fixed-point-result-indicator
(generic function).
init-control
(generic function).
iterate
(function).
limit-iterations
(function).
limit-iterations
(class).
log-computation
(function).
log-computation
(class).
alter-value-function
(generic reader).
change-status
(class).
change-status-final
(generic reader).
change-status-pred
(generic reader).
change-status-target
(generic reader).
converged-number-last
(generic reader).
(setf converged-number-last)
(generic writer).
converged-number-tolerance
(generic reader).
converged-value-close-p
(generic reader).
converged-value-copy
(generic reader).
converged-value-final
(generic reader).
converged-value-last
(generic reader).
(setf converged-value-last)
(generic writer).
limit-iterations-final
(generic reader).
limit-iterations-max
(generic reader).
limit-iterations-performed
(generic reader).
(setf limit-iterations-performed)
(generic writer).
log-function
(generic reader).
reduce-list
(function).
reduced
(function).
reduced-p
(function).
reduced-value
(function).
iteratorex
Extension of ITERATOR to annotate it with INFO
cl-iterative
.
common-lisp
.
info
(generic function).
(setf info)
(generic writer).
iteratorex
(class).
upgrade
(function).
cl-iterative-ex
Upgrades controls from CL-ITERATIVE to work with ITERATOREX
cl-iterative
.
common-lisp
.
add-info
(function).
add-info
(class).
control-id
(generic function).
control-with-id
(class).
converged-number-with-id
(function).
converged-number-with-id
(class).
converged-value-with-id
(function).
converged-value-with-id
(class).
failed-value-with-id
(function).
failed-value-with-id
(class).
finished-value-with-id
(function).
finished-value-with-id
(class).
init-info
(generic reader).
limit-iterations-with-id
(function).
limit-iterations-with-id
(class).
push-info-p
(generic function).
iterator
Computation flow
common-lisp
.
optima
.
->continue
(function).
->failed
(function).
->finished
(function).
bind
(function).
change-status
(function).
continue
(function).
continue-p
(function).
failed
(function).
failed-p
(function).
finished
(function).
finished-p
(function).
fmap
(function).
iterator
(function).
iterator
(class).
replace-value
(function).
status
(generic reader).
(setf status)
(generic writer).
update-value
(function).
value
(generic reader).
(setf value)
(generic writer).
iterator-p
(function).
status-p
(function).
Definitions are sorted by export status, category, package, and then by lexicographic order.
Make simple constuctor with boa arguments for CLASS
Change status of the ITERATOR to :CONTINUE
Change status of the ITERATOR to :FAILED
Change status of the ITERATOR to :FINISHED
Constructs ADD-INFO control
Propogates ITERATOR’s value through FUNCTIONS iff its status is :CONTINUE. Each function must accept iterator’s value and return a new iterator.
Destructively change iterator’s status
Combine controls forming a generic control. Controls are applied in order they appear
Make contine iterator
Is ITERATOR :CONTINUE?
Constructs CONVERGED-NUMBER-WITH-ID control
Constructs CONVERGED-VALUE-WITH-ID control
Make failed iterator
Is ITERATOR :FAILED?
Constructs FAILED-VALUE-WITH-ID control
Make finished iterator
Is ITERATOR :FINISHED?
Constructs FINIED-VALUE-WITH-ID control
Fixed point method solving x=f(x) starting from x0.
CONTROL is an object implementing control protocol:
INIT-CONTROL and APPLY-CONTROL.
FUNCTION might change INIT-VALUE destuctively
Returns (VALUES SOLUTION SOLVED-P INDICATOR), where
SOLUTION is the final result,
SOLVED-P is the indicator if the solution was reached successfully,
INDICATOR is an extra indicator of what could have gone wrong.
Update iterators value iff it is :CONTINUE
Iteratively apply CONTROL to iterator Y0 until it finishes
Constructs ITERATOR with given STATUS and VALUE
Constructs LIMIT-ITERATIONS-WITH-ID control
Destrcutively change ITERATOR’s value
Destructively update ITERATOR’s value
Apply CONTROL to a VALUE. CONTROL must return ITERATOR
control-with-id
) (value iteratorex
)) ¶add-info
) (val iteratorex
)) ¶alter-value
) value) ¶converged-number
) value) ¶converged-value
) value) ¶log-computation
) value) ¶limit-iterations
) value) ¶change-status
) value) ¶control-with-id
)) ¶automatically generated reader method
id
.
Returns the indicator of the cause of the final result
iteratorex
)) ¶iteratorex
)) ¶automatically generated reader method
info
.
iteratorex
)) ¶automatically generated writer method
info
.
Initialize CONTROL using INIT-VALUE. Useful for stateful controls
converged-number
) init-value) ¶converged-value
) init-value) ¶log-computation
) init-value) ¶limit-iterations
) init-value) ¶control-with-id
)) ¶automatically generated reader method
iterator
) (new-class-name (eql iteratorex:iteratorex)
) &rest initargs) ¶iteratorex
) out) ¶Control that adds info to an iterator
Control that alters the value if, for example, it is outside of some boundaries. The behaviour is control by FUNCTION.
Function that alters the value. Must return ITERATOR
:function
This slot is read-only.
A generic control class. It is used to combine other controls.
Control mixin that adds ID to other controls
Control that will finish the computation if the number sequence converges. This is a simplified (for numbers) version of CONVERGED-VALUE
Absolute tolerance within which two numbers are considered to be the same
:tolerance
This slot is read-only.
Internal storage of the previous item in the sequence
Extension of CONVERGED-NUMBER with ID info
Controls if the sequence of values is converged (Cauchy criteria) Since the value might change destructively, it requires COPY function to store the copy of the previous value in the sequence
Predicate that checks if two values are close enough for the sequence to be considered convergent
:close-p
This slot is read-only.
Reliably copy the value: the value itself might be
detroyed during the computation, this function must be able to copy it
to reliably compare previus and current value in the sequence
:copy
This slot is read-only.
Final function to apply to value once converged
:final
This slot is read-only.
Internal: stores the previous value (copied) of the sequence
Extension of CONVERGED-VALUE with ID info
Change computation to failed if predicate returns T
(function iterator:->failed)
Extension of FAILED-VALUE with ID info
Change computation to finish if predicate returns T
(function iterator:->finished)
Extension of FINISHED-VALUE with ID info
Computation flow status
Control that fails computation if it exceeds max number of evaluations
Max number of evaluations permitted
:max
This slot is read-only.
Final function to apply to value once failed
:final
This slot is read-only.
Internal storage of the number of evaluations already performed
0
Extension of LIMIT-ITERATIONS with ID info
Control that logs the progress of computation
Function to log the computation process.
Accepts two arguments: (TAG VALUE)
TAG is either :INIT or :APPLY indicating at which point it was called
VALUE is ITERATOR’s value passed.
:log-function
This slot is read-only.
Returns T if a given OBJ is ITERATOR
Reduce (fold left) LIST with FUNCTION starting from INIT-STATE. Supports shortcircuiting if FUNCTION returns REDUCED value
If OBJ is ITERATOR checks its STATUS
alter-value
)) ¶Function that alters the value. Must return ITERATOR
change-status
)) ¶Final transformation to apply to value once predicate is T
change-status
)) ¶Predicate on the value of ITERATOR
change-status
)) ¶Function of iterator changing the status
converged-number
)) ¶converged-number
)) ¶Internal storage of the previous item in the sequence
converged-number
)) ¶Absolute tolerance within which two numbers are considered to be the same
converged-value
)) ¶Predicate that checks if two values are close enough for the sequence to be considered convergent
converged-value
)) ¶Reliably copy the value: the value itself might be
detroyed during the computation, this function must be able to copy it
to reliably compare previus and current value in the sequence
converged-value
)) ¶Final function to apply to value once converged
converged-value
)) ¶converged-value
)) ¶Internal: stores the previous value (copied) of the sequence
limit-iterations
)) ¶Final function to apply to value once failed
limit-iterations
)) ¶Max number of evaluations permitted
limit-iterations
)) ¶limit-iterations
)) ¶Internal storage of the number of evaluations already performed
log-computation
)) ¶Function to log the computation process.
Accepts two arguments: (TAG VALUE)
TAG is either :INIT or :APPLY indicating at which point it was called
VALUE is ITERATOR’s value passed.
Base class for control changing status based on predicate on value
Predicate on the value of ITERATOR
:predicate
This slot is read-only.
Final transformation to apply to value once predicate is T
(function identity)
:final
This slot is read-only.
Function of iterator changing the status
This slot is read-only.
Jump to: | (
-
A B C D F G I L M P R S U V |
---|
Jump to: | (
-
A B C D F G I L M P R S U V |
---|
Jump to: | A C I L P S V |
---|
Jump to: | A C I L P S V |
---|
Jump to: | A C F I L P S |
---|
Jump to: | A C F I L P S |
---|