001/*
002 * $Id$
003 */
004
005package edu.jas.structure;
006
007
008/**
009 * Regular ring element interface. Defines idempotent operations and idempotent
010 * tests.
011 * @param <C> regular ring element type
012 * @author Heinz Kredel
013 */
014
015public interface RegularRingElem<C extends RegularRingElem<C>> extends GcdRingElem<C> {
016
017
018    /* Get component. 
019     * Not possible to define in interface.
020     * @param i index of component.
021     * @return val(i).
022    public C get(int i);
023     */
024
025
026    /**
027     * Is regular ring element full.
028     * @return If every component is non zero, then true is returned, else
029     *         false.
030     */
031    public boolean isFull();
032
033
034    /**
035     * Is idempotent.
036     * @return If this is a idempotent element then true is returned, else
037     *         false.
038     */
039    public boolean isIdempotent();
040
041
042    /**
043     * Idempotent.
044     * @return S with this*S = this.
045     */
046    public C idempotent();
047
048
049    /**
050     * Regular ring element idempotent complement.
051     * @return 1-this.idempotent().
052     */
053    public C idemComplement();
054
055
056    /**
057     * Regular ring element idempotent and.
058     * @param S Product.
059     * @return this.idempotent() and S.idempotent().
060     */
061    public C idempotentAnd(C S);
062
063
064    /**
065     * Regular ring element idempotent or.
066     * @param S Product.
067     * @return this.idempotent() or S.idempotent().
068     */
069    public C idempotentOr(C S);
070
071
072    /**
073     * Regular ring element fill with idempotent.
074     * @param S Product.
075     * @return fill this with S.idempotent().
076     */
077    public C fillIdempotent(C S);
078
079
080    /**
081     * Regular ring element fill with one.
082     * @return fill this with one.
083     */
084    public C fillOne();
085
086}