Package no.uib.cipr.matrix.distributed
Class DistVector
java.lang.Object
no.uib.cipr.matrix.AbstractVector
no.uib.cipr.matrix.distributed.DistVector
- All Implemented Interfaces:
Serializable
,Iterable<VectorEntry>
,Vector
Deprecated.
Distributed memory vector
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from interface no.uib.cipr.matrix.Vector
Vector.Norm
-
Field Summary
Fields inherited from class no.uib.cipr.matrix.AbstractVector
size
-
Constructor Summary
ConstructorsConstructorDescriptionDistVector
(int size, Communicator comm, Vector x) Deprecated.Constructor for DistVector -
Method Summary
Modifier and TypeMethodDescriptionDeprecated.x = alpha*y + x
void
add
(int index, double value) Deprecated.x(index) += value
copy()
Deprecated.Creates a deep copy of the vectordouble
Deprecated.xT*y
double
get
(int index) Deprecated.Returnsx(index)
Deprecated.Gets the communicator associated with this vectorgetLocal()
Deprecated.Returns the local part of the vectorint[]
Deprecated.Returns which indices are owned by which ranks.iterator()
Deprecated.boolean
local
(int index) Deprecated.Returns true if the insertion index is local to this rank, and no communication is needed afterwards.protected double
norm1()
Deprecated.protected double
norm2()
Deprecated.protected double
Deprecated.protected double
normInf()
Deprecated.scale
(double alpha) Deprecated.x=alpha*x
Deprecated.x=alpha*y
void
set
(int index, double value) Deprecated.x(index) = value
zero()
Deprecated.Zeros all the entries in the vector, while preserving any underlying structureMethods inherited from class no.uib.cipr.matrix.AbstractVector
add, check, checkSize, norm, set, size, toString
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface java.lang.Iterable
forEach, spliterator
-
Constructor Details
-
DistVector
Deprecated.Constructor for DistVector- Parameters:
size
- Global vector sizecomm
- Communicator to usex
- Local vector, its size cannot exceed the global size, and the sum of the local vector sizes must equal the global vector size (this is checked)
-
-
Method Details
-
set
public void set(int index, double value) Deprecated.Description copied from interface:Vector
x(index) = value
- Specified by:
set
in interfaceVector
- Overrides:
set
in classAbstractVector
-
add
public void add(int index, double value) Deprecated.Description copied from interface:Vector
x(index) += value
- Specified by:
add
in interfaceVector
- Overrides:
add
in classAbstractVector
-
get
public double get(int index) Deprecated.Description copied from interface:Vector
Returnsx(index)
- Specified by:
get
in interfaceVector
- Overrides:
get
in classAbstractVector
-
copy
Deprecated.Description copied from interface:Vector
Creates a deep copy of the vector- Specified by:
copy
in interfaceVector
- Overrides:
copy
in classAbstractVector
-
zero
Deprecated.Description copied from interface:Vector
Zeros all the entries in the vector, while preserving any underlying structure- Specified by:
zero
in interfaceVector
- Overrides:
zero
in classAbstractVector
-
scale
Deprecated.Description copied from interface:Vector
x=alpha*x
- Specified by:
scale
in interfaceVector
- Overrides:
scale
in classAbstractVector
- Returns:
- x
-
set
Deprecated.Description copied from interface:Vector
x=alpha*y
- Specified by:
set
in interfaceVector
- Overrides:
set
in classAbstractVector
- Returns:
- x
-
add
Deprecated.Description copied from interface:Vector
x = alpha*y + x
- Specified by:
add
in interfaceVector
- Overrides:
add
in classAbstractVector
- Returns:
- x
-
dot
Deprecated.Description copied from interface:Vector
xT*y
- Specified by:
dot
in interfaceVector
- Overrides:
dot
in classAbstractVector
-
norm1
protected double norm1()Deprecated.- Overrides:
norm1
in classAbstractVector
-
norm2_robust
protected double norm2_robust()Deprecated.- Overrides:
norm2_robust
in classAbstractVector
-
norm2
protected double norm2()Deprecated.- Overrides:
norm2
in classAbstractVector
-
normInf
protected double normInf()Deprecated.- Overrides:
normInf
in classAbstractVector
-
getLocal
Deprecated.Returns the local part of the vector -
getOwnerships
public int[] getOwnerships()Deprecated.Returns which indices are owned by which ranks. The current rank owns the indicesn[comm.rank()]
(inclusive) ton[comm.rank()+1]
(exclusive) -
local
public boolean local(int index) Deprecated.Returns true if the insertion index is local to this rank, and no communication is needed afterwards. -
iterator
Deprecated.- Specified by:
iterator
in interfaceIterable<VectorEntry>
- Overrides:
iterator
in classAbstractVector
-
getCommunicator
Deprecated.Gets the communicator associated with this vector
-
no.uib.cipr.matrix.distributed
package has been deprecated because of a number of hard to fix concurrency bugs. It is distributed only for backwards compatibility, but is not recommended. The utility of this package is questionable, as it does not allow distribution of computation between JVMs or across a network. For many people, distributed computing of multiple matrices can be achieved at a user-level through the JPPF Framework. Users who need to deal with few very large matrices may wish to implement their own storage classes and solvers using JPPF, but this will not be supported directly in matrix-toolkits-java.