text:
= 2.1.0 Recommmend use the latest tensorflow-addons which is compatiable with your tf version. Hi everyone! dice_loss targets [None, 1, 96, 96, 96] predictions [None, 2, 96, 96, 96] targets.dtype predictions.dtype dice_loss is_channels_first: True skip_background: False is_onehot_targets False Make multi-gpu optimizer The DeepLearning.AI TensorFlow Developer Professional Certificate program teaches you applied machine learning skills with TensorFlow so you can build and train powerful models. The following function is quite popular in data competitions: Note that $$\text{CE}$$ returns a tensor, while $$\text{DL}$$ returns a scalar for each image in the batch. Module provides regularization energy functions for ddf. # tf.Tensor(0.7360604, shape=(), dtype=float32). Since TensorFlow 2.0, the class BinaryCrossentropy has the argument reduction=losses_utils.ReductionV2.AUTO. In this post, I will always assume that tf.keras.layers.Sigmoid() is not applied (or only during prediction). In this post, I will implement some of the most common loss functions for image segmentation in Keras/TensorFlow. Deep-learning has proved in recent years to be a powerful tool for image analysis and is now widely used to segment both 2D and 3D medical images. TensorFlow is one of the most in-demand and popular open-source deep learning frameworks available today. Focal loss (FL) [2] tries to down-weight the contribution of easy examples so that the CNN focuses more on hard examples. Instead of using a fixed value like beta = 0.3, it is also possible to dynamically adjust the value of beta. To decrease the number of false positives, set $$\beta < 1$$. [1] S. Xie and Z. Tu. But off the beaten path there exist custom loss functions you may need to solve a certain problem, which are constrained only by valid tensor operations. Tversky index (TI) is a generalization of the Dice coefficient. Tips. Biar tidak bingung.dan di sini tensorflow yang digunakan adalah tensorflow 2.1 yang terbaru. 27 Sep 2018. However, then the model should not contain the layer tf.keras.layers.Sigmoid() or tf.keras.layers.Softmax(). It is used in the case of class imbalance. Generally In machine learning models, we are going to predict a value given a set of inputs. A negative value means class A and a positive value means class B. We can see that $$\text{DC} \geq \text{IoU}$$. Tensorflow model for predicting dice game decisions. [2] T.-Y. Example Balanced cross entropy (BCE) is similar to WCE. Hence, it is better to precompute the distance map and pass it to the neural network together with the image input. Lars' Blog - Loss Functions For Segmentation. The loss value is much high for a sample which is misclassified by the classifier as compared to the loss value corresponding to a well-classified example. I was confused about the differences between the F1 score, Dice score and IoU (intersection over union). Deformation Loss¶. dice_helpers_tf.py contains the conventional Dice loss function as well as clDice loss and its supplementary functions. Direkomendasikan untuk terus melakukan training hingga loss di bawah 0.05 dengan steady. I'm pretty new to Tensorflow and I'm trying to write a simple Cross Entropy loss function. [6] M. Berman, A. R. Triki, M. B. Blaschko. try: # %tensorflow_version only exists in Colab. However, mIoU with dice loss is 0.33 compared to cross entropyÂ´s 0.44 mIoU, so it has failed in that regard. I derive the formula in the section on focal loss. You can find the complete game, ... are the RMSProp optimizer and sigmoid-cross-entropy loss appropriate here? Loss functions applied to the output of a model aren't the only way to create losses. ... For my first ML project I have modeled a dice game called Ten Thousand, or Farkle, depending on who you ask, as a vastly over-engineered solution to a computer player. There are a lot of simplifications possible when implementing FL. If you are using keras, just put sigmoids on your output layer and binary_crossentropy on your cost function. shape = [batch_size, d0, .. dN], except sparse loss functions such as sparse categorical crossentropy where shape = [batch_size, d0, .. dN-1] y_pred: The predicted values. (max 2 MiB). By now I found out that F1 and Dice mean the same thing (right?) Due to numerical instabilities clip_by_value becomes then necessary. Example: Let $$\mathbf{P}$$ be our real image, $$\mathbf{\hat{P}}$$ the prediction and $$\mathbf{L}$$ the result of the loss function. To decrease the number of false negatives, set $$\beta > 1$$. binary). regularization losses). U-Net: Convolutional Networks for Biomedical Image Segmentation, 2015. When writing the call method of a custom layer or a subclassed model, you may want to compute scalar quantities that you want to minimize during training (e.g. Some deep learning libraries will automatically apply reduce_mean or reduce_sum if you don’t do it. You can see in the original code that TensorFlow sometimes tries to compute cross entropy from probabilities (when from_logits=False). I wrote something that seemed good to me … This is why TensorFlow has no function tf.nn.weighted_binary_entropy_with_logits. There is only tf.nn.weighted_cross_entropy_with_logits. To pass the weight matrix as input, one could use: The Dice coefficient is similar to the Jaccard Index (Intersection over Union, IoU): where TP are the true positives, FP false positives and FN false negatives. However, it can be beneficial when the training of the neural network is unstable. The ground truth can either be $$\mathbf{P}(Y = 0) = p$$ or $$\mathbf{P}(Y = 1) = 1 - p$$. which is just the regular Dice coefficient. Custom loss function in Tensorflow 2.0. Note: Nuestra comunidad de Tensorflow ha traducido estos documentos. This means $$1 - \frac{2p\hat{p}}{p + \hat{p}}$$ is never used for segmentation. TensorFlow: What is wrong with my (generalized) dice loss implementation. I have changed the previous way that putting loss function and accuracy function in the CRF layer. %tensorflow_version 2.x except Exception: pass import tensorflow as tf from tensorflow import keras from tensorflow.keras import layers print(tf.__version__) 2.3.0 import tensorflow_docs as tfdocs import tensorflow_docs.plots import tensorflow_docs.modeling Dataset Auto MPG Note: Nuestra comunidad de Tensorflow ha traducido estos documentos. Dice coefficient¶ tensorlayer.cost.dice_coe (output, target, loss_type='jaccard', axis=(1, 2, 3), smooth=1e-05) [source] ¶ Soft dice (Sørensen or Jaccard) coefficient for comparing the similarity of two batch of data, usually be used for binary image segmentation i.e. The values $$w_0$$, $$\sigma$$, $$\beta$$ are all parameters of the loss function (some constants). Calculating the exponential term inside the loss function would slow down the training considerably. By using our site, you acknowledge that you have read and understand our Cookie Policy, Privacy Policy, and our Terms of Service. An implementation of Lovász-Softmax can be found on github. With respect to the neural network output, the numerator is concerned with the common activations between our prediction and target mask, where as the denominator is concerned with the quantity of activations in each mask separately . deepreg.model.loss.deform.compute_bending_energy (ddf: tensorflow.Tensor) → tensorflow.Tensor¶ Calculate the bending energy based on second-order differentiation of ddf using central finite difference. For example, on the left is a mask and on the right is the corresponding weight map. … IÂ´m now wondering whether my implementation is correct: Some implementations I found use weights, though I am not sure why, since mIoU isnÂ´t weighted either. Serum Drunk Elephant, Cloudera Vmware Installation, Graco Slim Snacker High Chair Gala, Is Vinegar Leaf Bitter, Read The Lone Wolf Penelope Sky Online, " />
Select Page

