public PortfolioSimulator getSimulator() {

    final List<GeometricBrownianMotion> tmpAssetProcesses =
        new ArrayList<GeometricBrownianMotion>(myComponents.size());

    for (final SimpleAsset tmpAsset : myComponents) {
      final GeometricBrownianMotion tmpForecast = tmpAsset.forecast();
      tmpForecast.setValue(tmpAsset.getWeight().doubleValue());
      tmpAssetProcesses.add(tmpForecast);
    }

    return new PortfolioSimulator(myCorrelations.toPrimitiveStore(), tmpAssetProcesses);
  }
  @Override
  public List<BigDecimal> getWeights() {

    if (myWeights == null) {

      myWeights = new ArrayList<BigDecimal>(myComponents.size());

      for (final SimpleAsset tmpAsset : myComponents) {
        myWeights.add(tmpAsset.getWeight());
      }
    }

    return myWeights;
  }
  @Override
  protected void reset() {

    myMeanReturn = null;
    myReturnVariance = null;
    myWeights = null;

    myCovariances = null;
    myAssetReturns = null;
    myAssetVolatilities = null;
    myAssetWeights = null;

    for (final SimpleAsset tmpAsset : myComponents) {
      tmpAsset.reset();
    }
  }