tarf_monte_carlo 3.21 → 3.22
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/ext/tarf_monte_carlo/tarf_monte_carlo.c +3 -2
- data/lib/tarf_monte_carlo/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e0c41c44926141bcfb2844cf5aeecd360c2562f6680f9d4efaeaf7a0f5081fa4
|
4
|
+
data.tar.gz: ac6e38b63727f83e65758da64ab4666261a94522bf5c2c4e1f6768c2e4e23597
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 369f864b9d16f6888a04e547e40baea1ff012cab62dfb49167e5e91545238bee800b8159eb3e91b84bbf85cf01e89faf6c6e1f14380a0b6f56df11b3f2a93160
|
7
|
+
data.tar.gz: 889ba91d7510b289de991c41d89d8dc766ac2b60c30bb0aa69aac9264e1649ed6517d3c8b123bb88c24559436edc3a3c9ce969a7e6e57ad28ace3c08a94f345e
|
@@ -212,9 +212,9 @@ VALUE method_run_monte_carlo( VALUE self, VALUE args ) {
|
|
212
212
|
|
213
213
|
if (ConvertNotional == 1){
|
214
214
|
if(Spot < *( Ps_array + leg )){
|
215
|
-
Ns_array[leg] =
|
215
|
+
Ns_array[leg] = *(Ns_array + leg) / *( LSts_array + leg );
|
216
216
|
} else {
|
217
|
-
Ns_array[leg] =
|
217
|
+
Ns_array[leg] = *(Ns_array + leg) / *( USts_array + leg );
|
218
218
|
}
|
219
219
|
}
|
220
220
|
|
@@ -365,6 +365,7 @@ VALUE method_run_monte_carlo( VALUE self, VALUE args ) {
|
|
365
365
|
} else if( KType == POINTS || KType == PIVOT_POINTS || KType == COLLAR_POINTS || KType == DOUBLE_STRIKE_POINTS ) {
|
366
366
|
for( leg = 0; leg < NL; ++leg ) {
|
367
367
|
// simulation normal
|
368
|
+
rb_p(DBL2NUM(*(Ns_array + leg )));
|
368
369
|
if ( ko_so_far > 0.0 ) {
|
369
370
|
if( sim[leg] >= 0.0 ) {
|
370
371
|
// knock out condition
|