The prediction can either be $$\mathbf{P}(\hat{Y} = 0) = \hat{p}$$ or $$\mathbf{P}(\hat{Y} = 1) = 1 - \hat{p}$$. If a scalar is provided, then the loss is simply scaled by the given value. Note that this loss does not rely on the sigmoid function (“hinge loss”). By plotting accuracy and loss, we can see that our model is still performing better on the Training set as compared to the validation set, but still, it is improving in performance. Then $$\mathbf{L} = \begin{bmatrix}-1\log(0.5) + l_2 & -1\log(0.6) + l_2\\-(1 - 0)\log(1 - 0.2) + l_2 & -(1 - 0)\log(1 - 0.1) + l_2\end{bmatrix}$$, where, Next, we compute the mean via tf.reduce_mean which results in $$\frac{1}{4}(1.046 + 0.8637 + 0.576 + 0.4583) = 0.736$$. I will only consider the case of two classes (i.e. In order to speed up the labeling process, I only annotated with parallelogram shaped polygons, and I copied some annotations from a larger dataset. You can use the add_loss() layer method to keep track of such loss terms. The model has a set of weights and biases that you can tune based on a set of input data. The paper is also listing the equation for dice loss, not the dice equation so it may be the whole thing is squared for greater stability. When combining different loss functions, sometimes the axis argument of reduce_mean can become important. I thought itÂ´s supposed to work better with imbalanced datasets and should be better at predicting the smaller classes: I initially thought that this is the networks way of increasing mIoU (since my understanding is that dice loss optimizes dice loss directly). For multiple classes, it is softmax_cross_entropy_with_logits_v2 and CategoricalCrossentropy/SparseCategoricalCrossentropy. Instead I choose to use ModelWappers (refered to jaspersjsun), which is more clean and flexible. Loss Function in TensorFlow. Loss Functions For Segmentation. The predictions are given by the logistic/sigmoid function $$\hat{p} = \frac{1}{1 + e^{-x}}$$ and the ground truth is $$p \in \{0,1\}$$. Some people additionally apply the logarithm function to dice_loss. Setiap step training tensorflow akan terlihat loss yang dihasilkan. This way we combine local ($$\text{CE}$$) with global information ($$\text{DL}$$). Weighted cross entropy (WCE) is a variant of CE where all positive examples get weighted by some coefficient. Does anyone see anything wrong with my dice loss implementation? The paper [3] adds to cross entropy a distance function to force the CNN to learn the separation border between touching objects. In segmentation, it is often not necessary. The Lovász-Softmax loss: A tractable surrogate for the optimization of the intersection-over-union measure in neural networks, 2018. In Keras the loss function can be used as follows: It is also possible to combine multiple loss functions. One last thing, could you give me the generalised dice loss function in keras-tensorflow?? TI adds a weight to FP (false positives) and FN (false negatives). Ahmadi. Machine learning, computer vision, languages. Deep-learning segmentation frameworks rely not only on the choice of network architecture but also on the choice of loss function. If we had multiple classes, then $$w_c(p)$$ would return a different $$\beta_i$$ depending on the class $$i$$. [5] S. S. M. Salehi, D. Erdogmus, and A. Gholipour. Como las traducciones de la comunidad son basados en el "mejor esfuerzo", no hay ninguna garantia que esta sea un reflejo preciso y actual de la Documentacion Oficial en Ingles.Si tienen sugerencias sobre como mejorar esta traduccion, por favor envian un "Pull request" al siguiente repositorio tensorflow/docs. Dimulai dari angka tinggi dan terus mengecil. Sunny Guha in Towards Data Science. I pretty faithfully followed online examples. TensorFlow uses the same simplifications for sigmoid_cross_entropy_with_logits (see the original code). Jumlah loss akan berbeda dari setiap model yang akan di pakai untuk training. Works with both image data formats "channels_first" and … tensorflow >= 2.1.0 Recommmend use the latest tensorflow-addons which is compatiable with your tf version. Hi everyone! dice_loss targets [None, 1, 96, 96, 96] predictions [None, 2, 96, 96, 96] targets.dtype predictions.dtype dice_loss is_channels_first: True skip_background: False is_onehot_targets False Make multi-gpu optimizer The DeepLearning.AI TensorFlow Developer Professional Certificate program teaches you applied machine learning skills with TensorFlow so you can build and train powerful models. The following function is quite popular in data competitions: Note that $$\text{CE}$$ returns a tensor, while $$\text{DL}$$ returns a scalar for each image in the batch. Module provides regularization energy functions for ddf. # tf.Tensor(0.7360604, shape=(), dtype=float32). Since TensorFlow 2.0, the class BinaryCrossentropy has the argument reduction=losses_utils.ReductionV2.AUTO. In this post, I will always assume that tf.keras.layers.Sigmoid() is not applied (or only during prediction). In this post, I will implement some of the most common loss functions for image segmentation in Keras/TensorFlow. Deep-learning has proved in recent years to be a powerful tool for image analysis and is now widely used to segment both 2D and 3D medical images. TensorFlow is one of the most in-demand and popular open-source deep learning frameworks available today. Focal loss (FL) [2] tries to down-weight the contribution of easy examples so that the CNN focuses more on hard examples. Instead of using a fixed value like beta = 0.3, it is also possible to dynamically adjust the value of beta. To decrease the number of false positives, set $$\beta < 1$$. [1] S. Xie and Z. Tu. But off the beaten path there exist custom loss functions you may need to solve a certain problem, which are constrained only by valid tensor operations. Tversky index (TI) is a generalization of the Dice coefficient. Tips. Biar tidak bingung.dan di sini tensorflow yang digunakan adalah tensorflow 2.1 yang terbaru. 27 Sep 2018. However, then the model should not contain the layer tf.keras.layers.Sigmoid() or tf.keras.layers.Softmax(). It is used in the case of class imbalance. Generally In machine learning models, we are going to predict a value given a set of inputs. A negative value means class A and a positive value means class B. We can see that $$\text{DC} \geq \text{IoU}$$. Tensorflow model for predicting dice game decisions. [2] T.-Y. Example Balanced cross entropy (BCE) is similar to WCE. Hence, it is better to precompute the distance map and pass it to the neural network together with the image input. Lars' Blog - Loss Functions For Segmentation. The loss value is much high for a sample which is misclassified by the classifier as compared to the loss value corresponding to a well-classified example. I was confused about the differences between the F1 score, Dice score and IoU (intersection over union). Deformation Loss¶. dice_helpers_tf.py contains the conventional Dice loss function as well as clDice loss and its supplementary functions. Direkomendasikan untuk terus melakukan training hingga loss di bawah 0.05 dengan steady. I'm pretty new to Tensorflow and I'm trying to write a simple Cross Entropy loss function. [6] M. Berman, A. R. Triki, M. B. Blaschko. try: # %tensorflow_version only exists in Colab. However, mIoU with dice loss is 0.33 compared to cross entropyÂ´s 0.44 mIoU, so it has failed in that regard. I derive the formula in the section on focal loss. You can find the complete game, ... are the RMSProp optimizer and sigmoid-cross-entropy loss appropriate here? Loss functions applied to the output of a model aren't the only way to create losses. ... For my first ML project I have modeled a dice game called Ten Thousand, or Farkle, depending on who you ask, as a vastly over-engineered solution to a computer player. There are a lot of simplifications possible when implementing FL. If you are using keras, just put sigmoids on your output layer and binary_crossentropy on your cost function. shape = [batch_size, d0, .. dN], except sparse loss functions such as sparse categorical crossentropy where shape = [batch_size, d0, .. dN-1] y_pred: The predicted values. (max 2 MiB). By now I found out that F1 and Dice mean the same thing (right?) Due to numerical instabilities clip_by_value becomes then necessary. Example: Let $$\mathbf{P}$$ be our real image, $$\mathbf{\hat{P}}$$ the prediction and $$\mathbf{L}$$ the result of the loss function. To decrease the number of false negatives, set $$\beta > 1$$. binary). regularization losses). U-Net: Convolutional Networks for Biomedical Image Segmentation, 2015. When writing the call method of a custom layer or a subclassed model, you may want to compute scalar quantities that you want to minimize during training (e.g. Some deep learning libraries will automatically apply reduce_mean or reduce_sum if you don’t do it. You can see in the original code that TensorFlow sometimes tries to compute cross entropy from probabilities (when from_logits=False). I wrote something that seemed good to me … This is why TensorFlow has no function tf.nn.weighted_binary_entropy_with_logits. There is only tf.nn.weighted_cross_entropy_with_logits. To pass the weight matrix as input, one could use: The Dice coefficient is similar to the Jaccard Index (Intersection over Union, IoU): where TP are the true positives, FP false positives and FN false negatives. However, it can be beneficial when the training of the neural network is unstable. The ground truth can either be $$\mathbf{P}(Y = 0) = p$$ or $$\mathbf{P}(Y = 1) = 1 - p$$. which is just the regular Dice coefficient. Custom loss function in Tensorflow 2.0. Note: Nuestra comunidad de Tensorflow ha traducido estos documentos. This means $$1 - \frac{2p\hat{p}}{p + \hat{p}}$$ is never used for segmentation. TensorFlow: What is wrong with my (generalized) dice loss implementation. I have changed the previous way that putting loss function and accuracy function in the CRF layer. %tensorflow_version 2.x except Exception: pass import tensorflow as tf from tensorflow import keras from tensorflow.keras import layers print(tf.__version__) 2.3.0 import tensorflow_docs as tfdocs import tensorflow_docs.plots import tensorflow_docs.modeling Dataset Auto MPG Note: Nuestra comunidad de Tensorflow ha traducido estos documentos. Dice coefficient¶ tensorlayer.cost.dice_coe (output, target, loss_type='jaccard', axis=(1, 2, 3), smooth=1e-05) [source] ¶ Soft dice (Sørensen or Jaccard) coefficient for comparing the similarity of two batch of data, usually be used for binary image segmentation i.e. The values $$w_0$$, $$\sigma$$, $$\beta$$ are all parameters of the loss function (some constants). Calculating the exponential term inside the loss function would slow down the training considerably. By using our site, you acknowledge that you have read and understand our Cookie Policy, Privacy Policy, and our Terms of Service. An implementation of Lovász-Softmax can be found on github. With respect to the neural network output, the numerator is concerned with the common activations between our prediction and target mask, where as the denominator is concerned with the quantity of activations in each mask separately . deepreg.model.loss.deform.compute_bending_energy (ddf: tensorflow.Tensor) → tensorflow.Tensor¶ Calculate the bending energy based on second-order differentiation of ddf using central finite difference. For example, on the left is a mask and on the right is the corresponding weight map. … IÂ´m now wondering whether my implementation is correct: Some implementations I found use weights, though I am not sure why, since mIoU isnÂ´t weighted either.


text:
# Regression analysis of two data sets

I have two data sets, both resemble $y = x^2$, but say I don't know that yet. They are both evenly sampled, but the sampling rates are not the same between them, and they exist over different domains. Both sets may return data at the same $x$ value. How do I perform a regression over such a data set?

If I combine them into one large dataset, the fit will be weighted towards the dataset that has the higher density points (or the one with more total points maybe?) But, I want the two datasets to be weighted evenly in the $x$ dimension - that is, even though there is much higher data density around the point $x=5$ for the red set compared to the black set, I would want the black point to have as much weight as the red points between say $x = 4.5$ and $x=5.5$. I feel this is a very naive way of saying it, but perhaps someone with a stats background can fix this up.

• Why do you want to merge these dataset ? You have a superbe fit for each one. To this respect the pink curve is deceiving. Why not instead adding a dummy variable in your regression indicating if your point comes from the dataset 1 or 2 ? – brumar Jun 24 '15 at 7:11
• Because I want to reduce them to one set that best matches the setup. – James Jun 24 '15 at 11:10
• What do you call the "setup" ? y is your dependent variable, right ? Oh...Or maybe it's just a fictitious example to have an answer for your more complex case ? – brumar Jun 24 '15 at 12:26
• Yes, this is a simplified version of something else I want to do. – James Jun 25 '15 at 0:09

You could use weighted regression to achieve your goal. Apart from the data, for each observation a weight is given that indicates how important the error for that observation is. More information and an example here: How to use weights in function lm in R?

• How can the weights be calculated? – James Jun 25 '15 at 0:10
• The weights are subjective. In your case, the Data1 errors shoud be weighed more than the Data2 errors. Try 2 and 1 respectively first, and go from there. – spdrnl Jun 25 '15 at 9:48

Are these two datasets obtained by sampling the same population? And is the data longitudinal/correlated (eg. are you sampling the same two lab mice over and over again)? If the two datasets are sampled from the same population, and the data is not longitudinal/correlated, then in my mind it is fine to merge the data. You are simply adding more data points to your sample. The difference in domain is not an issue, as long as you actually want to model the data for that entire domain.

But, I want the two datasets to be weighted evenly in the x dimension - that is, even though there is much higher data density around the point $x=5$ for the red set compared to the black set, I would want the black point to have as much weight as the red points between say $x=4.5$ and $x=5.5$.

By this, do you mean that you want ONE black point at $x=5$ to equal in weight the MULTIPLE red points between $x=4.5$ and $x=5.5$? This seems strange to me, because you're essentially saying that you trust the black measurements much more than the red measurements, but if you are using the same setup and same sampling population, I don't see why this should be the case?

• From what it sounds like, you are not trying to compare the two methods, but rather trying to define the relationship between $x$ and $y$ using the two datasets. If the only difference between the two datasets are sampling intervals (I assume this is what you meant by resolution?), and the data is not sensitive to any other parameters like time (ie. on average, you would not expect to observe different $y$ given the same $x$, within measurement and random error), I see no problem in combining the data and fitting one model to it. – dwhdai Jan 4 '17 at 15:29

format: plain


text:
## MATH1111 Quizzes

The Exponential Function Quiz
Web resources available Questions

This quiz tests the work covered in Lecture 2 and corresponds to Section 1.2 of the text Calculus: Single and Multivariable (Hughes-Hallett, Gleason, McCallum et al.).
There is no web quiz from Wiley for this section.
There are two sections of economics quiz site that would be useful, Exponential Graphs and Exponential Functions.

The Mathematics Learning Centre has a booklet on Introduction to Exponents and Logarithms and tutors who can help you with the concepts.

There are some animations available at http://archives.math.utk.edu/visual.calculus/0/exp˙log.5/. The Java applet doesn’t require any plugins and is very useful.

Which table of values correspond to exponential functions?
There may be more than one correct answer.
 a) $\begin{array}{ccccccc}\hfill t& \hfill 0& \hfill 1& \hfill 2& \hfill 3& \hfill 4& \hfill 5\\ \hfill P& \hfill 5& \hfill 6& \hfill 9& \hfill 14& \hfill 21& \hfill 30\end{array}$ b) $\begin{array}{ccccccc}\hfill t& \hfill 0& \hfill 2& \hfill 4& \hfill 6& \hfill 8& \hfill 10\\ \hfill P& \hfill 300& \hfill 147& \hfill 72.03& \hfill 35.2947& \hfill 17.2944& \hfill 8.4726\end{array}$ c) $\begin{array}{ccccccc}\hfill t& \hfill 0& \hfill 1& \hfill 2& \hfill 5& \hfill 7& \hfill 10\\ \hfill P& \hfill 250& \hfill 125& \hfill 67.5& \hfill 38.75& \hfill 19.875& \hfill 9.9675\end{array}$ d) $\begin{array}{ccccccc}\hfill t& \hfill 0& \hfill 1& \hfill 2& \hfill 3& \hfill 4& \hfill 5\\ \hfill P& \hfill 12& \hfill 10& \hfill 8& \hfill 6& \hfill 4& \hfill 2\end{array}$ e) $\begin{array}{ccccccc}\hfill t& \hfill 0& \hfill 1& \hfill 2& \hfill 3& \hfill 4& \hfill 5\\ \hfill P& \hfill 20& \hfill 24& \hfill 28.8& \hfill 34.56& \hfill 41.472& \hfill 49.7664\end{array}$

