001/*
002 * $Id$
003 */
004
005package edu.jas.structure;
006
007
008/**
009 * Algabra element interface.
010 * @param <A> algebra type
011 * @param <C> scalar type
012 * @author Heinz Kredel
013 */
014public interface AlgebraElem<A extends AlgebraElem<A, C>, C extends RingElem<C>> extends RingElem<A> {
015
016
017    /**
018     * Scalar multiplication. Multiply this by a scalar.
019     * @param s scalar
020     * @return this * s.
021     */
022    public A scalarMultiply(C s);
023
024
025    /**
026     * Linear combination.
027     * @param a scalar
028     * @param b algebra element
029     * @param s scalar
030     * @return a * b + this * s.
031     */
032    public A linearCombination(C a, A b, C s);
033
034
035    /**
036     * Linear combination.
037     * @param b algebra element
038     * @param s scalar
039     * @return b + this * s.
040     */
041    public A linearCombination(A b, C s);
042
043}