From fe33b1dc1457e117b7fee00cf4299c3e138bff50 Mon Sep 17 00:00:00 2001 From: MRIDUL JAIN <105979087+Spinachboul@users.noreply.github.com> Date: Mon, 15 Jan 2024 14:05:04 +0530 Subject: [PATCH] Update tensor_prod.md --- docs/src/tensor_prod.md | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/docs/src/tensor_prod.md b/docs/src/tensor_prod.md index 9dd9d2b5..9ab69f0f 100644 --- a/docs/src/tensor_prod.md +++ b/docs/src/tensor_prod.md @@ -25,10 +25,9 @@ end Sampling parameters for training and test data ```@example tensor -n = 30 # Number of training points lb = -5.0 # Lower bound of sampling range ub = 5.0 # Upper bound of sampling range - +n = 30 # Number of training points ``` Visualize training data and the true function @@ -44,9 +43,9 @@ end Generate training and test data ```@example tensor x_train = sample(n, lb, ub, SobolSample()) # Sample training data points -y_train = f.(x_train) # Calculate corresponding function values +y_train = tensor_product_function.(x_train) # Calculate corresponding function values x_test = sample(1000, lb, ub, RandomSample()) # Sample larger test data set -y_test = f.(x_test) # Calculate corresponding true function values +y_test = tensor_product_function.(x_test) # Calculate corresponding true function values ``` Train two surrogates: Lobachevsky and Kriging