It is not clear what you really want. Above "name" is
'AlgebraGivenByStructuralConstants(...)' with arguments instead of
dots. The instruction you gave assigns algebra (a type) to a
variable. This variable is holding a type, which may look
somewhat unusual if you are used to different programming
languages, but otherwise is usual programming language variable.
If you do not want to write instructions with many different
variable names, then you can use usual programming language
solutions: use arrays or lists. Simple example (using
simpler types than ALGSC) for using array is:
(3) -> a_tab := new(10, Void)$PrimitiveArray(Type)
LISP output:
UNPRINTABLE
Type: PrimitiveArray(Type)
(4) -> a_tab(1) := DoubleFloat
(4) DoubleFloat
Type: Type
(5) -> 1::a_tab(1)
(5) 1.0
Type: DoubleFloat
So, you can assign types to array entries, and you can reference
array entries where you need types. Of course, instend of 1 you
can use different indices, which in case of PrimitiveArray is from
0 up to upper value which in our case is 9 (since we requested
array having 10 elements).
Similar example using a list:
(8) -> l : List(Type) := []
LISP output:
NIL
Type: List(Type)
(9) -> l := cons(DoubleFloat, l)
LISP output:
(UNPRINTABLE)
Type: List(Type)
(10) -> 1.0::first(l)
(10) 1.0
Type: DoubleFloat
Both fit well to use in a loop.
Note: there are significant limitations to what can be done with
types in similar computations. In particular, you may be forced
to write your code in Spad.
--
Waldek Hebisch