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

Class PwIntegralLineSet

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


    public class PwIntegralLineSet
    extends PjWorkshop
    Compute a whole set of integral lines of a given vector field on a triangulated surface for visualization purposes.

    Assign a surface by setGeometry(PgGeometry) and a display where the calculated integral lines will show up by setDisplay(PvDisplayIf) (if you wish that behaviour) and compute the integral lines (makeIntegralLines()). Various parameters may be configured.

    Use method getInfoPanel() to get a control panel for parameters step size, number of steps and index of vector field.

    An action event is fired whenever integral line computation that had been invoked from the info panel is completed.

    Of course you may also use the static method that computes the integral lines direcly (makeIntegralLines(PgElementSet,PgVectorField,PgPolygonSet,double,int).

    See Also:
    Serialized Form
    Author:
    Eike Preuss
    Version:
    09.12.06, 2.00 revised (kp) Moved to jvx.vector from jvx.geom.
    01.03.06, 1.90 revised (ah) PgPolygonOnElementSet.getVertexElemInd() not used anymore.
    10.02.03, 1.80 revised (ep) New methods get/setMaxNumLinesPerElement, and JavaDoc.
    24.01.03, 1.70 revised (ep) Backward integration and maxLinesPerElement combination corrected.
    22.01.03, 1.60 revised (ep) Added set/getIgnoreDirection, set/getLimitNumLinesPerElement.
    22.01.03, 1.50 revised (ep) Added set/getBackwardIntegration.
    20.01.03, 1.40 revised (ep) Added set/getFast method.
    17.12.02, 1.30 revised (ep) Add only polygons with numVertices >= 2.
    14.06.02, 1.20 revised (ep) Now extends PjWorkshop.
    31.12.01, 1.10 revised (ep) Added action listener support. 07.05.01, 1.00 created,revised (ep)
    • Constructor Detail

      • PwIntegralLineSet

        public PwIntegralLineSet()
    • Method Detail

      • init

        public void init()
        Initializes by setting all parameters to initial values and removing computed integral lines. Does not remove the settings for geometry and display!
        Overrides:
        init in class PjWorkshop
      • setGeometry

        public void setGeometry(PgGeometry geo)
        Set the geometry that will be used for integration when using the workshop's info panel or method makeIntegralLines(). This geometry must be a triangulated element set!

        A second call of the method will remove the previous setting. The workshop will register as an update listener to the given geometry to keep being informed about the number of vector fields on it.

        Specified by:
        setGeometry in interface PjWorkshopIf
        Overrides:
        setGeometry in class PjWorkshop
        Parameters:
        geo - triangulated surface with vector field(s)
      • removeGeometry

        public void removeGeometry()
        Removes the reference to the registered element set and removes this as update listener from geometry.
        Overrides:
        removeGeometry in class PjWorkshop
      • setDisplay

        public void setDisplay(PvDisplayIf disp)
        Set the display where computed integral lines will show up when using the workshop's info panel or method makeIntegralLines(). If called with null as argument this method will remove the display settings.

        A second call of the method will remove the previous setting.

        Specified by:
        setDisplay in interface PjWorkshopIf
        Overrides:
        setDisplay in class PjWorkshop
        Parameters:
        disp - display that will be used to present the results, may be null
      • setFast

        public void setFast(boolean flag)
        Use euler-integration.
        Since:
        JavaView 2.49.004
      • getFast

        public boolean getFast()
        Whether euler-integration is used (true) or a 4th order runge kutta method (false).
        Since:
        JavaView 2.49.004
      • setBackwardIntegration

        public void setBackwardIntegration(boolean flag)
        Compute integral lines in negative direction as well.
        Since:
        JavaView 2.49.004
      • getBackwardIntegration

        public boolean getBackwardIntegration()
        Whether integral lines are computed in negative direction as well. The forward and backward integration is concatenated to a single integral line.
        Since:
        JavaView 2.49.004
      • setLimitNumLinesPerElement

        public void setLimitNumLinesPerElement(boolean flag)
        Whether integral lines should stop when they reach a face with a number of passing integral lines that exceeds a given number.
        Since:
        JavaView 2.49.004
        See Also:
        setMaxNumLinesPerElement(int)
      • getLimitNumLinesPerElement

        public boolean getLimitNumLinesPerElement()
        Whether integral lines should stop when they reach a face with a number of passing integral lines that exceeds a given number.
        Since:
        JavaView 2.49.004
      • getMaxNumLinesPerElement

        public int getMaxNumLinesPerElement()
        Gets the maximal number of integral lines that may pass through one face. Is only used when the switch for it is on, see setLimitNumLinesPerElement(boolean).
        Since:
        JavaView 2.49.009
      • setIgnoreDirection

        public void setIgnoreDirection(boolean flag)
        Ignores the direction of vertex based vector fields, i.e. at each point there are two possible vectors: + and - the original vector.
        Since:
        JavaView 2.48.007
      • getIgnoreDirection

        public boolean getIgnoreDirection()
        Whether the direction of vertex based vector fields is ignored, i.e. at each point there are two possible vectors: + and - the original vector.
        Since:
        JavaView 2.48.007
      • removeIntegralLines

        public void removeIntegralLines()
        Removes previously computed set of integral lines from the display and internal uses. Next call of makeIntegralLines() will create a new polygon set, the old polygon set will not be updated with further results but the new one will. This new polygon set will be returned by method getIntegralLines().
        See Also:
        getIntegralLines()
      • addActionListener

        public void addActionListener(java.awt.event.ActionListener listener)
        An action event is fired whenever integral line computation that had been invoked from the info panel is completed.
      • removeActionListener

        public void removeActionListener(java.awt.event.ActionListener listener)
        An action event is fired whenever integral line computation that had been invoked from the info panel is completed.
      • cancel

        public void cancel()
        Removes previously comuted integral lines from display and invokes the same method of super-class.
        Overrides:
        cancel in class PjWorkshop
      • makeIntegralLines

        public static PgPolygonSet makeIntegralLines(PgElementSet geom,
                                                     PgVectorField vec,
                                                     PgPolygonSet out,
                                                     double stepsize,
                                                     int numSteps)
        Static method that computes a set of integral lines on the given geometry of the given vector field. From the center of each element emerges one integral line that is integrated numerically with given step size and number of iterations.
        Parameters:
        geom - the surface, MUST be triangulation!
        vec - vector field on surface geom.
        out - if not equal null, results are written here.
        stepsize - used for integration of each integral line.
        numSteps - used for integration of each integral line.
        Returns:
        parameter out if it is not null, otherwise a new polygon set that contains the results.
        See Also:
        PnGeodesicRK, PgPolygonOnElementSet
      • makeIntegralLines

        public static PgPolygonSet makeIntegralLines(PgElementSet geom,
                                                     PgVectorField vec,
                                                     PgPolygonSet out,
                                                     double stepsize,
                                                     int numSteps,
                                                     int elemStep)
        Static method that computes a set of integral lines on the given geometry of the given vector field. From the center of each element emerges one integral line that is integrated numerically with given step size and number of iterations.
        Parameters:
        geom - the surface, MUST be triangulation!
        vec - vector field on surface geom.
        out - if not equal null, results are written here.
        stepsize - used for integration of each integral line.
        numSteps - used for integration of each integral line.
        elemStep - compute integral line from every elemStep-th element.
        Returns:
        parameter out if it is not null, otherwise a new polygon set that contains the results.
        See Also:
        PnGeodesicRK, PgPolygonOnElementSet
      • makeIntegralLines

        public static PgPolygonSet makeIntegralLines(PgElementSet geom,
                                                     PgVectorField vec,
                                                     PgPolygonSet out,
                                                     double stepsize,
                                                     int numSteps,
                                                     int elemStep,
                                                     boolean fast,
                                                     boolean ignoreDir,
                                                     boolean backward,
                                                     int maxLinesPerElement,
                                                     int[] elementCount)
        Static method that computes a set of integral lines on the given geometry of the given vector field. From the center of each element emerges one integral line that is integrated numerically with given step size and number of iterations.
        Parameters:
        geom - the surface, MUST be triangulation!
        vec - vector field on surface geom.
        out - if not equal null, results are written here.
        stepsize - used for integration of each integral line.
        numSteps - used for integration of each integral line.
        elemStep - compute integral line from every elemStep-th element.
        fast - use euler-integration?
        ignoreDir - for use of PnVertexRKIgnoreDirection
        backward - also go along negative vector field
        Returns:
        parameter out if it is not null, otherwise a new polygon set that contains the results.
        See Also:
        PnGeodesicRK, PgPolygonOnElementSet
"JavaView? v5.03.003"

"

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

You see the box below because you did not login.