There is at least one mistake.
For example, choice (a) should be False.
Try again, the $t$ values are evenly spaces but the ratios are not fixed.
There is at least one mistake.
For example, choice (b) should be True.
Note that the $t$ values are equally spaced and the ratios $\frac{300}{147}=\frac{147}{72.03}=\dots =\frac{17.2944}{8.4726}\approx 2.04$ are fixed so the function is exponential.
There is at least one mistake.
For example, choice (c) should be False.
Try again, although the ratios are fixed the $t$ values are not evenly spaced.
There is at least one mistake.
For example, choice (d) should be False.
Try again, the $t$ values are evenly spaces but the ratios are not fixed.
There is at least one mistake.
For example, choice (e) should be True.
Note that the $t$ values are equally spaced and the ratios $\frac{20}{24}=\frac{24}{28.8}=\dots =\frac{41.472}{49.7664}\approx 8.333$ are fixed so the function is exponential.
Correct!
1. False Try again, the $t$ values are evenly spaces but the ratios are not fixed.
2. True Note that the $t$ values are equally spaced and the ratios $\frac{300}{147}=\frac{147}{72.03}=\dots =\frac{17.2944}{8.4726}\approx 2.04$ are fixed so the function is exponential.
3. False Try again, although the ratios are fixed the $t$ values are not evenly spaced.
4. False Try again, the $t$ values are evenly spaces but the ratios are not fixed.
5. True Note that the $t$ values are equally spaced and the ratios $\frac{20}{24}=\frac{24}{28.8}=\dots =\frac{41.472}{49.7664}\approx 8.333$ are fixed so the function is exponential.
Which of the following curves are concave up?
More than one answer may be correct.
 a) b) c) d)

