Documentation of 'jvx.vector.PwHodge' Java class
PwHodge ("JavaView Reference Manual")
"JavaView? v5.03.003"
jvx.vector

Class PwHodge

  • All Implemented Interfaces:
    java.io.Serializable, java.lang.Cloneable, PsUpdateIf, PjWorkshopIf


    public class PwHodge
    extends PjWorkshop
    Study Hodge decomposition of discrete vector fields. A vector field is split in gradient and rotation free parts with a remaining harmonic component.
    See Also:
    Serialized Form
    Author:
    Konrad Polthier, Eike Preuss
    Version:
    27.10.12, 4.00 revised (kp) Full revision of 2d case.
    07.10.07, 3.50 revised (kp) Full revision of update mechanism and optimization.
    09.12.06, 3.00 revised (kp) Moved to jvx.vector from jvx.geom.
    06.05.03, 2.80 revised (ep) Beta methods for computing rotational features.
    19.06.02, 2.70 revised (ep) Added method getZExtrema.
    28.01.02, 2.60 revised (ep) New workshop classes and internationalization.
    28.05.01, 2.50 revised (ep) Get displays WITH FRAME from viewer, initialize 0-gradient properties at begin.
    17.05.01, 2.40 revised (ep) 5 displays to 3 displays, corrected update of minimizers.
    11.12.00, 2.30 revised (ep) Made displays available to other classes.
    10.12.00, 2.20 revised (ep) May change zero bounds condition for U and W separately.
    06.06.00, 2.10 revised (ep) Moved to separate workshop.
    06.03.00, 2.00 revised (ep) Corrected updates and made various changes.
    24.11.99, 1.00 created (kp).
    • Constructor Detail

      • PwHodge

        public PwHodge()
    • Method Detail

      • init

        public void init()
        Description copied from class: PjWorkshop
        Initialize and reset project, stops the running animation if any. Does not reset any registered display nor geometry. They must be reset individually in each subclass.
        Overrides:
        init in class PjWorkshop
      • close

        public void close()
        Removes geometry and displays from workshop, and closes super workshop.
        Overrides:
        close in class PjWorkshop
        Version:
        06.08.05, 1.10 revised (kp) Code tuned.
      • reset

        public void reset()
        TODO: Not implemented yet.
        Overrides:
        reset in class PjWorkshop
      • removeGeometry

        public void removeGeometry()
        Description copied from class: PjWorkshop
        Remove the assigned geometry and its backup clone. Subclasses frequently overwrite this method but are advised to call this method.
        Overrides:
        removeGeometry in class PjWorkshop
      • setGeometry

        public void setGeometry(PgGeometry geom)
        Description copied from class: PjWorkshop
        Assign a geometry on which this workshop operates, and create a backup clone of the geometry. The backup geometry is restored if the workshop is canceled.

        Subclasses frequently overwrite this method but are advised to call this method.

        Specified by:
        setGeometry in interface PjWorkshopIf
        Overrides:
        setGeometry in class PjWorkshop
        Parameters:
        geom - the workshop modifies this geometry.
      • getVectorFieldIndex

        public int getVectorFieldIndex()
        Get index of vector field of domain geometry.
      • selectVectorField

        public void selectVectorField(int vfIndex)
        Selects a vector field of the underlying domain.
        Parameters:
        vfIndex - Select element based vector field of current geometry
      • setZeroBounds

        public void setZeroBounds(boolean flag)
        Whether the two resulting potentials should be zero on the boundary. That means that the vector field components are orthogonal and tangential to the boundary edges respectively.
      • setZeroBoundsU

        public void setZeroBoundsU(boolean flag)
        Sets zero boundary condition of potential of rotation free part (so this vector field is tangential to boundary edges if set).
      • getZeroBoundsU

        public boolean getZeroBoundsU()
      • setZeroBoundsV

        public void setZeroBoundsV(boolean flag)
        Sets zero boundary condition of potential of divergence free part (so this part is orthogonal to boundary edges if set).
      • getZeroBoundsV

        public boolean getZeroBoundsV()
      • isEnabledAutoDecompose

        public boolean isEnabledAutoDecompose()
        Determines if automatic Hodge decomposition on updates of geometry is enabled.
        Returns:
        true if auto Hodge decomposition is enabled
      • setEnabledAutoDecompose

        public void setEnabledAutoDecompose(boolean flag)
        Automatically compute Hodge decomposition on updates of geometry.
        Parameters:
        flag - true to enable automatic Hodge decomposition
      • getPotentialU

        public PgElementSet getPotentialU()
        Call method minimize() before using this method.
        Returns:
        potential of rotation free part
      • getPotentialW

        public PgElementSet getPotentialW()
        Call method minimize() before using this method.
        Returns:
        potential of divergence free part
      • getUGraph

        public PgSurfaceGraph getUGraph()
        Call method minimize() before using this method.
        Returns:
        potential of rotation free part
      • getWGraph

        public PgSurfaceGraph getWGraph()
        Call method minimize() before using this method.
        Returns:
        potential of divergence free part
      • setVisibleComponent

        public void setVisibleComponent(int index,
                                        boolean visible)
      • getVisibleComponent

        public boolean getVisibleComponent(int index)
      • setVisibleGraph

        public void setVisibleGraph(int index,
                                    boolean visible)
      • getVisibleGraph

        public boolean getVisibleGraph(int index)
      • setVisibleFeat

        public void setVisibleFeat(int index,
                                   boolean visible)
      • getVisibleFeat

        public boolean getVisibleFeat(int index)
      • setDetectionFlags

        public void setDetectionFlags(int flag)
        Sets which features to include in feature detection. Default is to detect nothing (flag==0).
        Parameters:
        flag - binary flag; combine the DETECT_... constants with binary OR operator.
      • getDetectionFlags

        public int getDetectionFlags()
        Compare the DETECT_... constants.
        See Also:
        setDetectionFlags(int)
      • setIconScale

        public void setIconScale(double value)
        Scales the icons that are drawn for sinks, sources, vortices and saddles.
        Parameters:
        value - default is 1.
      • isShowingDisplay

        public boolean isShowingDisplay(int dispIndex)
        Handling of the displays that show the vector field components and the potentials.
      • showDisplay

        public void showDisplay(int dispIndex,
                                boolean bVisible)
        Handling of the displays that show the vector field components and the potentials.
      • getDisplay

        public PvDisplayIf getDisplay(int dispIndex)
        Returns one of the three displays: rotation-free, divergence-free and harmonic component and their features.
        Parameters:
        dispIndex - 0-2
      • decompose

        public void decompose()
        Initiates minimization of the two energies that produce the three parts of the decomposition. As the minimization is done in separate threads this method perhaps returns without instant effect. The update method of the parent of this PwHodge object is called with this object as argument when the computation of the vector field parts is finished.

        A call of minimize() will terminate instantly, if there is already an unterminated minimization process running at the moment!!! To ensure that a new minimization is initiated, call stop() first and then minimize()!

      • stop

        public void stop()
        Stop minimization explicitly before it is completed. update(this) needs to be called to inform info panel.
      • getZExtrema

        public static PgPointSet getZExtrema(PgElementSet surface,
                                             java.awt.Color min,
                                             java.awt.Color other,
                                             java.awt.Color max,
                                             double eps)
        Extract local extreme with respect to z-direction and return as new point set.
"JavaView? v5.03.003"

"

The software JavaView? is copyright protected. All Rights Reserved.
"

You see the box below because you did not login.