DNDSR 0.1.0.dev1+gcd065ad
Distributed Numeric Data Structure for CFV
Loading...
Searching...
No Matches
OversetCart.ProductDecompose Namespace Reference

Functions

 sum_partition_greedy (np.ndarray arr, int n_part=2)
 
 int_factor_divide (int N, int n_part=2)
 

Variables

 prods = int_factor_divide(i)
 
 diffv = prods.max() - prods.min()
 
 arr = np.array([1, 3, 5, 7, 9, 11])
 
int target = 11
 
int index = np.searchsorted(arr, target, side="right") - 1
 

Function Documentation

◆ int_factor_divide()

OversetCart.ProductDecompose.int_factor_divide ( int  N,
int   n_part = 2 
)

Definition at line 25 of file ProductDecompose.py.

Here is the call graph for this function:

◆ sum_partition_greedy()

OversetCart.ProductDecompose.sum_partition_greedy ( np.ndarray  arr,
int   n_part = 2 
)
Partitions numbers into M subsets using Largest-First Decreasing (LFD).

Definition at line 5 of file ProductDecompose.py.

Here is the caller graph for this function:

Variable Documentation

◆ arr

OversetCart.ProductDecompose.arr = np.array([1, 3, 5, 7, 9, 11])

Definition at line 51 of file ProductDecompose.py.

◆ diffv

OversetCart.ProductDecompose.diffv = prods.max() - prods.min()

Definition at line 46 of file ProductDecompose.py.

◆ index

int OversetCart.ProductDecompose.index = np.searchsorted(arr, target, side="right") - 1

Definition at line 56 of file ProductDecompose.py.

◆ prods

OversetCart.ProductDecompose.prods = int_factor_divide(i)

Definition at line 45 of file ProductDecompose.py.

◆ target

int OversetCart.ProductDecompose.target = 11

Definition at line 53 of file ProductDecompose.py.