There is at least one mistake.
For example, choice (a) should be True.
This curveis $y={e}^{x}$ and it is concave up.
There is at least one mistake.
For example, choice (b) should be False.
Try again, this curve is concave down.
There is at least one mistake.
For example, choice (c) should be True.
Thiscurve is a quadratic and is concave up.
There is at least one mistake.
For example, choice (d) should be True.
This curve is$y={e}^{-x}$ and is concave up.
Correct!
1. True This curveis $y={e}^{x}$ and it is concave up.
2. False Try again, this curve is concave down.
3. True Thiscurve is a quadratic and is concave up.
4. True This curve is$y={e}^{-x}$ and is concave up.
Consider the exponential function below and determine which one of the following statements is true.
$P\left(t\right)=800{\left(0.7\right)}^{t}$
 a) $P$ describes exponential growth where the initial quantity is $800\phantom{\rule{0.3em}{0ex}}.$ b) $P$ describes exponential decay where the initial quantity is $800\phantom{\rule{0.3em}{0ex}}.$ c) $P$ describes exponential growth where the initial quantity is $0.7\phantom{\rule{0.3em}{0ex}}.$ d) $P$ describes exponential decay where the initial quantity is $0.7\phantom{\rule{0.3em}{0ex}}.$

Choice (a) is incorrect
Try again, the factor by which $P$ changes is $0.7\phantom{\rule{0.3em}{0ex}}.$
Choice (b) is correct!
Choice (c) is incorrect
Try again, read the definition of The General Exponential Function on page 11.
Choice (d) is incorrect
Try again, read the definition of The General Exponential Function on page 11.
The half-life of radium-226 is 1620 years. There is 100g of radium-226 in a particular sample now.
Which of the following gives the correct amount of radium-266 in 3240 years?
 a) 400g. b) 50g. c) 25g. d) 0g

Choice (a) is incorrect
Try again, you have doubled the quantity twice.
Choice (b) is incorrect
Try again, this is how much you would have after 1620 years.
Choice (c) is correct!
After 1620 years there would be 50g left and after a further 1620 years there would be half of that left, that is 25g left.
Choice (d) is incorrect
Try again, even though the sample loses 50g in the first 1620 years, it does not lose a further 50g in the next 1620 years.


text:
# Riemann mapping theorem

In complex analysis, the Riemann mapping theorem, named after Bernhard Riemann, states the following: if U is a simply connected open subset of the complex number plane C which is not all of C, then there exists a bijective holomorphic conformal map

f : UD,

where D = { z in C : |z| < 1 } denotes the open unit disk. Intuitively, the condition that U be simply connected means that U does not contain any "holes"; the conformality of f means that f maintains the shape of small figures.

The map f is essentially unique: if z0 is an element of U and φ in (−π, π] is an arbitrary angle, then there exists precisely one f as above with the additional properties f(z0) = 0 and arg f '(z0) = φ.

As a corollary, any two such simply connected open sets (which are different from C and C U {∞}) can be conformally mapped into each other.

The theorem was proved by Bernhard Riemann in 1851, but his proof depended on a statement in the calculus of variations which was only later proven by David Hilbert.

## Why is this theorem impressive?

To better understand how unique and powerful the Riemann mapping theorem is, consider the following facts:

• This analog of the Riemann mapping theorem for doubly connected domains is not true. In fact, there are no conformal maps between annuli except multiplication by constants, so the annulus $\displaystyle \{1\leq |z|\leq 2\}$ is not conformally equivalent to the annulus $\displaystyle \{1\leq |z|\leq 4\}$ . However, any doubly connected domain is conformally equivalent to some annulus.
• The analog of the Riemann mapping theorem in three dimensions or above is not even remotely true. In fact, the family of conformal maps in three dimensions is very poor, and contains, essentially, only Möbius transformations.
• Even if we allow arbitrary homeomorphisms in higher dimensions, we can find contractible manifolds that are not homeomorphic to the ball, such as the Whitehead continuum.
• The Riemann mapping theorem is the easiest way to prove that any two simply connected domains in the plane are homeomorphic. Even though the class of continuous functions is infinitely larger than that of conformal maps, it is not easy to construct a one-to-one function onto the disk knowing only that the domain is simply connected.
• Even relatively simple Riemann mappings, say a map of the circle to the square, have no explicit formula using only elementary functions.


text:
# Not Rotating Equilateral Triangles

Geometry Level 5

In the figure below, $$CDE$$ is an equilateral triangle. Find $$\angle ADE$$ in degrees.

Note: $$\angle BEC = 95^\circ$$, $$\angle ECB = 45^\circ$$, $$\angle ABE = 25^\circ$$, and $$\angle BAC = 65^\circ$$.

×


text:
# Free ASVAB Practice Tests

• Every Test is Unique
Custom software and unique templates randomize questions, answers, and variables every time you take a new test. You'll never take the same test twice!
• 1,557 Questions, Problems & Flash Cards
Huge database of 668 multiple-choice questions, 135 math and algebra problems, and 754 flash cards to help you prepare for the ASVAB.
• Detailed Solutions
Get a question wrong? All questions and problems have detailed answer explanations so you can learn exactly how to get it right the next time.
Want to know how you stack up? When you're done with a practice test you can compare your score to everyone else who has ever answered those questions.
• Interactive Study Guide
Detailed ASVAB study guide, MOS study guides, and line score study guides outline exactly what you should know to earn your target scores and customized tests and flash cards for each topic let you laser focus your limited study time.
• Brand New for 2019
ASVAB Test Bank has been completely redesigned for 2019 with all new questions, problems, and flash cards. And the redesign isn't done! Coming soon:
More Content
More questions, problems and flash cards
Bookmarks
Create a custom study guide with just the topics you're studying
Score Estimator
Custom estimate of your potential ASVAB score

Plus printable tests, Q&A, and an ad-free upgrade. Have a suggestion? Please let us know what you want!

Take an ASVAB Practice Test

Sample Practice Test Questions

Electronics Information

Which of the following converts electrical energy into another form of energy in an electrical circuit?

A load is a source of resistance that converts electrical energy into another form of energy. The components of a microwave, for example, are loads that work together to convert household electricity into radation that can be used to quickly cook food.

Automotive Information

The steering __________ transfers the motion of the steering gear output shaft to the steering arms that turn the wheels.

The steering linkage is a system of pivots and connecting parts between the steering gear and the control arms. The steering linkage transfers the motion of the steering gear output shaft to the steering arms that turn the wheels.

Shop Information

You've bored a large hole in a piece of wood to insert a doorknob. Which of these tools would you use to smooth the edges of the hole?

rasp

Files consist of diagonal rows of fine teeth and are used for fine finishing work to smooth, polish, or shape objects. Rasps are files with larger teeth that are used for coarse finishing work. Both files and rasps are designed to be inserted into detachable handles.

Arithmetic Reasoning

Solve 2 + (5 + 2) ÷ 5 x 3 - 42

-9$$\frac{4}{5}$$

Use PEMDAS (Parentheses, Exponents, Multipy/Divide, Add/Subtract):

2 + (5 + 2) ÷ 5 x 3 - 42
P: 2 + (7) ÷ 5 x 3 - 42
E: 2 + 7 ÷ 5 x 3 - 16
MD: 2 + $$\frac{7}{5}$$ x 3 - 16
MD: 2 + $$\frac{21}{5}$$ - 16
AS: $$\frac{10}{5}$$ + $$\frac{21}{5}$$ - 16
AS: $$\frac{31}{5}$$ - 16
AS: $$\frac{31 - 80}{5}$$
$$\frac{-49}{5}$$
-9$$\frac{4}{5}$$

Mechanical Comprehension

The mechanical advantage of a wheel and axle is equal to the:

ratio of the diameters of the wheels

A wheel and axle uses two different diameter wheels mounted to a connecting axle. Force is applied to the larger wheel and large movements of this wheel result in small movements in the smaller wheel. Because a larger movement distance is being translated to a smaller distance, force is increased with a mechanical advantage equal to the ratio of the diameters of the wheels. An example of a wheel and axle is the steering wheel of a car.

Mechanical Comprehension

Gear ratio indicates which of the following about two connected gears?

The mechanical advantage (amount of change in speed or torque) of connected gears is proportional to the number of teeth each gear has. Called gear ratio, it's the ratio of the number of teeth on the larger gear to the number of teeth on the smaller gear.  For example, a gear with 12 teeth connected to a gear with 9 teeth would have a gear ratio of 4:3.

General Science

50°F is how many °C?

10

The formula to convert from F° to C° is:

$$C° = {5 \over 9} (F° - 32)$$

plugging in our values gives:

