65 for(
register G4int a=0;
a < orig.k_size;
a++)
66 { knots[
a] = orig.knots[
a]; }
67 kCarTolerance = orig.kCarTolerance;
72 if (&right ==
this)
return *
this;
74 k_size = right.k_size;
76 for(
register G4int a=0;
a < right.k_size;
a++)
77 knots[
a] = right.knots[
a];
78 kCarTolerance = right.kCarTolerance;
88 knt = knots[order - 1];
91 if (ApxEq( k_value, knt))
97 knt = knots[k_size - order + 1];
100 if (ApxEq( k_value, knt))
106 if ( k_value == knots[k_size - order + 1] )
107 knot_index = k_size - order - 1;
108 else if ( k_value == knots[ order - 1] )
109 knot_index = order - 1;
114 for ( i = 0; i < k_size - 1; i++)
115 if((knots[i]<k_value) && (k_value <= knots[i+1]))
132 for (
G4int i = 0; i < num -
n; i++)
133 knots_to_add[i] = val;
136 new_kv->k_size = num - n +
GetSize();
139 delete [] knots_to_add;
152 G4int old_size = k_size;
154 newknots =
new G4double[k_size + add_size];
156 for ( newptr = 0; newptr < k_size+add_size; newptr++)
157 if ( kv1_ptr >= add_size )
158 newknots[newptr] = knots[kv2_ptr++];
159 else if ( kv2_ptr >= old_size )
160 newknots[newptr] = knots_to_add[kv1_ptr++];
161 else if ( knots_to_add[kv1_ptr] < knots[kv2_ptr])
162 newknots[newptr] = knots_to_add[kv1_ptr++];
164 newknots[newptr] = knots[kv2_ptr++];
174 for (
G4int i = 0; i < k_size; i++)
177 if ( val == knots[i] )
189 kv->k_size = upper-lower;
190 kv->knots =
new G4double[kv->k_size];
192 for (
G4int i = lower; i < upper; i++)
193 kv->knots[i-lower] = knots[i];