$$C° = {5 \over 9} (50 - 32)$$

$$C° = {5 \over 9} (18)$$

$$C° = {90 \over 9}$$

$$C° = 10$$

General Science

"For every action, there is an equal and opposite reaction." This describes which of Newton's laws of motion?

third

Newton's third law of motion states that For every action, there is an equal and opposite reaction. When an object exerts a force on another object, the second object exerts a force of equal magnitude in the opposite direction on the first object.

Mechanical Comprehension
If the handles of a wheelbarrow are 1.5 ft. from the wheel axle, how many pounds of force must you exert to lift the handles if it's carrying a 130 lbs. load concentrated at a point 0.5 ft. from the axle?
43.3
This problem describes a second-class lever and, for a second class lever, the effort force multiplied by the effort distance equals the resistance force multipied by the resistance distance: Fede = Frdr. In this problem we're looking for effort force:
$$F_e = \frac{F_r d_r}{d_e}$$
$$F_e = \frac{130 \times 0.5}{1.5}$$
$$F_e = \frac{65.0}{1.5}$$
$$F_e = 43.3$$
Mechanical Comprehension

A truck is using a rope to pull a car. Tension in the rope is greatest in which of the following places?

near the truck

Tension is a force that stretches or elongates something. When a cable or rope is used to pull an object, for example, it stretches internally as it accepts the weight that it's moving. Although tension is often treated as applying equally to all parts of a material, it's greater at the places where the material is under the most stress.


text:
# Why eigenvectors basis then transformation matrix is $\Lambda$?

Why is it that in a transformation, if the eigenvectors are chosen as the basis vectors, the transformation matrix $A$ would turn out to be that diagonal eigenvalues matrix $\Lambda$ and the transformation becomes $\Lambda \vec{x}=\vec{c}$ ?

What is the reason or cause that the transformation matrix could easily just be the eigenvalues matrix $\Lambda$?

I tried to prove it to show myself but somehow, it doesn't look very right. Let $\vec{b_i}$ be the eigenvectors that form the basis for the vector $\vec{v}$ and the $c_n$ are combination to the eigenvectors...

$\vec{v} = c_1 \vec{b_1} + c_2 \vec{b_2} + ... + c_n \vec{b_n}$

$T(\vec{v})= c_1 T(\vec{b_1}) + c_2 T(\vec{b_2}) + ... + c_n T(\vec{b_n})$

$T(\vec{v})= c_1 A\vec{b_1} + c_2 A\vec{b_2} + ... + c_n A\vec{b_n}$

$T(\vec{v})= c_1 \lambda_1 \vec{b_1} + c_2 \lambda_2\vec{b_2} + ... + c_n \lambda_n\vec{b_n}$

$T(\vec{v})= \begin{bmatrix} & & \\ \vec{b_1} & \vec{b_2} &...& \vec{b_n}\\ & & \end{bmatrix} \begin{bmatrix} \lambda_1 & & & \\ & \lambda_2 & & \\ & & \ddots & \\ & & & \lambda_n \end{bmatrix} \begin{bmatrix} c_1 & & & \\ & c_2 & & \\ & & \ddots & \\ & & & c_n \end{bmatrix}$

The last line is wrong but I'm trying to force out that $\Lambda$ which I couldn't.

Let me back up a bit. Remember what the point is of the "coordinate matrix of a linear transformation with respect to a basis."

If $T\colon\mathbf{V}\to\mathbf{V}$ is a linear transformation, and $\beta=[\mathbf{v}_1,\ldots,\mathbf{v}_n]$ is a basis for $T$, then the values of $T$ at every vector in $\mathbf{V}$ is completely determined by its values on $\mathbf{v}_1,\ldots,\mathbf{v}_n$. Why? Because given any $\mathbf{x}\in\mathbf{V}$, we know there exist (unique) scalars $c_1,\ldots,c_n$ such that $\mathbf{x}=c_1\mathbf{v}_1+\cdots+c_n\mathbf{v}_n$, so $$T(\mathbf{x}) = T(c_1\mathbf{v}_1+\cdots+c_n\mathbf{v}_n) = c_1T(\mathbf{v}_1)+\cdots+c_nT(\mathbf{v}_n).$$ So if you know what $T(\mathbf{v}_1),\ldots,T(\mathbf{v}_n)$ are, you know that $T(\mathbf{x})$ is for all $\mathbf{x}\in\mathbf{V}$.

Now, since $\beta$ is a basis, each $T(\mathbf{v}_i)$ can be expressed as a linear combination of the $\mathbf{v}_i$ in a unique way; that is, there are scalars $a_{11}, a_{12},\ldots,a_{nn}$ such that \begin{align*} T(\mathbf{v}_1) &= a_{11}\mathbf{v}_1 + a_{21}\mathbf{v}_2 + \cdots +a_{n1}\mathbf{v}_n\\ T(\mathbf{v}_2) &= a_{12}\mathbf{v}_1 + a_{22}\mathbf{v}_2 + \cdots + a_{n2}\mathbf{v}_n\\ &\vdots\\ T(\mathbf{v}_n) &= a_{1n}\mathbf{v}_1 + a_{2n}\mathbf{v}_2 + \cdots + a_{nn}\mathbf{v}_n. \end{align*} Then \begin{align*} G(\mathbf{x}) &= c_1T(\mathbf{v}_1 + \cdots + c_nT(\mathbf{v}_n)\\ &= c_1\left(a_{11}\mathbf{v}_1 + a_{21}\mathbf{v}_2 + \cdots +a_{n1}\mathbf{v}_n\right)\\ &\qquad+c_2\left(a_{12}\mathbf{v}_1 + a_{22}\mathbf{v}_2 + \cdots + a_{n2}\mathbf{v}_n\right)\\ &\qquad+\cdots+c_n\left(a_{1n}\mathbf{v}_1 + a_{2n}\mathbf{v}_2 + \cdots + a_{nn}\mathbf{v}_n\right)\\ &= \Bigl(c_1a_{11} + c_2a_{12} + \cdots + c_na_{1n}\Bigr)\mathbf{v}_1\\ &\qquad +\Bigl(c_1a_{21} + c_2a_{22} + \cdots + c_na_{2n}\Bigr)\mathbf{v}_2\\ &\qquad+\cdots+ \Bigl(c_1a_{n1}+c_2a_{n2}+\cdots+c_na_{nn}\Bigr)\mathbf{v}_n\\ &= \left(\begin{array}{cccc} \mathbf{v}_1 & \mathbf{v}_2 & \cdots & \mathbf{v}_n\end{array}\right) \left(\begin{array}{cccc} a_{11} & a_{12} & \ldots & a_{1n}\\ a_{21} & a_{22} & \ldots & a_{nn}\\ \vdots & \vdots & \ddots & \vdots\\ a_{n1} & a_{n2} & \ldots & a_{nn} \end{array}\right) \left(\begin{array}{c}c_1\\c_2\\\vdots\\c_n\end{array}\right). \end{align*}

The column vector $$\left(\begin{array}{c}c_1\\c_2\\\vdots\\c_n\end{array}\right)$$ represents the vector $\mathbf{x}$; it is the "coordinate vector of $\mathbf{x}$ with respect to $\beta$". The matrix $$\left(\begin{array}{ccc} a_{11} & \cdots & a_{1n}\\ \vdots & \ddots & \vdots\\ a_{n1} & \cdots & a_{nn}\end{array}\right)$$ is the matrix that "codifies" the images of $\mathbf{v}_i$ under $T$ in terms of $\beta$: the $i$th column is the coordinate vector of $T(\mathbf{v}_i)$ relative to $\beta$. This is the "coordinate matrix of $T$ relative to $\beta$."

What happens if $\mathbf{v}_1$ is an eigenvector corresponding to $\lambda_1$? Then $$T(\mathbf{v}_1) = \lambda_1\mathbf{v}_1 = \lambda_1\mathbf{v}_1 + 0\mathbf{v}_2 + 0\mathbf{v}_3 + \cdots + 0\mathbf{v}_n.$$ That is, the first column of the coordinate matrix is just $$\begin{array}{c} \lambda_1 \\ 0 \\ 0\\ \vdots \\ 0\\ 0\end{array}$$ What if $\mathbf{v}_2$ is an eigenvector corresponding to $\lambda_2$? Then $T(\mathbf{v}_2)=\lambda_2\mathbf{v}_2$. To write it as a linear combination of $\beta$, we just put $\lambda_2$ for the coefficient of $\mathbf{v}_2$, and $0$s for every other coefficient: $$T(\mathbf{v}_2) = \lambda_2\mathbf{v}_2 = 0\mathbf{v}_1 + \lambda_2\mathbf{v}_2 + 0\mathbf{v}_3 + \cdots + 0\mathbf{v}_n.$$ So the second column of the coordinate matrix is just $$\begin{array}{c}0\\\lambda_2\\0\\\vdots\\0\\0\end{array}$$ And so on: if $\mathbf{v}_i$ is an eigenvector corresponding to $\lambda_i$, then $$T(\mathbf{v}_i) = \lambda_i\mathbf{v}_i = 0\mathbf{v}_1+0\mathbf{v}_2+\cdots+0\mathbf{v}_{i-1} + \lambda_i\mathbf{v}_i + 0\mathbf{v}_{i+1} + \cdots+0\mathbf{v}_n,$$ so the $i$th column of the coordinate matrix will have $0$s everywhere except in the $i$th row, where it will have $\lambda_i$.

And so, if the entire basis is made up of eigenvectors, then the coordinate matrix will be such that the $i$th column has zeros everywhere except (perhaps) in the $i$th row, where it has the eigenvalue of $\mathbf{v}_i$; that is, we get a diagonal matrix $$\Lambda = \left(\begin{array}{cccc} \lambda_1 & 0 & \cdots & 0\\ 0 & \lambda_2 & \cdots & 0\\ \vdots & \vdots & \ddots & \vdots\\ 0 & 0 & \cdots & \lambda_n \end{array}\right).$$ And that is the coordinate matrix of $T$ with respect to $\beta$.

• Thanks for such a clear explanation. So can I say that for $T([\vec{x}]_v)$, that's the input $\vec{x}$ with respect to the eigenvector basis $V$, if the output was: $$T([\vec{x}]_v) = \begin{bmatrix} \vec{v_1} & \vec{v_1} & ... & \vec{v_1} \end{bmatrix} \left[\begin{array}{cccc} \lambda_1 & 0 & \cdots & 0\\ 0 & \lambda_2 & \cdots & 0\\ \vdots & \vdots & \ddots & \vdots\\ 0 & 0 & \cdots & \lambda_n \end{array}\right] \left[\begin{array}{c}c_1\\c_2\\\vdots\\c_n\end{array}\right]$$ This means that the output coordinates are with respect to the standard basis, is this right? – xenon Aug 20 '11 at 7:32
• And if I wanted the output coordinates with respect to the eigenvectors basis, then it would be just: $$T([\vec{x}]_v) = \left[\begin{array}{cccc} \lambda_1 & 0 & \cdots & 0\\ 0 & \lambda_2 & \cdots & 0\\ \vdots & \vdots & \ddots & \vdots\\ 0 & 0 & \cdots & \lambda_n \end{array}\right] \left[\begin{array}{c}c_1\\c_2\\\vdots\\c_n\end{array}\right]$$ Is this right too? – xenon Aug 20 '11 at 7:32
• @xEnOn: Careful: $T$ is an "abstract linear transformation". It acts on vectors in the vector space. $[\vec{x}]_v$ represents the coordinate vector of $\vec{x}$ relative to $v$. $T$ would "misunderstand" $[\vec{x}]_v$ if you try feeding it. What you need is the coordinate matrix of $T$. That is, you need $[T]_v^v$ applied to $[\vec{x}]_v$, and that will give you $[T(\vec{x})]_v$. I.e., $[T]_v^v([\vec{x}]_v) = [T(x)]_v$. – Arturo Magidin Aug 20 '11 at 16:35
• Thank you so much for your help! :) – xenon Aug 21 '11 at 2:01

The matrix of a linear transformation with respect to a basis has as columns the coordinates of the images of the basis elements under the transformation. If you have a basis of eigenvectors then the corresponding matrix will be diagonal because $A v_i = \lambda_i v_i$, that is, there is only one non-zero coordinate (more precisely, at most one, because $\lambda_i$ may be $0$).

• A way of seeing this same answer more intuitively is to think about a diagonal matrix as a linear transformation that corresponds to a scaling of the basis vectors. The eigenvectors are exactly the ones that are (purely) scaled by a given linear transformation, so if we use these as a basis then the matrix is diagonal. – Vhailor Aug 19 '11 at 15:46
• Thanks. But I'm still a little confuse. I have updated my question with a some lines that I did to try to prove to myself but somehow, I still feel I'm missing out something. In the end, I couldn't eventually form into the expected $T(\vec{v})=\Lambda \vec{v}$. – xenon Aug 19 '11 at 16:22
• @xEnOn: Remember that linear transformations act on vectors, but matrices act on the coordinates. In your example the coordinates of $\vec{v}$ are the (column) vector $(c_1,c_2,\ldots,c_n)^T$ ($T$ stands for transpose. OTOH the coordinates of the transformed vector $T(\vec{v})$ are $(\lambda_1c_1,\lambda_2c_2,\ldots,\lambda_nc_n)^T$. These are, indeed, related by $\Lambda$ as $$\left(\begin{array}{c} \lambda_1c_1 \\ \lambda_2c_2 \\ \vdots \\ \lambda_nc_n\end{array}\right)=\Lambda \left(\begin{array}{c} c_1 \\ c_2 \\ \vdots \\ c_n\end{array}\right).$$ – Jyrki Lahtonen Aug 19 '11 at 20:07


text:
1. ## amplitude?

Given y=1/13(3sint-2cost)+e^-3t(2cost+3sint)
Q describe behaviour of y for large values of t. Sketch with range.

The amplitube is in actual fact 1/(13)^0.5

So on the graph its between -1/(13)^0.5 and 1/(13)^0.5

How can this be when the max andmin value is clearly going to be 1/13 do you think this is a typo?
I think it has something to do with the technique givenx = A sinwt=Bcoswt you can wright it as
x=(A^2+B^2)^0.5(A/<(sinwt) + B/<(cowt)) < indicates the (A^2+B^2)^0.5
But im afraid i cant see the direct relation between this straight off tchnique and the rsin(w+/-x) method or rcos(w+/-x) method is it the same thing? I dont think this is the factor formulae either!
Oh its ok i got it

2. Originally Posted by i_zz_y_ill
Given y=1/13(3sint-2cost)+e^-3t(2cost+3sint)
Q describe behaviour of y for large values of t. Sketch with range.

The amplitube is in actual fact 1/(13)^0.5

So on the graph its between -1/(13)^0.5 and 1/(13)^0.5

How can this be when the max andmin value is clearly going to be 1/13 do you think this is a typo?
I think it has something to do with the technique givenx = A sinwt=Bcoswt you can wright it as
x=(A^2+B^2)^0.5(A/<(sinwt) + B/<(cowt)) < indicates the (A^2+B^2)^0.5
But im afraid i cant see the direct relation between this straight off tchnique and the rsin(w+/-x) method or rcos(w+/-x) method is it the same thing? I dont think this is the factor formulae either!
Oh its ok i got it
For large t: y=1/13(3sint-2cost)+e^-3t(2cost+3sint) ---> y=1/13(3sint-2cost) since e^-3t ----> 0 and (2cost+3sint) is bounded.


text:
Tensor product of coherent modules - MathOverflow most recent 30 from http://mathoverflow.net 2013-06-19T11:21:18Z http://mathoverflow.net/feeds/question/86107 http://www.creativecommons.org/licenses/by-nc/2.5/rdf http://mathoverflow.net/questions/86107/tensor-product-of-coherent-modules Tensor product of coherent modules Martin Brandenburg 2012-01-19T15:21:42Z 2012-01-19T15:59:14Z
Let $X$ be a ringed space. Recall that an $\mathcal{O}_X$-module $M$ is called coherent if it is of finite presentation and for every open $U \subseteq X$ every $\mathcal{O}_U$-submodule of finite type of $M|_U$ is of finite presentation. Coherent modules constitute an abelian category (in contrast to modules of finite presentation or just of finite type). See the Stacks project, modules, section 12. In general $\mathcal{O}_X$ might be not coherent.

Question. If $M,N$ are coherent $O_X$-modules, is it true that $M \otimes_{\mathcal{O}_X} N$ is coherent?

I guess that this will be false in this generality. So let us restrict to schemes, w.l.o.g. affine schemes. Here a module $M$ over a ring $A$ is coherent if it is of finite presentation and every submodule of finite type is of finite presentation.
 http://mathoverflow.net/questions/86107/tensor-product-of-coherent-modules/86108#86108 Answer by Francesco Polizzi for Tensor product of coherent modules Francesco Polizzi 2012-01-19T15:59:14Z 2012-01-19T15:59:14Z
In the analytic category this is indeed true: if $\mathscr{F}$, $\mathscr{G}$ are coherent analytic sheaves on a complex space $X$, then $\mathscr{F} \otimes_{\mathscr{O}_X} \mathscr{G}$ is also coherent.

For a reference, look at [Grauert-Remmert, Coherent Analytic Sheaves], Proposition at the bottom of page 240.

It seems to me that their proof works also in the algebraic category, maybe you should check.


text:
# Karush-Kuhn-Tucker conditions

(Redirected from Kuhn-Tucker conditions)

2010 Mathematics Subject Classification: Primary: 49Kxx [MSN][ZBL]

KKT conditions, Karush–Kuhn–Tucker optimality conditions, KKT optimality conditions, Kuhn–Tucker conditions

Consider the general mathematical programming problem: $$\begin{array}{lll} \mbox{minimize} & f(x), & x\in\mathbb{R}^n \\ \mbox{subject to} & g_i(x)\leq 0, & i=1,\ldots,p,\\ & h_j(x)=0, & j=1,\ldots,q, \end{array}$$ with $f$, $g_i$, $h_j$ all continuously differentiable ($C^1$-functions), and form the Lagrangian function $$L(x,\lambda,\mu)=f(x)+\sum_{i=1}^{p}\lambda_i g_i(x) + \sum_{j=1}^{q}\mu_j h_j(x).$$ The Karush–Kuhn–Tucker optimality conditions now are: $$\tag{1} \begin{array}{rl} \dfrac{\partial}{\partial x_k}L(x,\lambda,\mu)=0, & k=1,\ldots,n,\\ \lambda_i\geq 0, & i=1,\ldots,p,\\ \lambda_i g_i(x)=0, & i=1,\ldots,p,\\ g_i(x)\leq 0, & i=1,\ldots,p,\\ h_j(x)=0, & j=1,\ldots,q. \end{array}$$ Note that the two last conditions just say that $x$ is feasible and that the third conditions could be replaced by $\sum\lambda_i g_i(x)=0$ (given the second and fourth). Under suitable constraint qualifications, the KKT optimality conditions are necessary conditions for a local solution $x^*$ of the general mathematical programming problem, in the following sense.

If $x^*$ is a local minimum, then there are corresponding $\lambda^*$, $\mu^*$ such that the triple $(x^*,\lambda^*,\mu^*)$ satisfies the KKT optimality conditions. A triple satisfying the KKT optimality conditions is sometimes called a KKT-triple.

This generalizes the familiar Lagrange multipliers rule to the case where there are also inequality constraints.

The result was obtained independently by Karush in 1939, by F. John in 1948, and by H.W. Kuhn and J.W. Tucker in 1951, see [1], [7].

One suitable constraint qualification (for the case where there are no equality constraints) is $\overline{D}(x^*)=D(x^*)$, where $\overline{D}(x^*)$ is the closure of $$D(x^*)=\left\{d\colon\exists\sigma > 0\colon\sigma\geq\tau\geq 0 \Rightarrow x^*+\tau d \quad\text{feasible}\right\}$$ and $$D(x^*)=\left\{d\colon\nabla g_i(x^*)^T d\geq 0,\quad i=1,\ldots,p\right\},$$ where $\nabla g_i(x^*)$ is the gradient vector of $g_i$ at $x^*$, $$\nabla g_i(x^*)^T=\left(\dfrac{\partial g_i}{\partial x_1}(x^*),\ldots,\dfrac{\partial g_i}{\partial x_n}(x^*)\right),$$ see [2].

Given a KKT-triple $(x^*,\lambda^*,\mu^*)$, there are also (as in the case of Lagrange multipliers) second-order sufficient conditions that ensure local optimality of $x^*$.

#### Comment

The KKT conditions (1) provide a criterion for testing whether a solution which has been found by other methods is in fact an optimal solution.

The KKT conditions have been generalized in various directions:

• to necessary or sufficient conditions, or both types, for an extremum of a function subject to equality or inequality constraints [6]; especially in case of convex functions $f$ and $g_i$ and affine $h_j$, the KKT conditions (1) are sufficient, see [9], pp. 243–246.
• to changing the geometrical structure of the underlying manifold [6], [8].
• Fritz John condition.

#### References

 [1] A.V. Fiacco, G.P. McCormick, "Nonlinear programming, sequential unconstrained minimization techniques" , SIAM (1968) (Edition: Reprinted) [2] W.I. Zangwill, "Nonlinear programming" , Prentice-Hall (1969) [3] O.L. Mangasarian, "Nonlinear programming" , McGraw-Hill (1969) [4] G.P. McCormick, "Nonlinear programming: theory, algorithms, and applications" , Wiley (1983) [5] Jong-Shi Pang, "Complementarity problems" R. Horst (ed.) P.M. Pardalos (ed.) , Handbook of Global Optimization , Kluwer Acad. Publ. (1995) pp. 271–338 [6] K.J. Arrow, L. Hurwicz, H. Uzawa, "Studies in linear and nonlinear programming" , Stanford Univ. Press (1958) [7] H.W. Kuhn, A.W. Tucker, "Nonlinear programming" , Proc. Second Berkeley Symp. Math. Stat. Probab. , California Univ. Press (1951) pp. 481–492 [8] C. Udrişte, "Convex functions and optimization methods on Riemannian manifolds" , Kluwer Acad. Publ. (1994) [9] S.P. Boyd, L. Vandenberghe, "Convex Optimization" , Cambridge University Press (2004). DOI 10.1017/CBO9780511804441
How to Cite This Entry:
Kuhn-Tucker conditions. Encyclopedia of Mathematics. URL: http://www.encyclopediaofmath.org/index.php?title=Kuhn-Tucker_conditions&oldid=38783
This article was adapted from an original article by C. UdriÅŸte (originator), which appeared in Encyclopedia of Mathematics - ISBN 1402006098. See original article


text:
# Time series: An overview

## Tools Articles

• Date: 26 Sep 2012

A time series is created when the status of an observational unit is recorded through time. This definition is sufficiently broad to include most of our everyday existence, and further qualification is necessary...Our basic definition of a time series is thus that we observe a sequence of random variables or  equally spaced in time at , after a suitable rescaling of the time axis if necessary.The traditional approach to time series modeling recognizes four components of a time series: trend, or long-term movements in the series (T); seasonal fluctuations, which are of known periodicity (S); cyclic variations of a nonseasonal variety, whose periodicity is unknown (C); and R, the random error component.

The models developed within this framework are typically of the forms

When the trend is the component of primary concern, it may be modeled directly in the form  where  denotes the deterministic component of the series and  is the error term (or nondeterministic component). Alternatively, trend might be removed by a combination of transformations and differencing to produce a stationary series. When all four components are relevant, a variety of moving averages and filtering operations may be applied to the data, usually to estimate the seasonal component and thus to produce a deseasonalized series.

Data analysis for time series may be performed either in the time domain or the frequency domain. Time domain methods represent the random variable Y(t) in terms of its past history and uncorrelated error terms, the class of linear autoregressive moving average (ARMA) schemes being the main foundation upon which such analyses are based. The structure of such processes may be described in terms of the autocorrelations.

In the frequency domain, the stationary process is described by a set of cosine waves which vary in angular frequency and amplitude. The wavelength, or distance between successive peaks, is . The spectral density is the plot of the squared amplitude against , which indicates the power (or “variance explained”) at frequency .

A fundamental result in time series is that the autocorrelation function and the spectral density function form a Fourier transform pair so that the information contained in one function is formally equivalent to that contained in the other. Nevertheless, given a finite data record, one approach may do better. In the physical sciences, the study of wave-like phenomena often leads to the use of frequency domain analysis, whereas in the social and economic sciences, the regression type structure of the time domain is usually preferred.

Taken from: N. Balakrishnan, Time Series, Encyclopedia of Statistical Sciences, 2011.


text:
Search
Question: DESEq2 Large Memory When Parallel
0
7 months ago by
Stanford
Jeff Granja0 wrote:

I have a direct question about DESeq2's memory handling. I have come to really enjoy DESeq2 for ATAC-Seq and it is really well documented etc. The problem is matrices can get quite large in rows which slows down DESeq a lot. This is why the parallelism of DESeq is quite useful. I was curious if there is/was a push for maybe coming up with a way to deal with the large memory handling when it comes to the parallel extensions. Mainly when running the main DESeq pipeline with parallel = TRUE. When this occurs, the memory spikes and it multiplies the memory usage (n * memory) and this can get quite crazy (i have used 300 GB of RAM to finish a DESeq run). I was wondering if ever there would be the potential of adding capabilities with bigmemory matrices so that the memory is reduced. Also if there was a way for the parallelism to not copy the data for every thread. Thanks.

modified 7 months ago by Michael Love18k • written 7 months ago by Jeff Granja0

What platform is your operating system?

The operating system is Ubuntu 14.04.1 LTS.

Can you give more details, eg the object.size() of ‘dds’ and how you are using BiocParallel?

Hi,

I guess I mistook maybe that the size of the object being big itself but the object.size of dds is 24554008 bytes, the way i run BiocParallel is (threads i normally set to 16-24)

library(BiocParallel)

register(MulticoreParam(threads)) #threads normally 16-24

print("Garbage Collecting")

gc()

dds <- DESeq(dds ,parallel =TRUE, modelMatrixType = "expanded", betaPrior = TRUE)

Which the dimension of the counts matrix is around 400K rows and ~100 samples. I supply custom normalization factors as well.

Thanks!

Normally 16-24

For debugging, can you try a subset, eg 50k rows, with say 4 cores, and see how long that takes and how much memory?

I have been doing approximately that right as we speak. I have been using 8 cores ~60k rows (thresholding) and it took around ~8 hours when 12 cores ~400k rows was about ~24 hours (with ~300 GB of RAM usage). The memory usage scales with the size of the counts 8 cores 60k rows uses 3-4GB per thread while when i ran 12 cores ~400k rows was about 30GB per thread. This made me believe that the matrix memory is the core issue (maybe its getting copied for each thread so the RAM spikes). The speed seems to scale appropriately. Let me know if you want any more tests.

A further question i have is there anyway to maybe allow an option to save progress during DESeq main part? I have had the memory max for bpapply towards the very end which loses a lot of the work. Or an easy way to execute line by line with parallel options maybe a vignette?

Thanks!

Can you explain a bit about the design? This seems like way too long even for a single core, unless you have some very wide design matrix with hundreds of coefficients to fit. I think there’s some issue. I’ll try to replicate something like a problem of your dimension and report what I get on my machines.

Sure. So the datasets that cause the main problems definitely have lots of coefficients (50+). For this design in particular we have lots of cell types from mulitple donors and the questions we are interested in is the difference between the cell types as a whole and across individuals.

For each individual we have replicates and this leads to a simple design where it is (sorry i am not sure how to properly put this in) sample (Patient_Type_Rep) and a contrast column (Patient_Type) and the design is ~contrast in this case.

Edit(limited user so i cannot post below for a few hours) In this case there is about ~25 Types with ~3 Patients (~75 Patient_Type) with 2+ replicates so in total ~150 samples.

Can you give me a ballpark on number of patient and type? I’ll try it with mock data on my end and report timings etc.

In this case there is about ~25 Types with ~3 Patients (~75 Patient_Type) with 2+ replicates so in total ~150 samples.

0
7 months ago by
Michael Love18k
United States
Michael Love18k wrote:

hi Jeff,

I tried the following on my cluster here, using either 4 or 8 cores at a time:

library(DESeq2)
library(BiocParallel)
df <- expand.grid(type=factor(1:25),patient=factor(1:3),rep=1:2)
dds <- makeExampleDESeqDataSet(n=100000,m=150)
colData(dds) <- DataFrame(df)
# ~~~ ...then either this simple design ~~~
design(dds) <- ~patient + type
dds <- DESeq(dds, parallel=TRUE, BPPARAM=MulticoreParam(4))
# ~~~ ...or this with patient-specific type effects ~~~
dds$group <- factor(paste0(dds$patient, "_", dds\$type))
design(dds) <- ~group
dds <- DESeq(dds, parallel=TRUE, BPPARAM=MulticoreParam(4))

The max memory for 4 cores was 6 GB and the max for 8 cores was 10 GB. Our cluster uses SLURM and I requested span[hosts=1] which "indicates that all the processors allocated to this job must be on the same host". By the way, the reason why the memory gets into the low GBs is because there are many coefficients and statistics being stored within 'dds', beyond the counts and normalization factors, and I think it's hard to restrict what R objects are being sent around to child processes. You could be more explicit in the scripts about breaking apart the dataset into discrete chunks, for example, only the dispersion fit and prior variance steps need to look across all genes (these are fast), and the other steps could occur in totally independent jobs. I think to be certain that objects wouldn't be shared, you'd have to do the splitting manually. I can help if you want to do this route. But my numbers below indicate that you might be better off just lowering the number of cores and maybe filtering the rows a bit if possible.

My timing (I just tried once for each) was 1400 s for simple design / 4 cores, 1100 s for simple design / 8 cores, 2800 s for patient-specific design / 4 cores, 1200 s for patient-specific design / 8 cores. So I would expect ~4x these numbers for memory and timing when you go from 100k to 400k rows.

Do you really have 400k rows with minimal signal across a minimum number of samples? Some modest filtering (e.g. >= 4 samples with normalized counts >= 10) might help brings things to a more manageable state, where it's just taking 20 min to run and using only a few GB.

After saving 'dds' at the completion of the code above, you'll still have to call results() to extract comparisons, and again you'll want to use parallel=TRUE. I would recommend using the above code with version >= 1.16, and then use lfcShrink() to get shrunken LFC for a given 'contrast':

res <- results(dds, contrast=c("group","...","..."), parallel=TRUE)
res <- lfcShrink(dds, contrast=c("group","...","..."), res=res)

In the upcoming release of DESeq2 (v1.18 which will come out at the end of the month), you could replace the two lines above with the following faster line of code, which would build a results table with shrunken LFC for the contrast of interest:

res <- lfcShrink(dds, contrast=c("group","...","..."), parallel=TRUE)

hi Jeff,

I've been looking into this for the past weeks, and I did time trials for 400k rows. For the complex design above with 150 samples and patient-specific effects for each cell type, the whole pipeline took 1:15 on the clock and used a max of 13 GB, across 8 cores. That seems reasonable, each core using ~1.5 GB.

I found that I could reduce max memory by not using the DESeq() function, but breaking out the steps one by one. This is unfortunate, but I think unavoidable due to the nature of memory sharing when the parallel functions are called within a function (DESeq, and its parallel sub-function) by the general purpose backends 'parallel' and 'snow'. The run time was about the same for using DESeq() with parallel=TRUE but the max memory was 23 GB.

The code I used is pasted below. I think I'll work on the code in DESeq2 functions so that users can copy paste this from the source if it's useful. It's essentially what goes on when you call DESeq() with parallel=TRUE. But I think breaking this code out is only going to give a measurable benefit if you have 100,000s of rows and number of coefficients getting close to 100.

library(BiocParallel)
dds <- estimateSizeFactors(dds)
idx <- factor(sort(rep(1:8,length=nrow(dds))))
dds.list <- lapply(1:8, function(i) dds[idx==i,])
dds.list <- bplapply(dds.list, function(d) {
suppressPackageStartupMessages(library(DESeq2))
estimateDispersionsGeneEst(d)
}, BPPARAM=SnowParam(8))
dds <- do.call(rbind, dds.list)
dds <- estimateDispersionsFit(dds)
dispPriorVar <- estimateDispersionsPriorVar(dds)
dds.list <- lapply(1:8, function(i) dds[idx==i,])
dds.list <- bplapply(dds.list, function(d, dispPriorVar) {
suppressPackageStartupMessages(library(DESeq2))
d <- estimateDispersionsMAP(d, dispPriorVar=dispPriorVar)
nbinomWaldTest(d)
}, dispPriorVar, BPPARAM=SnowParam(8))
dds <- do.call(rbind, dds.list)

Content
Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.


text:
# On Diophantine approximations with positive integers: a remark to W.M.Schmidt's theorem

Authors
Type
Preprint
Publication Date
Dec 21, 2011
Submission Date
Apr 13, 2009
Identifiers
arXiv ID: 0904.1906
Source
arXiv
Yellow

## Abstract

We prove a generalization of W.M. Schmidt's theorem related to the Diophantine approximations for a linear form of the type $\alpha_1x_1+\alpha_2x_2 +y$ with {\it positive} integers $x_1,x_2$.

Seen <100 times