text
stringlengths 100
957k
| meta
stringclasses 1
value |
|---|---|
## Convergence of Markov Chain
18 minute read ,
What is Markov Chain ? Markov Chain is a Stochastic Model in which Future is dependent only on Present not on Past , What I mean to say that is ...
## Highest Posterior Density Interval
3 minute read ,
Highest Posterior Density Interval is interval of the parmeter in which the posterir value are high when compared to any other point outside the interval (i....
## Introduction to Logistic Regression
4 minute read ,
Usually in Linear Regression we consider $X$ as a explanatory variable whose columns are $X_1 , X_2 …..X_{p}$ are the variables which we use predict are the ...
## Supervised Learning with Scikit Learn
31 minute read , , , , , , , , , ,
Machine Learning is the art of giving computers the ability to learn from data and make decisions on their own without explicitly programmed for example ...
## Tensorflow Hello World
5 minute read ,
Tensorflow is made up of two words tensor and flow , where tensor means multidimensional array and flow means graph of operations. It is developed by google ...
|
{}
|
Home > Error Rate > Word Error Rate Tool
# Word Error Rate Tool
## Contents
This problem can be overcome by using the hit rate with respect to the total number of test-reference match pairs found by the matching process used in scoring, (H+S+D+I), rather than We show that BLEU-oriented global optimization of ASR system parameters improves the translation quality by an absolute 1.5% BLEU score, while sacrificing WER over the conventional, WER-optimized ASR system. Works only for iterables up to 254 elements (uint8). For text dictation it is generally agreed that performance accuracy at a rate below 95% is not acceptable, but this again may be syntax and/or domain specific, e.g. http://hardwareyellowpages.com/error-rate/word-error-rate-calculation-tool.html
Score, WER, information item error etc. Edit distance The word error rate may also be referred to as the length normalized edit distance.[4] The normalized edit distance between X and Y, d( X, Y ) is defined Pretty-printing enables human-readable logging of alignments and metrics. List of target sentences assigned to a source sentence in database. https://en.wikipedia.org/wiki/Word_error_rate
## Word Error Rate Python
Whereas WER provides an important measure in determining performance on a word-by-word level and is typically applied to measure progress when developing different acoustic and languages models, it only provides one All such factors may need to be controlled in some way. Insertion: A word was added. IF I=0 then WAcc will be equivalent to Recall (information retrieval) a ratio of correctly recognized words 'H' to Total number of words in reference 'N'.
Retrieved 28 August 2013. ^ Morris, A.C., Maier, V. & Green, P.D., "From WER and RIL to MER and WIL: improved evaluation measures for connected speech recognition", Proc. CiteSeerX10.1.1.89.424. ^ Nießen et al.(2000) ^ Computation of Normalized Edit Distance and Application:AndrCs Marzal and Enrique Vidal McCowan et al. 2005: On the Use of Information Retrieval Measures for Speech Recognition In a Microsoft Research experiment, it was shown that, if people were trained under "that matches the optimization objective for understanding", (Wang, Acero and Chelba, 2003) they would show a higher Python Calculate Word Error Rate It is 0 exactly when the hypothesis is the same as the reference.
During an extrapolation session: Out of the 147 hypothesis sentences, 42 have not been found in database and have to be evaluated. Wikipedia® is a registered trademark of the Wikimedia Foundation, Inc., a non-profit organization. Unlike the Levenshtein distance, however, the operations are on words and not on individual characters. WER is a minimum edit-distance measure produced by applying a dynamic alignment between the output of the ASR system and a reference transcript (similar to the Levenstein distance (Manning, C., Schütze,
This may be particularly relevant in a system which is designed to cope with non-native speakers of a given language or with strong regional accents. Word Error Rate In Mobile Communication We recommend upgrading to the latest Safari, Google Chrome, or Firefox. All such factors may need to be controlled in some way. Theme: Elegant by Talha Mansoor Store Store home Devices Microsoft Surface PCs & tablets Xbox Virtual reality Accessories Windows phone Software & Apps Office Windows Additional software Windows apps Windows phone
## Word Error Rate Algorithm
A further complication is added by whether a given syntax allows for error correction and, if it does, how easy that process is for the user. https://github.com/romanows/WordSequenceAligner The word error rate is defined as $$WER = \frac{\text{#insertions} + \text{#deletions} + \text{#substitutions}}{\text{Words in the reference}}$$ \$ asr align --help usage: asr align [-h] [-s1 S1] [-s2 S2] align optional Word Error Rate Python Corrected version: Stephan Vogel, Sonja Nießen, Hermann Ney. "Automatic Extrapolation of Human Assessment of Translation Quality". Sentence Error Rate Navigation index modules | previous | ASR 0.1.0 documentation » Align¶ This tool to calculate the word error rate (WER).
The WER is a valuable tool for comparing different systems as well as for evaluating improvements within one system. http://hardwareyellowpages.com/error-rate/word-error-rate-example.html doi:10.1016/S0167-6393(01)00041-3. So if we have the reference "This is wikipedia" and hypothesis "This _ wikipedia", we call it a deletion. Tags: ASR, iTalk2Learn test data, speech recognition, WER, word-by-word, word-error-rate Related posts Fantastic feedback about Fractions Lab! Word Error Rate Matlab
References [1] Jelinek, F. (1997) Statistical Methods for Speech Recognition, MIT Press. [2] Manning, C., Schütze, H. (1999) Foundations of Statistical Natural Language Processing, MIT Press. 27/02/2015 in Blog, Project. Its most important features ar are: Highly informative colored output Estimation of the n-most common errors Character Error Rate (CER) estimation Support an external vocabulary to calculate out-of-vocabulary (OOV) words License BWidget ToolKit 1.2.1 or higher. navigate here Example WordSequenceAligner werEval = new WordSequenceAligner(); String [] ref = "the quick brown cow jumped over the moon".split(" "); String [] hyp = "quick brown cows jumped way over the moon
Reload to refresh your session. Character Error Rate I've understood it after I saw this on the German Wikipedia: \begin{align} m &= |r|\\ n &= |h|\\ \end{align} \begin{align} D_{0, 0} &= 0\\ D_{i, 0} &= i, 1 \leq i Furthermore, compound words and affixes may be scored as errors even though they were actually recognized correctly, e.g. “Beispiel Sammlung” vs “Beispielsammlung” (collection of exercises) in German.
## The WER is a valuable tool for comparing different systems as well as for evaluating improvements within one system.
1. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
2. In Proc. 2nd International Conference on Language Resources and Evaluation, pp. 39-45, Athens, Greece, May-June 2000.
3. doi:10.1016/S0167-6393(01)00041-3.
4. Brodcasting Shared "Board" with Google App Engine ...
ICASSP Publication Type Inproceedings Book Title Proc. Reload to refresh your session. It does not consider the contextual and syntactic roles of a word, which are often critical for MT. Word Error Rate Java Examination of this issue is seen through a theory called the power law that states the correlation between perplexity and word error rate.[1] Word error rate can then be computed as:
ICSLP 2004 ^ Wang, Y.; Acero, A.; Chelba, C. (2003). Click here to visit the EvalTrans page there. These factors are likely to be specific to the syntax being tested. his comment is here Hunt (1990) has proposed the use of a weighted measure of performance accuracy where errors of substitution are weighted at unity but errors of deletion and insertion are both weighted only
We recommend upgrading to the latest Safari, Google Chrome, or Firefox. depend fundamentally on the choice of sample translations. The resulting transcript is then compared to the true transcription provided as reference. Contact GitHub API Training Shop Blog About © 2016 GitHub, Inc.
Features Evaluation Manually assigned quality criteria: score (0-10), information item errors (ok, absence, syntax, semantic, ...) Automatically computable quality criterion: word error rate (multi-reference) Whole-testcorpus quality criteria: subjective sentence error Note that since N is the number of words in the reference, the word error rate can be larger than 1.0, and thus, the word accuracy can be smaller than 0.0. It compares a reference to an hypothesis and is defined like this: $$\mathit{WER} = \frac{S+D+I}{N}$$ where S is the number of substitutions, D is the number of deletions, I is the Source code necessary, as it has to be patched: There are problems with the lack of Unicode support in Tcl 8.0; higher versions have not been tested yet.
O(nm) time ans space complexity. So you can delete one from the hypothesis and compare the rest. Personal Open source Business Explore Sign up Sign in Pricing Blog Support Search GitHub This repository Watch 4 Star 5 Fork 2 nsmartinez/WERpp Code Issues 0 Pull requests 0 Projects You signed out in another tab or window.
System/Software requirements To use EvalTrans, you need a system supported by the following software: Tcl/Tk 8.0 or higher. Please enable JavaScript to view the comments powered by Disqus. The usual measures regarding the detection of keywords are precision and recall (and their harmonic mean called the f-measure). Structure EvalTrans is written in Tcl/Tk: Easy extension and on-the-fly debugging possible Time-critical routines written in C: low answer time Command line tool EvalTransBatchEval enables quick evaluation in batch jobs Screenshots
Open in Desktop Download ZIP Find file Branch: master Switch branches/tags Branches Tags master Nothing to show Nothing to show New pull request Fetching latest commit… Cannot retrieve the latest commit Reload to refresh your session. an article like “the” is regarded to have the same importance as a mathematical term such as “denominator”). The possible operations are: Deletion: A word was deleted.
does the fault lie with the user or with the recogniser. Thomas, US Virgin Islands.
|
{}
|
# Root of 2259505572983
#### [Root of two trillion two hundred fifty-nine billion five hundred five million five hundred seventy-two thousand nine hundred eighty-three]
square root
1503165.1849
cube root
13122.1341
fourth root
1226.0364
fifth root
295.6669
In mathematics extracting a root is declared as the determination of the unknown "x" in the equation $y=x^n$ The outcome of the extraction of the root is seen as a mathematical root. In the case of "n is 2", one talks about a square root or sometimes a second root also, another possibility could be that n = 3 by this time one would consider it a cube root or simply third root. Considering n beeing greater than 3, the root is declared as the fourth root, fifth root and so on.
In maths, the square root of 2259505572983 is represented as this: $$\sqrt[]{2259505572983}=1503165.1848626$$
Furthermore it is legit to write every root down as a power: $$\sqrt[n]{x}=x^\frac{1}{n}$$
The square root of 2259505572983 is 1503165.1848626. The cube root of 2259505572983 is 13122.134118669. The fourth root of 2259505572983 is 1226.0363717535 and the fifth root is 295.66688333451.
Look Up
|
{}
|
Let $M$ be (for example) a Calabi-Yau threefold with Kaehler form $\omega$ and holomorphic 3-form $\Omega$. We say that a submanifold $L$ of $M$ is a special Lagrangian submanifold if $L$ is Lagrangian with respect to symplectic form $\omega$ and also $\mathrm{Im}\Omega|_L=0$. I would like to know geometric intuition of the latter condition. I am aware that Lagrangian condition roughly corresponds to $L$ having only position coordinate, momentum coordinate, or certain mixture of them (Lagrangian formulation of classical mechanics). I wonder if there is a good explanation about the extra condition $\mathrm{Im}\Omega|_L=0$.
|
{}
|
# Laplacian Eigenmaps Derivation Question
I had read a few papers on Laplacian Eigenmaps and have been a bit confused on 1 step in the standard derivation. First I just want to deal with the 1-D case. We are given that we want to find the vector $y\in \mathbb{R}^n$ that minimizes $y^TLy$ where L is an $n$ x $n$ symmetric real matrix (positive semidefinite).
If we know that $y$ is an eigenvector of $L$ then I can see that finding the $\text{argmin } y^TLy$ boils down to finding the eigenvector of $L$ with the least non-zero eigenvalue.
Without assuming that $y$ is an eigenvector of $L$ (I don't think we should make this assumption), I get that $\text{argmin } y^TLy = \text{argmin } y^T(\sum\limits_{i=1}^n\lambda_iu_iu_i^T)y$ where $u_i$ is the eigenvector of $L$ corresponding to the eigenvalue $\lambda_i$. Assuming unit length for $y$ and $u_i$, minimizing $y^TLy$ reduces to finding the smallest $d$ eigenvalues (assuming our embedded space is of dimension $d$). Does this mean our embedded space has the basis given by the corresponding $d$ eigenvectors (or for the 1-D case the eigenvector corresponding to the smallest non-zero eigenvalue)?
Thanks so much.
|
{}
|
# Asymptotic Behaviour of $\Gamma^{(k)}(1)$
Pretty simple question to which I haven't found much in the literature. Are there proper results for the asymptotic behaviour of the derivatives of the Gamma-function? That is for $$\Gamma^{(k)}(1) = \int_0^\infty (\log t)^k e^{-t} \, {\rm d}t$$ as $$k$$ gets large?
The range of integration over the interval $$(0,1)$$ is responsible, for the strong factorial growth which I oversaw. Hence, I'd be somewhat more interested in the asymptotics of $$\int_1^\infty (\log t)^k e^{-t} \, {\rm d}t \, .$$ The integrand has a maximum at approximately $$t\approx \frac{k}{\log k}$$, so it will blow up somehow. Laplace's method is what comes to my mind, which gives $$\int_1^\infty (\log t)^k e^{-t} \, {\rm d}t \sim \sqrt{\frac{2\pi k}{W(k)+1}} \, W(k)^k \, e^{-\frac{k}{W(k)}}$$ where $$W(k)$$ is the principal branch of LambertW.
The remainder for the asymptotic expansion of the starting expression (given by metamorphy) is then just $$\frac{\int_1^\infty (\log t)^k e^{-t} \, {\rm d}t}{k!} \sim \frac{1}{\sqrt{W(k)+1}} \left( \frac{e \, W(k)}{k \, e^{\frac{1}{W(k)}}} \right)^k \, ,$$ vanishing faster than any power.
Is it possible to obtain an asymptotic expansion, instead of just the asymptotics?
• For the new part of the question - yes, I think Laplace's mtehod is the way to go, too. And for higher-order asymptotics, I see nothing more than just to continue the computations of the method... – metamorphy Apr 23 '20 at 16:07
$$\Gamma(1+z)$$ has simple poles at $$z=-n$$ with the residue $$(-1)^{n-1}/(n-1)!$$ where $$n$$ takes positive integer values. Thus, for any positive integer $$m$$, the function $$\Gamma(1+z)+\sum_{n=1}^{m}\frac{(-1)^n}{(n-1)!}\frac{1}{n+z}=\sum_{k=0}^{\infty}\left(\frac{\Gamma^{(k)}(1)}{k!}+(-1)^k\sum_{n=1}^{m}\frac{(-1)^n}{n^k\cdot n!}\right)z^k$$ is regular in $$|z|, and the last series converges at $$z=m$$ (at least). This gives the asymptotics $$\Gamma^{(k)}(1)\asymp(-1)^k k!\sum_{n=1}^{(\infty)}\frac{(-1)^{n-1}}{n^k\cdot n!},\qquad k\to\infty.$$ Despite the convergence, this is only an asymptotic equality; there is a remainder that is not captured. (It is coming from $$\int_1^\infty t^z e^{-t}\,dt$$ which is an entire function of $$z$$.)
• Kind of weird, that despite the weak growth of $(\log t)^k$ compared to $t^k$, the asymptotic behaviour is pretty much the same... – Diger Apr 22 '20 at 21:43
• @Diger: it is $t\to 0$ (not $t\to\infty$) that causes such a growth. – metamorphy Apr 22 '20 at 22:24
• Sorry, you are right...That's precisely the definition of the Gamma function $$\int_0^1 (-\log t)^k \, {\rm d}t$$ upon change of variables. So the asymptotics pretty much follow by splitting the integral in two parts: $(0,1)$ and $(1,\infty)$. – Diger Apr 22 '20 at 22:41
Note that $$\sum_{k=0}^\infty \Gamma^{(k)}(1) \frac{z^k}{k!} = \Gamma(1+z)$$ The closest singularity of $$\Gamma(\zeta)$$ to $$\zeta=1$$ is at $$\zeta=0$$, where $$\Gamma$$ has a simple pole with residue $$1$$. The next closest singularity is at $$\zeta=-1$$. Thus $$\Gamma(1+z) - \frac{1}{1+z} = \sum_{k=0}^\infty \left(\frac{\Gamma^{(k)}(1)}{k!} - (-1)^{k}\right) z^k$$ has radius of convergence $$2$$. Thus $$\Gamma^{(k)}(1) \sim (-1)^k k!$$, with $$\left| \Gamma^{k}(1) - (-1)^k k! \right| = O\left(r^k k!\right)\ \text{for all } r \in (0,1/2)$$
|
{}
|
Redis provides two separate persistence mechanisms, RDB and AOF. This chapter first describes how the AOF feature works, how commands are stored in AOF files, and how different AOF storage modes affect data security and Redis performance. After that, we will introduce the method of restoring the database state from the AOF file and the implementation mechanism behind the method. Some pseudo-code will also be used to facilitate understanding. This article is based on the redis design and implementation book. The knowledge about redis persistence is more important, so I read the book directly to avoid detours, and record it in this article.
## Basic Introduction
AOF persistence is used to record database state by saving the write commands executed by the redis server.
1 2 3 set key1 value1 sadd fruits "apple" "banner" rpush numbers 128 125
The RDB persistence method is to save the key-value pairs of key1, fruits, and numbers to the RDB file, while the AOF persistence method is to save the set, sadd, and rpush commands executed by the server to the AOF file, and all commands written to the AOF file are saved in the Redis command request protocol format.
## Persistence Implementation
The implementation of the AOF persistence function can be divided into three steps (sync): append, write, and synchronize.
### Command append
When AOF persistence is on, the server appends the executed write command to the end of the aof_buf buffer of the server state in protocol format after executing a write command.
### Writing and Synchronization
The server process in Redis is an event loop, where file events are responsible for receiving command requests from clients and sending command replies to clients, and time events are responsible for executing functions like the serverCron function that need to be run at regular intervals. Because the server may execute commands while processing file events, causing some content to be appended to the aof_buf buffer, before the server ends an event loop, it calls the flushAppendOnlyFile function to consider whether the contents of the aof_buf buffer need to be written and saved to the AOF file The following is the pseudo-code.
1 2 3 4 5 6 7 8 9 10 11 12 #事件轮询函数 def evenloop(): while True: # 处理文件事件,接收命令请求以及发送命令回复 # 处理命令请求时可能会有新的内容被追加到 aof_buf 缓存区中 processFileEvents() # 处理时间事件 processTimeEvents() # 是否将 aof_buf 缓冲区中的内容写入并同步到 appendonly.aof 文件中。 flushAppendOnlyFile()
The behavior of the flushAppendOnlyFile function is determined by the value of the appendfsync option configured by the server, and the different values produce the following behavior.
Options Behaviors
always Write and synchronize all contents of the aof_buf buffer to the AOF file (safest, but poor performance)
everysec Writes and synchronizes all the contents of the aof_buf buffer to the AOF file, and then synchronizes the AOF file again if the last time the AOF file was synchronized was more than 1 second ago. (safe, better performance)
no Writes and synchronizes all the contents of the aof_buf buffer to the AOF file, but does not synchronize the AOF file; it is generally up to the operating system to decide when to synchronize. (typically 30 seconds, unsafe, best performance))
If the user does not actively set a value for the appendfsync option, then the appendfsync option defaults to everysec. For more information on the appendfsync option, see the sample configuration file redis.conf that comes with the Redis project.
To improve the efficiency of writing to files, in modern operating systems, when the user calls the write function to write some data to a file, the operating system usually stores the written data in a memory buffer temporarily and waits until the buffer is full or the specified time limit has passed before actually writing the data in the buffer to disk. This approach improves efficiency, but also creates a security problem for writing data, because if the computer is down, the write data stored in the memory buffer will be lost. For this reason, two synchronization functions, fsync and fdatasynce, are provided to force the operating system to write the data in the buffer to the hard disk immediately, thus ensuring the security of the written data.
### AOF persistence and efficiency
The value of the server configuration appendfsync option directly determines the efficiency and security of the AOF persistence feature.
• When the value of appendfsync is always, the server writes all the contents of the aof_buf buffer to the AOF file in each event loop and synchronizes the AOF file, so always is the slowest of the three values of the appendfsync option, but in terms of security, always is also the safest. always is also the safest in terms of security, because even if there is a crash, AOF persistence will only lose the command data generated in an event loop.
• When the value of appendfsync is everysec, the server writes all the contents of the aof_buf buffer to the AOF file in each event loop, and synchronizes the AOF file in a subthread every second. In terms of efficiency, everysec mode is fast enough, and even if there is a downtime, the database will only lose one second of command data.
• When the value of appendfsync is no, the server writes all the contents of the aof_buf buffer to the AOF file in each event loop, and it is up to the operating system to control when the AOF file is synchronized. Because the flushAppendonlyFile call in no mode does not require a synchronization operation, the AOF file writes in this mode are always the fastest, but because this mode accumulates write data in the system cache for a period of time, the single synchronization time in this mode is usually the longest of the three modes. From the standpoint of spreading operations, the no mode is similar in efficiency to the everysec mode, in that in the event of a downtime, a server using the no mode will lose all write command data since the last synchronization of the AOF file.
Since the AOF file contains all the write commands needed to rebuild the database state, the server simply reads and re-executes the write commands stored in the AOF file to restore the database state before the server is shut down. The detailed steps for Redis to read the AOF file and restore the database state are as follows:
• Create a pseudo-client without a network connection (fakeclient): Because Redis commands can only be executed in the client context, and the commands used to load the AOF file come directly from the AOF file and not from a network connection, the server uses a pseudo-client without a network connection to execute the write commands saved in the AOF file. The effect of a pseudo-client executing a command is exactly the same as a client with a network connection executing a command.
• Parses and reads a write command from the AOF file.
• Execute the read write command using the pseudo-client.
• Keep performing steps 2 and 3 until all write commands in the AOF file have been processed.
When the above steps are completed, the database state stored in the AOF file is restored in its entirety.
### AOF rewriting
Because AOF persistence records database state by storing executed write commands, as server runtime passes, the contents of the AOF file will become larger and larger, and if left unchecked, an oversized AOF file is likely to have an impact on the Redi server or even the entire host computer. The larger the AOF file, the more time it takes to perform a data restore using the AOF file.
• As an example
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 redis> RPUSH list "A" "B" // ["A","B"] (integer) 2 redis> RPUSH list "C" // ["A","B", "C"] (integer) 3 redis> RPUSH list "D" "E" // ["A","B", "C", "D", "E"] (integer) 5 redis> LPOP list // ["B", "C", "D", "E"] "A" redis> LPOP list // ["C", "D", "E"] "B" redis> RPUSH list "F" "G" // ["C", "D", "E", "F" "G"] (integer) 5
Then the AOF file would need to store six commands just to record the state of the list key. For real-world applications, the number and frequency of write commands will be much higher than the simple example above, and will cause much more serious problems. To solve the problem of AOF file size expansion, Redis provides the AOF file rewrite feature. With this feature, the Redis server can create a new AOF file to replace the existing AOF file. The old and new AOF files hold the same repository state, but the new AOF file does not contain any redundant commands that waste space, so the size of the new AOF file is usually much smaller than the old AOF file.
In the next section, we will describe how AOF file rewriting is implemented, and how the BGREWRITEAOF command is implemented.
### Implementation of AOF file rewriting
Although Redis names the ability to generate new AOF files to replace AOF files with AOF file rewrites, in reality, AOF file rewrites do not require any reading, parsing, or writing of existing AOF files; they are implemented by reading the current database state of the server.
Consider a situation where the server executes the following command on the list key.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 redis> RPUSH list "A" "B" // ["A","B"] (integer) 2 redis> RPUSH list "C" // ["A","B", "C"] (integer) 3 redis> RPUSH list "D" "E" // ["A","B", "C", "D", "E"] (integer) 5 redis> LPOP list // ["B", "C", "D", "E"] "A" redis> LPOP list // ["C", "D", "E"] "B" redis> RPUSH list "F" "G" // ["C", "D", "E", "F" "G"] (integer) 5
Then the server must write six commands in the AOF file in order to keep the current state of the list keys. If the server wants to use as few commands as possible to record the state of the list key, then the easiest and most efficient way is not to read and analyze the contents of the existing AOF file, but to read the value of the key list directly from the database and then replace the six commands saved in the AOF file with a single RPUSH list “C” “D” “E” “E” “G” command, thus reducing the This reduces the number of commands needed to save the list key from six to one.
The pseudo-code of the whole process can be represented as follows.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 def aof_rewrite(new_aof_file_name): #创建新AOF文件 f = create_file(new_aof_file_name) #当遍历疑据库 for db in redisserver.db: #忽略空数据库 if db.is_empty:continue #写入 SELECT 命令,指定数据库号码 f.writecommand("SELECT"+ db.id) #遍历最据库中的所有键 for key in db: #忽略已过期的健 if key.is_expired(): continue #根据键的痰型对键进行重写 if key.type == String: rewrite_string(key) elif key.type == List: rewrite_list(key) elif key.type == Hash: rewrite_hash(key) elif key.type == Set: rewrite_set(key) elif key.type == SortedSet: rewrite_sorted_set(key) # 如果键带有过翔时闻,那么过期时锏也要敲重写 if key.have_expire_time(): rewrite_expire_time(key) #写入完毕,关闭文件 f.close() def rewrite_string(key): #使用Get命令获取字符串键的值 value=Get(key) #使用SET命令重写字符串键 f.write_command(SET, key, value) def rewrite_list(key): #使用LRANGE命令获取所有元素 item1,item2, ... , itemN = LRANGE(key, 0, 1) #使用RPUSH命令重写列表 f.write_command(RPUSH, key, item1,item2.....) def rewrite_hash(key): #使用HGETALL命令获取哈希所有键值对 field1, value1, field2, value2,...,fieldN,valueN = HGETALL(key) #使用HMSET命令重写字符串键 f.write_command(HMSET, key, field1, value1, field2, value2,...,fieldN,valueN) def rewrite_set(key): #使用 SMEMBERS 命令获取集合键包含的所有元素 elem1, elem2, ..., elemN = SMERBERS(key) #使用 SADD 命令重写集合 f.write_command(SADD, key, elem1, elem2, ..., elemN) def rewrite_sorted_set(key): #使用 ZRANGE 命令获取有序集合键包含的所有元素 member1, score1, member2, score2, ..., memberN, scoreN = ZRANGE(key, 0, -1, "WITHSCORES") #使用 ZADD 命令重写有序集合 f.write_command(ZADD, key, member1, score1, member2, score2, ..., memberN, scoreN) def rewrite_expire_time(key): #获取毫秒精度的键过期时间 timestamp = get_expire_time_in_unixstamp(key) #使用 PEXPIREAT 命令重写过期时间 f.write_command(PEXPIREAT, key, timestamp)
Because the new AOF file generated by the aof_rewrite function contains only the commands necessary to restore the current database state, the new AOF file does not waste any hard disk space.
Note: In practice, to avoid overflowing the client input buffer when executing commands, the rewriter will first check the number of elements contained in the key if the number of elements exceeds the value of the redis.h/REDIS_AOF_REWRITE_ITEMS_PER_ CMD constants, then the rewriter will use multiple commands to record the value of the key instead of just one command. In version 3.0, the value of the REDIS_AOF_REWRITE_ITEMS_PER_CMD constant is 64, which means that if a collection key contains more than 64 elements, then the rewriter will use multiple SADD commands to record the collection, and each command sets the number of elements to 64 as well.
### AOF background rewrites
The AOF rewriter aof_rewrite function described above does a good job of building a new AOF file, but because this function does a lot of writing, the thread calling it will be blocked for a long time. Because the Redis server uses a single thread to handle command requests, if the aof_rewrite function were called directly by the server, the server would not be able to handle command requests from the client during the rewrite of the AOF file.
Obviously, as an auxiliary maintenance tool, Redis does not want AOF rewrites to prevent the server from processing requests, so Redis decided to put the AOF rewrites into a subprocess, which accomplishes two things at once.
• The server process (the parent process) can continue to process the command request while the child process does the AOF rewrite.
• The child process carries a copy of the server process’ teachings, and using a child process instead of a thread ensures data security while avoiding the use of locks
However, there is a problem that needs to be solved by using child processes, because the server process needs to continue processing command requests during the AOF rewrite, and the new commands may modify the existing database state, thus making the current database state of the server and the database state saved in the rewritten AOF file inconsistent.
#### For an example
time server process subprocess
t1 execute command SET k1 v1
t2 execute command SET k1 v2
t3 execute command SET k1 v3
t4 Create subprocess, execute AOF file rewrite Start AOF file rewrite
t5 execute the command SET k2 100 execute the rewrite operation
t6 execute command SET k3 101 execute rewrite operation
t7 execute command SET k4 102 Complete AOF rewrite
The above shows an example of AOF file rewrite. When the child process starts the file rewrite, there is only one key k1 in the database, but when the child process finishes the AOF file rewrite, there are three new keys k2, k3, and k4 in the database of the server process, so the rewritten AOF file and the current database state of the server are not consistent. The new AOF file only holds data for one key, k1, while the server database now has four keys, k1, k2, k3, and k4.
To solve this data inconsistency problem, the Redis server sets up an AOF rewrite buffer that is used after the server creates a child process, and when the Redis server finishes executing a write command, it sends the write command to both the AOF buffer and the AOF rewrite buffer. This means that during the execution of the AOF rewrite by the child process, the server process needs to perform the following three tasks.
• Execute the command from the client.
• Append the executed write command to the AOF buffer
• Append the executed write command to the AOF rewrite buffer
This ensures that.
• The contents of the AOF buffer are written and synchronized to the AOF file on a regular basis, and processing of existing AOF files is performed as usual.
• All write commands executed by the server since the creation of the child process are recorded in the AOF rewrite buffer.
When the child process finishes the AOF rewrite, it sends a signal to the parent process, and after receiving the signal, the parent process will call a signal handler and do the following:
1. write all the contents of the AOF rewrite buffer to the new AOF file, at which time the database state saved in the new AOF file will be the same as the current database state of the server.
2. rename the new AOF file, atomically overwriting the existing AOF file, completing the replacement of the old and new AOF files.
After this signal handler function is executed, the parent process can continue to receive command requests as usual. During the entire AOF background rewrite process, only the signal handler function will block the server process (the parent process). At other times, AOF background rewrites do not block the parent process, which minimizes the impact of AOF rewrites on server performance.
The complete rewriting process is as follows.
time server process subprocess
t1 execute command SET k1 v1
t2 execute command SET k1 v2
t3 execute command SET k1 v3
t4 Create subprocess, execute AOF file rewrite Start AOF file rewrite
t5 execute the command SET k2 100 execute the rewrite operation
t6 execute command SET k3 101 execute rewrite operation
t7 execute command SET k4 102 Complete AOF rewrite, send signal to parent process
t8 Receive the signal from the child process, and append the commands SET k2 100, SET k3 101, SET k4 102 to the end of the new AOF file
t9 Overwrite the old AOF file with the new AOF file
The above is the principle of the AOF background rewrite, that is, the implementation of the BGREWRITEAOF command.
## Summary
• The AOF file records the database state of the server by saving all write command requests that modify the database.
• All commands in the AOF file are saved in the format of the Redis command request protocol.
• The different values of the appendfsync option have a significant impact on the security of the AOF persistence feature and the Redis server
• The server can restore the original state of the database by simply loading and re-executing the commands saved in the AOF file.
• An AOF rewrite produces a new AOF file that holds the same database state as the original AOF file, but in a smaller size.
• AOF rewrite is an ambiguous name for a function that is implemented by reading key-value pairs from the database without the program having to perform any read, parse, or write operations on the existing AOF file.
• When the BGRERIRTEAOF command is executed, the Redis server maintains an AOF rewrite buffer that records all write commands executed by the server during the creation of a new AOF file by a child process. When the child process finishes creating the new AOF file, the server appends everything in the rewrite buffer to the end of the new AOF file, making the database state stored in the old and new AOF files identical. Finally, the server replaces the old AOF file with the new AOF file, thus completing the AOF file rewrite operation.
|
{}
|
# HSC Extension 1 and 2 Mathematics/3-Unit/HSC/Induction
Induction is a form of proof useful for proving equations involving non-closed expressions (i.e., expressions with ${\displaystyle n}$ terms; sequences).
## Explanation
Induction involves first proving that the equation is true for ${\displaystyle n=1}$, then proving true for ${\displaystyle n=k+1}$ (assuming for the purpose of the proof that the equation holds true for ${\displaystyle n=k}$). Since it is true for ${\displaystyle n=k}$ and true for ${\displaystyle n=k+1}$, and also true for ${\displaystyle n=1}$, it is true for ${\displaystyle n=2}$. It follows that it is true for all positive integers ${\displaystyle n}$.
### Examples
#### Proving the formula for the sum of a series
Q: Prove by mathematical induction that for all integers ${\displaystyle n\geq 1}$,
${\displaystyle 1^{3}+2^{3}+3^{3}+4^{3}+\cdots +n^{3}=(1+2+3+....n)^{2}}$
A:
1. When ${\displaystyle n=1}$, ${\displaystyle 1^{3}=1={\tfrac {1}{4}}(1)^{2}((1)+1)^{2}={\tfrac {1}{4}}(4)=1}$, so it is true for ${\displaystyle n=1}$
2. Suppose that the statement is true for ${\displaystyle k,k\in \mathbb {N} }$. That is, suppose that ${\displaystyle 1^{3}+2^{3}+3^{3}+4^{3}+\cdots +k^{3}={\tfrac {1}{4}}k^{2}(k+1)^{2}}$. This is sometimes called the induction hypothesis.
3. Then prove the statement for ${\displaystyle n=k+1}$ (that is, prove that ${\displaystyle 1^{3}+2^{3}+3^{3}+\cdots +(k+1)^{3}={\tfrac {1}{4}}(k+1)^{2}(k+2)^{2}}$:
{\displaystyle {\begin{aligned}{\mbox{LHS}}&=1^{3}+2^{3}+3^{3}+4+3+\cdots +k^{3}+(k+1)^{3}\\&={\tfrac {1}{4}}k^{2}(k+1)^{2}+(k+1)^{3}&{\mbox{ (by the induction hypothesis)}}\\&={\tfrac {1}{4}}(k+1)^{2}(k^{2}+4(k+1))\\&={\tfrac {1}{4}}(k+1)^{2}(k^{2}+4k+4)\\&={\tfrac {1}{4}}(k+1)^{2}(k+2)^{2}\\&={\mbox{RHS}}\end{aligned}}}
4. It follows from parts 1 and 2 by mathematical induction that the statement is true for all positive integers ${\displaystyle n}$.
|
{}
|
Mathias Brandewinder on .NET, F#, VSTO and Excel development, and quantitative analysis / machine learning.
19. February 2012 15:37
This post is part of a series providing commentary on the VSTO Stocks project. I initially developed it for theExcel Developers Conference in London, to illustrate some of the benefits or interesting features of VSTO add-ins compared to traditional VBA automation. The add-in is a work in progress, and is by no means production ready, but it is functional; I will update the code and add comments over time. Feel free to ask questions in the comments!
Level: intermediate.
Code version: 39134382823e
The straightforward way to organize an Add-In solution is to just create a single project of type Excel 2007 Add-In (or whichever Office application / version you may target). So why would I go through the pain of structuring my Solution into four distinct Projects in the VSTO Stocks add-in?
Having a single project is a perfectly valid way to proceed, with things kept simple and tight. However, a drawback of going that route is that it makes it easy to write untestable code, with poor separation of concerns.
Note: in the past, I also ran into testing issues with one single project, because I couldn’t reference the Add-In project itself in my automated tests suite, which was problematic. This problem seems to be gone now.
Specifically, one source of such problems is to directly reference either ThisAddIn or Globals classes to access the Excel object model. They behave more or less as static classes would, which is a testing nightmare. For instance, in order to access the Active worksheet in a method, I could write code like this:
public void DoSomeStuff()
{
var workbook = excel.ActiveWorkbook;
var activeSheet = workbook.ActiveSheet;
// do stuff with the sheet
}
As is, this method is virtually untestable: we do not control the instantiation of Globals, and cannot replace it with fakes to emulate various situations that could arise in the application. What if, for instance, we wanted to test the behavior of that function when no worksheet is active?
That problem would be avoided altogether if instead of accessing Excel through the Add-In, we injected a reference to Excel in the method:
public void DoSomeStuff(Application excel)
{
var workbook = excel.ActiveWorkbook;
var activeSheet = workbook.ActiveSheet;
// do stuff with the sheet
}
Now we are free to substitute Application with our own version, set it up to emulate whatever scenario we see fit, and test what the behavior of the method should be in that case. I’ll revisit that question later when discussing automated tests, and leave it at that for now. For that matter, note also that we could perfectly well re-use that method anywhere, as there is no dependency on the add-in.
By separating into multiple projects, we can enforce that rule. In our Solution, the add-in acts purely as a bootstrapper: its only role is to kick things off when Excel starts, and initialize the UserInterface project, where the core of the application logic resides.
Note: I may rename the UserInterface project to ExcelApplication later on, the name would be more fitting.
The UserInterface project has a reference to Microsoft.Office.Interop.Excel, but not the Add-In, and therefore cannot use Globals or ThisAddin. In the ThisAddIn_Startup method, the running instance of Excel is retrieved and passed to the TaskPaneBuilder in the UserInterface project. From that point on, the Add-In itself doesn’t do anything: the ExcelController in the UserInterface project holds a reference to Excel, and handles all the interactions with Excel going forward.
So what is the Domain project about, then?
This one may or may not be a luxury item, depending on your project. The intent of the Domain project is to represent the business model you are dealing with; it should have no knowledge of Excel (hence the lack of reference to the Excel interop). For instance, StockHistory or MovingAverage are concepts which exist and can be modeled independently of Excel. Our add-in is currently using Excel as a client, but nothing would preclude developing a web-based version later, for instance. In that case, having a separate library which contains the Domain would prove very valuable, because it could be used as-is: the “only” effort required would be to write a different client / user interface to interact with that Domain model.
The name of the fourth project, UnitTests, should give away its purpose: it hosts the automated tests that verify certain behavior of the application. We’ll revisit it later on.
Of course, you don’t have to follow that organization - I also write add-ins which live in one single project! The right organization for your solution depends on each individual project, their complexity, and how they may grow over time. The structure/ideas I describe here are on the heavy side, but have served me well over the years - I hope they will help you think about your projects as well!
17. February 2012 06:27
I finally finished “Working effectively with legacy code”, reading it a few pages at a time every morning on my way to work. Legacy code is one of these topics you know are important, but which you never really want to hear about, so the book has stayed on the backlog for a while. Recently, I helped out someone establish tests on a legacy code base, and began following Michael Feather’s tweets with great enjoyment, and decided it was time to read it.
The developer who is already familiar with unit testing, comfortable with his language, object-oriented concepts, and what makes code maintainable - and wants to expand his thoughts and tools on testing and testability.
## 3 things I liked about it
• The chapter titles are awesome – just like good naming is a hallmark of Clean Code, the chapter titles convey very clearly what the intent is. “I need to change a Monster method and I can’t write tests for it”, “It takes forever to make a change”, “How do I know that I am not breaking anything”, “I am changing the same code all over the place” – they all evoke situations we have been through one time or another, and the corresponding chapters do address these questions head-on.
• Clear concepts and vocabulary: if anything, the one sentence that will stay with me is “legacy code is simply code without tests”, a wonderfully clear and opinionated definition, which not everyone may agree with. Feathers defines a few concepts (like a Seam or a Pinch Point), which provide a helpful language to think and and discuss legacy code.
• Multiple languages: I write primarily in C# and F#, so in principle, learning about specific issues of testing legacy C code isn’t high on my concerns list. Still, I found that going through examples in languages I am not familiar with was interesting, in that it provided both a broader perspective on testing and on the relative strengths and weaknesses of various languages. It also made me think of techniques I seldom (if ever) use in C#, like pre-processor directives.
## 3 things I didn’t like that much
• Multiple languages: covering multiple languages provides a broader perspective, but it also comes at the expense of each individual language. If you are specifically interested in, say, C#-specific techniques, this book may disappoint you - it is fairly general.
• A bit dated: for a book published in 2004, it aged remarkably well. Still, 8 years is a long time in computer-years. From a C# developer perspective, there have been a few major releases of both the language and the IDE, with implications on testing and refactoring. I would assume (hope) that today, most language/IDEs do support refactorings like Extract Method. On the language side, the book touches on using function pointers to achieve decoupling, but the context is mostly C. With the emergence of functional concepts (Func<T> in modern C# for instance), I think this would warrant a bigger discussion today.
• A somewhat tedious read: this book is not exactly a page-turner. Reading legacy code examples (a good part of them probably not in a language you are comfortable with, unless you are a polyglot) and figuring out mechanical steps to disentangle it isn’t material that will be turned into a Hollywood movie any time soon.
## Parting thoughts
I really enjoyed this book, but I would recommend it with an asterisk. Depending on how you want to look at it, a polyglot book will either lose specificity, or gain generality. Personally, I think in this case, the gain in generality easily compensates for the lack of depth in each individual language. Yes, I would like a C#-specific book which points to useful, up-to-date tools – but that book would be obsolete in 2 years at best. By covering a variety of languages, Feathers illustrates very different solutions or ideas, and because he uses only fairly simple features in each language, the ideas remain easy to understand and convert into other “coding dialects”.
My personal bent is for concepts and language, because they last longer than recipes and tools, which is why I really enjoyed this book: it helped me create / articulate a mental map. I don’t have many computer books published in 2004 that I read for insight, today – and this one feels like one of these “timeless classics”.
That being said, I think it takes a certain experience with unit testing and code maintenance to appreciate the book, and I wouldn’t recommend it to someone who is just starting with tests and wants to find quick solutions to their problems. It may work (the book is very clear on steps and methodology), but I suspect it may be potentially frustrating.
Totally unrelated note: this is the first technical book I read on Kindle, and I have mixed feelings about it. I was hoping that the Kindle could serve as a portable library for all these massive technical bricks. On one hand, it’s nice to have the possibility to carry around searchable books; on the other hand, clearly, it’s not the best way to read through code samples, where good old paper still has an edge.
6. February 2012 04:24
This post is part of a series providing commentary on the VSTO Stocks project. I initially developed it for the Excel Developers Conference in London, to illustrate some of the benefits or interesting features of VSTO add-ins compared to traditional VBA automation. The add-in is a work in progress, and is by no means production ready, but it is functional; I will update the code and add comments over time. Feel free to ask questions in the comments!
Level: beginner.
Code version: 346c1bd9394e
One of the key benefits I find in using VSTO for Office automation instead of VBA is that it enables using Source Control tools.
During a development effort, regardless of the technology used, lots of things can go wrong. A code change which initially looked like a great idea progressively degenerates into chaos, something goes awry with a file which becomes irrecoverably corrupt, a hard drive suddenly decides it is time to call it quits – all these happen. When they do, it’s nice to have a safety net, and know that somewhere, safe and warm, a snapshot of the code taken in happier times is waiting and can be restored, giving you a safe point to restart from, with only a few hours of work lost.
What I have often seen done with Excel development goes along these lines: on a regular basis, the developer saves the workbook somewhere “safe” with a time-stamp convention, like “MyWorkbook-2010-12-24.xlsx”.
On the plus side, this is a very lightweight process, which addresses some of the issues. At the same time, it is cumbersome: the developer needs to be diligent, the process is manual and error-prone (messing up the timestamp, or accidentally over-writing archives is very possible), and recovering the right version from a folder that contains multiple versions only identified by a timestamp is impractical.
Developers working in other ecosystems have been facing the same issue, and address it with specialized tools: source control systems. In a nutshell, the idea of source control is to operate like a library: the source code is stored in a “vault” (known as the Repository), developers check out a local copy of the current version on their machine, edit it, and check in/commit the modified code back into the vault if they are happy with the result.
Put differently, whatever code is currently being modified on the developer’s machine is “scratch paper”; it become “real” only once it is committed.
There are a few obvious benefits. The entire history of the project is saved for posterity, and its state at any point in time can be instantly restored. The system generates timestamps automatically, and each commit has comments attached to it, which helps navigation between versions. This encourages experimenting with code ideas: check out the code, spike something – if it works, great, if not, discard it and revert to the previous repository version.
[pic of repo on CodePlex]
Overview of the project history with Mercurial + Tortoise on Windows
More interestingly, version control systems typically store the difference between the current version and the previous one, and not the file itself. Besides keeping the size of the repository minimal, it also allows to produce “diffs”, i.e. code differences: the source control system can easily produce a view that highlights all the differences between two versions of the code, which is invaluable.
The “Diff” highlights what has been added or removed between versions.
Diff view of the changes to a specific file on CodePlex
## Why hasn’t the traditional Excel developer community embraced source control?
The main reason, in my opinion, is that Source Control systems are at their best when dealing with text files. While this is the case for most development platforms, Excel is peculiar in that aspect: the code is embedded in the Workbook, in multiple forms (Excel formulas, code-behind worksheets, macro modules…), and the overall project isn’t a collection of text files containing code. Up to version 2003, workbooks were saved as a proprietary binary file, which couldn’t be used to produce meaningful "differences” – and the Open XML format adopted since version 2007 still isn’t very practical for differentiation purposes.
By contrast, a VSTO add-in like VSTO Stocks consists entirely of .NET code, which is ultimately a collection of text files – there is nothing attached to a specific Workbook. As a result, it is a perfect fit for Source Control, with automatic archival of successive versions, and highly detailed “audit” of changes between versions.
Note that nothing prevents using Source Control tools for “classic” Excel development – I do it all the time, even when working with Excel 2003 workbooks. You won’t get the full benefits of source control (no diffs), but you will still get a history of all the code changes in the project. Also, if you tend to re-use VBA utilities like UDFs, .bas files are perfect candidates for source control: store the utilities .bas files in a repository, and import them in workbooks when you need them.
## How to get started with Souce Control?
A nice thing about Source Control tools is that some of the best and most widely used systems are open source and totally free. The two systems I use are Subversion (for the past 7 years or so) and Mercurial since a few months – they are both great. The other name that comes up a lot is Git, which as far as I know is very similar to Mercurial.
The main difference is that Subversion has a centralized model (there is a central “source of truth” where the official code resides, and where all changes get committed), whereas Mercurial is a distributed system (developers can work with the full benefits of version control even disconnected from the “central”, and can merge their work with any other clone of the repository). Both are worth looking into, and offer different advantages. There are plenty of discussions comparing the two approaches, so I won’t go further into it.
On the other hand, regardless of what system you pick, I recommend installing Tortoise (TortoiseHg for Mercurial, TortoiseSVN for Subversion); it’s an extension which integrates source control with Windows, so that you can manage your repositories directly via the graphical user interface. It’s a great way to start without having to struggle with arcane command-line tools.
Tortoise integrates your Version Control system right into Windows.
#### Need help with F#?
The premier team for
F# training & consulting.
|
{}
|
# Kinetic Theory of Gases
## What is the Kinetic Theory of Gases?
Kinetic theory of gases is used as a framework for understanding gases and predicting their behavior. It links the microscopic behavior of gas molecules to the macroscopic properties of gases.
Kinetic theory of gases is based on following assumptions about gas molecules –
1. Gases consist of many molecules which are in constant and random motion in straight lines.
2. Molecules are rigid, elastic spheres and identical in all respect for a given gas and different for different gases.
3. The size of all the molecules is negligible as compared with the total volume of gas.
4. Inter molecular forces between gas molecules are negligible.
5. The average kinetic energy of all molecules does not change so long as the gas temperature is constant.
6. During the random motion molecules collide with one another and also with walls of container.
7. These collisions are instantaneous and perfectly elastic.
8. The average kinetic energy of all molecules is proportional to the absolute temperature of the gas.
These assumptions results that at any temperature gas molecules in equilibrium will have the same average kinetic energy (but not necessary that the molecules will have same velocity and mass).
### Expression for Pressure from Kinetic Theory of Gases
Consider that an ideal gas having mass ( M ) is enclosed in a cubical vessel as shown in figure. Let –
• Length of each side of cube is ( l ) .
• Therefore volume of cube will be \left ( V = l^3 \right ) .
• Let, ( n ) is the number of molecules per unit volume of gas.
• ( m ) is the mass of each molecule.
Consider that a molecule moving with velocity ( v ) hits a wall perpendicular to X axis of container. Before collision, the components of molecule velocity are –
( v_x, \ v_y, \ v_z )
Because the collisions are elastic, the molecule will rebound with the same velocity. The y-component and z-component of velocity will not change but the x-component of velocity will reverse its sign.
Therefore, velocity of the molecule after collision will be –
( - v_x, \ v_y, \ v_z )
Therefore, change in momentum of the molecule will be –
\Delta p = m v_x - ( - m v_x ) = 2 m v_x
Hence, by the the momentum imparted to the wall in each collision will be –
\Delta p = 2 m v_x
• The distance moved by a molecule between two successive collisions with this face is 2l .
• Then time interval between two collisions with this face will be \left ( \frac {2l}{v_x} \right ) .
• Therefore, number of collisions per unit time with this face will be \left ( \frac {v_x}{2l} \right )
Hence, change in momentum per unit time at this face –
\left ( \frac {\Delta p}{t} \right ) = 2m v_x \left ( \frac {v_x}{2l} \right )
= \left ( \frac {m v^2_x}{l} \right )
By change in per unit time is the
Therefore, force exerted on this face will be –
\text {Force} = \text {Change in momentum per unit time}
Therefore, \quad F_x = \frac {\Delta p}{t} = \left ( \frac {m {v_x}^2}{l} \right )
Let, ( n ) is the number of molecules per unit volume. Therefore, total number of molecules in cube will be –
N = \left ( n l^3 \right )
Let, \quad \left ( \bar {v_x}^2 \right ) is the average of the squares of the X-component velocities of all molecules.
Then, average force on this face will be –
\text {Average force} = \text {Number of molecules} \ \times \ \text {Momentum imparted by one molecule}
Or, \quad F_{total} = N \left ( \frac {m \bar {v_x}^2}{l} \right )
= N \left ( \frac {m}{l} \right ) \ \bar {v_x}^2
Assuming the gas is so the molecular velocities are equally distributed in all directions.
Therefore, by symmetry –
\bar {v_x}^2 = \bar {v_y}^2 = \bar {v_z}^2
= \left ( \frac {1}{3} \right ) \bar {v}^2
Where, ( \bar {v}^2 ) is the root mean square velocity of molecules.
Therefore, average pressure on this wall will be –
P = \frac {\text {Total force}}{\text {Area}}
= \left [ \frac {N \left ( \frac {m}{l} \right ) \ \bar {v_x}^2}{l^2} \right ] = N \left ( \frac {m}{l^3} \right ) \ \bar {v_x}^2
= N \left ( \frac {m}{V} \right ) \left ( \frac {1}{3} \right ) \bar {v}^2 = \left ( \frac {1}{3} \right ) m \left ( \frac {N}{V} \right ) \bar {v}^2
= \left ( \frac {1}{3} \right ) \ m \ n \ \bar {v}^2 ……… (1)
Also, \quad P = N \left ( \frac {m}{V} \right ) \left ( \frac {1}{3} \right ) \bar {v}^2
= \left ( \frac {Nm}{V} \right ) \left ( \frac {1}{3} \right ) \bar {v}^2
= \left ( \frac {M}{V} \right ) \left ( \frac {1}{3} \right ) \bar {v}^2
= \left ( \frac {1}{3} \right ) \rho \bar {v}^2 ………. (2)
Because, \quad Nm = M (Total mass of gas).
Also \quad \left ( \frac {M}{V} \right ) = \rho (Density of gas).
### Kinetic Energy from Kinetic Theory of Gases
According to kinetic theory of gases, the pressure exerted by a gas of density ( \rho ) and RMS velocity ( v ) is given by –
P = \left ( \frac {1}{3} \right ) \rho \ v^2
Average kinetic energy of translation per unit volume of gas will be –
E' = \left ( \frac {1}{2} \right ) \times \text {( Mass / Volume )} \times \text {( velocity )}^2 = \left ( \frac {1}{2} \right ) \rho \ v^2
Therefore, \quad \left ( \frac {P}{E'} \right ) = \left [ \frac {\left ( \frac {1}{3} \right ) \rho v^2 }{\left ( \frac {1}{2} \right ) \rho v^2 } \right ]
= \left ( \frac {2}{3} \right )
So, \quad P = \left ( \frac {2}{3} \right ) E'
Therefore, \quad \text {Pressure} = \left ( \frac {2}{3} \right ) \times \text {Average KE per unit volume} .
Hence, pressure exerted by a gas is equal to two-thirds of average kinetic energy of translation per unit volume of gas.
## Kinetic Interpretation of Temperature
Consider that, ( M ) is the molecular mass of gas and root mean square ( RMS ) velocity of molecules is ( v ) .
Then, average kinetic energy of translation per mole of gas will be –
E = \left ( \frac {1}{2} \right ) M v^2
From kinetic theory of gases, the pressure exerted by a gas of density ( \rho ) is –
P = \left ( \frac {1}{3} \right ) \rho \ v^2
= \left ( \frac {1}{3} \right ) \left ( \frac {M}{V} \right ) v^2
So, \quad P V = \left ( \frac {1}{3} \right ) M \ v^2
= \left ( \frac {2}{3} \right ) \times \left ( \frac {1}{2} \ M \ v^2 \right )
= \left ( \frac {2}{3} \right ) E
Also for one mole of a gas we know –
P V = R T
So, \quad \left ( \frac {2}{3} \right ) E = R T
Or, \quad E = \left ( \frac {3}{2} \right ) RT
If, ( N ) is the Avogadro’s number,
Then kinetic energy per molecule \quad \bar {E} = \left ( \frac {E}{N} \right )
= \left [ \frac { \left ( \frac {3}{2} \right ) RT }{ N } \right ]
= \left ( \frac {3}{2} \right ) \left ( \frac {R}{N} \right ) T
= \left ( \frac {3}{2} \right ) k_B \ T , where ( k_B ) is the Boltzmann’s constant.
Therefore, \quad \bar {E} \propto T
Also, \quad \bar {E} = \left ( \frac {3}{2} \right ) k_B \ T
Hence, mean kinetic energy per molecule of a gas is proportional to the absolute temperature of the gas. It is independent of the pressure, volume and nature of the ideal gas.
|
{}
|
MathSciNet bibliographic data MR2514218 (2010d:65325) 65N30 (35B45 35J25 65N15) Kinoshita, T.; Hashimoto, K.; Nakao, M. T. On the \$L\sp 2\$$L\sp 2$ a priori error estimates to the finite element solution of elliptic problems with singular adjoint operator. Numer. Funct. Anal. Optim. 30 (2009), no. 3-4, 289–305. Article
For users without a MathSciNet license , Relay Station allows linking from MR numbers in online mathematical literature directly to electronic journals and original articles. Subscribers receive the added value of full MathSciNet reviews.
Username/Password Subscribers access MathSciNet here
AMS Home Page
American Mathematical Society 201 Charles Street Providence, RI 02904-6248 USA
© Copyright 2014, American Mathematical Society
Privacy Statement
|
{}
|
# Updating a design to modern concepts …
So in order to (really) bring my monitoring app into the modern age, I want to change its flow from a synchronous on-demand event driven analysis and reporting tool, to an asynchronous monitoring and analysis tool, with an on-demand “report” function which is basically a presentation core atop the data set.
There are many reasons for this. Not the least of which is that this should be far more efficient at handling what I want to do … not to mention more responsive. I also don’t really want to do this as many independent processes … past history with debugging many independent but functionally interdependent processes.
What we are fundamentally doing is parsing logs. Right now, its apache logs, but a well designed system should be able to parse any logs, with the addition of a basic parser code (no, not a grammar … but something nice and simple).
So what if we wanted to run the parser when the log gets updated? Ok, I know … there are some codes that are smart enough to trigger an event upon an action. Assume for the moment that we are dealing with something where this isn’t true.
Let me go far afield from Apache. And look at Gluster. Its logs are (at best) a horrible … horrible mess. Extracting anything useful from them is very hard. And unfortunately, with many more people depending upon it, we have to parse the output, and at generate some sort of signal when dejecta impacts the rotating air movement system.
But the same is true of other servers as well. The issue is that there really is no good standard for this right now. Something with one of the message queues and a nice standard format? Would be nice. Until then, we have to ()*&*(&^%&% parse ()*&*&^%$%$%\$ logs.
Apache is my stand in for a good test case.
So, rather than wait for an external query event to look at stuff, why not set up a nice asynchonous inotify based log reader? Maintain local state only during program execution. Read till the end of the file on startup, calculate the offset, turn on an inotify listener, and only scan the changes from the offset to the end of the file on the write event … updating the internal offset, and doing whatever needful thing we need to do after parsing the data?
Yeah, its more complex. But it gives us far more power.
First step in this process is getting Mojolicious to run in a thread environment. The web side of this is “easy”. Not quite a SMOP. But we have this part working. So if we can run it in a thread, yeah, we are moving in the right direction.
Second step is getting the inotify listener running in the same thread environment. We already use this code for another product (in our Tiburon system), so I am hoping it works as well here.
After that is a little glue logic, and thinking up more efficient data storage (don’t need to keep all this data in RAM, and I want to efficiently/quickly serialize/deserialize it. I smell some CSV “files” living in /dev/shm/ … we do that in our manometer.pl code now. And that’s where we lifted our thread design.
So right now, I am assembling the pieces, and seeing what I can do with them. All of this in a nice multi-threaded perl code. With integrated web servers, and all manner of other nice features.
### 2 thoughts on “Updating a design to modern concepts …”
1. Hi Joe,
I’ve never parsed the gluster logs, but have parsed logs for various other software that have been problematic. Do you have any example of logs that are done well?
Mark
2. Beware of log rotation, particularly rotation of nearly empty logs. The new log may be larger than the old one, so just checking size isn’t enough. A hash of the log’s first N bytes may suffice for some N long enough to capture a date/time.
Comments are closed.
|
{}
|
# Collision Response Problem
## Recommended Posts
Hi Iam working on a Swept Sphere <-> Triangle collision detection/response. The detection part appears to be working well. I pass the Sphere center and the desired movement vector - what I get back is a float ( called t ) telling how much of the movement could be executed without collision in the given direction ( 1.0 for full movement ). Now in order to stay numerically stable, I dont want to move the Sphere ON the surface, but a little in front of the surface. My code to do so is simply as follows:
float mag=Magnitude(info.vVel);
// the min makes sure we are never pushed farther away than where we came from
CVec3 pushback=Normalize(-info.vVel)*min(EPSILON,mag); // 0.085f for me
CVec3 newPos=info.vStart+info.t*info.vVel+pushback;
Tough this kinda seems to work, Iam not entirely happy with the way this is solved, since the amount we are kept away from the collision point depends on the velocity vector. Thus if the velocity vector is chosen accordingly, its still possible to approach further than EPSILON to the collision point, which is not a nice thing. I tried playing around with the EPSILON but I found it quite impossible to find a value that works well for everything: Too large values cause a jittering ( Sphere moves into the tri, gets pushed back, to a distance of EPSILON, then it moves again ( a distance smaller than EPSILON ), and it doesnt get pushed back because no collision is detected, then it moves into the tri again -> pushback -> jittering ), smaller values lead to a problem where the sphere gets occasionally stuck inside the tri, and this problem is still there with large values ( just less frequently ). I tried to derive a formula to compute how much velocity I have to take back in order to get a distance of EPSILON to the collision point, but that didnt really help ( Iam not sure why because its kinda impossible to debug it, but obviously theres too many cases where the camera makes a move smaller than EPSILON towards the surface ) So whats the correct way to keep some safety distance towards the surface? Maybe my timesteps are too small or something? And that leads to the problem of getting stuck sometimes? ( It really occurs only very seldom... I have to try for a few minutes before I got it stuck...but thats still not acceptable ) Thanks alot
##### Share on other sites
Quote:
Original post by DtagHiIam working on a Swept Sphere <-> Triangle collision detection/response. The detection part appears to be working well. I pass the Sphere center and the desired movement vector - what I get back is a float ( called t ) telling how much of the movement could be executed without collision in the given direction ( 1.0 for full movement ). Now in order to stay numerically stable, I dont want to move the Sphere ON the surface, but a little in front of the surface. My code to do so is simply as follows:*** Source Snippet Removed ***Tough this kinda seems to work, Iam not entirely happy with the way this is solved, since the amount we are kept away from the collision point depends on the velocity vector. Thus if the velocity vector is chosen accordingly, its still possible to approach further than EPSILON to the collision point, which is not a nice thing. I tried playing around with the EPSILON but I found it quite impossible to find a value that works well for everything: Too large values cause a jittering ( Sphere moves into the tri, gets pushed back, to a distance of EPSILON, then it moves again ( a distance smaller than EPSILON ), and it doesnt get pushed back because no collision is detected, then it moves into the tri again -> pushback -> jittering ), smaller values lead to a problem where the sphere gets occasionally stuck inside the tri, and this problem is still there with large values ( just less frequently ). I tried to derive a formula to compute how much velocity I have to take back in order to get a distance of EPSILON to the collision point, but that didnt really help ( Iam not sure why because its kinda impossible to debug it, but obviously theres too many cases where the camera makes a move smaller than EPSILON towards the surface )So whats the correct way to keep some safety distance towards the surface?Maybe my timesteps are too small or something? And that leads to the problem of getting stuck sometimes? ( It really occurs only very seldom... I have to try for a few minutes before I got it stuck...but thats still not acceptable )Thanks alot
I don't have a nice clean answer for you, but I will say that I've implemented swept sphere vs. poly soup coldet, and after much tweaking was able to get results I was happy with (that is, no shaking, jittering, getting stuck, or falling through, even under extreme conditions).
There were a number of things that went into this, but what might be most relevant to your question is that I gave up on any assumptions about whether the sphere would be intersecting geometry at the end of the time step, or how close it would be. Like you I did have an epsilon 'buffer', but even then it's hard to guarantee a particular post-condition. To deal with this, I performed both a swept test and a static intersection test; the static test caught any anomalous post-conditions and put the sphere back in a non-intersecting state. Even then there are weird cases that can occur; in these (rare) cases you can just bail back to the initial position, which presumably is known to be non-intersecting.
##### Share on other sites
Hi,
Very interesting, I just dealt with this problem on my 2D physics engine. I have one phase for moving and positioning objects, and then a static movement phase for checking to see which objects are within *epsilon* of other objects. If an object is close to another object, it gets a contact. A contact stores a pointer to the other object, a pointer to the part of each objects' geometry that is touching, and a normal of collision. With the normal of collision, it is very easy to verify that an object is specifying an invalid movement. Also, sliding can be done easily.
When you do your collisions, are all actors moving dynamically, or are you moving and checking collisons one object at a time?
-Tim Kerchmar
##### Share on other sites
Hey
I just tried what jyk suggested. It fixed all problems where the sphere was getting INTO the world somewhere, but instead, the sphere just stopped at that point because the sphere couldnt be moved further back.
My implementation is like this:
If a full movement could be done:
Loop:
See if the sphere is intersecting with any geometry. If so push it back a little along the velocity vector ( but not farther then the length of the velocity vector ). Loop until its not intersecting anymore;
If no full movement could be done. Initially perform a small pushback. Then the same loop as above.
The cases where it got stuck were always cases where the sphere could not be pushed back far enough to get enough distance to be not colliding. Tough in all cases where the sphere was pushed back, the movement felt a little weird.
Just to test a little, I also implemented a small stepping algorithm ( First move up by STEPSIZE, then move velocity-STEPSIZE, and finally apply gravity. ) This turned out to fix nearly all of the problems! Iam not sure why it helped so much.
Iam also not sure whether this is a clean solution, any ideas on that?
As for pTymN:
"With the normal of collision, it is very easy to verify that an object is specifying an invalid movement."
Its not only my problem to DETECT invalid movement, but also how to react properly. If its "too late" to push the sphere back, what should I do?
"When you do your collisions, are all actors moving dynamically, or are you moving and checking collisons one object at a time?""
Iam having a sphere ( represented by the camera for testing purposes right now ) and Iam testing that against terrain. I havent implemented dynamic objects<->dynamic objects yet. My plan was to do the tests against the terrain with an ellipsoid, and the tests of objects against each other using AABB<->AABBs. Havent put any more thinking into that yet tough ;)
##### Share on other sites
It sounds like you are using static-dynamic, which is a better solution than just moving the object incrementally and seeing if that position intersects geometry. Since you are "gauranteed" that the sphere does not start out intersecting the terrain, can't you just do this:
CVec3 newPos=info.vStart+info.t*info.vVel*0.9;
It seems that your epsilon can get too small for larger numbers, especially since you are using float not double. This line of code would automatically adjust the pushback with the magnitude of the movement.
Beware that it can be confusing to tell between a collision that happens at 1.0 and one that never happened. There is certainly no reason to only move 90% of the distance when there has been no collision.
##### Share on other sites
Quote:
Original post by pTymNSince you are "gauranteed" that the sphere does not start out intersecting the terrain, can't you just do this:CVec3 newPos=info.vStart+info.t*info.vVel*0.9;
As states above, I have played around alot with the epsilon. Using a too low epsilon like you suggested results in jittering problems.
##### Share on other sites
Yeah, but your epsilon doesn't scale the amount of velocity added to the starting point. Your epsilon subtracts a constant amount from the velocity. I had good luck with scaling the velocity in my engine.
##### Share on other sites
Hmmm what should that be good for? Why should the algorithm need more safetey distance for a fast moving object than for a small moving object?
##### Share on other sites
Could you give it a try? I can't really explain why it works, but I experienced less problems with my physics engine when I switched methods.
##### Share on other sites
I just tried what you suggested, its pretty much the same effect as a medium epsilon ( As expected ). Tough since this does not have any advantage, why decrease the velocity procentually?
##### Share on other sites
Looks like (maybe?) you already got it sorted, but I thought I'd mention that in my static intersection resolution step, I resolve the intersection along the direction of the penetration vector, not by moving the object back along the velocity vector. Although you still need the swept test for objects that move fast enough to tunnel, this method of resolving static intersection actually produces natural sliding collision response all by itself. Anyway, the point is that a properly implemented static resolution step shouldn't cause your object to get stuck or move unnaturally.
##### Share on other sites
I was tackling with similar problem recently. Below is the code I used for the collision handling part. Note, I used verlet integration for the movement (hence the m_pos, and m_oldpos)
int iter = 15; Vec3 prev(m_oldpos); Vec3 pos(m_pos); while(iter) { Vec3 delta(pos - prev); float len = delta.Length(); // Stop if moving just a little bit. if(len < 0.0001f) break; // Check fo collisions, if no hits allow full movement. if(!phys->CollideSweptSphere(prev, delta, m_rad, hitRes)) break; // Check if the initial state is colliding. if(hitRes.t < 0.00001f) { Vec3 d = hitRes.pos - prev // Convert to ellipse space. // Could report this back from the CollideSweptSphere too. d.x /= m_rad.x; d.y /= m_rad.y; d.z /= m_rad.z; d.Normalize(); d *= 1.01f; d.x *= m_rad.x; d.y *= m_rad.y; d.z *= m_rad.z; prev = hitRes.pos - d; continue; } Vec3 coll = prev + delta * hitRes.t + hitRes.norm * 0.0001f; Vec3 D = pos - coll; Vec3 Dn = (D.Dot(hitRes.norm)) * hitRes.norm; Vec3 Dt = D - Dn; static float friction = 0.01f; static float restitution = 0.5f; pos = coll + (Dn * -restitution + Dt * (1.0f - friction)); prev = coll; --iter; } // Update the position. m_pos = pos;
The hit result structure contains the time of collision, the normal of the collision and point on surface of the collision.
I also do "backface culling in the collision test code", that is only report the collision if moving towards the polygon. Unless I did that the ellipsoid got stuck once it was initially intersecting with the geometry (t always almost zero).
I believed long and hard that it would be possible that the last position is always safe. But for some reason the ellipsoid just sometimes slipped inside geometry. There is obvious flaw in the above code in the check if the ellipsoid is moving just a little bit, which basically allows the penetration to happen. But I think the almost parallel movement is root of the cause. The floating point accuracy just is not enough.
Later I moved to use more simpler method. Just move the object, check for collisions and push away. The verlet integration takes care of details of sliding along a surface. That works much better in my case since I also wanted to collide with capsules and objects composited from multiple primitives too. And it was so simple to implement too :)
##### Share on other sites
Assuming that 'hitRes.pos' in memons code refers to the actual collision point where the sphere intersected with the tri, you both appear to be pushing back along the sliding plane normal. I just tried it and it indeed _appears_ to work well ;)... What Iam asking myself is: Not moving on the velocity vector means "unchecked movement" meaning that the amount pushed away from from the plane is never checked for intersections with other tris. So having moving into a sharp corner could make one of the planes push the sphere through the other tri... couldnt it? I tried to reproduce the case, and it was indeed the case that in these corner situations my equivalent of memons code piece
// Check if the initial state is colliding.
if(hitRes.t < 0.00001f)
{
...
Catched these cases and brought the sphere back into the world, resulting in a slight jitter of the camera in these cases ( not a really bad one tough ). All in all Iam not sure whether this is going to work in ALL cases?
jyk: It worked alot better with the stepping, but thats obviously a hack because not all physical objects should have stepping :/
##### Share on other sites
One more comment: the static resolution step should be recursive as well, that is, if an intersection is detected you should resolve it and then run the test again. This should handle most cases like the one you describe, where resolving one intersection causes another.
There are cases where the object can get stuck between two surfaces, and be 'bounced' back and forth. I'm not sure what the best way to handle these cases is, but in my implementation I just bailed back to the start position after a certain number of iterations (this didn't happen often, and given the proper restrictions on geometry or object size, you should be able to avoid it entirely).
##### Share on other sites
Ok thanks everyone ;) After a bit more tweaking it appears to work perfectly now. Didnt have a getting stuck or anything after 20 min of intensive trying to break it, so Im considering that part as working ;)
Just one more thing: Does anyone know any resources in whats the best way to make it look physically more correct? I added gravity etc, ( with euler integration which appears to be enough for this ), and some basic factors to fade out velocity due to friction etc, but it looks somewhat unrealistic when things are falling ( either theyre too slow or too fast :/ ).
Additionally I didnt find a clean way to make the sphere not slide off hills due to gravity ( my way was to prevent sliding of flat tris when the movement is gravitational and, but it didnt seem like a physically correct idea ;) )
## Create an account
Register a new account
• ## Partner Spotlight
• ### Forum Statistics
• Total Topics
627662
• Total Posts
2978508
• 10
• 10
• 12
• 22
• 13
|
{}
|
# Difference between a space and a “wave” symbol (tilde/“~”)?
As title, what is the difference between a and ~?
I see no differences after the compilation.
MWE:
\documentclass[a4paper]{article}
\usepackage[english]{babel}
\usepackage[utf8]{inputenc}
\usepackage{amsmath}
\usepackage{graphicx}
\usepackage[colorinlistoftodos]{todonotes}
\author{You}
\date{\today}
\begin{document}
\maketitle
I am cool.
I~am~cool.
\end{document}
-
You will see the difference at end of line. ~ is unbreakable space where as space isn't unbreakable. – Harish Kumar Mar 28 '14 at 1:54
"I am cool"... That's a rather bold statement :p – Jubobs Mar 28 '14 at 2:23
It controls space too, it's very often used after a \the.... counter output command. – Christian Hupfer Jan 13 '15 at 21:27
In text mode ~=\nobreakspace – karlkoeller Jan 13 '15 at 21:29
@yo' Should I delete this questions, then? – hkviktor Jan 13 '15 at 21:31
The difference can be seen at the end of line. A space is breakable and a ~ is an un-breakable space.
\documentclass[a4paper]{article}
\usepackage[english]{babel}
\usepackage[utf8]{inputenc}
\usepackage{amsmath}
\usepackage{graphicx}
\usepackage[colorinlistoftodos]{todonotes}
\author{You}
\date{\today}
\begin{document}
\maketitle
\hspace*{0.9\textwidth}I am cool.
\hspace*{0.9\textwidth}I~am~cool.
\end{document}
The three words I am and cool are glued together in the second line.
-
The ~ is an active character, which means it's the same as a macro like \mbox and so on. Its function is described by its definition, which is
\nobreakspace{}
so typing ~ is equivalent to typing \nobreakspace{}.
What does \nobreakspace do? Here it is:
\leavevmode\nobreak\
(a space follows the last backslash). So a paragraph is started or nothing is done if we're already in a paragraph (\leavevmode); then \nobreak is issued, which disallows any line break at the point (\nobreak) and then a normal interword space is inserted.
Thus when typing
no~break
there will be a space between the two words, but the line will not be broken after no.
Why the {} after \nobreakspace? If you have no~break in a caption, in the .aux file the expanded version will appear
no\nobreakspace {}break
The braces have been introduced to cope with the rare case when a space after ~ is wanted; without them no~ break would write
no\nobreakspace break
and, upon reading the .aux file, the space would be ignored. With the braces
no\nobreakspace {} break
will be written and the additional space would not be ignored.
What happens if one types no~ break in the output? Two spaces are added but no line break at them is possible, because a space is a feasible line break point only if it is not preceded by a discardable item; since \nobreakspace becomes
\leavevmode\penalty 10000 \
and penalties are discardable like spaces, neither \ nor the following space can be used for a line break.
In the reverse case no ~break two spaces are output, but now a break point is possible at the first space (and both will disappear together with the penalty in case it is taken).
-
Nice explanation. Can I say +1? – karlkoeller Jan 13 '15 at 21:40
You speak about the no~ break but not about no ~break. In particuler this case may appear when using a char limitation per line with a line return intead of the space. What happen in this case? – Romain Picot Oct 22 '15 at 12:40
@RomainPicot Almost the same, you get two spaces if no break happens, but a break is possible (which is not with no~ break) – egreg Oct 22 '15 at 12:48
@egreg thank you for the precision ;-) – Romain Picot Oct 22 '15 at 12:50
@RomainPicot I added a final note, thanks for the prompt. – egreg Oct 22 '15 at 12:55
This is the definition of ~ in latex.ltx
\catcode \~=13
\def~{\nobreakspace{}}
while \nobreakspace is defined as
\DeclareRobustCommand{\nobreakspace}{%
\leavevmode\nobreak\ }
So, the active character ~` is equivalent to a space that cannot be broken into lines.
-
|
{}
|
, 24.01.2020thawkins79
# 1. find cot θ if csc θ = square root of five divided by two and tan θ > 0. (6 points) a) square root of five b) 2 c) square root of five divided by five d) one half 2. find cos θ if sin θ = negative twelve divided by thirteen and tan θ > 0. (6 points) a) negative five divided by twelve b) negative five divided by thirteen c) twelve divided by five d) negative thirteen divided by twelve 3. use basic identities to simplify the expression. (6 points) tangent of theta divided by secant of theta. a) cos3θ b) tan2θ c) sec2θ d) sin θ 4. simplify the expression. (6 points) sine of x to the second power minus one divided by cosine of negative x a) -sin x b) cos x c) sin x d) -cos x 5. find all solutions in the interval [0, 2π). (6 points) sin2x + sin x = 0 a) x = 0, π, four pi divided by three , five pi divided by three b) x = 0, π, pi divided by three , two pi divided by three c) x = 0, π, pi divided by three , five pi divided by three d) x = 0, π, three pi divided by two 6. find all solutions to the equation. cos x = sin x (6 points) a) pi divided by four plus n pi such that n equals zero, plus or minus one, plus or minus two to infinity b) pi divided by four plus two n pi comma seven pi divided by four plus two n pi such that n equals zero, plus or minus one, plus or minus two to infinity c) pi divided by two plus n pi such that n equals zero, plus or minus one, plus or minus two to infinity d) three pi divided by four plus two n pi comma five pi divided by four plus two n pi such that n equals zero, plus or minus one, plus or minus two to infinity 7. find an exact value. sin 105° (6 points) a) quantity square root of six plus square root of two divided by four b) quantity negative square root of six plus square root of two divided by four c) quantity square root of six minus square root of two divided by four d) quantity negative square root of six minus square root of two divided by four 8. find an exact value. (6 points) tangent of seven pi divided by twelve a) quantity two minus square root of three divided by four b) -2 - square root of three c) quantity two plus square root of three divided by four d) 2 + square root of three 9. write the expression as the sine, cosine, or tangent of an angle. (6 points) sin 57° cos 13° - cos 57° sin 13° a) cos 70° b) cos 44° c) sin 44° d) sin 70° 10. write the expression as the sine, cosine, or tangent of an angle. (6 points) cos 94° cos 37° + sin 94° sin 37° a) sin 131° b) sin 57° c) cos 131° d) cos 57° 11. write the expression as the sine, cosine, or tangent of an angle. (6 points) sin 5x cos x - cos 5x sin x a) cos 6x b) cos 4x c) sin 6x d) sin 4x 12. rewrite with only sin x and cos x. (6 points) sin 2x - cos 2x a) 2 sin2x - 2 sin x cos x + 1 b) 2 sin x c) 2 sin2x + 2 sin x cos x - 1 d) 2 sin2x - 2 sin x cos x - 1 13. find the exact value by using a half-angle identity. (6 points) cosine of pi divided by twelve a) one half times the square root of quantity one plus square root of three b) one half times the square root of quantity one minus square root of three c) one half times the square root of quantity two plus square root of three d) one half times the square root of quantity two minus square root of three 14. verify the identity. (7 points) 4 csc 2x = 2 csc2x tan x 15. verify the identity. (8 points) cotangent of x divided by quantity one plus cosecant of x equals quantity cosecant of x minus one divided by cotangent of x 16. verify the identity. (7 points) sin quantity x plus pi divided by two = cos x i would really appreciate priority for this! you!
Step-by-step explanation:
See figure 1 attached
Radius of circle equal 1. This radius is at the same time the hypotenuse of triangle OMP . You can see:
sin∠POM = opposite leg/hypotenuse given that hypotenuse is 1
sin∠POM = opposite leg = PM Note PM never change sign when
rotating from 0 up to π/2 (quadrant one). Its value will be
0 ≤ sin∠POM ≤ 1
cos∠POM = adjacent leg/hypotenuse /hypotenuse given that hypotenuse is 1 then for the same reason
cos∠POM = adjacent leg = OM
OM never change sign in the first quadrant, and can tak vals beteen 1 for 0° up to 1 for π/2
Tan∠POM = sin∠POM /cos∠POM
The last relation is always positive (in the first quadrant) and
STEP 3
Step-by-step explanation:
Francesca drew point (–2, –10) on the terminal ray of angle , which is in standard position. She found values for the six trigonometric functions using the steps below.
Step 1
A unit circle is shown. A ray intersects point (negative 2, negative 10) in quadrant 3. Theta is the angle formed by the ray and the x-axis in quadrant 1.
Step 2
Step 3
Francesca made her first error in step 3 because the sine, cosine, and tangent ratios are incorrect, which also resulted in incorrect cosecant, secant, and tangent functions.
The correct values are:
Section 1.
sin∠X =5/13
cos∠X =12/13
tan∠X = 5/12
Step-by-step explanation:
The sine of an angle is defined as; Opposite side/the Hypotenuse. From the right angle triangle given; the opposite side of angle X is 5 while the hypotenuse is 13.
The cosine of an angle is defined as; Adjacent side/Hypotenuse. From the right angle triangle given; the adjacent side of angle X is 12.
The tangent of an angle is defined as; Opposite side/Adjacent side.
Section 2
sin∠Y = 12/13
cos∠Y = 5/13
tan∠Y = 12/5
Step-by-step explanation:
The sine of an angle is defined as; Opposite side/the Hypotenuse. From the right angle triangle given; the opposite side of angle Y is 12 while the hypotenuse is 13.
The cosine of an angle is defined as; Adjacent side/Hypotenuse. From the right angle triangle given; the adjacent side of angle Y is 5.
The tangent of an angle is defined as; Opposite side/Adjacent side.
Section 3
The sin∠X and the cos∠Y are equal, their value is 5/13.
Step-by-step explanation:
The sine of angle is always equal to the cosine of its complement. Complement angles add up to 90 degrees. In this case, ∠X+∠Y =90 hence ∠X is a complement of ∠Y.
Section 4
The tangents of ∠X and ∠Y are reciprocals of each other. That is;
tan∠X = 5/12 and tan∠Y = 12/5. Clearly; tan∠Y = 1/tan∠X .
Step-by-step explanation:
The tangent of an angle will always be equal to the reciprocal of the tangent of its complement. In this case, ∠X+∠Y =90 hence ∠X is a complement of ∠Y.
Option C is correct.
Step-by-step explanation:
We need to find reference angle and signs of sinФ, cosФ and tanФ
We know that is equal to 150°
and 150° is in 2nd quadrant.
So, Ф is in 2nd quadrant.
And In 2nd quadrant sine is positive, while cos and tan are negative
The reference angle Ф' is found by: π - Ф
=> Ф = 5π/6
so, Reference angle Ф' = π - 5π/6
Ф' = 6π - 5π/6
Ф' = π/6
So, Option C Θ' = pi over 6; sine is positive, cosine and tangent are negative is correct.
D.She made her first error in step 3 because the sine, cosine, and tangent ratios are incorrect, which also results in incorrect cosecant, secant, and tangent functions.
Step-by-step explanation:
on e 2020
A) sine: positive cosine: positive tangent: positive
Step-by-step explanation:
Consider the first quadrant in the coordinate diagram below:
x and y are positive
For positive x and y, is also positive. Therefore:
is positive
is positive
is positive
6.d.Quantity square root of six plus square root of two divided by four.
7.:Quantity negative square root 2 minus square root three divided by two.
8.C.Sin 8x
9.d.
10.b.
Step-by-step explanation:
6.=Sin(45+30)
Sin(A+B)=Sin A Cos B+Sin B Cos A
Using identity
Sin(45+30)= Sin 45 Cos 30+ Cos 45 Sin 30=
d.Quantity square root of six plus square root of two divided by four.
7.
=
Answer :Quantity negative square root 2 minus square root three divided by two.
8.
Using this identity
Then we get
C.Sin 8x
9
Using this identity then we get
d.
10. sin 2x -cos 2x
Using above identities
Therefore,
b.
The reference angle, θ' = π/6.
sin(5π/6) is positive, cosine & tangent are both negative
1.sin x = \frac{5}{13}
cos x = \frac{12}{13}
tan x = \frac{5}{12}
sin y = \frac{12}{13}
cos y = \frac{5}{13}
tan y = \frac{12}{5}
2. ditance travelled = hypotenuse = \frac{200}{sin 40} = 311.14yards
Step-by-step explanation:
sin x =
cos x =
tan x =
therefore from the figure sin x = \frac{5}{13}
cos x = \frac{12}{13}
tan x = \frac{5}{12}
according to angle y height will be 12 and base will be 5
therefore sin y = \frac{12}{13}
cos y = \frac{5}{13}
tan y = \frac{12}{5}
2. given that height = 200 yards and angle x= 40
we know that tan x = \frac{height}{base}
therefore tan 40 = \frac{200}{base}
therefore base = \frac{200}{tan 40}
they have asked us to find hypotenuse therefore
sin x = \frac{height}{hypotenuse}
hypotenuse = \frac{200}{sin 40} = 311.14yards
6 Find an exact value.
sin 75°
sin(A+B)=sin(A)cos(B)+cos(A)sin(B)
sin(45)=cos(45)=(2^0.5)/2 sin(30)=0.5 cos(30)=(3^0.5)/2
sin(45+30)=sin(45)cos(30)+cos(45)sin(30)=(6^0.5+2^0.5)/4
the answer is the letter d) quantity square root of six plus square root of two divided by four.
7. Find an exact value.
sine of negative eleven pi divided by twelve.
sin(-11pi/12) = -sin(11pi/12) = -sin(pi - pi/12) = -sin(pi/12) = -sin( (pi/6) / 2)
= - sqrt( (1-cos(pi/6) ) / 2) = -sqrt( (1-√3/2) / 2 ) = -(√3-1) / 2√2=(√2-√6)/4
the answer is the letter c) quantity square root of two minus square root of six divided by four.
8. Write the expression as the sine, cosine, or tangent of an angle.
sin 9x cos x - cos 9x sin x
sin(A−B)=sinAcosB−cosAsinB
sin(9x−x)= sin9xcosx−cos9xsinx= sin(8x)
the answer is the letter c) sin 8x
9. Write the expression as the sine, cosine, or tangent of an angle.
cos 112° cos 45° + sin 112° sin 45°
cos(A−B)=cosAcosB+sinAsinB
cos(112−45)=cos112cos45+sin112sin45=cos(67)
the answer is the letter d) cos 67°
10. Rewrite with only sin x and cos x.
sin 2x - cos 2x
sin2x = 2sinxcosx
cos2x = (cosx)^2 - (sinx)^2 = 2(cosx)^2 -1 = 1- 2(sinx)^2
sin2x- cos2x=2sinxcosx-(1- 2(sinx)^2=2sinxcosx-1+2(sinx)^2
sin2x- cos2x=2sinxcosx-1+2(sinx)^2
the answer is the letter b) 2 sin x cos2x - 1 + 2 sin2x
### Other questions on the subject: Mathematics
Mathematics, 21.06.2019, tgentryb60
Mathematics, 21.06.2019, jtorres0520
63°Step-by-step explanation:Complementary angles sum to 90°let the smaller angle be x then the larger angle = x + 36, the sum is thenx + x + 36 = 902x + 36 = 90 ( subtract 36 from...Read More
Mathematics, 21.06.2019, 19thomasar
These are the multiples of 15 but what you are probably asking or what are the factors of 15...Read More
|
{}
|
[OS X TeX] markup changes/revisions
Peter Dyballa Peter_Dyballa at Web.DE
Wed Mar 1 06:49:41 EST 2006
Am 01.03.2006 um 12:07 schrieb Rechtsanwalt Friedrich Vosberg:
> I just want to run a markup processor in TeXShop.
Parts of what you want could be done with GNU Emacs and file hooks.
Here are two answers from the TeX FAQ (http://www.tex.ac.uk/cgi-bin/
texfaq2html):
*Marking changed parts of your document*
One often needs clear indications of how a document has changed, but
the commonest technique, "change bars" (also known as "revision
bars"), requires surprisingly much trickery of the programmer (the
problem being that TeX 'proper' doesn't provide the programmer with
any information about the "current position" from which a putative
start- or end-point of a bar might be calculated; PDFTeX does provide
the information, but we're not aware yet of any programmer taking
advantage of the fact to write a PDFTeX-based changebar package).
The simplest package that offers change bars is Peter Schmitt's
backgrnd.tex; this was written as a Plain TeX application that
patches the output routine, but it appears to work at least on simple
LaTeX documents. Wise LaTeX users will be alerted by the information
that backgrnd patches their output routine, and will watch its
behaviour very carefully (patching the LaTeX output routine is not
something to undertake lightly...).
The longest-established solution is the changebar package, which
uses \special commands supplied by the driver you're using. You need
therefore to tell the package which driver to generate \specials for
(in the same way that you need to tell the graphics package); the
list of available drivers is pretty restricted, but does include
dvips. The package comes with a shell script chbar.sh (for use on
UNIX machines) that will compare two documents and generate a third
which is marked-up with changebar macros to highlight changes. The
(excellent) shareware WinEDT editor has a macro that will generate
changebar (or other) macros to show differences from an earlier
version of your file, stored in an RCS-controlled repository - see
http://www.winedt.org/Macros/LaTeX/RCSdiff.php
The vertbars package uses the techniques of the lineno package (which
must be present); it's thus the smallest of the packages for change
bar marking, since it leaves all the trickery to another package. The
framed package is another that provides bars as a side-effect of
other desirable functionality: its leftbar environment is simply a
stripped-down frame (note, though, that the environment makes a
separate paragraph of its contents, so it is best used when the
convention is to mark a whole changed paragraph.
Finally, the memoir class allows marginal editorial comments, which
you can obviously use to delimit areas of changed text.
Another way to keep track of changes is employed by some word-
processors - to produce a document that embodies both "old" and "new"
versions. The Perl script latexdiff does this for LaTeX documents;
you feed it the two documents, and it produces a new LaTeX document
in which the changes are very visible. An example of the output is
embedded in the documentation, latexdiff-man.pdf (part of the
distribution). A rudimentary revision facility is provided by another
Perl script, latexrevise, which accepts or rejects all changes.
Manual editing of the difference file can be used to accept or reject
selected changes only.
backgrnd.tex
macros/generic/misc/backgrnd.tex
changebar.sty
macros/latex/contrib/changebar (gzipped tar, browse)
framed.sty
macros/latex/contrib/misc/framed.sty
latexdiff, latexrevise
support/latexdiff (gzipped tar, browse)
lineno.sty
macros/latex/contrib/lineno (gzipped tar, browse)
memoir.cls
macros/latex/contrib/memoir (gzipped tar, browse)
vertbars.sty
macros/latex/contrib/misc/vertbars.sty
While LaTeX (or any other TeX-derived package) isn't really like a
compiler, people regularly want to do compiler-like things using it.
Common requirements are conditional 'compilation' and 'block
comments', and several LaTeX-specific means to this end are available.
The simple \newcommand{\gobble}[1]{} and \iffalse ... \fi aren't
really satisfactory (as a general solution) for comments, since the
matter being skipped is nevertheless scanned by TeX, not always as
you would expect. The scanning imposes restrictions on what you're
allowed to skip; this may not be a problem in today's job, but could
return to bite you tomorrow. For an example of surprises that may
come to bite you, consider the following example (derived from real
user experience):
\iffalse % ignoring this bit
consider what happens if we
use \verb|\iftrue| -- a surprise
\fi
The \iftrue is spotted by TeX as it scans, ignoring the \verb
command; so the \iffalse isn't terminated by the following \fi. Also,
\gobble is pretty inefficient at consuming anything non-trivial,
since all the matter to be skipped is copied to the argument stack
before being ignored.
If your requirement is for a document from which whole chapters (or
the like) are missing, consider the LaTeX \include/\includeonly
system. If you '\include' your files (rather than \input them - see
What's going on in my \include commands?), LaTeX writes macro traces
of what's going on at the end of each chapter to the .aux file; by
using \includeonly, you can give LaTeX an exhaustive list of the
files that are needed. Files that don't get \included are skipped
entirely, but the document processing continues as if they were
there, and page, footnote, and other numbers are not disturbed. Note
that you can choose which sections you want included interactively,
The inverse can be done using the excludeonly package: this allows
you to exclude a (list of) \included files from your document, by
means of an \excludeonly command.
If you want to select particular pages of your document, use Heiko
Oberdiek's pagesel or the selectp packages. You can do something
similar with an existing PDF document (which you may have compiled
using pdflatex in the first place), using the pdfpages package. The
job is then done with a document looking like:
\documentclass{article}
\usepackage[final]{pdfpages}
\begin{document}
\includepdf[pages=30-40]{yoursource.pdf}
\end{document}
(To include all of the document, you write
\includepdf[pages=-]{yoursource.pdf}
omitting the start and end pages in the optional argument.)
If you want flexible facilities for including or excluding small
portions of a file, consider the comment, version or optional packages.
The comment package allows you to declare areas of a document to be
included or excluded; you make these declarations in the preamble of
your file. The command \includecomment{version-name} declares an
environment version-name whose content will be included in your
document, while \excludecomment{version-name} defines an environment
whose content will be excluded from the document. The package uses a
method for exclusion that is pretty robust, and can cope with ill-
formed bunches of text (e.g., with unbalanced braces or \if commands).
These FAQs employ the comment package to alter layout between the
are narrowversion and wideversion for the two versions of the file.
version offers similar facilities to comment.sty (i.e.,
\includeversion and \excludeversion commands); it's far "lighter
weight", but is less robust (and in particular, cannot deal with very
large areas of text being included/excluded).
A significant development of version, confusingly called versions
(i.e., merely a plural of the old package name). Versions adds a
command \markversion{version-name} which defines an environment that
prints the included text, with a clear printed mark around it.
optional defines a command \opt; its first argument is an
'inclusion flag', and its second is text to be included or excluded.
Text to be included or excluded must be well-formed (nothing
mismatched), and should not be too big - if a large body of text is
needed, \input should be used in the argument. The documentation (in
the package file itself) tells you how to declare which sections are
to be included: this can be done in the document preamble, but the
documentation also suggests ways in which it can be done on the
command line that invokes LaTeX, or interactively.
And, not least of this style of conditional compilation, verbatim
(which should be available in any distribution) defines a comment
environment, which enables the dedicated user of the source text
editor to suppress bits of a LaTeX source file. The memoir class
offers the same environment.
An interesting variation is the xcomment package. This defines an
environment whose body is all excluded, apart from environments named
in its argument. So, for example:
\begin{xcomment}{figure,table}
This text is not included
\begin{figure}
This figure is included
\end{figure}
This is not included, either
\begin{table}
This table also included
\end{table}
...
\end{xcomment}
A further valuable twist is offered by the extract package. This
allows you to produce a "partial copy" of an existing document: the
package was developed to permit production of a "book of examples"
from a set of lecture notes. The package documentation shows the
following usage:
\usepackage[
active,
generate=foobar,
extract-env={figure,table},
extract-cmd={chapter,section}
]{extract}
which will cause the package to produce a file foobar.tex
containing all the figure and table environments, and the \chapter
and \section commands, from the document being processed. The new
file foobar.tex is generated in the course of an otherwise ordinary
run on the 'master' document. The package provides a good number of
other facilities, including (numeric or labelled) ranges of
environments to extract, and an extract environment which you can use
to create complete ready-to-run LaTeX documents with stuff you've
extracted.
comment.sty
macros/latex/contrib/comment (gzipped tar, browse)
excludeonly.sty
macros/latex/contrib/misc/excludeonly.sty
extract.sty
macros/latex/contrib/extract (gzipped tar, browse)
memoir.cls
macros/latex/contrib/memoir (gzipped tar, browse)
optional.sty
macros/latex/contrib/misc/optional.sty
pagesel.sty
Distributed with Heiko Oberdiek's packages macros/latex/contrib/
oberdiek (gzipped tar, browse)
pdfpages.sty
macros/latex/contrib/pdfpages (gzipped tar, browse)
selectp.sty
macros/latex/contrib/misc/selectp.sty
verbatim.sty
Distributed as part of macros/latex/required/tools (gzipped tar, browse)
version.sty
macros/latex/contrib/misc/version.sty
versions.sty
macros/latex/contrib/versions/versions.sty
xcomment.sty
Distributed as part of macros/latex/contrib/seminar (gzipped tar,
browse)
You too could think of packing the different versions of a paragraph
into separate files and only one is included, maybe based on some
'argument' (a \def definition) you pass to tex ...
--
Mit friedvollen Grüßen
Pete
The human animal differs from the lesser primates in his passion for
lists of "Ten Best".
-- H. Allen Smith
------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
|
{}
|
# How do you use a ROC curve to optimize a random forest classifier? [duplicate]
So the threshold is a parametric parameter of the curve. Where you can find the interval in which it is in by using the scores two points immediately adjacent to them. You can also look into an $F_1$ score to help you pick an optimal threshold.
|
{}
|
# Potential vs. Potential Energy
1. Jun 25, 2009
### guitarman
Hey, I'm trying to teach myself physics II and am having difficulty understanding the difference between potential and potential energy. Could somebody please attempt to explain the differences between them to me, and use analogies if possible? Thanks in advance!
2. Jun 25, 2009
### cepheid
Staff Emeritus
I would say that potential energy is a property of a system. If you have a system of two opposite charges separated by a distance r, then there is potential energy associated with the system (because work had to be done against the attractive electrostatic force to separate them by that distance).
This potential energy is a single number. However, if the magnitude of one of the charges changes or the distance between them changes, so too does the potential energy of the overall system. (The number changes, because the system being described has changed.)
Electric potential gives us a way of characterizing the effect associated with ONE single charge without making direct reference to a specific second one. If you look at the definition, you will see that the potential due to a charge is defined as the potential energy that the system would have if another positive unit test charge were located a distance r away from the charge in question. Therefore, electric potential is a function of position r, in space as opposed to being a single number. In fact, potential r, is a scalar field (a quantity that takes on a scalar value at every point in space). The electric potential of a single charge can be thought of as a quantity that characterizes the influence of this charge on its surroundings, but without having to specify what might be there in those surroundings.
This explanation makes it clear why electric potential has units of "potential energy PER unit of charge." It is the potential energy that the system would have if a unit test charge (1 C) were placed at point r, and therefore is neatly independent of the specific amount of charge present at point r.
Last edited: Jun 25, 2009
3. Jun 26, 2009
### rcgldr
The earth approximates an infintely large flat plate if the heights involved are relatively small where gravity is constant for these relatively small heights. In this case, gravitational potential is simply the height above (or below) some reference height, for example, define height = 0 at sea level.
Given that gravitiational acceleration is = 9.8 meters / second^2 at all relatively small heights, and and 1 newton = 1 kilogram meter / second^2, then at height = 30 meters, gravitational potential is 30 meters x 9.8 newtons / kilogram of mass = 294 joules / kilogram.
A 1 micro gram mass and a 1 kilo gram mass at height 30 meters have the same gravitational potential, but not the same gravitational potential energy (GPE). In this case the 1 microgram mass would have a GPE of 294 x 10-9 joules, while the 1 kilogram mass would have a GPE of 294 joules.
I did some of the math in this thread about voltage (electrical potential).
Last edited: Jun 26, 2009
4. Jun 26, 2009
### Tac-Tics
Electric potential is the voltage.
Imagine an empty space with a positively charged ball. This ball creates an electric field all throughout space. The value of that field at any point is sometimes called the potential or the voltage. The potential at any point in space depends on the position and charge of all the objects in your system.
Pick two points around the ball. Take a second charged ball and put it at point A, initially at rest. It will start to move. When the second ball reaches point B, it has picked up some amount of kinetic energy. Where did that energy come from? The answer is while it was at rest at point A, the ball actually had potential energy.
How much potential energy does the second ball have? The answer depends on three values:
* The potential at point A
* The potential at point B
* The charge on the second ball
Most importantly, if we double the charge on the second ball, we double the energy. It's a linear relationship. We can just calculate the energy for one coulomb. That value is now the "exchange rate" between energy and charge. If you have a 5V battery and you want to know how much energy you get when you move some electrons from one terminal to the other, you can figure out that amount by counting the total charge on the electrons, then multiplying it by the exchange rate, 5 joules per coulomb.
5. Jun 26, 2009
### tiny-tim
Hi guitarman!
From the PF Library on potential energy …
Potential is not the same as potential energy:
Electric potential (or electric potential difference or voltage) is confusingly so named, since it is potential energy per charge.
Similarly, gravitational potential is potential energy per mass: $-GM/r$
Unfortunately, the same letter $\bold{F}$ is often used for both "field" and "force", which obscures the fact that (for an "inline" field) the force vector equals the field vector times a charge (for example, electric charge or mass).
Generally, the potential of a vector field $\bold{F}_{field}$ is a scalar function $U$ such that $\bold{F}_{field}\ = \ -\bold{\nabla}U$. So the potential energy is potential times charge:
[tex]-\int\bold{F}_{force}\cdot\bold{ds}\ = -\ q\int\bold{F}_{field}\cdot\bold{ds}\ = \ q\int (\bold{\nabla}U)\cdot\bold{ds}\ =\ q\int\frac{\partial U}{\partial s}ds\ =\ qU[/itex]
|
{}
|
# Multiple choice questions linked to solutions using Optional Content Groups (OCG)
I am setting up some practice tests for an aptitude exam my son will undertake for entry to university. Many example questions are available. Hard copy books publish the questions at the front of the book and the answers at the back. Flipping pages is not conducive to understanding the question and its solution. It also makes practice under timed conditions difficult.
I'm close to setting up an e-book for practicing the test. The e-book uses Optional Content Groups (OCG) created with the hyperref and ocgx2 packages. However, I have not been able to link the choice of the correct multiple choice answer with displaying the solution. A MWE setup is as follows.
Two questions (Q1 and Q2) are set out in relation to a passage of text. Each question has five, multiple choice answers. There is a single solution for each question. The content for each passage, the questions, multiple choice answers and solution combination is loaded from an external file (DB.csv) using datatools and are set out on the page in a tcolorbox raster. The multiple choice answers are associated with radio buttons that toggle whether a particular answer choice is correct or incorrect. A separate box adjacent to the choices can be toggled to show the solution.
Currently, the solution is toggled separately from the responses to multiple choice answers. I am trying to get the solution to toggle on when the correct multiple choice answer is given. For example, the correct answer to question 1 is D. When the radio button for choice D is pressed, I want the solution to show in the adjacent box.
Thus, my question is: How do I link clicking on one ocg (a multiple choice answer) to show a separate ocg (the solution), when that link is subject to a conditional test (it is the correct answer).
This is an annotated picture of the output from the MWE
This is the MWE:
% Adapted from https://tex.stackexchange.com/questions/286280/textfield-and-animateinline
\PassOptionsToPackage{table,x11names,dvipsnames,svgnames}{xcolor}
\documentclass[11pt,a4paper]{article}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{datatool}
\usepackage{enumitem}
\usepackage{fancyhdr}
\usepackage{filecontents}
\usepackage{graphics} % \resizebox
\usepackage{ifthen}
\usepackage{ocgx2}
\usepackage[most]{tcolorbox}
\usepackage{xcolor}
\usepackage{hyperref} % \TextField etc.
\hypersetup{
hyperindex=true,
urlcolor= purple,
citecolor={blue!50!black},
urlcolor={blue!80!black},
bookmarks=true,
pdftoolbar=true,
bookmarksopen=true,
pdftitle={LNAT},
pdfauthor={},
pdfsubject={LNAT},
}
\begin{filecontents*}{DB.csv}
"Old MacDonald had a farm. On that farm he had cows, horses, goats and sheep.",How many ruminants did McDonald have on his farm?,0,1,2,3,4,4,"Ruminants have a special stomach for fermentation of plant-based food. A horse is not a ruminant.",How many ungulates did McDonald have on his farm?,0,1,2,3,4,5,"Ungulates are hoofed animals. All McDonald's animals have hooves."
\end{filecontents*}
\newcounter{P}
\setcounter{P}{0}
\newcounter{Q}
\setcounter{Q}{0}
\setlist{label*=\Alph*.,noitemsep,leftmargin=0.9cm}
\setlength\parindent{0pt}
\makeatletter
% patch hyperref's Form producing commands to make them layer-aware
\makeatother
%alternative check box command for layer switching
\newcommand\layerCheckBox[3]{%
% #1: layer name (as shown in Layers tab),
% #2: layer id,
% #3: initial visibility
\raisebox{-0.6ex}{\resizebox{3ex}{!}{%
\makebox[0pt][l]{\showocg{#2}{$\circ$}}%
\begin{ocg}{#1}{#2}{#3}$\bullet$\end{ocg}%
}%
\hspace{0.1cm}
}}
% This is setting up the header
\cfoot{}
}
\begin{document}
% For each record (line) in database
% Assign field values by name to macros
%\DTLsetseparator{|}
\DTLforeach{DB}{%
\passage=Passage,
\Aquestion=AQuestion,
\Achoicea=AChoice1,
\Achoiceb=AChoice2,
\Achoicec=AChoice3,
\Achoiced=AChoice4,
\Achoicee=AChoice5,
\Asolution=ASolution,
\Bquestion=BQuestion,
\Bchoicea=BChoice1,
\Bchoiceb=BChoice2,
\Bchoicec=BChoice3,
\Bchoiced=BChoice4,
\Bchoicee=BChoice5,
\Bsolution=BSolution%
}{%
\stepcounter{P}
\begin{tcboxeditemize}
[raster rows=5,raster columns=5,raster height=\textheight-2cm,arc=6pt,
raster every box/.style={colframe=red!50!black,colback=red!10!white,coltitle=white,fonttitle=\large\bfseries}] % raster options
%
{colframe=CornflowerBlue!50!white,colback=CornflowerBlue!10!white,arc=6pt} % outer tcolorbox options
\tcbitem[raster multicolumn=2,raster multirow=5,colframe=green!50!black,colback=white,raster height=\tcbtextheight,colbacktitle=white,coltitle=black,title=Passage \arabic{P}]
\passage
%
\tcbitem[raster multicolumn=2,raster multirow=5,blankest,raster height=\tcbtextheight]
%
\begin{tcbitemize}[raster rows=5,raster columns=2,raster height=\tcbtextheight,colbacktitle=white]
% Question 1
\stepcounter{Q}
\tcbitem[raster multicolumn=2,colframe=blue!50!white,colback=white,coltitle=black,fonttitle=\large\bfseries,title=\arabic{Q}. \Aquestion]
\begin{enumerate}
% Question 1 - Choice A
\item [\layerCheckBox{Q\arabic{Q}A}{\arabic{Q}A}{off} A.] \Achoicea \par
\end{ocg}%
% Question 1 - Choice B
\item [\layerCheckBox{Q\arabic{Q}B}{\arabic{Q}B}{off} B.] \Achoiceb \par
\end{ocg}%
% Question 1 - Choice C
\item [\layerCheckBox{Q\arabic{Q}C}{\arabic{Q}C}{off} C.] \Achoicec \par
\end{ocg}%
% Question 1 - Choice D
\item [\layerCheckBox{Q\arabic{Q}D}{\arabic{Q}D}{off} D.] \Achoiced \par
\end{ocg}%
% Question 1 - Choice E
\item [\layerCheckBox{Q\arabic{Q}E}{\arabic{Q}E}{off} E.] \Achoicee \par
\end{ocg}%
\end{enumerate}
% Question 2
\stepcounter{Q}
\tcbitem[raster multicolumn=2,colframe=blue!50!white,colback=white,coltitle=black,fonttitle=\large\bfseries,title=\arabic{Q}. \Bquestion]
\begin{enumerate}
% Question 2 - Choice A
\item [\layerCheckBox{Q\arabic{Q}A}{\arabic{Q}A}{off} A.] \Bchoicea\par
\end{ocg}%
% Question 2 - Choice B
\item [\layerCheckBox{Q\arabic{Q}B}{\arabic{Q}B}{off} B.] \Bchoiceb\par
\end{ocg}%
% Question 2 - Choice C
\item [\layerCheckBox{Q\arabic{Q}C}{\arabic{Q}C}{off} C.] \Bchoicec\par
\end{ocg}%
% Question 2 - Choice D
\item [\layerCheckBox{Q\arabic{Q}D}{\arabic{Q}D}{off} D.] \Bchoiced\par
\end{ocg}%
% Question 2 - Choice E
\item [\layerCheckBox{Q\arabic{Q}E}{\arabic{Q}E}{off} E.] \Bchoicee\par
\end{ocg}%
\end{enumerate}
\end{tcbitemize}
\tcbitem[raster multicolumn=1,raster multirow=5,blankest,raster height=\tcbtextheight]
% These are the solutions
\begin{tcbitemize}[raster rows=5,raster columns=1,raster height=\tcbtextheight]
% Solution to question 1
\tcbitem[colframe=blue!50!white,colback=white]
\hspace{-0.6cm} \layerCheckBox{S\arabic{Q}A}{S\arabic{Q}A}{off}
\Asolution
\end{ocg}
% Solution to question 2
\tcbitem[colframe=blue!50!white,colback=white]
\hspace{-0.6cm} \layerCheckBox{S\arabic{Q}B}{S\arabic{Q}B}{off}
\Bsolution
\end{ocg}
\end{tcbitemize}
\end{tcboxeditemize}
\clearpage
\stepcounter{P}
}
\end{document}
In order to become visible at the same time when the correct choice button is clicked, the text in the solution box must be put on the same OCG as the corresponding choice button. In the present example, these are OCGs 1D for question One and 2E for question Two.
Note that \arabic{Q} does not expand to the correct values in the "% Solution to question ?" code sections of the original source. Therefore, the need values are hard-coded in the code below.
Moreover, individual radio button groups (e. g. radiobtngrp=Choices-1, radiobtngrp=Choices-2) should be used for different questions, because answering Q Two should not hide the choice made for Q One.
\PassOptionsToPackage{table,x11names,dvipsnames,svgnames}{xcolor}
\documentclass[11pt,a4paper]{article}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{datatool}
\usepackage{enumitem}
\usepackage{fancyhdr}
\usepackage{filecontents}
\usepackage{graphics} % \resizebox
\usepackage{ifthen}
\usepackage{ocgx2}
\usepackage[most]{tcolorbox}
\usepackage{xcolor}
\usepackage{hyperref} % \TextField etc.
\hypersetup{
hyperindex=true,
urlcolor= purple,
citecolor={blue!50!black},
urlcolor={blue!80!black},
bookmarks=true,
pdftoolbar=true,
bookmarksopen=true,
pdftitle={LNAT},
pdfauthor={},
pdfsubject={LNAT},
}
\begin{filecontents*}{DB.csv}
"Old MacDonald had a farm. On that farm he had cows, horses, goats and sheep.",How many ruminants did McDonald have on his farm?,0,1,2,3,4,4,"Ruminants have a special stomach for fermentation of plant-based food. A horse is not a ruminant.",How many ungulates did McDonald have on his farm?,0,1,2,3,4,5,"Ungulates are hoofed animals. All McDonald's animals have hooves."
\end{filecontents*}
\newcounter{P}
\setcounter{P}{0}
\newcounter{Q}
\setcounter{Q}{0}
\setlist{label*=\Alph*.,noitemsep,leftmargin=0.9cm}
\setlength\parindent{0pt}
% hyperref Form elements not used in this example, un-comment if really needed
%\makeatletter
%% patch hyperref's Form producing commands to make them layer-aware
%\makeatother
%alternative check box command for layer switching
\newcommand\layerCheckBox[3]{%
% #1: layer name (as shown in Layers tab),
% #2: layer id,
% #3: initial visibility
\raisebox{-0.6ex}{\resizebox{3ex}{!}{%
\makebox[0pt][l]{\showocg{#2}{$\circ$}}%
\begin{ocg}{#1}{#2}{#3}$\bullet$\end{ocg}%
}%
\hspace{0.1cm}
}}
% This is setting up the header
\cfoot{}
}
\begin{document}
% For each record (line) in database
% Assign field values by name to macros
%\DTLsetseparator{|}
\DTLforeach{DB}{%
\passage=Passage,
\Aquestion=AQuestion,
\Achoicea=AChoice1,
\Achoiceb=AChoice2,
\Achoicec=AChoice3,
\Achoiced=AChoice4,
\Achoicee=AChoice5,
\Asolution=ASolution,
\Bquestion=BQuestion,
\Bchoicea=BChoice1,
\Bchoiceb=BChoice2,
\Bchoicec=BChoice3,
\Bchoiced=BChoice4,
\Bchoicee=BChoice5,
\Bsolution=BSolution%
}{%
\stepcounter{P}
\begin{tcboxeditemize}
[raster rows=5,raster columns=5,raster height=\textheight-2cm,arc=6pt,
raster every box/.style={colframe=red!50!black,colback=red!10!white,coltitle=white,fonttitle=\large\bfseries}] % raster options
%
{colframe=CornflowerBlue!50!white,colback=CornflowerBlue!10!white,arc=6pt} % outer tcolorbox options
\tcbitem[raster multicolumn=2,raster multirow=5,colframe=green!50!black,colback=white,raster height=\tcbtextheight,colbacktitle=white,coltitle=black,title=Passage \arabic{P}]
\passage
%
\tcbitem[raster multicolumn=2,raster multirow=5,blankest,raster height=\tcbtextheight]
%
\begin{tcbitemize}[raster rows=5,raster columns=2,raster height=\tcbtextheight,colbacktitle=white]
% Question 1
\stepcounter{Q}
\tcbitem[raster multicolumn=2,colframe=blue!50!white,colback=white,coltitle=black,fonttitle=\large\bfseries,title=\arabic{Q}. \Aquestion]
\begin{enumerate}
% Question 1 - Choice A
\item [\layerCheckBox{Q\arabic{Q}A}{\arabic{Q}A}{off} A.] \Achoicea \par
\end{ocg}%
% Question 1 - Choice B
\item [\layerCheckBox{Q\arabic{Q}B}{\arabic{Q}B}{off} B.] \Achoiceb \par
\end{ocg}%
% Question 1 - Choice C
\item [\layerCheckBox{Q\arabic{Q}C}{\arabic{Q}C}{off} C.] \Achoicec \par
\end{ocg}%
% Question 1 - Choice D
\item [\layerCheckBox{Q\arabic{Q}D}{\arabic{Q}D}{off} D.] \Achoiced \par
\end{ocg}%
% Question 1 - Choice E
\item [\layerCheckBox{Q\arabic{Q}E}{\arabic{Q}E}{off} E.] \Achoicee \par
\end{ocg}%
\end{enumerate}
% Question 2
\stepcounter{Q}
\tcbitem[raster multicolumn=2,colframe=blue!50!white,colback=white,coltitle=black,fonttitle=\large\bfseries,title=\arabic{Q}. \Bquestion]
\begin{enumerate}
% Question 2 - Choice A
\item [\layerCheckBox{Q\arabic{Q}A}{\arabic{Q}A}{off} A.] \Bchoicea\par
\end{ocg}%
% Question 2 - Choice B
\item [\layerCheckBox{Q\arabic{Q}B}{\arabic{Q}B}{off} B.] \Bchoiceb\par
\end{ocg}%
% Question 2 - Choice C
\item [\layerCheckBox{Q\arabic{Q}C}{\arabic{Q}C}{off} C.] \Bchoicec\par
\end{ocg}%
% Question 2 - Choice D
\item [\layerCheckBox{Q\arabic{Q}D}{\arabic{Q}D}{off} D.] \Bchoiced\par
\end{ocg}%
% Question 2 - Choice E
\item [\layerCheckBox{Q\arabic{Q}E}{\arabic{Q}E}{off} E.] \Bchoicee\par
\end{ocg}%
\end{enumerate}
\end{tcbitemize}
\tcbitem[raster multicolumn=1,raster multirow=5,blankest,raster height=\tcbtextheight]
% These are the solutions
\begin{tcbitemize}[raster rows=5,raster columns=1,raster height=\tcbtextheight]
% Solution to question 1
\tcbitem[colframe=blue!50!white,colback=white]
\hspace{-0.6cm} \layerCheckBox{Q1D}{1D}{off}
\begin{ocg}{Q1D}{1D}{off}%
\Asolution
\end{ocg}
% Solution to question 2
\tcbitem[colframe=blue!50!white,colback=white]
\hspace{-0.6cm} \layerCheckBox{Q2E}{2E}{off}
\begin{ocg}{Q2E}{2E}{off}%
\Bsolution
\end{ocg}
\end{tcbitemize}
\end{tcboxeditemize}
\clearpage
\stepcounter{P}
}
\end{document}
• Thank you Alex. Now it is obvious. I need to generalize this for ~400 questions so I'll need to create unique identifiers for each OCG. That's why I used the counters to create the OCG ID's. I made a mistake when I made the MWE though. – Ross Nov 27 '17 at 10:33
• Yes, of course, a real world questionnaire would require the use of counters to generate identifiers. I am sure you will get it right ;-). – AlexG Nov 27 '17 at 11:08
|
{}
|
# Sobel operator and 8 bit paletted image
This topic is 3033 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.
## Recommended Posts
Hi! I'm having few problem applying a Sobel filter to an image that I have loaded into the NDS (I'm programming it at libnds). I have to do this in indexed color (paletted 8 bit image). Here is the code I use:
void imageToSobel(u8* bmp, u16* palette, int len, int weight, int height) {
int i, j;
int x, y;
u8 p1, p2, p3, p4, p6, p7, p8, p9;
u8 R, G, B, gray;
for(i = 0; i < len/2; i++) {
R = palette & 0x1F;
G = (palette >> 5) & 0x1F;
B = (palette >> 10) & 0x1F;
gray = div32(30*R, 100) + div32(59*G, 100) + div32(11*B, 100);
BG_PALETTE = RGB15(gray, gray, gray);
}
for(i = 0; i < height; i++) {
for(j = 0; j < weight; j++) {
p1 = bmp[(i-1)*weight+(j-1)];
p2 = bmp[(i-1)*weight+j];
p3 = bmp[(i-1)*weight+(j+1)];
p4 = bmp[i*weight+(j-1)];
p6 = bmp[i*weight+(j+1)];
p7 = bmp[(i+1)*weight+(j-1)];
p8 = bmp[(i+1)*weight+j];
p9 = bmp[(i+1)*weight+(j+1)];
x = (p1+(p2+p2)+p3-p7-(p8+p8)-p9);
y = (p3+(p6+p6)+p9-p1-(p4+p4)-p7);
BG_GFX[i*weight+j] = sqrt32((x*x) + (y*y));
}
}
}
The first for loop converts the image to gray scale, and do it fine. But in the next for is the problem; it's seem that doesn't do correctly... I try the same code but loading a 16 bit image and works fine, so the algorithm is correct... Could somebody help me? I don't know where is the mistake :( Thank you! PD: Sorry about my bad English.
##### Share on other sites
maybe it's just a precision issue.
try:
gray = div32(30*R+59*G+11*B, 100);
##### Share on other sites
That doesn't fix the problem :/
The problem isn't it in the for which change the image into gray scale; is in the second for, which apply the sobel filter :(
1. 1
2. 2
3. 3
4. 4
frob
13
5. 5
• 16
• 13
• 20
• 12
• 19
• ### Forum Statistics
• Total Topics
632170
• Total Posts
3004550
×
|
{}
|
# Strong and weak gravitational Fields
1. Sep 8, 2008
### NoobixCube
Hi all,
When working on some GTR derivations the authors of the text make approximations based on the magnitude of the gravitational field. What are the general limits of strong and weak gravitational fields?
2. Sep 8, 2008
### Phrak
From what I've seen in deriving one weak field limit, you begin with a spacetime where the metric is flat; trace(g_uv) = -1,1,1,1. Small perturbations |h_00| << 1 lead to Newton's gravitational potential. Any additions of |h_uv| << 1 to the metric would seem to constitue a weak field limit--if the sign of h_uv is physically permissible. I've put the absolute value around h_uv to avoid making a sign error.
3. Sep 9, 2008
### NoobixCube
Well it came about when deriving the precession of the perihelion of Mercury which does deal with assuming Newtons Solution to the two body problem is a very good approximation. Then when accounting for the General Relativistic equation of motion you have to assume that the Gravitational filed is weak and hence may yield a full solution by assuming a small perturbation to the exact solution for Newtons problem. So you answer touched on my problem, by I was looking for a quantitative value for say a strong field.
4. Sep 9, 2008
### atyy
Try section 4.1.1 of Clifford Will's article:
http://relativity.livingreviews.org/Articles/lrr-2006-3/ [Broken]
Last edited by a moderator: May 3, 2017
5. Sep 10, 2008
### Phrak
I don't know of any other meaning to "strong gravitational fields" other than field strengths that cannot be considered weak in the particular analysis in question.
This is somewhat implied by atyy's link, as well. I only glanced at it, but Will's one-size-fits-all rule defining the weak field limit is suspicious.
Last edited: Sep 10, 2008
6. Sep 11, 2008
|
{}
|
# Question #fde10
Dec 4, 2017
$221.30 g m o {l}^{- 1}$
#### Explanation:
1. Calculate the volume of the unit cell
Convert pm to cm
1 pm = $1 \cdot {10}^{- 10} c m$
419 pm = $4.19 \cdot {10}^{- 8} c m$
Volume of unit cell = ${\left(4.19 \cdot {10}^{- 8} c m\right)}^{3}$
Volume of unit cell = $7.36 \cdot {10}^{- 23} c {m}^{3}$
2. Determine the mass of the metal in the unit cell
Mass of metal in unit cell = $20 g c {m}^{- 3} \times 7.36 \cdot {10}^{- 23} c {m}^{3}$
Mass of metal in unit cell = $1.47 \cdot {10}^{- 21} g$
3. Determine number of atoms per unit cell
We have face-centered unit cell:
Lattice points on the corner count for an 1/8 because they are shared with 8 other unit cells. Lattice points on the face count for 1/2 as they are shared with one other unit cell.
1/8 x 8 corners = 1 lattice point
1/2 x 6 faces = 3 lattice points
Total number of lattice points (atoms) per unit cell = 4
4. Calculate molar mass of unknown metal
Mass per atom = Total mass of metal in unit cell / number of atoms in unit cell
Mass per atom = $\frac{1.47 \cdot {10}^{- 21} g}{4}$
Mass per atom = $3.68 \cdot {10}^{- 22} g$
Use mass to determine molar mass by multiplying by Avogadro's number:
molar mass = $3.68 \cdot {10}^{- 22} g \times 6.022 \cdot {10}^{2} m o {l}^{- 1}$
molar mass = $221.30 g m o {l}^{- 1}$
Looking at the periodic table, this molar mass is the closest to radon.
|
{}
|
# Recreate a 'Snake' game in a console/terminal
## Games are fun
this codegolf here was so fun I had to make a version for other classic games similar in complexity. Shortest Way of creating a basic Space Invaders Game in Python
This time, however, try to recreate the classic 'Snake' game, in which you start out as a small shape, constantly moving to collecting pieces to increase your score. When you collect a piece, your 'tail' grows, which follows the path you have made. The objective is to last the longest without crashing into your own tail, or into the walls
Qualifications:
• You, the characters that make up the tail, the walls, and the pieces you collect should all be different characters
• show an HUD with the score. The score increases by 1 point for each piece you collect
• The player loses when they collide with their own tail or the wall
• a piece spawns in a random area immediately after a piece is collected, not to mention at the start of the game
• Speed of the game doesn't matter, as long as it is consistent
• The 'cells' should be 2x1 characters, since the height of block characters is ~twice the width Can be 1x1, because 2x1 is just ugly and I didnt really think of that
• The keys for changing the direction should be awsd, left, up, down, right respectively
• the starting direction should always be up
• You must show the edges of the wall. The score may overlap the wall
Shortest code that meets the above criteria wins. Imaginary Bonus Points for creativity
• The snake isn't supposed to grow when eating? Jan 4 '12 at 0:18
• hm? "When you collect a piece, your 'tail' grows, which follows the path you have made.", so yes, the snake grows. Jan 4 '12 at 2:46
• Without the awsd and the starting direction should always be up requirements, M-x snake would work Apr 22 '14 at 14:12
• @scrblnrd3 M-: (progn(define-key snake-mode-map"a"'snake-move-left)...(setq snake-initial-velocity-x 0 snake-initial-velocity-y 1)(snake)) would do the trick then. Mar 31 '16 at 12:51
• Related: Nibbles Nostalgia Jun 9 '18 at 1:11
## JavaScript (553 512 bytes)
c=0;a=b=d=-1;e=[f=[20,7],[20,8]];i=Math.random;~function n(){if(c&&(87==a||83==a
))c=0,d=87==a?-1:1;if(d&&(65==a||68==a))d=0,c=65==a?-1:1;p([j=e[0][0]+c,k=e[0][1
]+d])||!j||39==j||!k||10==k?b+=" | GAME OVER":(e.unshift([j,k]),p(f)?(f=[1+38*i(
)|0,1+9*i()|0],b++):e.pop());for(m=h="";11>h;h++){for(g=0;40>g;g++)l=g+","+h,m+=
!g||39==g||!h||10==h?"X":e[0]==l?"O":p(l)?"*":f==l?"%":" ";m+="\n"}x.innerHTML=m
+b;!b.sup&&setTimeout(n,99)}();onkeydown=function(o){a=o.keyCode};function p(o){
return e.join(p).indexOf(p+o)+1}
I tried to make it output to the real console at first (with console.log and console.clear), but it was flickering too much, so I put it into console-like HTML. It will work with this:
<pre id=x>
Also I implemented it with 2x1 cells first, but it just looked worse than 1x1. That would be a minor change though.
Uses awsd keys on keyboard.
Update:
I was able to cut it down to 512 (exactly 0x200) bytes by improving the tail search and doing some more magic.
You now get 2 points when a piece spawns in your tail (it's a feature). I also fixed the overlapping when the snake bites itself.
• beautiful! and you're right, it does look better as 1x1 than 2x1. the only worry I really had there was up and down being way faster than left and right but it's doable considering the constraints. The flashing in the console I don't mind so much (see my space invaders program, its fairly flickering) but I suppose a plain text web page works too! one qualm though... is there any way to restart without needing to refresh? :( Jan 4 '12 at 5:24
• Doesn't work with awsd Jan 4 '12 at 21:56
• @Blazer That would take more 13 characters :-/ ... and you have the F5 key anyway.
– copy
Jan 5 '12 at 0:23
• @Neal Yeah I used the arrow keys but fixed it now.
– copy
Jan 5 '12 at 0:24
• @copy I suppose I didn't make it a requirement Jan 5 '12 at 0:28
16 bit 8086
526 bytes / 390 bytes
Decode this using a Base64 decoder and call it "snake.com" then execute from Windows command prompt. Tested on WinXP, you may need to use DosBox to get the right video mode. Control keys are 'wasd' and space to exit. Press 'w' to start.
uBMAzRC5AD+2AOipAb1AAbgAoI7Auf//v4sMsAHzqrgAtLksAfOqg8cU/sx19OgsAYs+8gKwAuj4
ALQAzRpCiRYOA4kWEAPouAC0C80hCsB0IbQIzSG+ygKDxgOAPAB0EjgEdfSLRAGzAP/Qo1cBiB7w
A775AnREiz70AiaKHbAA6HUAA7/mAok+9AKA/gB0FscGVwHNAoEudAGu/zPJtj/o2QDofQC0AM0a
OxYOA3X2/wYOA+lZ/8YEAE7+BIA8CnT16F4AaOAB6EQAM9K5LQD38YvCweACBQoA9+WL+OguALlL
iRYQA4vCw772Ar8K9bUEshCstACL2AHDi4f6ArMDtwXR+LEAwNEC/smA4Q8miA0p7/7PdevoIQA6
xHQE/st13ugKAP7NdcroAwB1+8O3BSbGBQEp7/7PdfaBx0EG/srDuBAQM9uAwwLNEID7CnX2w7gD
gQPvQrVA4++BVdVjgQ==
Here's a character mode version that's 390 bytes long:
uAMAzRC4ALiOwLlQADP/uCCf86uzF6u4AA+xTvOruCCfq7LdfCxUPOr6BgBiz5+AqF8Aqu0AM0aQ
m8Bov+z/rhdAoDDBMOzArhnAoDDBsOLPn4Cix58AiaJHQOclgmijUmiR2JPn4CgP4DvoUCdFOLPo
ID0gP6JoA9AHXhJscFA93DoYgCutsA9+K57X/38YkWiAKLwjPSw76CAr8CALkEALSfrAQwq+L6w8
0gd3EBIFcCAGGCAWSAASBXAgB3dwFzeQEgVwIAYP+gAP7/AgACqtAH0AcAAAAA
This character mode one's three bytes longer (but the snake's better):
uAMAzRC4ALiOwLlQADP/uCCf86uzF6u4AA+xTvOruCCfq/7LdfCxUPOr6BsBiz6BAibHBQEKtADN
GkKJFokCiRaLAujHALQLzSEKwHQhtAjNIb5ZAoPGA4A8AHQSOAR19ItEAbMA/9CjUwGIHn8C6XgA
TgD38UID0gP6JoA9AHXhJscFA93DoYsCutsA9+K57X/38YkWiwKLwjPSw76FAr8CALkEALSfrAQw
q+L6w80gd3IBIFoCAGGDAWSBASBaAgB3eAFzegEgWgIAYP+gAP7/AgACqtAH0AcAAAAA
• points for creativity, but i think using dosbox is cheating because the challenge is to make the game work in an ascii console or terminal, not a dosbox. also, shouldn't code golf be source code, not binary? Jan 5 '12 at 23:10
• @Blazer: That is the source code - I typed the machine code in using a hex editor - that's how l337 I am! ;-) The DosBox thing is only needed if your video drivers have trouble with mode 13 graphics (mine card is OK with it). It wouldn't be difficult to do an ascii version (probably smaller too) Jan 6 '12 at 8:50
• The "390-byte" version decodes to only 388 bytes and hangs when run under dosbox. Looks like something may have been lost in transmission. :( Still, the other two versions are extremely cool! Jan 6 '12 at 12:45
• Is there an ungolfed version of the code? (I don't know this language)
– A.L
Apr 20 '14 at 18:46
• @n.1: The program is 8086 machine code, you can load it into a debugger (D86) and view the code as written, albeit without label names. Apr 22 '14 at 8:07
## shell/sh, 578 chars
I tried to be POSIX compliant (being as much portable as possible and avoid bashisms, even the random-number-generator does not need /proc). You can e.g. play it in your native terminal or via a SSH-session: run with 'dash -c ./snake' There is also an unuglyfied/readable variant in ~2800 bytes, which can be seen here.
Some notes: shell-scripting is not suited for coding games 8-)
• to be fair, we only used so called 'builtins', which means:
• no external calls of programs like 'clear', 'stty' or 'tput'
• because of that, we redraw the whole screen on every move
• the only used builtins (aka native commands) are:
• echo, eval, while-loop, let, break, read, case, test, set, shift, alias, source
• there is no random number generator (PRNG), so we have to built our own
• getting a keystroke blocks, so we have to spawn another thread
• for getting the event in parent-task we use a tempfile (ugly!)
• the snake itself is a list, which is cheap:
• each element is a (x,y)-tuple
• loosing the tail means: shift the list by 1
• the grid is internally an array, but shell/sh does not know this:
• we "emulated" array(x,y) via an ugly eval-call with global vars
• and finally: we had a lot of fun!
#!/bin/sh
alias J=do T=let E=echo D=done W=while\ let
p(){ eval A$1x$2=${3:-#};} g(){ eval F="\${A$1x$2:- }";}
r(){
E $((1+(99*I)%$1))
}
X=9
Y=8
L="8 8 $X$Y"
I=41
W I-=1
J
p $I 1 p$I 21
p 1 $I p 41$I
D
p 3 3 :
>L
W I+=1
J
E -ne \\033[H
y=22
W y-=1
J
Z=
x=42
W x-=1
J
g $x$y
Z=$Z$F
D
E "$Z" D E$B
. ./L
case $D in a)T X+=1;;d)T X-=1;;s)T Y-=1;;*)T Y+=1;;esac g$X $Y case$F in
\ |:)p $X$Y O
L="$L$X $Y" case$F in
:)W I+=1
J
x=r 39
y=r 19
g $x$y
[ "$F" = \ ]&&{ p$x $y : break } D T B+=1;;*)set$L
p $1$2 \
shift 2
L=$@;;esac;;*).;; esac D& while read -sn1 K J E D=$K>L
D
• Does this actually work? if the snake is going to the right and you press a it stops. Weird. Apr 20 '14 at 14:59
• Yes, because you bite yourself - thats the way it must be IMHO. We discussed that internally and everybody agrees on this. Apr 20 '14 at 15:31
• echo -n is definitely not portable. If the first operand is -n, or if any of the operands contain a backslash ( '\' ) character, the results are implementation-defined. Using echo for anything other than literal text without any switches is not portable. pubs.opengroup.org/onlinepubs/009604599/utilities/echo.html Apr 20 '14 at 18:57
• nyuszika7h: any idea how to circument this? Apr 20 '14 at 20:53
• nyuszika7h: i found a way to remove the main 'echo -n' call - so there is only one call left. it's calling the escape-sequence for 'go to home-position (0,0)' Apr 22 '14 at 14:07
### C# .NET Framework 4.7.2 Console (2,4562,4402,4242,4082,0521,9731,747 1,686 bytes)
This was fun, but I really had to think what variables were what, because they are only one letter.
using m=System.Console;using System;using System.Collections.Generic;using System.Threading;class s{static void Main(){m.CursorVisible=0>1;new s()._();}int l;Action<string> w=(x)=>m.Write(x);Action<int,int>n=(x,y)=>m.SetCursorPosition(x,y);(int x,int y)d,c,a;int h,u;List<(int x,int y)>p;void _(){while(1>0){f();h=25;u=25;p=new List<(int x,int y)>();l=0;d=(0,-1);c=(u/2,h/2);e();m.SetWindowSize(u+4,h+4);m.SetBufferSize(u+4,h+4);while(1>0){k();if(t())break;g();r();}f();m.SetWindowSize(u+4,h+6);m.SetBufferSize(u+4,h+6);n(1,h+3);w(" Game over,\n press any key to retry.");f();m.ReadKey(1>0);m.Clear();}}private bool t(){if(c.x<0||c.y<0||c.x>=u||c.y>=h){r();n(c.x+2,c.y+2);w("X");return 1>0;}for(i=0;i<p.Count;i++){for(int j=0;j<i;j++){if(p[i].x==p[j].x&&p[i].y==p[j].y){r();n(c.x+2,c.y+2);w("X");return 1>0;}}}return 0>1;}private void e(){a=(z.Next(u),z.Next(h));l++;}void f(){while(m.KeyAvailable)m.ReadKey(1>0);}int i;void k(){var b=DateTime.Now;while((DateTime.Now-b).TotalMilliseconds<230)Thread.Sleep(10);if(!m.KeyAvailable)return;var a=m.ReadKey(1>0).Key;switch(a){case ConsoleKey.A:if(d.x==0)d=(-1,0);break;case ConsoleKey.W:if(d.y==0)d=(0,-1);break;case ConsoleKey.S:if(d.y==0)d=(0,1);break;case ConsoleKey.D:if(d.x==0)d=(1,0);break;}f();}void g(){c.x+=d.x;c.y+=d.y;p.Add((c.x,c.y));while(p.Count>l)p.RemoveAt(0);if(c.x==a.x&&c.y==a.y)e();}void r(){n(1,1);w("/");w(new string('-',u));w("\\");n(1,h+2);w("\\");w(new string('-',u));w("/");for(i=0;i<h;i++){n(1,i+2);w("|");n(u+2,i+2);w("|");}for(i=0;i<h;i++){for(int j=0;j<u;j++){n(i+2,j+2);w(" ");}}n(a.x+2,a.y+2);w("@");for(i=0;i<p.Count;i++){n(p[i].x+2,p[i].y+2);w("#");}n(2,0);w("Score:"+l);}Random z=new Random();}
Some screenshots:
<no longer have binaries, you can compile yourself>
• Console.Write("Score:"+l);Console.WriteLine() -> Console.WriteLine("Score:"+l) Jun 16 '19 at 5:43
• Have you tried tuples as in (int X,int Y)d; ...; d=(0,-1)? That might save bytes. I also can't see why are you doing Vector2 d;Vector2 c;Vector2 a; instead of Vector2 d,c,a. I think you can also store the Console.SetCursorPosition function as a Action<...> single-letter variable. You can subtract DateTime with the - operator. You can also declare loop variables globally and simply zero them out when needed, without declaring them. Jun 16 '19 at 6:30
• [suggestions continue] You can use 1>0 or store true in a variable instead of using the keyword. You might be able to use the glorious --> operator in the loops. In the DateTime b = DateTime.Now part, b can be var. You might or might not be able to save some bytes using dynamic (often lets you merge differently-typed declarations). Jun 16 '19 at 6:41
• Pulling m.write(String) into it's own one-letter long function would probably save a ton Jul 8 '19 at 16:11
• There's also a few blocks that use b.width and b.height a lot that could probably be saved to another 1 letter-named local var Jul 8 '19 at 16:20
# Applesoft Basic - 478 (462)
This was my first ever code golf, but it was written back in 1989, and it mostly implements the snake game as requested (but without food, the snakes just continuously grow, and it's actually two players, not one) using only two lines of Applesoft Basic.
There were a number of two-line program contests at the time, such as in Dr. Dobbs journal. I spent 6 months figuring out how to fit this into two lines which have a limit of 255 characters (and only one branch)
The program typed in is exactly two lines:
1ONSCRN(X,Y)<>7ANDB<>0ANDSCRN(U,V)<>7GOTO2:HOME:GR:X=10:Y=20:U=30:V=Y:I=201:J=202:K=203:M=205:W=215:A=193:S=211:Z=218:O=1:Q=-1:P=49152:COLOR=7:HLIN0,39AT0:HLIN0,39AT39:VLIN0,39AT0:VLIN0,39AT39:VTAB22: ?"WASZ IJKM "C:ONB=0GOTO2:CALL-678:RUN
2PLOTX,Y:PLOTU,V:B=PEEK(P):G=B<>ZANDB<>W:H=B<>AANDB<>S:O=G*(O*H+(B=S)-(B=A)):L=H*(L*G+(B=Z)-(B=W)):G=B<>IANDB<>M:H=B<>JANDB<>K:Q=G*(Q*H+(B=K)-(B=J)):R=H*(R*G+(B=M)-(B=I)):X=X+O:Y=Y+L:U=U+Q:V=V+R:FORN=1TO99:NEXT:C=C+1:VTAB22:HTAB12:?C:GOTO1
The listing when formatted looks like this:
1 ONSCRN(X,Y)<>7 AND B<>0 AND SCRN(U,V) <> 7 GOTO 2: HOME : GR :
X=10 : Y=20 : U=30 : V=Y : I=201 : J=202 : K=203 : M=205 : W=215 :
A=193 : S=211 : Z=218 : O=1 : Q=-1 : P=49152 : COLOR=7 : HLIN 0,39
AT 0 : HLIN 0,39 AT 39 : VLIN 0,39 AT 0 : VLIN 0,39 AT 39 : VTAB 22 :
? "WASZ IJKM "C : ON B=0 GOTO 2 : CALL -678 : RUN
2 PLOT X,Y : PLOT U,V : B=PEEK(P) : G= B<>Z AND B<>W: H=B<>A AND B<>S :
O=G*(O*H+(B=S)-(B=A)) : L=H*(L*G+(B=Z)-(B=W)) : G=B<>I AND B<>M :
H=B<>J AND B<>K : Q=G*(Q*H+(B=K)-(B=J)) : R=H*(R*G+(B=M)-(B=I)) :
X=X+O : Y=Y+L : U=U+Q : V=V+R : FOR N=1 TO 99 : NEXT : C=C+1 :
VTAB 22 : HTAB 12 : ? C : GOTO 1
The game is actually two players and includes "instructions" at the bottom of the page showing the keys as well as a counter so you can see how many steps you survived. It's 478 characters, 16 of those are the instructions and counter output, so 462 if you want to shave those off.
• As described, this sounds more like the Tron light cycles mini game than the snake game. Apr 20 at 3:11
• Yes, the Tron Light Cycles game is essentially 2 player snake. That's true. Apr 22 at 15:04
Ruby 1.9 /Windows only/ (354 337 355 346 bytes)
require'Win32API';G=(W=Win32API).new g="crtdll","_getch",t=[],?I
B=(c=?#*39+h="#
#")+((S=' ')*38+h)*20+c;n=proc{c while B[c=rand(800)]!=S;B[c]=?*;S}
n[h=760];k={97=>-1,100=>1,119=>d=-41,115=>41}
(B[h]=?O;system'cls';$><<B<<$.;sleep 0.1
d=k[G.call]if W.new(g,"_kbhit",[],?I).call>0
t<<h;B[h]=?o;B[h+=d]==?*?B[h]=n[$.+=1]:B[t.shift]=S)while B[h]==S Plays in a 20x40 board in the windows console. The score is shown under the board. Use WASD to control the snake, any other key to exit (forcefully!). Edit the sleep time at the end of line 5 to control the speed. (Or save 10 characters and make it nearly unplayable by removing the sleep entirely!) Bonus feature: randomly fails to start (when initial piece is generated in snake's location). I needed ~100 chars to work around the lack of a non-blocking getchar. Apparently Ruby 1.9.3 includes a "io/console" library which would have saved roughly half of those. And this solution is Windows specific. There are published solutions to do the same type of thing in *nix systems, but I haven't tested them to compare the character count. Edit: Had to add 18 bytes after I realized that the tail only grows after eating, not after each step. Edit 2: (Possibly) fixed crash issue, saved the 9 bytes by restricting to one food item. • I like the idea of multiple food items at once, however there is a big problem: the tail should move with the player, only growing by one character for every piece of food you collect. Jan 5 '12 at 23:08 • You added the comment while I was working on fixing it... If there is only supposed to be one piece, I can remove the 9.times{}, saving 9 chars. Jan 5 '12 at 23:43 • the only requirement is that there be 1 or more piece of food at a time, so yes you could just make it 1 piece at a time, saving some characters Jan 5 '12 at 23:49 • the game randomly crashed on me at ~140 points, not sure why. but otherwise very nice Jan 6 '12 at 2:32 • Fixed the crash, I think. If it crashes again, please let me know the ruby error message. Jan 28 '12 at 0:47 # Python 3 - 644 from curses import * import time from collections import deque from random import randrange as R N,W,S,E=z=119,97,115,100 t=tuple u=0,0 def m(s): a=lambda o,y,x:y.addch(o[0],o[1],x);q=lambda:(R(L-2),R(C-2));L,C=s.getmaxyx();curs_set(0);s.nodelay(1);s.border();s.refresh();r=newwin(L-2,C-2,1,1);n=deque();y,x=[L-2,0];d=N;n.append(u);c=N;p=q();a(p,r,N);a(u,s,48) while 1: if c in z:d=c if d==N:y-=1 if d==S:y+=1 if d==W:x-=1 if d==E:x+=1 l=n.pop() if (y,x) in n:return if (y,x)==p:p=q();a(p,r,N);n.append(l);s.addstr(0,0,str(len(n))) n.appendleft((y,x));a((y,x),r,S);a(l,r,32);r.refresh();time.sleep(.2);c=s.getch() wrapper(m) Does not quit cleanly. Piece might disappear if it spawns on top of the snake. # TI-Basic, 307 bytes This one is very special to me, since I learned to program with a similar snake game on my TI-83+ (in high school, during boring classes). Also, on these calculators, golfing the programs was a real concern because of the limited space and performance The controls are the direction keys, but they could easily be changed for awsd (although noone would want that since it's an abc layout) codes for the keys would be: A: 41, W: 85, S: 81, D: 51 ClrHome 99→dim(ʟX ʟX→Y {8,16→dim([A] For(X,1,16 For(Y,1,8 If X=1 or X=16 or Y=1 or Y=16 Then Output(Y,X,": 1→[A](Y,X End:End:End 8→X:7→Y:-1→V Repeat [A](Y,X 1+I(I<99→I Y→ʟY(I X→ʟX(I Output(Y,X,0 1→[A](Y,X If X=N and Y=O or not(N Then Repeat not([A](O,N randInt(2,7→O randInt(2,15→N End Output(O,N,1 Output(1,1,S S+1→S Else 1+J(J<99→J ʟY(J Output(Ans,ʟX(J)," 0→[A](Ans,ʟX(J End getKey→G not(G)U+(G=26)-(G=24→U not(G)V+(G=34)-(G=25→V X+U→X:Y+V→Y End ## Bash (too many characters: ca. 1522) t=tput tc="$t cup"
tr="$t rev" ts="$t sgr0"
ox=5
oy=5
((w=$($t cols)-2-2*ox))
((h=$($t lines)-2-2*oy))
trap "$t rmcup stty echo echo 'Thanks for playing snake!' " EXIT$t smcup
$t civis stty -echo clear printf -v hs %$((w+2))s
printf -v v "|%${w}s|"$tc $oy$ox
printf %s ${hs// /_} for((i=1;i<=h+1;++i)); do$tc $((oy+i))$ox
printf %s "$v" done$tc $((oy+h+2))$ox
printf %s ${hs// /¯} dx=0 dy=-1 hx=$((w/2))
hy=$((h-2)) l=2 xa=($hx $hx) ya=($hy $((hy+1)))$tr
for((i=0;i<${#xa[@]};++i)); do$tc $((ya[i]+1+oy))$((xa[i]+1+ox))
printf \
done
$ts print_food() {$tc $((fy+1+oy))$((fx+1+ox))
printf "*"
}
nf() {
rf=1
while((rf))
do
rf=0
((fx=RANDOM%w))
((fy=RANDOM%h))
for ((i=0;i<${#ya[@]};++i)) do if((ya[i]==fy&&xa[i]==fx)) then rf=1 break fi done done print_food } nf ps() { s="SCORE:$l"
$tc$((oy-1)) $((ox+(w-${#s})/2))
printf "$s" } ps while : do read -t 0.2 -s -n1 k if (($?==0))
then
case $k in w|W)((dy==0))&&{ dx=0;dy=-1;};; a|A)((dx==0))&&{ dx=-1;dy=0;};; s|S)((dy==0))&&{ dx=0;dy=1;};; d|D)((dx==0))&&{ dx=1; dy=0;};; q|Q)break;; esac fi ((hx=${xa[0]}+dx))
((hy=${ya[0]}+dy)) if((hx<0||hy<0||hx>w||hy>h)) then go=1 break fi for((i=1;i<${#ya[@]}-1;++i))
do
if((hx==xa[i]&&hy==ya[i]))
then
go=1
break 2
fi
done
$tc$((ya[-1]+1+oy)) $((xa[-1]+1+ox)) printf \$tr
$tc$((hy+1+oy)) $((hx+1+ox)) printf \$ts
if((hx==fx&&hy==fy))
then
((++l))
ps
nf
else
ya=(${ya[@]::${#ya[@]}-1})
xa=(${xa[@]::${#xa[@]}-1})
fi
ya=($hy${ya[@]})
xa=($hx${xa[@]})
done
if((go))
then
\$tc 3 3
echo GAME OVER
fi
# Binary - 617 274 Bytes
Base 64:
jtiO0LgAuI7AMf+50Ae4IAJg86u4//+5JgC/qALzq7kRAKtguSkAMcDzq7j//6thgceeAOLsuSYAv0oN86
gD0gdYCqT2AGHgeJ6UG+GH0B7on3R0f986T8B2FXiT4YfYD8AXQJi74YfbAgquskRUW/MAKDBhR9AaEUfb
MK9vOGxAQwqoPvA4jgMOQIwHXu6AQAX+l0/2Bmuf//AABm9/G5///38YnXgef/D4H/gAJ95on6g8Iog+oo
g/ooffiD+hJ91IHH0wDB5wImgD0JdMewB6phww==
Hex:
d88ed08e00b88eb831c0b9ff07d020b86002abf3ffb8b9ff0026a8bff302b9ab001160ab29b93100f3
c0b8abffff61abc781009eece226b9bf000d4aabf38961bdcf00068ce8e40024603c7f74483c1c744b
3c13744d3c0a755081eca0c7eb00830e04c709ebef83eb048104a0efb00026093d800f07c494067480
26203d80754faa0660071ee989be417d18ee01f7894747f3fdfca461078957183e807d01fc0974be8b
7d1820b0ebaa4524bf45023006837d14a1017d140ab3f3f6c486300483aa03efe088e430c008ee7504
e85f0074e960ffb966ffff0000f766b9f1fffff1f7d789e7810fffff810280e67dfa89c283832828ea
For a cleaner graphic, you should run cls before running the .com.
You should use the command cycles 1 if you want the game to be playable
|
{}
|
# If $a+b+c=\pi$ and $\cot t=\cot a+\cot b+\cot c$, show $\sin^3t=\sin(a-t)\sin(b-t)\sin(c-t)$
I have a problem from a mathematics book:
If $$\alpha + \beta +\gamma = \pi \tag{1}$$ and $$\cot \theta = \cot\alpha + \cot \beta + \cot \gamma, 0 < \theta < \frac{\pi}{2}\tag{2}$$ show that $$\sin^{3}\theta = \sin(\alpha - \theta)\sin(\beta - \theta)\sin(\gamma - \theta)\tag{3}$$
The only way I can think of doing this is by using brute force (multiplying out all the terms on the right of equation (3) ). There must be some solution to this that is not as complicated. I have tried using the identity that if $$\alpha + \beta +\gamma = \pi$$ then $$\tan\alpha+\tan\beta+\tan\gamma=\tan\alpha\tan\beta\tan\gamma$$, but it does not fit as (2) uses cotangents instead of tangents.
Somehow, the $$\alpha$$, $$\beta$$ and $$\gamma$$ all disappear in (3). My question is: how can I solve this, and is there any way other than brute force to solve this?
This is the Brocard angle of a triangle, conventionally denoted by $$\omega$$ rather than $$\theta$$.
Anyway, by expanding the compound angle formula for sine, you get \begin{align*} \frac{\sin(\alpha-\theta)}{\sin\theta}&=\frac{\sin\alpha\cos\theta-\cos\alpha\sin\theta}{\sin\theta}\\ &=\sin\alpha(\cot\theta-\cot\alpha)\\ &=\sin\alpha(\cot\beta+\cot\gamma)\\ &=\sin\alpha\cdot\frac{\cos\beta\sin\gamma+\sin\beta\cos\gamma}{\sin\beta\sin\gamma}\\ &=\frac{\sin\alpha}{\sin\beta\sin\gamma}\cdot(\cos\beta\sin\gamma+\sin\beta\cos\gamma)\\ &=\frac{\sin\alpha}{\sin\beta\sin\gamma}\cdot\sin(\beta+\gamma)\\ &=\frac{\sin^2\alpha}{\sin\beta\sin\gamma} \end{align*} and similar. So taking their product gives equation (3).
|
{}
|
You can use the Negative Binomial Distribution Calculator to calculate the value of the negative binomial distribution. The form of the negative binomial distribution depends on the probability of success of p. The calculator will help you determine the probability of taking n attempts to achieve a fixed number of successes. We will also explain how our negative binomial distribution calculator works.
The basic assumption of the binomial distribution is that there is a finite number of n independent experiments in which the result is “success” or “failure”. The probability of “success” is p and is the same for all experiments. The probability of failures is 1-p. In statistics, the binomial distribution model is used for dichotomous variables. The data type could be correct – incorrect, men – women, etc.
On our site, you can find other posts in the field of health, sports, mathematics, or finance. Using them, you can get answers to the questions of how to perform a binomial multiplication operation or what is the exponential probability distribution? On the other hand, calculate mean value, with this Mean Calculator.
What is negative binomial distribution?
In the beginning, we need to clarify the meaning of binomial distribution. This term refers to the probability distribution. It considers that a particular value will take one of the independent values according to the selected parameters or assumptions. Accordingly, the assumptions of this type of distribution are one result for each attempt.
Also, every test attempt has an equal probability of succeeding. Each of the tested trials does not depend on the other. You can apply this method in statistics, known as discrete distribution. As such, it has only two possible states, success or failure.
On the other hand, we also distinguish negative binomial distribution. It refers to the probability of trials that must occur in order to achieve a predetermined number of successes. You can also know the negative binomial distribution under the name Pascal distribution.
Additionally, this method involves a series of consecutive events. These events have a fixed probability of success. In the situation of negative binomial distributions, things are a little bit different. The value of the random variable represents the number of tried attempts to achieve r success.
The binomial distribution contains a fixed number of attempts (n) and the value of a random variable for the number of successes (x). Possible values in the binomial distribution are 0 ≤ X ≤ n. In the case of a negative binomial distribution, you can have a fixed number of successes denoted by r and a random variable Y the number of attempts to r-th achieved success. Given the known elements, the possible values are Y ≥ r.
The negative binomial distribution formula
Specifically, the most common logical error in statistics is an unrepresentative sample in the test. A representative sample in statistics is one that well represents the population to which it belongs, and is best achieved by random selection of members.
Probability is the quantification of expectations that an event will happen. We can express probability by a number between 0 and 1, where 0 indicates impossibility and 1 indicates security.
The formula for calculating the negative binomial distribution has the following mathematical appearance and can calculate a probability mass function of one success:
P (Y=n) = \;<em>_{n-1}\textrm{C} \:<em>_{r-1}\cdot p^{r}\cdot (1-p)^{n-r}
Accordingly, the equation has the following meanings:
• n refers to the total value of the attempt (events)
• r denotes the total number of successes
• p refers to the probability of one success
• the expression (n-1)C(r-1) represents the value of the number of combinations using the values (n-1) and (r-1)
• the part of formula P(Y = n) represents the probability of the accuracy of the number of n attempts you need to make to achieve the r number of successes.
Negative binomial distribution example
The following example will explain how you can use our calculator. It contains four empty fields with the exact values needed to enter. Finally, the calculator will do the calculations for you and view the results obtained using the formula.
We will assume that you are dealing with the distribution of brochures on the street. The goal is to split all 17 brochures you have.
• Firstly, you need to enter the number of brochures in the empty field on the calculator that requires success (r). We will further assume that it took you 23 attempts.
• Secondly, you need to enter the values in the events field (n).
• Also, to get to the value finale in the right way, you need the probability that some person will take that brochure. In this case, the possibility has a value of 0.4, which you should enter into the calculator.
• Finaly, in the advanced mode of the calculator, you can see the amount of the value of the combinations. It will be 74,613.
After entering all the values in the calculator by following the mathematical expression for the formula, you can get the following results:
P (Y=23) = 0.000598056
To sum up, we can mention some examples of negative binomial distribution from everyday life. If you want to know how many times you need to roll the dice to get the number 6 in a row, you can find out by using our tool. Also, it is possible to find out how many times it takes to toss a coin to get five times the head.
Negative binomial distribution graph
The graph shows an example of a negative binomial distribution. You can see the P (X = n) and probability values on the vertical axis. The horizontal axis shows the values of the random variable by the number of attempts. Since this is a negative binomial distribution, we are talking about a type of geometric distribution. This means that the number of attempts to achieve the first success is a geometric distribution.
This value of the random variable attempt has a certain value of probability P (X = 1), P (X = 2), etc. Therefore, the value of the negative binomial distribution is equal to the geometric distribution if the value of “r” = 1. It is important to mention the so-called control parameters r and p. If the value of the parameter r changes and the control parameter p is fixed, the distribution tail becomes larger.
Instead of the term probability distribution, the term probability mass function or probability function is often used. Additionally, you can write more simply the formula for the probability mass function of the distribution with negative numbers.
FAQ
How can we represent the negative binomial distribution in statistics?
The negative binomial distribution represents the number of successes of a series of independently distributed Bernoulli attempts, provided that a random number of failures has not occurred before.
Where can you use negative binomial distribution?
You can use it as a measure to describe the distribution of data, such as the number of bacteria in a blood sample, so you can tell if it is a contagious distribution.
What is the number of attempts?
Let’s take the example of throwing a coin. Count the number of revolutions of the coin until it falls on the side of the head. If we toss a coin ten times, the number 10 is the number of attempts.
What is the number of successes?
Success is equal to the number of attempts classified as successful. Following a negative binomial distribution, each experiment can have success or failure.
|
{}
|
# User:Michiexile/MATH198/Lecture 3
IMPORTANT NOTE: THESE NOTES ARE STILL UNDER DEVELOPMENT. PLEASE WAIT UNTIL AFTER THE LECTURE WITH HANDING ANYTHING IN, OR TREATING THE NOTES AS READY TO READ.
## Contents
### 1 Functors
We've spent quite a bit of time talking about categories, and special entities in them - morphisms and objects, and special kinds of them, and properties we can find.
And one of the main messages visible so far is that as soon as we have an algebraic structure, and homomorphisms, this forms a category. More importantly, many algebraic structures, and algebraic theories, can be captured by studying the structure of the category they form.
So obviously, in order to understand Category Theory, one key will be to understand homomorphisms between categories.
#### 1.1 Homomorphisms of categories
A category is a graph, so a homomorphism of a category should be a homomorphism of a graph that respect the extra structure. Thus, we are led to the definition:
Definition A functor $F:C\to D$ from a category C to a category D is a graph homomorphism F0,F1 between the underlying graphs such that for every object $X\in C_0$:
• $F_1(1_X) = 1_{F_0(X)}$
• F1(gf) = F1(g)F1(f)
Note: We shall consistently use F in place of F0 and F1. The context should be able to tell you whether you are mapping an object or a morphism at any given moment.
##### 1.1.1 Examples and non-examples
• Monoid homomorphisms
• Monotone functions between posets
• Pick a basis for every vectorspace, send $V\mapsto\dim V$ and $f:V\to W$ to the matrix representing that morphism in the chosen bases.
#### 1.2 Interpreting functors in Haskell
One example of particular interest to us is the category Hask. A functor in Hask is something that takes a type, and returns a new type. Not only that, we also require that it takes arrows and return new arrows. So let's pick all this apart for a minute or two.
Taking a type and returning a type means that you are really building a polymorphic type class: you have a family of types parametrized by some type variable. For each type
a
, the functor dataFa = ... will produce a new type,
F a
. This, really, is all we need to reflect the action of F0. The action of F1 in turn is recovered by requiring the parametrized type
F a
to implement the
Functor
typeclass. This typeclass requires you to implement a function
fmap::(a -> b) -> F a -> F b
. This function, as the signature indicates, takes a function
f :: a -> b
and returns a new function
fmap f :: F a -> F b
.
The rules we expect a Functor to obey seem obvious: translating from the categorical intuition we arrive at the rules
• fmap id = id
and
• fmap (g . f) = fmap g . fmap f
Now, the real power of a
Functor
still isn't obvious with this viewpoint. The real power comes in approaching it less categorically. A Haskell functor is a polymorphic type. In a way, it is an prototypical polymorphic type. We have some type, and we change it, in a meaningful way. And the existence of the
Functor
typeclass demands of us that we find a way to translate function applications into the
Functor
image. We can certainly define a boring Functor, such as
data Boring a = Boring
instance Functor Boring where
fmap f = const Boring
but this is not particularly useful. Almost all
Functor
instances will take your type and include it into something different, something useful. And it does this in a way that allows you to lift functions acting on the type it contains, so that they transform them in their container. And the choice of words here is deliberate. Functors can be thought of as data containers, their parameters declaring what they contain, and the
fmap
implementation allowing access to the contents. Lists, trees with node values, trees with leaf values,
Maybe
,
Either
all are
Functor
s in obvious manners.
data List a = Nil | Cons a (List a)
instance Functor List where
fmap f Nil = Nil
fmap f (Cons x lst) = Cons (f x) (fmap f lst)
data Maybe a = Nothing | Just a
instance Functor Maybe where
fmap f Nothing = Nothing
fmap f (Just x) = Just (f x)
data Either b a = Left b | Right a
instance Functor (Either b) where
fmap f (Left x) = Left x
fmap f (Right y) = Right (f y)
data LeafTree a = Leaf a | Node [LeafTree a]
instance Functor LeafTree where
fmap f (Node subtrees) = Node (map (fmap f) subtrees)
fmap f (Leaf x) = Leaf (f x)
data NodeTree a = Leaf | Node a [NodeTree a]
instance Functor NodeTree where
fmap f Leaf = Leaf
fmap f (Node x subtrees) = Node (f x) (map (fmap f) subtrees)
### 2 The category of categories
We define a category Cat by setting objects to be all small categories, and arrows to be all functors between them. Being graph homomorphisms, functors compose, their composition fulfills all requirements on forming a category. It is sometimes useful to argue about a category CAT of all small and most large categories. The issue here is that allowing $CAT\in CAT_0$ opens up for set-theoretical paradoxes.
#### 2.1 Isomorphisms in Cat and equivalences of categories
The definition of an isomorphism holds as is in Cat. However, isomorphisms of categories are too restrictive a concept.
To see this, recall the category Monoid, where each object is a monoid, and each arrow is a monoid homomorphism. We can form a one-object category out of each monoid, and the method to do this is functorial - i.e. does the right thing to arrows to make the whole process a functor.
Specifically, if $h:M\to N$ is a monoid homomorphism, we create a new functor $C(h):C(M)\to C(N)$ by setting C(h)[0]( * ) = * and C(h)[1](m) = h(m). This creates a functor from Monoid to Cat. The domain can be further restricted to a full subcategory OOC of Cat, consisting of all the 1-object categories. We can also define a functor $U:OOC\to Monoid$ by U(C) = C[1] with the monoidal structure on U(C) given by the composition in C. For an arrow $F:A\to B$ we define U(F) = F[1].
These functors take a monoid, builds a one-object category, and hits all of them; and takes a one-object category and builds a monoid. Both functors respect the monoidal structures - yet these are not an isomorphism pair. The clou here is that our construction of C(M) from M requires us to choose something for the one object of the category. And choosing different objects gives us different categories.
Thus, the composition CU is not the identity; there is no guarantee that we will pick the object we started with in the construction in C. Nevertheless, we would be inclined to regard the categories Monoid and OOC as essentially the same. The solution is to introduce a different kind of sameness: Definition A functor $F:C\to D$ is an equivalence of categories if there is a functor $G:D\to C$ and:
• A family $u_C:C\to G(F(C))$ of isomorphisms in C indexed by the objects of C, such that for every arrow $f:C\to C': G(F(f)) = u_{C'}\circ f\circ u_C^{-1}$.
• A family $u_D:D\to F(G(D))$ of isomorphisms in D indexed by the objects of D, such that for every arrow $f:D\to D': F(G(f)) = u_{D'}\circ f\circ u_D^{-1}$.
The functor G in the definition is called a pseudo-inverse of F.
#### 2.2 Natural transformations
The families of morphisms required in the definition of an equivalence show up in more places. Suppose we have two functors $F:A\to B$ and $G:A\to B$. Definition A natural transformation $\alpha:F\to G$ is a family of arrows $\alpha a:F(a)\to G(a)$ indexed by the objects of A such that for any arrow $s:a\to b$ in $G(s)\circ\alpha a = \alpha b\circ F(s)$ (draw diagram)
The commutativity of the corresponding diagram is called the naturality condition on α, and the arrow αa is called the component of the natural transformation α at the object a.
Given two natural transformations $\alpha: F\to G$ and $\beta: G\to H$, we can define a composition $\beta\circ\alpha$ componentwise as $(\beta\circ\alpha)(a) = \beta a \circ \alpha a$.
Proposition The composite of two natural transformations is also a natural transformation.
Proposition Given two categories C,D the collection of all functors $C\to D$ form a category Func(C,D) with objects functors and morphisms natural transformations between these functors.
### 3 Properties of functors
The process of forming homsets within a category C gives, for any object A, two different functors Hom(A, − ): $X\mapsto Hom(A,X)$ and $Hom(-,A): X\mapsto Hom(X,A)$. Functoriality for Hom(A, − ) is easy: Hom(A,f) is the map that takes some $g:A\to X$ and transforms it into $fg:A\to Y$.
Functoriality for Hom( − ,A) is more involved. We can view this as a functor either from Cop, or as a different kind of functor. If we just work with Cop, then no additional definitions are needed - but we need an intuition for the dual categories.
Alternatively, we introduce a new concept of a contravariant functor. A contravariant functor $F:C\to D$ is some map of categories, just like a functor is, but such that F(1[X]) = 1[F(X)], as usual, but such that for a $f:A\to B$, the functor image is some $F(f):F(B)\to F(A)$, and the composition is F(gf) = F(f)F(g). The usual kind of functors are named covariant.
• Full
• Faithful
### 4 Applications for functors
• CS applications
• State machines and monoid actions
### 5 Homework
• * Recall that a category is called discrete if it has no arrows other than the identities. Show that a small category A is discrete if and only if every set function $A_0\to B_0$, for every small category B, is the object part of a unique functor $A\to B$. Analogously, we define a small category B to be indiscrete if for every small category A, every set function $A_0\to B_0$ is the object part of a unique functor $A\to B$. Characterise indiscrete categories by the objects and arrows they have.
• Show that the category of vectorspaces is equivalent to the category with objects integers and arrows matrices.
• Prove the propositions in the section on natural transformations.
• Prove that
listToMaybe :: [a] -> Maybe a
is a natural transformation from the list functor to the maybe functor. Is
catMaybes
a natural transformation? Between which functors? Find three more natural transformations defined in the standard Haskell library.
|
{}
|
# Do astronomers and astrophysicists more often use diameters or radii when discussing about planets, dwarf planets, exoplanets and stars?
Mathematicians much more often use radii over diameters when discussing about circles and spheres, because in mathematics the radius is more fundamental than the diameter (the sphere is defined using its radius).
But what about in astronomy? Do astronomers and astrophysicist more often use diameters or radii when characterizing planets, dwarf planets, exoplanets and stars?
• It depends on what you are going to do with it (and no, in mathematics the radius is not more fundamental than the diameter. It may get used more often because it is often the more convenient, but than does not make it more fundamental (whatever that might mean in this context)). – Conrad Turner May 18 '15 at 12:54
|
{}
|
, 21.06.2019 16:50 Jfhehwnxodin8398
# Consider circle h with a 3 centimeter radius. if the length of minor arc what is the measure of zrst?
### Another question on Mathematics
Mathematics, 21.06.2019 14:30
In trapezoid efgh, m∠gfe=63∘. identify m∠ghe. !
|
{}
|
# Do wet dreams invalidate the fast in Ramadan?
I feel a little embarrassed to ask this. I woke up and realized that I had a wet dream and I needed to perform ghusl (released semen). I did not have enough time to do ghusl so I prayed fajr (without performing ghusl) because there was only 10 mins before sunrise. This never happened to me before and I was really embarrassed. Is my fast valid despite this?
• The fast is valid but you need to perform ghusl as soon as possible. – Medi1Saif Jun 25 '16 at 21:03
• @Medi1Saif you are giving answer in comment section – nim Jul 1 '16 at 8:05
## 2 Answers
In The Name of Allah, The Most Beneficent, The Most Merciful.
Wet dreams during the day in Ramadan does not invalidate the fast because it is not intentional. The Qur'an says (interpretation of the meaning):
“Allaah burdens not a person beyond his scope” [Qur'an 2:286]
The Messenger of Allah said:
"Three things do not break the fast of the fasting person: Cupping, vomiting, and the wet dream." [Jami` at-Tirmidhi 719, grade : da'if.]
Yes because you didn't do it intentionally,
UNLESS you masturbate if that's what you mean "I needed to ghusl (release semen), then you have to make up your fast.
Don't be embarrassed its human nature
(do a proper ghusl and don't be worried if you don't pray on time all it matters if you pray, if you forget and remember do it on the spot. but it's always better to pray on time)
|
{}
|
# Stability and spatial adaptivity in high dimension
Moritz Jirak (University of Braunschweig)
Thiele Seminar
Monday, 12 March, 2018, at 14:15-15:00, in Aud. D2 (1531-119)
Description:
Given a $d$-dimensional process, we are interested in analysing its stability properties over the time horizon. The main objective is to find the anomalous single components, that is, the set of coordinates where the behaviour of the process changes significantly. Based on high-dimensional limit results, we obtain globally optimal tests and estimators.
In particular, we show that the usual price of $\sqrt{\log d}$ is unavoidable in general. We then proceed by showing that the power can be significantly improved by exploiting the underlying covariance structure, and that the minimax rate can generally be expressed in terms of certain quantiles. Corresponding tests and estimators can be constructed based on a bootstrap-procedure, adapting to the covariance structure. A key aspect that we exploit here is an interesting probabilistic feature of the quantiles, a quasi-exponential invariance in their significance level $\alpha$.
Organised by: The T.N. Thiele Centre
Contact person: Mark Podolskij
|
{}
|
Derivative of inverse secant
Homework Statement
The two graphs are possible legitimate representations of ##y=\sec^{-1}(x)##.
The derivative is positive on all the domain and so is graph A, but graph B has negative tangent when x<-1
Homework Equations
Derivative of inverse secant:
$$(\sec^{-1}(x))'=\frac{1}{x(\pm\sqrt{x^2-1})}$$
The Attempt at a Solution
The derivative was established on all the domain, so i think it must be positive. the slope must be pointing upwards on all the domain.
I don't know.
BvU
Homework Helper
Check the domain. figure B would be somewhat impractical.
figure B would be somewhat impractical.
Why? there is a 1 to 1 matching between x and y values. the picture is from a text book
BvU
Homework Helper
Since cos(x) is 1 to 1 on ##\ [0,\pi]\ ## I would expect the##\ \operatorname{asec}^{-1}\ ## to have the range ##\ [0,\pi]\ ## on the domain ##<-\infty,-1]\ \cup \ [1,\infty>\ ##.
Your derivative is correct only for ##x>1##.
Your derivative is correct only for ##\ x>1 \#.
For all x:
$$[\sec^{-1}(x)]'=\frac{1}{\lvert x \rvert \sqrt{x^2-1}}$$
Graph B is possible since:
I think they have a mistake, i don't see why "the later method has the disadvantage of failing to satisfy Eq. (10) when x is negative".
(10a) merely says:
$$y=\sec^{-1}(x)=\cos^{-1}\left( \frac{1}{x} \right)~\Rightarrow~x=\frac{1}{\cos(y)}$$
when -π<y<-π/2, meaning going clockwise and in the third quadrant, x<0, so ## x=\frac{1}{\cos(y)}## is true, so figure B is also correct.
Last edited:
vela
Staff Emeritus
Homework Helper
It's because, by definition, ##0 \le \cos^{-1} x \le \pi##. If ##\sec^{-1} x < 0##, then it can't possibly equal ##\cos^{-1} \frac 1x## which is non-negative.
It's only by definition if that's how you choose to define it. Plenty of old books define it differently so as to avoid the whole issue of artificially inserting the absolute value.
vela
Staff Emeritus
Homework Helper
It's only by definition if that's how you choose to define it. Plenty of old books define it differently so as to avoid the whole issue of artificially inserting the absolute value.
So what? Karol's question was about what the book claimed, and the book uses the standard definition of inverse cosine.
So what? Karol's question was about what the book claimed, and the book uses the standard definition of inverse cosine.
I'm not sure what you mean by "so what?" His question was not about the arccosine, it was about the arcsecant and there seems to be a notion in the responses that there is a correct way to define it, despite the fact that Karol posted an image with an alternative definition. There is no relationship between the choices of restriction for the arccosine and arcsecant. There are an infinite number of ways to define any of the six inverse trig functions. The way that it is usually defined in modern textbooks requires the artificial introduction of an absolute value in the derivation of the derivative of the arcsecant and it appears that that was the point of his original question. If you define it differently, which is perfectly arbitrary, you can avoid the entire issue of the absolute value if the derivative is negative for negative arguments and positive for positive arguments. If you choose the restriction such that the derivative is positive for both positive and negative values of the argument then you have to artificially introduce the absolute value and I have to spend 15 minutes of lecture explaining this every time I teach calc 1.
vela
Staff Emeritus
Homework Helper
He wrote, "I don't see why 'the later method has the disadvantage of failing to satisfy Eq. (10) when x is negative'." His question seems pretty clear to me.
He wrote, "I don't see why 'the later method has the disadvantage of failing to satisfy Eq. (10) when x is negative'." His question seems pretty clear to me.
But that wasn't his original question which, to me, still appears unanswered.
i don't understand why:
If ##\sec^{-1} x < 0##, then it can't possibly equal ##\cos^{-1} \frac 1x## which is non-negative.
What's the difference between ##~\sec^{-1}(x)~## and ##~\cos^{-1} \left( \frac 1x \right)##?
$$y=\sec^{-1}(x)~\Rightarrow~\sec(y)=\frac {1}{\cos(y)}=x,~~y=\cos^{-1} \left( \frac 1x \right)~\Rightarrow~\cos(y)=\frac {1}{x}$$
They are the same, and for:
$$y=\sec^{-1}(x)<0~\Rightarrow~-\frac{\pi}{2}<y<-\pi$$
If x<0, as the book claims there's a problem:
$$y=\cos^{-1} \left( \frac 1x \right)~\Rightarrow~\cos(y)=\frac 1x~\Rightarrow~\cos(y)<0~\Rightarrow~-\frac{\pi}{2}<y<-\pi$$
No contradiction, the y's are the same
vela
Staff Emeritus
Homework Helper
The statements ##y=\cos x## and ##x = \cos^{-1} y## are not equivalent. When you define a function, you always have to specify its domain and codomain. You're ignoring this fact, which is leading to your confusion.
The cosine function maps a real number to a real number in the interval [-1,1]. According to the conventional definition, the inverse cosine function maps [-1,1] to ##[0,\pi]##. If you happen to have an angle between 0 and ##\pi##, then it's true that ##\cos^{-1} \cos x = x##, but that relationship does not generally hold. For example, say ##x = 2\pi##. Then you have ##\cos x = 1## but ##\cos^{-1} 1 = 0 \ne x##. It's not correct to say ##\cos^{-1} 1 = 2\pi## because ##2\pi## isn't in the codomain of the inverse cosine function.
Of course, you can, as Alan noted, define the inverse cosine function differently so that ##\cos^{-1} 1 = 2\pi##, but then you can't say that ##\cos^{-1} 1 = 0##.
The statements ##y=\cos x## and ##x = \cos^{-1} y## are not equivalent. When you define a function, you always have to specify its domain and codomain. You're ignoring this fact, which is leading to your confusion.
The cosine function maps a real number to a real number in the interval [-1,1]. According to the conventional definition, the inverse cosine function maps [-1,1] to ##[0,\pi]##. If you happen to have an angle between 0 and ##\pi##, then it's true that ##\cos^{-1} \cos x = x##, but that relationship does not generally hold. For example, say ##x = 2\pi##. Then you have ##\cos x = 1## but ##\cos^{-1} 1 = 0 \ne x##. It's not correct to say ##\cos^{-1} 1 = 2\pi## because ##2\pi## isn't in the codomain of the inverse cosine function.
Of course, you can, as Alan noted, define the inverse cosine function differently so that ##\cos^{-1} 1 = 2\pi##, but then you can't say that ##\cos^{-1} 1 = 0##.
But how does it answer the question with what ##~\sec^{-1}(x)~## differss from ##~\cos^{-1} \left( \frac 1x \right)~## when x<0?
If it's about the codomain, then according to the pic in post #5 ##~\sec^{-1}(x)~## is between [o,π], as is ##~\cos^{-1} \left( \frac 1x \right)~##
And another thing. the absolute value in the derivative of ##~\sec^{-1}(x)~## isn't related to choice of codomain:
vela
Staff Emeritus
Homework Helper
If it's about the codomain, then according to the pic in post #5 ##~\sec^{-1}(x)~## is between [o,π], as is ##~\cos^{-1} \left( \frac 1x \right)~##
I don't know if you're trying to be obtuse or what. You asked about the following excerpt:
It clearly says the codomain of the alternate ##\sec^{-1} x## is NOT ##[0,\pi]##.
It clearly says the codomain of the alternate ##\sec^{-1} x## is NOT ##[0,\pi]##.
So ##~\sec^{-1}(x)\neq \cos^{-1}\left( \frac1x \right)## when x<0 and when ##~\sec^{-1}(x)~##'s codomain is between ##[-\pi,-\frac{\pi}{2}]## because ##~\cos^{-1}\left( \frac1x \right)##'s codomain is ##[0,\pi]##?
And why, when ##~\sec^{-1}(x)~##'s codomain is between ##[-\pi,-\frac{\pi}{2}]##, it has an advantage of simplifying the derivative of ##~\sec^{-1}(x)~##?
The derivative, as i showed in post #14, doesn't depend on anything and is always positive?
SammyS
Staff Emeritus
Homework Helper
Gold Member
So ##~\sec^{-1}(x)\neq \cos^{-1}\left( \frac1x \right)## when x<0 and when ##~\sec^{-1}(x)~##'s codomain is between ##[-\pi,-\frac{\pi}{2}]## because ##~\cos^{-1}\left( \frac1x \right)##'s codomain is ##[0,\pi]##?
To clarify your statement regarding the alternate definition of the sec-1 function, which has a codomain including the interval [-π, -π/2 ):
##\displaystyle \sec^{-1}(x)\neq \cos^{-1}\left( \frac1x \right) \ ## when ##\ x<0 \,,\ ## because in this case, ##\displaystyle\ -\pi \le \sec^{-1}(x) < -\frac{\pi}{2} \ ## while ##\displaystyle\ \frac{\pi}{2} < \cos^{-1}\left(\frac 1 x \right) < \pi \ ##
And why, when ##~\sec^{-1}(x)~##'s codomain is between ##[-\pi,-\frac{\pi}{2}]##, it has an advantage of simplifying the derivative of ##~\sec^{-1}(x)~##?
The derivative, as i showed in post #14, doesn't depend on anything and is always positive?
It seems that you have previously answered this in posts #1 and #5, if not elsewhere, however, the statement you have here is not correct.
The simplification to the derivative, of course, is that the absolute value is eliminated for the alternate definition, whereas for the definition with the standard codomain, the derivative is positive, regardless of the sign of x and this requires the use of the absolute value or some equivalent expression.
.
In the book:
I don't quite understand the d(-u), i think it says that the integral relates to the variable -u.
I guess the above line is because, for x>1:
$$\int \frac{dx}{x\sqrt{x^2-1}}=\sec^{-1}(x)$$
And for x<-1:
$$\int \frac{dx}{x\sqrt{x^2-1}}=\int \frac{d(-x)}{(-x)\sqrt{(-x)^2-1}} =\int \frac{d(-x)}{\lvert (-x)\rvert \sqrt{(-x)^2-1}} =\sec^{-1}(-x)$$
$$\left\{ \begin{array}{ll} \text{for}~x>1 & \sec^{-1}(x) \\ \text{for}~x<-1 &\sec^{-1}(-x) \end{array} \right.~\Rightarrow~\sec^{-1}\vert x \vert$$
I thank you all very much for your support
Karol
What is the meaning of:
$$\int \frac{d(-x)}{(-x)\sqrt{x^2-1}}~?,~\int f(-x)d(-x)~?,~d(-x)?$$
|
{}
|
$$\require{cancel}$$
# 2.2: Dynamics of Quantum State Vectors
## Time Dependence
We discussed the state vector $$\left|\;\Psi\;\right>$$ in terms of its infinite number of components in Hilbert space – one for every position on the $$x$$-axis, but so far we have not said anything about how or if this state vector changes with time. Given that the probability of finding the particle at a given position should be able to change with time, it only makes sense that the quantum state vector would be dynamic.
In this treatment of quantum mechanics, we do not incorporate special relativity, so time and space are not treated on an equal footing, which means that there is no "time component" of the quantum state vector in the Hilbert space, and we treat it as a vector that changes with time. The component of this vector parallel to the unit vector $$\left|\;x\;\right>$$ (i.e. the wave function) is therefore also a function of time:
$\left<\;x\;|\;\Psi\left(t\right)\;\right> = \psi\left(x,t\right)$
Similarly for momentum space:
$\left<\;k\;|\;\Psi\left(t\right)\;\right> = \phi\left(k,t\right)$
The question that now arises is, "What determines how the quantum state vector evolves over time?" While we will not be able to derive an exact answer to this, we can certainly motivate it. We know that macroscopically objects change momentum because of external influences – forces. Forces can be expressed as potential energies, so if we know what the full potential energy function $$V\left(x\right)$$ looks like, then we would expect it to have some say over the time evolution of the state vector. How exactly it does this is the subject of the next couple sections.
## Vector Space Operators
If we wish to change a regular vector, we have the following two options (or a combination of both):
shrink or expand its length – This is most easily accomplished by simply multiplying it by a scalar, but it is not the only way. Take, for example, the vector $$\widehat i$$ in two dimensions, represented by the usual matrix. Its length can be changed by multiplying it by a square matrix that is clearly not a simple scalar:
$\left[ \begin{array}{*{20}{c}} A & B \\ 0 & C \end{array}\right] \left[ \begin{array}{*{20}{c}} 1 \\ 0 \end{array}\right] = A \left[ \begin{array}{*{20}{c}} 1 \\ 0 \end{array}\right]$
Interestingly, this vector is expanded by an amount $$A$$ by this matrix regardless of the values of $$B$$ and $$C$$, which means there exist infinitely-many such square matrices that all have the same effect on the column matrix representing this unit vector. However, if we multiply this same square matrix by the column matrix representing the very same unit vector in a different basis, then the same result (just expanding the length) doesn't occur. If we want a square matrix that behaves this way (shrinks or expands a unit vector in every basis by the same amount), then it needs to be a scalar multiplied by the unit matrix:
$A\;I \leftrightarrow \left[ \begin{array}{*{20}{c}} A & 0 \\ 0 & A \end{array}\right]$
To distinguish this matrix from just the scalar $$A$$ (which has the same effect when it multiplies a vector), we call it a c-number.
change its direction (rotate it) – The rotation of a vector can be represented in matrix form using the rotation matrix. To rotate the vector counterclockwise (from the $$+x$$-axis toward the $$+y$$-axis by an angle $$\theta$$, use the square matrix:
$R\left(\theta\right) \leftrightarrow \left[ \begin{array}{*{20}{c}} \cos\theta & -\sin\theta \\ \sin\theta & \cos\theta\end{array}\right]$
It's easy to confirm that rotating $$\widehat i$$ by $$90^o$$ results in $$\widehat j$$. It's also left as an exercise to show that this rotation operation is precisely that – it only rotates a vector, it doesn't change its length at all.
While we have expressed these as matrix multiplications, it is important to keep in mind that matrices are only specific representations of these actions. The fundamental objects that have these effects on the abstract vectors themselves are called operators. So for example, the $$A\;I$$ above is a c-number operator, and $$R\left(\theta\right)$$ above is a rotation operator. Operators are what cause vectors to change, and they can be represented in many ways, depending upon the basis we want to work in.
It should also be noted that if we do two operations in succession on a vector, in general the order of these operations matters. In some special cases operators might commute, but this is not always the case, just as this is the case with matrices. If one or both of the operators is a c-number, then of course the operators will commute, though this is not a necessary condition for commutation. Indeed, the 'c' in "c-number" stands for "commuting."
## Hilbert Space Operators
For vectors in Hilbert space, the operators are not as simple as discrete square matrices, but they still have the same function – they change vectors into other vectors. The difference is that they have to be able to change an infinite continuum of components. The components of $$\left|\;\Psi\;\right>$$ in the position basis $$\left|\;x\;\right>$$ are the values of the wave function $$\psi\left(x\right)$$. Changing all of these values at the same time means that the wave function is changed to another function. This can be done in a number of ways. The first is simple multiplication. If we multiply the function $$\psi\left(x\right)$$ by another function $$\Omega\left(x\right)$$, then a whole new function is the result. A second way to change a function into another function is to perform one or more derivatives. And this is true in any basis, most notably in the position and momentum bases:
$\left|\;\widetilde\Psi\;\right> = \Omega \left|\;\Psi\;\right> \;\;\;\;\; \leftrightarrow \;\;\;\;\; \widetilde\psi\left(x\right) = \left\{ \begin{array}{*{20}{c}} \Omega\left(x\right)\psi\left(x\right) \\ or \\ \dfrac{d^n}{dx^n}\psi\left(x\right) \end{array} \right. \;\;,\;\;\;\;\; \widetilde\phi\left(k\right) = \left\{ \begin{array}{*{20}{c}} \Omega\left(k\right)\phi\left(k\right) \\ or \\ \dfrac{d^n}{dk^n}\phi\left(k\right) \end{array} \right.$
Of course, combinations of these also work, such as the sum of a function and a derivative.
## Time Evolution of a Quantum State
As was stated earlier, the time evolution of a quantum state vector must be determined by something we can define physically. We know from the discussion that followed that we effect change in a Hilbert space vector by operating on it with operators. We won't drag this out any further, since really what follows amounts to a postulate. We define the hamiltonian operator as the operator version of the total energy of the particle, which is the sum of the kinetic energy and potential energy operators:
$H \equiv KE + PE$
The time evolution of a quantum state is defined by how the hamiltonian affects the state vector, which is as follows:
$H \left|\;\Psi\;\right> = i\hbar \dfrac{\partial}{\partial t}\left|\;\Psi\;\right>$
This is known as Schrödinger's equation.
|
{}
|
# All Questions
2 views
### Value of counter from pgffor in a complex example
From this answer I learned how to print rows into 1 column table using pgffor: | 1 | | 2 | | 3 | Code looks like this: \documentclass{article} \usepackage[utf8]{inputenc} \usepackage{pgffor} \...
9 views
### pgfplot: 2D with line color depending on another value
I would like to create a 2 dimensional plot with several lines. One of the lines depends on additional values in third dimension. Now i'd like to make the line color of this "3d-line" depending on ...
14 views
### How to get the value of counter in pgffor while using \expandafter
I looked into this answer and tried to improve it. My goal is to get this table: | 1 | | 2 | | 3 | But instead I get this: | 1 | | 1 | | 1 | Code: \documentclass{article} \usepackage[utf8]{...
4 views
### latexdiff for IEEE trans using texstudio
Trying to use latexdiff for an IEEE paper, I got lots of errors for compiling it using Pdflatex. Any idea why? what is the best configuration of latexdiff. Note that the original documents was ...
11 views
### standalone not working with psfrag
I have the following MWE \documentclass{standalone} \usepackage{psfrag} \begin{document} text \end{document} I use latex and dvipdf. I have two machines with MacTex-2016. I've just updated with ...
14 views
### Defining different fonts for \title and \thanks in memoir
I wanted to change the font for the \title and \thanks. This can be done by adding the font in front of the text in whatever I want to change, e.g. \title{\sffamily{My Title}}. I guess there is a ...
14 views
### invoking mathtype from texsudio
Any idea how can I automatically invoke Mathtype from texstudio using macro (javascript) and put the formula back onto texstudio automatically. It can be done manually, but I want to know is it ...
41 views
### Represent pseudocode in tabular format
I want to write my pseudocode in the below tabular format. It seems that authors of above pseudocode have used some special latex package. Can anyone help me by either naming the package which has ...
7 views
### vertically center on beamer slide (excluding navigation)
I would like to center some content on a beamer frame that has navigation pane on top (theme Darmstadt). Currently I just pass the option c to the frame and it centers the content on the entire slide. ...
12 views
### Basic Random Number \pgf Question
In my attempt to learn random numbers, I basically copied the only line of code out of the TikZ/PGF Manual. But it does not compile. Why? p.s. I am a relative LaTeX/TikZ/programming newbie. \...
25 views
### Horizontal sections of a page
I want to divide a portrait A4 paper into three horizontal sections. I know I can use \mbox as I don't want any borders around these sections but the problem arises as I have an image which acts as ...
9 views
### How to place picture in three d
How do you add a 2 dimensional picture into a three dimensional drawing in asymptote? I have tried add(picture, triple), but it gives no output. import three; picture p; draw(p, (0,0)--(1,1)); ...
5 views
### splitbib: conflict between \SBresetdepth and export option?
I use the splitbib package to produce a publication list broken into sections for different kinds of publications. I want each section to begin numbering at 1. For this purpose splitbib provides the ...
22 views
### Unable to fix the bibliography. Bold question mark persists
I am unable to fix the bibliographical error. The bold question mark persists. Can you please help me understand what is going on? Although the problem of the bold question mark is common and widely ...
17 views
### Manual install of Biber-BibLaTeX on MacTex 2016
Due to compatibility issues with my template files, I have to use previous versions of Biber 2.3 and BibLaTeX 3.2 (MacTeX 2016), which I downloaded from source forge. But I have found no install ...
11 views
### Path Problems Again with El Cap 10.11.6?
Last year I updated my mac to El Capitan, and followed the instructions here to fix the path issues. It was easy! Today I updated to 10.11.6. The preferences in TeXMaker (my GUI of choice) reverted ...
18 views
### Using Greek Letters - Symbols in regular text (LyX)
I have been having trouble in writing Greek letters like: μ,α in regular text when using LyX. When I try to include the package "babel-greek" the programme does not compile the pdf file. I checked ...
21 views
### Adding numbered appendices as section in documentclass report
I'm writing a text using the documentclass report and I can't find a way to add appendices like this within the article class: \documentclass{article} \begin{document} \tableofcontents \section{First ...
17 views
### tabularx table formats poorly when too long
I have a long, multi-columned tabularx table in a document I'm working with. I'm finding that under certain circumstances the table's formatting breaks. My minimum working example (works with the ...
26 views
### trying to plot some nodes [duplicate]
hello all i need to:- make marked blue lines longer [ so i can put the multiplication-red-block their] i want to make h_5[n] more big i want to define a variable (xx for example) to make it enter ...
16 views
If you use a pdf-viewer to add comments to a pdf document, you do not modify the typesetting - of course. I would like to have the same behaviour using a command of the pdfcomment package (or other ...
26 views
### pgffor inside table [duplicate]
How can I use pgffor in tabular environment to output many rows? Here is what I tried: \documentclass{article} \usepackage[utf8]{inputenc} \usepackage{pgffor} \begin{document} %works correctly \...
29 views
### How to put a period between the chapter number and chapter title in the headings using scrrept, scrlayer-scrpage, and scrheadings?
By default, the headings with scrrept, scrlayer-scrpage, and scrheadings are of the form "«number» «title»" in the headings for numbered chapters. I am wishing to change it to "Chapter «number». «...
48 views
### Draw a wattmeter
How can I draw a wattmeter using LaTeX and circuitikz? I want to use the one with a big circle and W inside, and 4 circles (up, down, left right) which contain respectively 2 + and 2 -, Thank you ...
11 views
### Knitr: Referencing data from a figure later in the paper
I'm working with knitr Is it possible to reference data from a figure in the paper? I have a code chunk that produces a figure in the appendix of my paper. I know how to reference the figure itself ...
33 views
### How to get caption to line break in scrbook?
So I have a large project and one of the pictures is quite small, but has a very large caption. Currently the caption just extends into the page of text and all of the solutions I have seen for ...
20 views
### Customize article template in LyX
Lyx-2.2.0, article template and newbie in LyX and LaTeX. Planning to use LyX for office needs, like reports, letters, code listings etc. So I need to customize (create new template, based on default) ...
18 views
### Shuffling the first name and surname of authors in latex
I want to have my references as first and middle name initials and, surname. Instead, I am getting the opposite. My bibtex (.bib) library is ref and .bst is model4-names provided by Elsevier. is The ...
21 views
### Updating value for \graphicspath within document
I am familiar with \graphicspath and have used it in numerous papers where all of my figures are in a single directory. However, I am now working on a larger project and I have images hierarchically ...
25 views
### One side page in a two side document in Lyx
I am writing my thesis in a two sided document style. However I want the title page, certificate page and declaration page to be in a single sided format. How do I do this in LYX ? I used standard ...
122 views
### How to draw Block diagram like this in LaTeX?
I like to draw the following diagram: So far i succeed to draw the the following: \begin{tikzpicture}[ block/.style={draw, minimum width=10mm, minimum height=6mm}, sum/.style={circle, draw, ...
10 views
### texdiff summary statistics
I have old chapter .tex files that I have edited over months, and now I want to get metrics of how much I have changed the files. One option is texdiff, followed by a grep on DIF. How to create a &#...
95 views
### How can I know the number of expandafters when appending to a csname macro?
I am looking for an informative answer here. If I want to append to a macro, I have a couple of options, each depending on whether I want the items fully expanded, partially expanded (a certain number ...
24 views
### Map slide number to source file
Hy, guys! I prepared more than 160 beamer draft slides for a Course articulated in 10, three hour, classes. It is a draft version: I plan to change some portions in the next weeks. My source is ...
23 views
### First row of array is the first line
I want to code an array on which the first row would be the first line. I used the array environment. Here is what I get but it's not what I want (the line is centered on the second row). Here is ...
11 views
### Texmaker; some shortcuts don't work
For example, this shortcut on Texmaker 4.4.1-1.1 on Ubuntu 16.04 doesn't work: CTRL+F. Did I miss something? Because it's present in the keyboard shortcut list in the configuration options. Some ...
22 views
Exploring the site, I get only this method in order to replace the ugly "Content" by "Table of content" on the title: \renewcommand\contentsname{Table of Contents} Is there a package missing? \...
16 views
### Producing an a transducer directivity pattern with dB scale
Edit: Question updated to address comments from Willie Wong. The directiviy pattern now plots as I've added 90 to each value. I need the y-axis to read from -N to 0 dB where N will vary, however when ...
124 views
### Out of order numbering counter
I work in a department that writes requirement documents for our workflow. So, a product will have a document created before design that says: Req 1: product must do A Req 2: product must do B Req ...
42 views
### Why with XeLaTeX in TeXLive, is TeX Gyre Pagella Math font not found
I'm using TeXLive 2016 (under OS X). If I run XeLaTeX on the following file (which just modifies the distributed TeX Gyre file test-xelatex-texgyre_pagella_math.tex, I get error ... fontspec error: "...
21 views
### Argument of \addcontentsline has an extra }
I'm having trouble apparently with the \addcontentsline command: ! Argument of \addcontentsline has an extra }. <inserted text> \par l.157 \addcontentsline {toc}{section}{Introduction} Here's ...
25 views
### Pie graph with outside text
I constructed a pie chart based on a code I found on the internet and I already tried to make some changes because it's all messy and I wanted, when the percentags are too small (<3%) to have ...
22 views
### Trying to use reledmac with luatexja
I am using MikTeX 2.9, and trying to get the reledmac package working with luatexja. Both packages work fine if I try to use them on their own, but if I combine them I get the same error whether or ...
33 views
### converting latex project into ms word .docx
I am writing my history doctoral dissertation in LaTeX. I had been previously (PhD dissertation: templates vs scratch) convinced in this forum to take this path. I like LaTeX for its ease with ...
28 views
### Appendix in ToC
I have problem with appendix names at table of contents. I need to set font style to normal and colon after appendix name, like in the figure: (Liitteet=appendices, liite=attachment) With this code: ...
27 views
### Even and odd questions in grade table using ExSheets
I would like to create a grade table using the ExSheets package. Unfortunately the table is too long for the title page. Having tried other approaches (e.g. longtable-environment, resizebox and others)...
17 views
### vertical alignment two columns list
I am writing a highschool math textbook and i have a problem with lists. I want to split an itemize in 4 columns. The problem is that, if there math text like franction, I can't make items to be ...
21 views
### Plot 2D slice of a 3D field using pgfplots
I have data (a CSV file) from a discrete three-dimensional field (for instance, T(x,y,z), where x, y and z are discrete values) and would like to plot a slice of this field (for instance, T(x,y) for z=...
For instance $f_k$ converges to $f$ a.e.. (a.e.=almost everywhere). Which is the correct way to type this? 1) a.e.. 2) a.e. . 3) Or others? Thanks for any help.
|
{}
|
Introduction to PhenoPath In phenopath: Genomic trajectories with heterogeneous genetic and environmental backgrounds
knitr::opts_chunk$set(fig.width = 5, fig.height = 3) suppressPackageStartupMessages(library(dplyr)) suppressPackageStartupMessages(library(ggplot2)) suppressPackageStartupMessages(library(tidyr)) suppressPackageStartupMessages(library(forcats)) library(phenopath) Overview of PhenoPath The PhenoPath model PhenoPath models gene expression expression$y$in terms of a latent pathway score (pseudotime)$z$. Uniquely, the evolution of genes along the trajectory isn't common to each gene but can be perturbed by an additional sample-specific covariate$\beta$. For example, this could be the mutational status of each sample or a drug that each sample was exposed to. This software infers both the latent pathway scores$z_n$and interaction coefficients$\beta_{pg}$for samples$n = 1, \ldots, N$, covariates$p = 1, \ldots, P$and genes$G = 1, \ldots, G$. Mean-field variational inference Inference is performed using co-ordinate ascent mean field variational inference. This attempts to find a set of approximating distributions$q(\mathbf{\theta}) = \prod_i q_i(\theta_i)$for each variable$i$by minimising the KL divergence between the KL divergence between the variational distribution and the true posterior. For a good overview of variational inference see @blei2016variational. Example on simulated data Simulating data We can simulate data according to the PhenoPath model via a call to simulate_phenopath(): set.seed(123L) sim <- simulate_phenopath() This returns a list with four entries: print(str(sim)) • parameters is a data frame with the simulated parameters, with a column for each of the parameters$\alpha$,$\beta$and$\lambda$, and a row for each gene. There is an additional column specifying from which regime that gene has been simulated (see ?simulate_phenopath for details). • y is the$N \times G$matrix of gene expression • x is the$N$-length vector of covariates • z is the true latent pseudotimes By default this simulates the model for$N= 100$cells and$G=40$genes. For 8 representative genes we can visualise what the expression looks like over pseudotime: df_gex <- tbl_df(sim$y[,c(1,3,11,13,21,23,31,33)]) %>%
mutate(x = factor(sim[['x']]), z = sim[['z']]) %>%
gather(gene, expression, -x, -z)
ggplot(df_gex, aes(x = z, y = expression, color = x)) +
geom_point() +
facet_wrap(~ gene, nrow = 2) +
scale_color_brewer(palette = "Set1")
We see for the first two genes there is differential expression only, genes 3 and 4 show a pseudotime dependence, genes 5 and 6 show pseudotime-covariate interactions (but marginally no differential expression), while genes 7 and 8 show differential expression, pseudotime dependence and pseudotime-covariate interactions.
We can further plot this in PCA space, coloured by both covariate and pseudotime to get an idea of how these look in the reduced dimension:
pca_df <- tbl_df(prcomp(sim$y)$x[,1:2]) %>%
mutate(x = factor(sim[['x']]), z = sim[['z']])
ggplot(pca_df, aes(x = PC1, y = PC2, color = x)) +
geom_point() + scale_colour_brewer(palette = "Set1")
ggplot(pca_df, aes(x = PC1, y = PC2, color = z)) +
geom_point()
Fit PhenoPath model
PhenoPath fits models with a call to the phenopath function, which requires at least an expression matrix y and a covariate vector x. The expression data should represent something comparable to logged counts, such as $log_2(\text{TPM}+1)$. Note that buy default PhenoPath centre-scales the input expression.
For use with SummarizedExperiments see the section on input formats. For this example we choose an ELBO tolerance of 1e-6 and ELBO calculations thinned by 40. A discussion of how to control variational inference can be found below.
fit <- phenopath(sim$y, sim$x, elbo_tol = 1e-6, thin = 40)
print(fit)
The phenopath function will print progress on iterations, ELBO, and % change in ELBO that may be turned off by setting verbose = FALSE in the call.
Once the model has been fit it is important to check convergence with a call to plot_elbo(fit) to ensure the ELBO is approximately flat:
plot_elbo(fit)
Examining results
The posterior mean estimates of the pseudotimes $z$ sit in fit$m_z that can be extracted using the trajectory function. We can visualise these compared to both the true pseudotimes and the first principal component of the data: qplot(sim$z, trajectory(fit)) +
xlab("True z") + ylab("Phenopath z")
qplot(sim$z, pca_df$PC1) +
xlab("True z") + ylab("PC1")
We see that this has high correlation with the true pseudotimes:
cor(sim$z, trajectory(fit)) Next, we're interested in the interactions between the latent space and the covariates. There are three functions to help us here: • interaction_effects retrieves the posterior interaction effect sizes • interaction_sds retrieves the posterior interaction standard deviations • significant_interactions applies a Bayesian significant test to the interaction parameters Note that if$P=1$(ie there is only one covariate) each of these will return a vector, while if$P>1$then a matrix is returned. Alternatively, one can call the interactions function that returns a data frame with the following entries: • feature The feature (usually gene) • covariate The covariate, specified from the order originally supplied to the call to phenopath • interaction_effect_size The effect size of the interaction ($\beta$from the statistical model) • significant Boolean for whether the interaction effect is significantly different from 0 • chi The precision of the ARD prior on$\beta$• pathway_loading The pathway loading$\lambda$, showing the overall effect for each gene marginalised over the covariate In our simulated data above, the first 20 genes were simulated with no interaction effect while the latter 20 were simulated with interaction effects. We can pull out the interaction effect sizes, standard deviations, and significance test results into a data frame and plot: gene_names <- paste0("gene", seq_len(ncol(fit$m_beta)))
df_beta <- data_frame(beta = interaction_effects(fit),
beta_sd = interaction_sds(fit),
is_sig = significant_interactions(fit),
gene = gene_names)
df_beta$gene <- fct_relevel(df_beta$gene, gene_names)
ggplot(df_beta, aes(x = gene, y = beta, color = is_sig)) +
geom_point() +
geom_errorbar(aes(ymin = beta - 2 * beta_sd, ymax = beta + 2 * beta_sd)) +
theme(axis.text.x = element_text(angle = 90, hjust = 1),
axis.title.x = element_blank()) +
ylab(expression(beta)) +
scale_color_brewer(palette = "Set2", name = "Significant")
A typical analysis might follow by graphing the largest effect size; we can do this as follows:
which_largest <- which.max(df_beta$beta) df_large <- data_frame( y = sim[['y']][, which_largest], x = factor(sim[['x']]), z = sim[['z']] ) ggplot(df_large, aes(x = z, y = y, color = x)) + geom_point() + scale_color_brewer(palette = "Set1") + stat_smooth() Advanced Using an SummarizedExperiment as input Alternatively you might have expression values in an SummarizedExperiment. For single-cell data it is highly recommended to use the SummarizedExperiment in which case data is stored in a class derived from SummarizedExperiment. We'll first construct an example SummarizedExperiment using our previous simulation data: suppressPackageStartupMessages(library(SummarizedExperiment)) exprs_mat <- t(sim$y)
pdata <- data.frame(x = sim$x) sce <- SummarizedExperiment(assays = list(exprs = exprs_mat), colData = pdata) sce Note that PhenoPath will use by default is in the exprs assay of a SummarizedExperiment (ie assay(sce, "exprs")) as gene expression values, which can be changed using the sce_assay string in the column to phenopath. We can then pass the$x$covariates to PhenoPath in three ways: 1. As a vector or matrix as before 2. As a character that names a column of colData(sce) to use 3. A formula to build a model matrix from colData(sce) For our example, these three look like fit <- phenopath(sce, sim$x) # 1
fit <- phenopath(sce, "x") # 2
fit <- phenopath(sce, ~ x) # 3
Note that if the column of the SCESet is a factor it is coerced into a one-hot encoding. The intercept term is then removed as this is taken care of by the $\lambda$ coefficient automatically, and the columns centre-scaled.
Initialisation of latent space
The posterior distribution is naturally multi-modal and the use of variational inference means we essentially dive straight into the nearest local maximum. Therefore, correct initialisation of the latent space is important. This is controlled through the z_init argument.
PhenoPath allows for three different initialisations:
1. An integer specifying a principal component of the data to initialise to
2. A vector specifying the initial values
3. Random initialisation from standard normal distribution
For our example these three look like
fit <- phenopath(sim$y, sim$x, z_init = 1) # 1, initialise to first principal component
fit <- phenopath(sim$y, sim$x, z_init = sim$z) # 2, initialise to true values fit <- phenopath(sim$y, sim$x, z_init = "random") # 3, random initialisation Controlling variational inference {#varcontrol} There are several parameters that tune the coordinate ascent variational inference (CAVI): 1. maxiter maximum number of iterations to run CAVI for 2. elbo_tol the percentage change in the ELBO below which the model is considered converged 3. thin Computing the ELBO is expensive, so only compute the ELBO every thin iterations For example: fit <- phenopath(sim$y, sim\$x,
maxiter = 1000, # 1000 iterations max
elbo_tol = 1e-2, # consider model converged when change in ELBO < 0.02%
thin = 20 # calculate ELBO every 20 iterations
)
Technical
sessionInfo()
References
Try the phenopath package in your browser
Any scripts or data that you put into this service are public.
phenopath documentation built on May 2, 2018, 3:34 a.m.
|
{}
|
# Math Help - Ideals of ring of square matrices having rational entries...
1. ## Ideals of ring of square matrices having rational entries...
set of all $2*2$ matrices forms a ring
I want to prove that its only Ideals are Zero matrix and ring itself.
How to prove it??
set of all $2*2$ matrices forms a ring
More generally, every two sided ideal of matrix ring $M_n(R)$ is equal to $M_n(I)$ for some two-sided ideal I of R. Since Q is a field, its ideals are (0) and Q itself. Now the conclusion follows.
|
{}
|
# Plotting data points with x axis advancing in 0.5 steps
I'm still pretty new to Mathematica and i want to plot the following data points with the x axis advancing in 0.5 steps:
OG[6] = 1.0685458987703726;
OG[5.5] = 1.0649776023558106;
OG[5] = 1.0585;
OG[4.5] = 1.046957482313205;
OG[4] = 1.0453;
OG[3.5] = 0.9951879076222613;
OG[3] = 0.9597;
OG[2.5] = 0.8761019519547198;
OG[2] = 0.8023;
OG[1.5] = 0.809720272706028;
OG[1] = 1.0542;
OG[0.5] = 1.4881005040525765;
OG[0] = 1.9194;
The datapoints correspond to a upper price limit (number in brackets) in a financial market model. I wrote the datapoints together from different simulation runs so there is no function that gives me all of these.
When i try to plot them using the following code:
OG[P_]:= P
ListLineplot[Table[OG[P],{P,0,6,0.5}]]
The function of OG[P_] is random because i thought i need a function for Table to work.
I get this result which has nothing to do with the data I wanted to plot and the x axis only shows whole numbers.
My question is how do i plot this correctly so that the x axis advances in 0.5 steps and it plots my datapoints? Thanks in advance for you help.
• Look up DataRange. Also, you don't need Table[] for plotting values, since you can do ListLinePlot[{1.9194, 1.4881005040525765, (* everything else *)}] directly. – J. M. is away Nov 1 '17 at 14:50
• ListLinePlot[Table[{P, OG[P]}, {P, 0, 6, 0.5}]] will do the plot and use a horizontal increment of 0.5. If you don't include the {P, } or if you just use the raw list of numbers, it will use a horizontal increment of 1.0, not 0.5 – Bill Nov 1 '17 at 15:28
• @Bill ... except if you use DataRange. – anderstood Nov 1 '17 at 15:45
• @J.M. ok thx but is there a way to plot the values so that OG[0]has the coordinates (0, 1.9194) and ÒG[1] the coordinates (0.5, 1.4881005040525765)? So you can see in the graph which value corresponds to which upper limit. – user52902 Nov 1 '17 at 15:55
• @anderstood There are almost always a dozen different ways of accomplishing anything in Mathematica, almost always a few of which are completely incomprehensible. Pick one that you can remember and can likely use without making too many mistakes and stick with it – Bill Nov 1 '17 at 17:09
I don't think you need to define OG in this way. I would first try to get your data into a form like this (there can be many ways to do this, depending on how you want to enter your data):
data = {{0., 1.9194}, {0.5, 1.4881}, {1., 1.0542}, {1.5, 0.80972}, {2.,
0.8023}, {2.5, 0.876102}, {3., 0.9597}, {3.5, 0.995188}, {4.,
1.0453}, {4.5, 1.04696}, {5., 1.0585}, {5.5, 1.06498}, {6.,
1.06855}};
ListLinePlot will take this and plot this in the way I think you want:
ListLinePlot[data]
If you want to modify the $x$-axis to be in increments of 0.5, you can use the Ticks option:
ListLinePlot[
data,
Ticks -> {Range[0, 6, 0.5], Automatic}
]
(Of course, there's a lot more you can play with, formatting-wise; this is just a "basic" version you can start from.)
To give some insight into what (I think) is happening with your code above, is to note that the values of P that Table[OG[P], {P, 0, 6, 0.5}] goes through are non-integers (see Types of Numbers), whereas when you enter your data as, for example, OG[0] = 1.9194;, the 0 "argument" of OG is an integer.
So, when Table[OG[P], {P, 0, 6, 0.5}] looks for OG[0.] (for example), it doesn't find OG[0.] from the list of "OG[ ] =" lines, so it instead goes the OG[P_] := P line to figure out OG[0.] (0, according to OP[P_]:=P). You can see how this happens for all the "integer" values of P in your table:
Another thing to note is that ListLinePlot[{y1,y2,…}] plots points {1,y1},{2,y2},..., so even if you were to plot ListLinePlot[{1.9194, 1.4881005040525765, ...}], the $x$-values would still be "incorrect".
Even in this case, you can, of course, still mess with the ticks to get the appearance you want, but I think a solution similar to the one I wrote above will be more straightforward.
Hopefully all this makes sense and is (at least a little bit) helpful!
|
{}
|
# The commenting problem
Posted by Piers Cawley on Mar 3, 2007
On Monday I went to the London Ruby Users’ Group March meeting. The theme of the meeting was code review, so I put up a chunk of code from my yet to be released Sudoku solver.
It ended up being more like a talk because I spent most of the time trying to explain how Amb, the continuation based backend worked.
At one point, someone noticed the lack of comments in the code and wondered if this was because I considered it self evident.
Well, no, it isn’t. However, as far as I could tell, any sensibly short comment that I could write would founder on the fact that, if you understand continuations the code is reasonably straightforward, and if you don’t, it’s a maze of little, twisty passages, all different.
Then, on the train back I came up with what I hope might be a useful explanation of how a continuation works. So, without further ado: consider the following code:
def first(&predicate) self.each do |i| if predicate.call(i) return i end end raise “Predicate not satisfied” end
A fairly straightforward piece of Ruby which iterates using each and returns the first thing in the collection that satisfies predicate or throws an exception if nothing matches. About the only thing that could possibly be thought of as magical is the workings of return - the block that contains the return is invoked over in the implementation of each, but it ‘knows’ to return from first.
Because you’re an experienced computer programmer, you know that, although return looks a bit like a function that takes 0 or 1 arguments, it’s actually a keyword of the language.
Strangely, a continuation looks like a function that takes 0 or 1 arguments… here’s that code rewritten slightly:
def first(&predicate) callcc do |k_return| self.each do |i| if predicate.call(i) k_return.call(i) end end raise “Predicate not satisfied” end # k_return ‘returns’ here. end
This function does exactly the same as the version that uses return. k_return is a continuation created by callcc. The continuation wraps up the process of returning a value from a block in a thing that can be passed around as if it, itself, were a block. Of course, if a continuation was just another way of writing ‘return’, there’d be nothing to them. Where they get weird is that you can use them more than once, and you can stash them away to use later, in an instance variable say.
So, in my sudoku solver, every time the solver makes a guess, it stashes away a continuation that would, in effect, guess differently. So when, some 20 cells later, it turns out that the guess was wrong, the solver uses the continuation to backtrack and try a different guess. This trick of keeping track of ‘remaining’ guesses is sufficiently general that it can all be wrapped up in a library. The solver itself only has to deal with methods like one_of and assert. Instead of having to write an explicit, twisty search loop, you can simply specify your values, make a bunch of assertions about them and then sit back and let the library handle the search.
For completeness’ sake, and because I hope it might help you understand how continuations work a little better, here’s a couple of other callcc based equivalents.
collection.each do |i| … break if … end
Becomes
callcc do |k_break| collection.each do |i| … k_break.call if … end end
And
collection.each do |i| next if … … end
Becomes
collection.each do |i| callcc do |k_next| k_next.call if … … end end
And, finally
collection.each do |i| redo if … … end
becomes
collection.each do |i| k_redo = nil callcc {|cnt| k_redo = cnt} k_redo.call if … … end
That last one’s the real key to getting a handle on how continuations work, and how you can use them to build interesting control structures. Notice that there’s no limit to the number of times you can call k_redo. You could, for instance do (and yes, I know there are better ways to do this):
collection.each do |i| k_redo = nil n = 10 callcc {|cnt| k_redo = cnt} puts n n -= 1 k_redo.call if n > 0 … end
which prints a countdown from 10 to 0 before getting on with whatever it’s supposed to be getting on with.
### Solicitation
Please let me know if I’ve helped clear up your understanding of continuations. Or if I’ve just muddied the water still further. Thanks for you time.
|
{}
|
## Abstract
Vibrations of thin and thick beams containing internal complexities are analyzed through generalized bases made of global piecewise-smooth functions (GPSFs). Such functional bases allow us to globally analyze multiple domains as if these latter were only one, such that a unified formulation can be used for different mechanical systems. Such bases were initially introduced to model a specific part of stress and displacement components through the thickness of multi-layered plates; subsequent extensions were introduced in the literature to allow the modeling of thin-walled beams and plates. However, in these latter cases, certain analytical difficulties were experienced when inner boundary conditions needed to be englobed into the GPSFs; in this work, such mentioned difficulties are successfully overcome through certain affine transformations which allow the analyses of vibrating complex beam systems through a straightforward analytical procedure. The complex mechanical components under investigation are Euler and/or Timoshenko models containing inner complexities (stepped beams, concentrated mass or stiffness, internal constraints, etc.). The ability of the models herein analyzed is shown through the comparison of the resulting solutions to exact counterparts, if existing, or to finite elements solutions.
## 1 Introduction
Within the frame of bent beams and plates, the theories describing the dynamic or static behavior of mechanical components originate from the ideas developed on two models of beam, i.e., the Euler–Bernoulli model (developed around the mid 18th century, let us say ∼1750) (e.g., Love [1] and its historical introduction) and Timoshenko [2,3]. The Euler–Bernoulli model along with its derived models is also generally recognized as associated with the so-called classical theory, whilst the Timoshenko model, along with its derived ones, is generally associated with the so-called uniform shear deformable theory. Higher order theories have also been developed in the 20th century but they are not relevant to the present context.
Despite the age of the classical beam theory, such a model is still appreciated today for its own simplicity and is involved in uncountable engineering contexts to predict static or dynamic behaviors in beam models. However, although such a classical theory can be considered of great importance within the engineering landscape, it is not always able to fulfill all the needs required. Indeed, its growing inability to accurately predict frequencies and modes as the wavelengths become increasingly comparable to the thickness of the beams is well recognized. To this end, the uniform shear deformable theory can generously assist to predict frequencies and modes of the real system with greater accuracy. Such an improvement, of uniform shear deformable theory with respect to the classical counterpart, has been revealed so much significant in the engineering landscape that some authors consider Timoshenko’s model one of the most remarkable events in the development of the structural dynamics of the 20th century [4]. During the 20th century, Timoshenko’s model has been longely debated, for example in order to identify a better shear coefficient, to conjecture a frequencies range for its usability, and last but not least, the existence of two series or double spectrum of frequencies (e.g., Refs. [57]). We can even find in the literature a recent and significant historical analysis carried out by Elishakoff [8] aimed at attempting to attribute the paternity of the ideas lying at the base of the mentioned uniform shear deformable theory; an analysis which finally led Elishakoff [8] to realize that the beam theory that incorporates both the rotary inertia and shear deformation as is known presently, with shear correction factor included, should be referred to as the Timoshenko–Ehrenfest beam theory rather than uniquely Timoshenko beam theory as universally recognized today. With regard to the aforementioned models, i.e., the Euler–Bernoulli and Timoshenko–Ehrenfest beam models, in the mechanical engineering landscape, this work intends to extend certain analytical methods to solve the equations related to both models in the case of multi-domains containing inner complexities. This need is essentially justified by engineering modeling reasons. Indeed, theories of simple single beams subjected solely to classical boundary conditions, are certainly an interesting subject for academic purposes but the modeling of systems both based on such theories and closer to real systems is an even more valuable subject of investigation. This latter is the case when inner and/or outer complexities are present on beam and plate systems. In this work, the focus is on beam-type systems.
When inner and/or outer complexities are present, exact methods, developed for simple beams (e.g., Ref. [9]), need to be substituted by valid analytical alternatives or even by numerical procedures. To this end, global piecewise-smooth functions (GPSFs) [10] are considered a valuable modeling base. The initial introduction of the GPSFs originally dates back to 2002 and was followed over the years by successful applications (e.g., Refs. [1115]). Subsequent extensions of GPSFs were introduced in the literature to both allow (i) a possible reduction of the computational effort [16] making the GPSFs adaptive (i.e., AGPSFs) and (ii) modeling thin-walled beams and plates [17,18]. In particular, in Ref. [17] the modelization of thin-walled beams and plates was carried out by adding certain supplementary analytical conditions whilst in Ref. [18] an integration procedure was used to substitute such mentioned conditions. Moreover, the way to also globally approximate discontinuous functions which can occur when certain types of inner complexities are mounted along beam systems was established in Ref. [18]. Although an intrinsic simplicity was researched in both cases [17,18], it is retained that a better procedure still needs to be identified in order to use AGPSFs both to (i) reduce the complexity related to creating the AGPSFs as functional bases and (ii) for modeling beams and plates containing different types of discontinuities along the beam system. In this work certain transformations, which have been called affine, have been identified and used to model thin-walled beams containing inner complexities more straightforwardly than has previously been done. In particular, such affine transformations can be seen as a variant of the procedure illustrated in the original work [10]; recursive modification at the ends of the local bases are now able to make the respective global functions continuous with their first derivative continuous; such a modification will provide a C1 continuity condition allowing us to model thin-walled beams, intended as models based on the Euler–Bernoulli beam theory. In this work, AGPSFs are also used to model Timoshenko–Ehernfest beam systems in order to complete earlier investigations [9] and to show the flexibility of AGPSFs in modeling systems based on different theories.
It is herein stressed that this work is not intended only to analyze beam-type systems; rather, the aim of this work also offers too the perspective to adopt the named GPSFs of class C−1, C0, C1 (where C−1 means functions containing finite jumps, C0 means continuous functions having only discontinuous derivatives and, finally, C1 refers to continuous functions with first derivatives continuous) for plates where such types of discontinuities need to be modeled. Moreover, in order to show the flexibility of such bases (AGPSFs) here the vibrations of beams, containing a combination of the discontinuities C−1, C0, C1 differently located on the same multi-beam systems, are also investigated.
This research is organized as follows. Section 2 presents the mathematical details regarding the new bases and the affine transformations leading from one base to another. In this section, discussions are provided in the context of Ritz-type analysis derived through the theorem of virtual displacements along with global bases (i.e., AGPSFs) fulfilling the inner and outer essential boundary conditions. Section 3 presents the mechanical systems containing inner complexities under analyses and the related variational models based on Euler–Bernoulli and Timoshenko–Ehrenfest theories. Section 4 presents and discusses the results of the numerical simulations and in Sec. 5 relevant conclusions are drawn.
## 2 The GPSFs of C0 and C1 Class Through Affine Transformation
The functional bases of GPSFs were originally introduced in 2002 [10] with the intent to model piecewise physical entities (stress and displacements). In 2015 [16] GPSFs became A-GPSFs when a way to make them adapt to the complexities of the functions, and for certain aspects to reduce computational effort, was clarified. The aforementioned studies were initially thought to model piecewise entities through the thickness of freely vibrating components. Subsequent development of A-GPSFs followed in the middle plane of thin-walled beams and plates to study the free vibrations of the same components [17,18]. The adoption of A-GPSFs within the middle plane of a structural element needed a variant for using these bases. Indeed, thin-walled beams and plates when used along with the theorem of virtual displacement can require the continuity of the first derivative in order to fulfill essential boundary conditions, whilst, GPSFs were initially designed only to be piecewise continuous without requiring any higher order of smoothness.
Particular attention should be paid to the aforementioned requirements. In particular, classical GPSFs and A-GPSFs show the natural ability to model smooth functions in particular cases of unsmooth ones, but this would happen within a purely mathematical process of fitting (e.g., least square approximation, etc.). When the mathematical process of fitting is involved in a resolution process aimed at solving differential equations through a Ritz procedure, essential conditions need to be fulfilled under the penalty of divergence. Therefore, what we generally need to study vibrations of thin-walled beams and plates are functional components of A-GPSFs occasionally equipped with a higher order of smoothness. This was the main reason for the introduction of certain supplementary analytical conditions added to A-GPSFs [17] or the introduction of an integration process [18].
In this paper, we show how certain affine transformations, recursively applied to local functions, can achieve global functional bases having different degrees of smoothness. This provides a unified approach to solving different beam systems. For illustrative purposes, let us initially take into account Fig. 1 where a global domain with x ∈ [−1, 1] contains NL = 3 local domains with $x∈[−1,−1/3]∪[−1/3,1/3]∪[1/3,1]$.
Fig. 1
Fig. 1
Close modal
Each local domain in Fig. 1 contains three functional local functions (N = 3) for each subdomain corresponding to the first three Legendre polynomials which can be obtained through the following well known expressions in [−1, 1]:
$L0(x)=1,L1(x)=x,L2(x)=(3x2−1)/2,…,Lq(x)=12qq!⋅dqdxq[(x2−1)q]$
(1)
where q in Eq. (1) corresponds to the degree of the ith = (q + 1)th Legendre polynomial generated through Rodrigues’ formula. Once the ith Legendre polynomial (i = 1, …, N) has been generated in [−1, 1], the same polynomial can be moved into any local domain [a, b] by simply substituting the variable x with (2(xa)/(ba) − 1), which is the procedure carried out to produce Fig. 1.
Figure 1 is the starting point to produce the GPSFs of any class (C0 or C1). Indeed, based on Fig. 1, GPSFs are obtained through the assembling scheme of Fig. 2. A-GPSFs can be constructed by using the same scheme as in Fig. 2 followed by the eventual elimination of repeated paths [16].
Fig. 2
Fig. 2
Close modal
Figure 2 represents the local functions of Fig. 1 through black dots whilst, their junctions are represented through paths. In any case, two consecutive levels (i and i + 1) always provide a number of GPSFs equal to the number of local domains (NL = 3 in Fig. 2). The closing path joining all the local functions in the last level of expansion (N) is added only in the last two levels.
The leading idea consists in leaving the responsibility to create global functions of class C0 or C1 to the path. Therefore, by addressing the attention to an arbitrarily established path (e.g., the continuous or the dashed one in Fig. 2), when two adjacent local functions follow from left to right, in the established path, the local downstream polynomial should undergo an affine transformation, i.e., its degree is kept invariant but in the interface between the adjacent sub-domains, the local functions should assume the same value, when a GPSFs of C0 class is required, or both the same value and the same first derivative, when a GPSFs of class C1 is required. In particular, with respect to Fig. 3, where f(x) represents the antecedent function whilst φ(x) is the following function, the continuity conditions in xo are established through Eq. (2).
${Co:g(x)=f(xo)φ(xo)φ(x)C1:g(x)=f′(xo)φ′(xo)φ(x)+φ′(xo)f(xo)−φ(xo)f′(xo)φ′(xo)$
(2)
Fig. 3
Fig. 3
Close modal
The function g(x) replaces φ(x) in the established path according to the class of continuity we are interested in achieving in the GPSFs. Of course, Eq. (2) must be recursively applied along the whole established path in order to achieve one GPSF per path. At this stage, some observations should be made. By looking at Eq. (2), it can be deduced that the function g(x) is still a polynomial having the same degree of the original one in the same domain. This preserves the completeness of the local bases and, consequently, the completeness of the global bases (i.e., of the GPSFs). Moreover, it is interesting to observe that Eq. (2) is well posed as there is no possibility that both φ(xo) and φ′(xo) can become zero at the ends of local polynomials; in fact, local polynomials are orthogonal polynomials, in particular of Legendre, and, as such, they never cancel out at the ends. This last condition would seem to fail for constant components along with the requirement to get C1 continuity; however, it should be noticed that in the case of C1 class of continuity the first two levels of expansions always lead to only two global functions: the constant and the linear term. This is justified for geometric reasons and by the fact that the number of class C1 GPSFs when N = 2 always reduces to two functions, whatever the number of local domains (NL), because NLN-2(NL−1) = 2 for any NL.
Based on the aforementioned illustrated analysis, a functional base of of class C0 or C1 GPSFs can be produced through a subroutine that automatically implements Eqs. (1) and (2) along with the assembly scheme of Fig. 2. Therefore, based on Fig. 1, Figs. 4 and 5 illustrate GPSFs of class C0 and C1 respectively. In these figures, the dashed line corresponds to the zero line, the first column is the functional base of GPSFs whilst the second and third columns illustrate the first and second derivatives of GPSFs respectively.
Fig. 4
Fig. 4
Close modal
Fig. 5
Fig. 5
Close modal
When the problem consists of approximating trends or functions, for example in the sense of minimum least squares, a set of functional bases of GPSFs (i.e., the first column of Figs. 4 and 5) suffices the scope. Class C0 or C1 GPSFs can be used depending on the features of the function we need to approximate, on the convergence speed we would like to get, and, finally and on the accuracy required. When the problem consists only of approximating trends or functions, the worst result we could achieve is an approximation of low accuracy; this could be due, for example, to an attempt to approximate C0 functions through GPSFs of class C1. When the GPSFs have to be used in a Ritz-type analysis, as is the case herein dealt with for both the Euler–Bernoulli and Timoshenko–Ehrenfest beam model, the functional set of GPSFs needs to be complemented by their respective derivatives (i.e., the second and third columns in Figs. 4 and 5). Every single functional component of the set of GPSFs possibly along with its derivatives involved in its relevant analysis must fulfill the essential (or geometric) boundary conditions under penalty of divergence from the exact results. In particular, when the Euler–Bernoulli model is analyzed, the relevant boundary value problem involves an unknown displacement function through a 4th order (in the space) partial differential equation; in this case, the essential boundary conditions regard both the GPSFs and their first derivatives. The fulfillment of the natural boundary conditions is entrusted to the variational statement leading to the Ritz-type analysis and involving the second derivatives. When the Timoshenko–Ehrenfest model is analyzed, the relevant boundary value problem involves two unknown generalized displacement functions through a 2th order (in the space) system of two partial differential equations; in this case, the essential boundary conditions regard the GPSFs only. The fulfillment of the natural boundary conditions is entrusted to the variational statement leading to the Ritz-type analysis and involving the first derivatives. Therefore, except for special cases that may derive from specific and/or atypical complexities present in the Euler–Bernoulli beam systems, a Ritz-type analysis generally requires the use of class C1 GPSFs (Fig. 5); while, Timoshenko–Ehrenfest beam systems generally require the use of lower class GPSFs (i.e., C0 as in Fig. 4).
## 3 Free Vibrations of Mechanical Components With Internal Complexities Through a Unified Consistent Variational Approach Along With A-GPSFs
In this section, let us focus our attention on beam-type systems including internal complexities. The system has a total length L and could even have constant piecewise thickness h or stepwise material properties. The in-plane and normal coordinate length parameters are denoted with x and z respectively, and u and w represent the corresponding displacement components.
The free vibrations of the beam-type system illustrated in Fig. 6 are analyzed through both the classical Euler–Bernoulli and the Timoshenko–Ehrenfest beam theory. In this regard, relevant GPSFs are used in a unique formulation that will be developed through functions in a single global domain [0, L].
Fig. 6
Fig. 6
Close modal
Therefore, based on the assumed displacement field Eq. (3) which is the characteristics of the Euler–Bernoulli beam theory,
$u(x,z;t)=−zw(x;t),x$
(3)
where (),x = ∂()/∂x and the time part is intended as w(x;t) = w(x)cos(ω · t), the theorem of virtual displacements can be written as in the following Eq. (4).
$∫VolσxδεxdVol+∫Volρw¨δwdVol+mw¨m⋅δwm+kwk⋅δwk=0$
(4)
Here, ρ is the volumetric density, δ is the virtual operator whilst, σx and ɛx are the longitudinal stress and strain respectively; these latter are related through Young’s modulus (σx = x). In Eq. (4), the letteral indexes m and k refer to the specific section where the respective quantities are collocated on the beams of Fig. 6. Therefore, based on Eq. (4) an eigenproblem, aimed at extracting the natural frequencies and associated eigenfunctions, can be achieved once an expansion series of w(x) has been set as in Eq. (5).
$w(x)=∑i=1naiW(x)i=aTW$
(5)
Let us notice that the expansion in series, W(x)i with i = 1,…,n, has been set as global in the whole domain [0, L] of the beam without caring about the internal complexities; the proper modeling of these latter are entrusted to the choice of the base which can be one among the GPSFs depending on the type of internal complexity in the mechanical component. At this stage, an aspect of the resolution procedure deserves to be noted: we are developing the model exactly as we would have done on a simple beam, i.e., using a series expansion and ignoring the involvement in the structure of internal complexities. However, even though, we are carrying out such a development a convergence to the exact results is expected for merit which belongs only to the GPSFs constructed through a simple affine transformation.
Based on Eqs. (3)(5) along with the relationship between strain and displacement (ɛx = u,x) the following eigenproblem Eq. (6), aimed at extracting the natural frequencies and associated analytical eigenfunctions, can be achieved.
$Ka=ω2MaK=∫0LEJW″⋅W″Tdx+kWkWkTM=∫0LρAW⋅WTdx+mWmWmT$
(6)
In Eq. (6), J and A represent the inertia and area of the transversal section respectively, Wk and Wm correspond to the vector W(x) evaluated at xk and xm respectively.
An eigenproblem similar to Eq. (6) can be formulated with respect to the Timoshenko–Ehrenfest theory. Here, the assumed displacement field corresponds to Eq. (7),
$u(x,z;t)=−zψ(x;t)$
(7)
where ψ(x; t) represents the rotation of the transversal section of the beam as independent from the transversal displacement w(x; t), thus that two unknown functions can be set into the model, such as $w(x;t)=w(x)cos(ω⋅t)$ and $ψ(x;t)=ψ(x)cos(ω⋅t)$. The theorem of virtual displacements is taken into account in the following Eq. (8).
$∫Vol(σxδεx+τzxδγzx)dVol+∫Volρw¨δwdVol+∫Volρz2ψ¨δψdVol+mw¨m⋅δwm+kwk⋅δwk=0$
(8)
Therefore, based on Eq. (8) an eigenproblem, aimed at extracting the natural frequencies and associated eigenfunctions, can be achieved once an expansion series of both w(x) and ψ(x) have been set as in Eq. (9).
${ψ(x)=∑i=1naiΨ(x)i=aTΨw(x)=∑i=1lbiW(x)i=bTW$
(9)
where the formulation is still constructed regardless of the fact that the beam may be homogeneous or inhomogeneous with steps and/or containing inner complexities located in certain sections. Based on Eqs. (7)(9) along with the relationship between strain and displacement (ɛx = u, x and γzx = u, z + w, x) the following eigenproblem Eq. (10), aimed at extracting the natural frequencies and associated analytical eigenfunctions, can be achieved.
$[K11K12K12TK22](ab)=ω2[M1100M22](ab);K11=∫0L(EJΨ′⋅Ψ′T+χAGΨ⋅ΨT)dx;K22=∫0LχAGW′⋅W′Tdx+kWkWkT;K12=−∫0LχAGΨ⋅W′Tdx;M11=∫0LρJΨ⋅ΨTdx;M22=∫0LρAW⋅WTdx+mWmWmT$
(10)
In Eq. (10), χ represents the shear correction factor and G is the transverse shear modulus. In both models, Euler–Bernoulli and Timoshenko–Ehrenfest, the transversal section is assumed rectangular with thickness h and width b.
Before closing this section, let us still notice that the expansion in series, Ψ(x)i with i = 1, …, n, W(x)i with i = 1, …, l have been set as global in the whole domain [0, L] of the beam without caring about the internal complexities; the proper modeling of these latter is entrusted to the choice of the base which can be one among the GPSFs depending on the type of internal complexity in the mechanical component. Still, we should notice that we have developed the model exactly as we would have done on a simple beam, i.e., using a series expansion and ignoring the involvement in the structure of internal complexities. However, even though, we are carrying out such a development, a convergence to the exact results is expected for merit which belongs only to the GPSFs constructed through a simple affine transformation.
## 4 Numerical Simulations and Discussions
In this part of the manuscript, the analytical model presented in Sec. 3 is analyzed in conjunction with the GPSFs presented in Sec. 2 through the new affine transformation.
In the first simulation, a simple unique beam simply supported at the ends is taken into account. This test illustrates how the GPSFs can get the relevant results of a simple beam as a particular case. Indeed, a simple beam can be seen as if it were of an arbitrary number of sub-domains. A subdivision of NL sub-domains having equal lengths along with an equal number of local functional components (N) has been adopted in each subdomain to build all the GPSFs. For this specific initial test only, the Timoshenko–Ehrenfest model has been taken into account and compared with existing exact results [9].
To compare the current results with those published in Ref. [9], simply supported boundary conditions have been simulated; therefore, once the GPSFs were obtained, all the functional components of the set were multiplied by the function x(x-L) in order to make able GPSFs able to geometrical fulfill the simply supported boundary conditions. The results reported in Table 1 were obtained by using the following geometrical-material characteristics: L = 1 m, h = 25 cm, E = 210 GPa, ρ = 7850 kg/m3, ν = 0.3, and χ = 5 (1 + ν)/(6 + 5ν) with a beam having unitary width b.
Table 1
First ten natural frequencies (Hz) through GPSFs of class C1; b.c.: SS; L = 1 m, h = 25 cm
No.Exact plane stressa [9]Exact Timoshenko [9]N(NL)
18(1)6(6)8(4)10(3)12(2)
1535.523535.468535.468535.468535.468535.468535.468
21774.261772.911772.911772.911772.911772.911772.91
33275.883270.163270.163270.163270.163270.163270.16
44858.324845.474845.474845.474845.474845.474845.47
56415.326585.446585.446585.446437.486585.446585.44
66458.756437.486437.486437.486585.446437.486437.48
77015.207211.007211.007211.007211.007211.007211.00
88055.328025.848025.848025.858025.848025.848025.84
98435.818711.708711.708711.708711.708711.708711.70
109640.719604.469604.469604.499604.479604.469604.46
Size[K]b3652525244
No.Exact plane stressa [9]Exact Timoshenko [9]N(NL)
18(1)6(6)8(4)10(3)12(2)
1535.523535.468535.468535.468535.468535.468535.468
21774.261772.911772.911772.911772.911772.911772.91
33275.883270.163270.163270.163270.163270.163270.16
44858.324845.474845.474845.474845.474845.474845.47
56415.326585.446585.446585.446437.486585.446585.44
66458.756437.486437.486437.486585.446437.486437.48
77015.207211.007211.007211.007211.007211.007211.00
88055.328025.848025.848025.858025.848025.848025.84
98435.818711.708711.708711.708711.708711.708711.70
109640.719604.469604.469604.499604.479604.469604.46
Size[K]b3652525244
a
Symmetrical/extensional modes intentionally excluded.
b
2 N NL–4(NL−1).
Table 1 lists the first ten natural frequencies obtained through the minimum number of functional components. For example, 8(4) means that once the expansion level 8 has been fixed for each domain (N = 8) the values in Table 1 correspond to the minimum number of sub-domains required to get that frequencies (NL = 4: {8, 8, 8, 8}). Thus, Table 1 clarifies that the most advantageous procedure (from the point of view of the size of the eigenproblem) would seem associated with a beam modeled as it is, i.e., through a unique domain. However, in this case, the classical Legendre polynomials used to require up to the 17th degree to get the exact results on the first six significant figures. Any further increasing number of domains provides a slightly higher size of the eigenproblem, even if through a constant size, but with the advantage of reducing the maximum polynomial degrees involved. In any case, during the convergence analysis, the analytical model based on class C1 GPSFs generated through an affine transformation has shown an excellent monotonic convergence to the exact results listed in Table 1. Finally, we should note, similarly to Ref. [9], that the analytical procedures herein dealt with naturally provide frequencies (in Table 1) falling into one single set regardless of the existence of one or two spectra.
In order to further stress the ability of the method to converge to exact results, Table 2 compares these exact results produced by Eisenberger [19] to the results achieved through A-GPSFs.
Table 2
First five natural frequencies, $ω^=ωL2ρA/EJ$, b.c.: CS with internal slide at x = xc [19]
ξ = xc/L
0.250.50.750.9
No.Ref. [19]
13.39215.48005.95614.3332
232.323318.826521.165026.6222
368.344769.882850.802171.0179
4105.0211109.5340120.8773123.4203
5199.3862214.9602220.8016182.2637
No.A-GPSFs
13.39225.48005.95624.3332
232.323418.826421.165126.6222
368.344869.882850.802271.0179
4105.0212109.5340120.8773123.4203
5199.3862214.9602220.8016182.2637
{N1, N2}{6, 14}{9, 10}{12, 7}{15, 5}
Size[K]19181819
ξ = xc/L
0.250.50.750.9
No.Ref. [19]
13.39215.48005.95614.3332
232.323318.826521.165026.6222
368.344769.882850.802171.0179
4105.0211109.5340120.8773123.4203
5199.3862214.9602220.8016182.2637
No.A-GPSFs
13.39225.48005.95624.3332
232.323418.826421.165126.6222
368.344869.882850.802271.0179
4105.0212109.5340120.8773123.4203
5199.3862214.9602220.8016182.2637
{N1, N2}{6, 14}{9, 10}{12, 7}{15, 5}
Size[K]19181819
The results listed in Table 2 are those obtained through the minimum number of functional components. A careful perusal of the results in Table 2 reveals an excellent agreement between the results obtained using this method and the exact results listed by Eisenberger [19, Table 4]; extremely slight discrepancies can be observed but these, whenever existing, seem mainly due to different roundings used. In Table 2, it is also interesting to note the flexibility of the A-GPSFs which allow convergence in a cost-effective manner by increasing the order of the polynomial components only in the largest domains thus keeping the computational effort contained and balanced.
The next system herein analyzed, as aimed at testing the performance of the resolution procedure based on Ritz-type analysis along with GPSFs, is the system depicted in Fig. 7 which is based on the following geometrical-material characteristics kept fixed during the simulation process: L = 60 cm, xm = 15 cm, xc = 30 cm, xk = 45 cm, width uniform of 2 cm, m = 100 g, k = 100 3EJ/(L/4)3, E = 206 GPa, ρ = 7800 kg/m3, ν = 0.3, and χ = 5 (1 + ν)/(6 + 5ν).
Fig. 7
Fig. 7
Close modal
The system illustrated in Fig. 7 presents such unusual inner complexities that a resolution aimed at treating the system as if it were a unique domain, without recurring to GPSFs, would be unthinkable; as it will be clear in this set of simulations the new GPSFs perform the related dynamical analysis efficiently based on both the Euler–Bernoulli and the Timoshenko–Ehrenfest models.
What is requested in order to analyze the system in Fig. 7 is a proper choice of GPSFs (which here, for the sake of brevity, we will assume always having the same level of expansion for any sub-domain).
In this latter regard, Fig. 8 can assist our choices. In particular, Fig. 8 shows the continuity conditions the GPSFs bases should have in order to converge to the expected exact results.
Fig. 8
Fig. 8
Close modal
First, from Fig. 8 we can immediately notice that the class of GPSFs is not the same, neither for the different sections nor for the theory we use.
As far as the Timoshenko–Ehrenfest beam theory is concerned, the model generally requires class C0 GPSFs (for both the functions W and Ψ). Of course, this different choice is due to the fact that all the components of a base of GPSFs must fulfill the relevant inner and outer essential boundary conditions. This is the reason why, in xc, W must be discontinuous (through a jump [18]) whilst Ψ must preserve the rotation, and thus it needs to be of C0 class. The jump in W at xc is ensured by adding a constant term for x ∈ [0, xc] to the set of GPSFs for W and nil elsewhere. The essential boundary conditions at the ends are ensured by multiplying all the functional components of W and Ψ by x(x0.6) and x respectively. Therefore, the resultant set of GPSFs used in the Timoshenko–Ehrenfest model for N = 3 in NL = 4 sub-domains (i.e., {3,3,3,3}) is illustrated in Fig. 9.
Fig. 9
Fig. 9
Close modal
As far as the Euler–Bernoulli beam theory is concerned, the model generally requires class C1 GPSFs (for W) in order to let the base of GPSFs converge at the exact results; still such a requirement is related to the need for all the functional components of the set to fulfill the relevant inner and outer essential boundary conditions. This is the reason why in xc the first derivative of W (the rotation of the transversal section) must be locally continuous while leaving W to be discontinuous through a jump. The jump in W at xc is ensured by adding a constant term for x ∈ [0, xc] to the set of GPSFs and nil elsewhere. The essential boundary conditions at the ends and at inner points are ensured by multiplying the first functional component W1 and the remaining functional components Wi for i > 1, by (100/9)(4x2–40x3/3 + 100x4/9) and x2(x–0.6) respectively. The set of GPSFs used in the Euler–Bernoulli model for N = 3 in NL = 4 sub-domains (i.e., {3,3,3,3}) is illustrated in Fig. 10.
Fig. 10
Fig. 10
Close modal
Based on the aforementioned analytical considerations, numerical simulations were carried out in order to produce the results. The results have been assessed by using the theories herein dealt with (through the mentioned GPSFs) and compared to finite element (FE) solutions based on Euler–Bernoulli and Timoshenko's elements described in Petyt [20]. Aside from the mention regarding the finite elements having equal length and distributed through the beam-type system of Fig. 8, here any further detail aimed at illustrating the simulation of the FE system is not mentioned both for the sake of brevity and because the relevant modeling is retained known.
Tables 3 and 4 report the frequencies of the system of Fig. 8 when the thickness is uniform and equal to 3 mm; therefore, we are considering a system having a length/thickness ratio of 200 which is quite slender in the range of the first ten frequencies; for this, it is not surprising that both theories (Euler–Bernoulli and Timoshenko–Ehrenfest) give similar results.
Table 3
First ten natural frequencies (Hz) through GPSFs, refer to Fig. 8; hi = {3,3,3,3} mm; theory: Euler–Bernoulli
GPSFsFE solutions (140 elements)
No.{4,4,4,4}{5,5,5,5}{6,6,6,6}{8,8,8,8}{10,10,10,10}
128.892328.764228.759328.759028.759028.7590
277.718377.254777.250977.248577.248577.2485
3149.045148.067147.946147.928147.928147.928
4227.637226.501226.390226.387226.387226.387
5437.768431.592430.235430.151430.151430.151
6560.551550.649549.703549.688549.687549.687
7912.214819.523796.815796.130796.123796.123
81136.956978.380949.622946.735946.727946.727
91910.601545.931481.001457.881457.801457.80
102289.961717.941702.181675.131674.701674.70
Size[K]1115192735280
GPSFsFE solutions (140 elements)
No.{4,4,4,4}{5,5,5,5}{6,6,6,6}{8,8,8,8}{10,10,10,10}
128.892328.764228.759328.759028.759028.7590
277.718377.254777.250977.248577.248577.2485
3149.045148.067147.946147.928147.928147.928
4227.637226.501226.390226.387226.387226.387
5437.768431.592430.235430.151430.151430.151
6560.551550.649549.703549.688549.687549.687
7912.214819.523796.815796.130796.123796.123
81136.956978.380949.622946.735946.727946.727
91910.601545.931481.001457.881457.801457.80
102289.961717.941702.181675.131674.701674.70
Size[K]1115192735280
Table 4
First ten natural frequencies (Hz) through GPSFs, refer to Fig. 8; hi = {3,3,3,3} mm; theory: Timoshenko–Ehrenfest
No.GPSFsFE solutions (520 elements)
{4,4,4,4}{5,5,5,5}{6,6,6,6}{8,8,8,8}{10,10,10,10}
128.792128.756428.755228.755228.755228.7552
277.717177.237877.231277.229877.229877.2298
3149.065147.887147.858147.855147.855147.855
4227.222226.489226.322226.316226.316226.316
5438.496432.002429.806429.757429.757429.757
6561.531551.987548.975548.895548.895548.895
7951.881803.987796.174794.439794.435794.435
81199.08969.184947.643944.728944.717944.718
92105.371536.041482.531453.431453.241453.24
103250.681742.031707.281668.311667.801667.80
Size[K]27354359751040
No.GPSFsFE solutions (520 elements)
{4,4,4,4}{5,5,5,5}{6,6,6,6}{8,8,8,8}{10,10,10,10}
128.792128.756428.755228.755228.755228.7552
277.717177.237877.231277.229877.229877.2298
3149.065147.887147.858147.855147.855147.855
4227.222226.489226.322226.316226.316226.316
5438.496432.002429.806429.757429.757429.757
6561.531551.987548.975548.895548.895548.895
7951.881803.987796.174794.439794.435794.435
81199.08969.184947.643944.728944.717944.718
92105.371536.041482.531453.431453.241453.24
103250.681742.031707.281668.311667.801667.80
Size[K]27354359751040
Tables 3 and 4, also show how both theories, based on GPSFs, provide results in excellent agreement with the finite element solutions. The ability of the present analytical models, based on GPSFs, to get converged frequencies with a size far less than the FE eigenproblem can also be noticed.
Finally, we should report that the finite element solutions in the case of the Euler–Bernoulli beam element correspond to the most convergent frequencies through the minimum number of degrees-of-freedom (280) and before of ill-conditioning warnings appeared. On the other hand, the finite element solutions in the case of the Timoshenko beam element correspond to the most convergent values through the minor number of degrees-of-freedom (1040).
Tables 5 and 6 regard a different simulation when compared to Tables 3 and 4. Here, with respect to the inner guided constraint, the left side of the beam keeps a uniform thickness of 3 mm, whilst the thickness on the right side is increased to 5 cm.
Table 5
First ten natural frequencies (Hz) through GPSFs, refer to Fig. 8; hi = {3, 3, 50, 50} mm; theory: Euler–Bernoulli
No. GPSFs FE solutions (284 elements) {6,6,6,6} {8,8,8,8} {10,10,10,10} {12,12,12,12} {14,14,14,14} 1 28.7485 28.6727 28.6726 28.6726 28.6726 28.6726 2 35.8937 35.8882 35.8882 35.8882 35.8882 35.8882 3 173.171 173.144 173.144 173.144 173.144 173.144 4 566.099 566.079 566.078 566.078 566.078 566.078 5 919.294 918.661 918.652 918.652 918.652 918.652 6 1723.04 1706.15 1705.80 1705.80 1705.80 1705.80 7 2023.02 2022.80 2022.80 2022.80 2022.80 2022.80 8 2555.54 2274.29 2269.98 2269.94 2269.94 2269.94 9 3659.09 3474.59 3467.97 3467.86 3467.86 3467.86 10 5834.90 4301.04 4240.84 4239.52 4239.51 4239.51 Size[K] 19 27 35 43 51 568
No. GPSFs FE solutions (284 elements) {6,6,6,6} {8,8,8,8} {10,10,10,10} {12,12,12,12} {14,14,14,14} 1 28.7485 28.6727 28.6726 28.6726 28.6726 28.6726 2 35.8937 35.8882 35.8882 35.8882 35.8882 35.8882 3 173.171 173.144 173.144 173.144 173.144 173.144 4 566.099 566.079 566.078 566.078 566.078 566.078 5 919.294 918.661 918.652 918.652 918.652 918.652 6 1723.04 1706.15 1705.80 1705.80 1705.80 1705.80 7 2023.02 2022.80 2022.80 2022.80 2022.80 2022.80 8 2555.54 2274.29 2269.98 2269.94 2269.94 2269.94 9 3659.09 3474.59 3467.97 3467.86 3467.86 3467.86 10 5834.90 4301.04 4240.84 4239.52 4239.51 4239.51 Size[K] 19 27 35 43 51 568
Table 6
First ten natural frequencies (Hz) through GPSFs, refer to Fig. 8; hi = {3, 3, 50, 50} mm; theory: Timoshenko–Ehrenfest
No.GPSFsFE solutions (768 elements)
{6,6,6,6}{8,8,8,8}{10,10,10,10}{12,12,12,12}{14,14,14,14}
128.580528.580328.580328.580328.580328.5803
235.872235.872135.872135.872135.872135.8721
3173.042173.039173.039173.039173.039173.039
4565.223565.156565.156565.156565.156565.156
5918.476916.343916.329916.329916.329916.330
61733.791698.711698.171698.171698.171698.17
71895.211895.121895.121895.121895.121895.12
82431.342260.012256.612256.582256.582256.58
93687.603451.573438.603438.443438.443438.45
105471.004340.144200.814196.174196.134196.13
Size[K]435975911071536
No.GPSFsFE solutions (768 elements)
{6,6,6,6}{8,8,8,8}{10,10,10,10}{12,12,12,12}{14,14,14,14}
128.580528.580328.580328.580328.580328.5803
235.872235.872135.872135.872135.872135.8721
3173.042173.039173.039173.039173.039173.039
4565.223565.156565.156565.156565.156565.156
5918.476916.343916.329916.329916.329916.330
61733.791698.711698.171698.171698.171698.17
71895.211895.121895.121895.121895.121895.12
82431.342260.012256.612256.582256.582256.58
93687.603451.573438.603438.443438.443438.45
105471.004340.144200.814196.174196.134196.13
Size[K]435975911071536
The finite element solutions require an increasing computational effort; in particular, by using a similar convergence criterion as mentioned in Tables 3 and 4, the finite element solutions for the Euler–Bernoulli beam element require a number of 568 degrees-of-freedom, whilst when the Timoshenko beam element is taken into account the convergence requires at least 1536 degrees-of-freedom. The analytical model based on GPSFs still converges without experiencing any particular analytical difficulties and with a size of the eigenproblem significantly lower than the finite element solution.
Finally, it is interesting to notice that, aside from the 7th mode, the discrepancy between the frequencies assessed through the Euler–Bernoulli theory and the frequencies of the Timoshenko–Ehrenfest theory are quite similar. This is because the 7th mode involves a significant displacement field on the right side when compared to the left side, thus involving the importance of the shear for the thicker part of the model on the right side.
The last numerical Tables 7 and 8, take into account uniformly thicker beams. The thickness is increased from 3 mm to 21 mm. The FE solution always requires a higher size of the eigenproblem with respect to the size of the analytical procedure. Significantly higher becomes the size of the eigenproblem when the Timoshenko beam element is taken into account. Here, still the present analytical method provides excellent agreement with the expected results.
Table 7
First ten natural frequencies (Hz) through GPSFs, refer to Fig. 8; hi = {21, 21, 21, 21} mm; theory: Euler–Bernoulli
No.GPSFsFE solutions (128 elements)
{4,4,4,4}{5,5,5,5}{6,6,6,6}{8,8,8,8}{10,10,10,10}
1232.085230.864230.829230.826230.826230.826
2564.597561.952561.947561.935561.935561.935
31290.881286.691286.301286.281286.281286.28
41618.711610.701610.201610.191610.191610.19
53071.793029.463021.123020.553020.553020.55
63960.023904.553891.453891.363891.363891.36
76878.176071.516016.576002.736002.716002.71
88241.517212.186975.616964.686964.626964.62
913,529.010,821.510,374.910,219.010,218.410,218.4
1017,432.412,182.712,099.811,808.911,805.411,805.4
Size[K]1115192735256
No.GPSFsFE solutions (128 elements)
{4,4,4,4}{5,5,5,5}{6,6,6,6}{8,8,8,8}{10,10,10,10}
1232.085230.864230.829230.826230.826230.826
2564.597561.952561.947561.935561.935561.935
31290.881286.691286.301286.281286.281286.28
41618.711610.701610.201610.191610.191610.19
53071.793029.463021.123020.553020.553020.55
63960.023904.553891.453891.363891.363891.36
76878.176071.516016.576002.736002.716002.71
88241.517212.186975.616964.686964.626964.62
913,529.010,821.510,374.910,219.010,218.410,218.4
1017,432.412,182.712,099.811,808.911,805.411,805.4
Size[K]1115192735256
Table 8
First ten natural frequencies (Hz) through GPSFs, refer to Fig. 8; hi = {21, 21, 21, 21} mm; Theory: Timoshenko–Ehrenfest
GPSFsFE solutions (800 elements)
No.{4,4,4,4}{5,5,5,5}{6,6,6,6}{8,8,8,8}{10,10,10,10}
1229.638229.500229.498229.498229.498229.498
2557.271555.589555.569555.566555.566555.566
31258.961256.121255.921255.921255.921255.92
41586.581583.531583.151583.141583.141583.14
52929.842900.672893.572893.462893.462893.46
63710.203669.443656.203655.993655.993656.00
76157.305550.395523.925516.585516.575516.59
87342.196388.356309.826299.296299.276299.29
911,749.49297.219061.638972.028971.558971.62
1015,650.110,410.510,185.310,058.010,057.010,057.1
Size[K]27354359751600
GPSFsFE solutions (800 elements)
No.{4,4,4,4}{5,5,5,5}{6,6,6,6}{8,8,8,8}{10,10,10,10}
1229.638229.500229.498229.498229.498229.498
2557.271555.589555.569555.566555.566555.566
31258.961256.121255.921255.921255.921255.92
41586.581583.531583.151583.141583.141583.14
52929.842900.672893.572893.462893.462893.46
63710.203669.443656.203655.993655.993656.00
76157.305550.395523.925516.585516.575516.59
87342.196388.356309.826299.296299.276299.29
911,749.49297.219061.638972.028971.558971.62
1015,650.110,410.510,185.310,058.010,057.010,057.1
Size[K]27354359751600
## 5 Conclusions
Within the frame of freely vibrating continuous systems, expansions in series based on GPSFs [10,17,18] have been complemented with an affine transformation in order to model both thin and thick elements. Such an affine transformation has significantly simplified the implementation of the GPSFs. The GPSFs built through affine transformations have allowed analytical models to efficiently implement a Ritz-type analysis based on both Euler–Bernoulli and Timoshenko–Ehrenfest beam theories. Excellent analytical stability has been experimented in both cases along with the ability of the GPSFs to converge to the exact results. The analytical methods presented in this work are an extension of the exact analytical models earlier published [9]; the present analytical model along with this latter reference, are able the show, for several systems, the reason why the generous Timoshenko–Ehrenfest model still today represents, after one century, a reference point in mechanical and/or structural engineering.
Although the present author believes that GPSFs can be efficiently improved for investigating systems containing different types of inner complexities and for different theories, it is retained that a significant step forward to future investigations on the dynamics of beams and plates containing inner complexities has been presented in the present work.
## Conflict of Interest
There are no conflicts of interest.
## Data Availability Statement
The authors attest that all data for this study are included in the paper.
## References
1.
Love
,
A. E. H.
,
1944
,
A Treatise on the Mathematical Theory of Elasticity
,
Dover Publications
,
New York
.
2.
Timoshenko
,
S. P.
,
1921
, “
On the Correction for Shear of the Differential Equation for Transverse Vibrations of Prismatic Bars
,”
Lond., Edinb. Dublin Philos. Mag. J. Sci.
,
41
(
245
), pp.
744
746
.
3.
Elishakoff
,
I.
,
2019
,
Handbook on Timoshenko-Ehrenfest Beam and Uflyand-Mindlin Plate Theories
,
World Scientific
,
Hackensack, NJ
.
4.
Elishakoff
,
I.
,
Kaplunov
,
J.
, and
Nolde
,
E.
,
2015
, “
Celebrating the Centenary of Timoshenko’s Study of Effects of Shear Deformation and Rotary Inertia
,”
Appl. Mech. Rev.
,
67
(
6
), p.
060802
.
5.
Traill-Nash
,
R. W.
, and
Collar
,
A. R.
,
1953
, “
The Effect of Shear Flexi-Bility and Rotary Inertia on the Bending Vibrations of Beams
,”
Quart. J. Mech. Appl. Math.
,
6
(
2
), pp.
186
222
.
6.
Levinson
,
M.
, and
Cooke
,
D. W.
,
1982
, “
On the Two Frequency Spectra of Timoshenko Beams
,”
J. Sound Vib.
,
84
(
3
), pp.
319
326
.
7.
Stephen
,
N. G.
,
2006
, “
The Second Spectrum of Timoshenko Beam Theory-Further Assessment
,”
J. Sound Vib.
,
292
(
1–2
), pp.
372
389
.
8.
Elishakoff
,
I.
,
2020
, “
Who Developed the So-Called Timoshenko Beam Theory
,”
Math. Mech. Solids
,
25
(
1
), pp.
97
116
.
9.
Messina
,
A.
, and
Reina
,
G.
,
2020
, “
On the Frequency Range of Timoshenko Beam Theory
,”
,
27
(
27
), pp.
179
189
.
10.
Messina
,
A.
,
2002
, “
Free Vibrations of Multilayered Plates Based on a Mixed Variational Approach in Conjunction With Global Piecewise-Smooth Functions
,”
J. Sound Vib.
,
256
(
1
), pp.
103
129
.
11.
Messina
,
A.
,
2003
, “
Free Vibrations of Multilayered Doubly Curved Shells Based on a Mixed Variational Approach and Global Piecewise-Smooth Functions
,”
Int. J. Solids Struct.
,
40
(
12
), pp.
3069
3088
.
12.
Messina
,
A.
,
2011
, “
Influence of the Edge-Boundary Conditions on Three-Dimensional Free Vibrations of Isotropic and Cross-Ply Multi-Layered Rectangular Plates
,”
Compos. Struct.
,
93
(
8
), pp.
2135
2151
.
13.
Messina
,
A.
,
2012
, “
Three-Dimensional Free Vibration Analysis of Cross-Ply Laminated Rectangular Plates Through 2D and Exact Models
,”
,
19
(
4
), pp.
250
264
.
14.
Messina
,
A.
, and
Carrera
,
E.
,
2014
, “
Three-Dimensional Free Vibration of Multi-Layered Piezoelectric Plates Through Approximate and Exact Analyses
,”
J. Intell. Mater. Syst. Struct.
,
26
(
5
), pp.
489
504
.
15.
Messina
,
A.
, and
Carrera
,
E.
,
2016
, “
Three-Dimensional Analysis of Freely Vibrating Multilayered Piezoelectric Plates Through Adaptive Global Piecewise-Smooth Functions
,”
J. Intell. Mater. Syst. Struct.
,
27
(
20
), pp.
2862
2876
.
16.
Messina
,
A.
,
2015
, “
Analyses of Freely Vibrating Cross-Ply Laminated Plates in Conjunction With Adaptive Global Piecewise-Smooth Functions (A-GPSFs)
,”
Int. J. Mech. Sci.
,
90
, pp.
179
189
.
17.
Messina
,
A.
,
2018
, “
Modelling the Vibrations of Multi-Span Beams and Plates Through Adaptive Global Piecewise-Smooth Functions (A-GPSFs)
,”
Acta Mech.
,
229
(
4
), pp.
179
189
.
18.
Messina
,
A.
,
2021
, “
Generalized A-GPSFs and Modeling of Vibrating Elements With Internal Complexities
,”
pp.
1
14.
19.
Eisenberger
,
M.
,
2002
, “
Exact Vibration Frequencies and Modes of Beams With Internal Releases
,”
Int. J. Struct. Stab. Dyn.
,
2
(
1
), pp.
63
75
.
20.
Petyt
,
M.
,
1990
,
Introduction to Finite Element Vibration Analysis
,
Cambridge University Press
,
Cambridge
.
|
{}
|
# zbMATH — the first resource for mathematics
## Found 14 Documents (Results 1–3)
Interdisciplinary Mathematics. 24. Brookline, MA: Math Sci Press. xv, 595 p. (1988).
Reviewer: V.Perlick (Berlin)
Geometric techniques in gauge theories, Proc. 5th Conf. Differ. Equ., Scheveningen/Neth. 1981, Lect. Notes Math. 926, 1-73 (1982).
|
{}
|
# Math Help - Rings, ID, and Fields
1. ## Rings, ID, and Fields
Assume that the ring R is isomorphic to the ring R'. Prove that if R is commutative, then r' is commutative.
2. Let $\phi : R \rightarrow R'$
If R is commumative then
$\forall a,b \in R: ab = ba$
$\Rightarrow \phi(ab) = \phi(ba)$
Also $\phi(ab) = \phi(a)\phi(b)$ and $\phi(ba) = \phi(b)\phi(a)$
and $\phi$ is bijective.
This should be enough for you to see why that R' is communative
3. Originally Posted by bookie88
Assume that the ring R is isomorphic to the ring R'. Prove that if R is commutative, then r' is commutative.
Let $\phi:R\to R'$ denote an isomorphism, and $x,y\in R'$. Then there are $a,b\in R$ with $\phi(a)=x$ and $\phi(b)=y$. Furthermore, $xy=\phi(a)\phi(b)=\phi(ab)=\phi(ba)=\phi(b)\phi(a) =yx$. So $R'$ is commutative.
EDIT: Looks like someone beat me to it. Oh well.
|
{}
|
Team METISS
Scientific Foundations
Contracts and Grants with Industry
Other Grants and Activities
Bibliography
Inria / Raweb 2003
Project: METISS
# Project : metiss
## Section: Scientific Foundations
The large family of audio signals includes a wide variety of temporal and frequential structures, objects of variable durations, ranging from almost stationary regimes (for instance, the note of a violin) to short transients (like in a percussion). The spectral structure can be mainly harmonic (vowels) or noise-like (fricative consonants). More generally, the diversity of timbers results in a large variety of fine structures for the signal and its spectrum, as well as for its temporal and frequential envelope.
In addition, a majority of audio signals are composite, i.e. they result from the mixture of several sources (voice and music, mixing of several tracks, useful signal and background noise). Audio signals may have undergone various types of distortion, recording conditions, media degradation, coding and transmission errors, etc.
To account for these factors of diversity, our approach is to focus on techniques for decomposing signals on redundant systems (or dictionaries). The elementary atoms in the dictionary correspond to the various structures that are expected to be met in the signal.
#### Redundant systems and adaptive representations
Traditional methods for signal decomposition are generally based on the description of the signal in a given basis (i.e. a free, generative and constant representation system for the whole signal). On such a basis, the representation of the signal is unique (for example, a Fourier basis, Dirac basis, orthogonal wavelets, ...). On the contrary, an adaptive representation in a redundant system consists of finding an optimal decomposition of the signal (in the sense of a criterion to be defined) in a generating system (or dictionary) including a number of elements (much) higher than the dimension of the signal.
Let y be a monodimensional signal of length T and D a redundant dictionary composed of $N>T$ vectors ${g}_{i}$ of dimension T .
$y=\left[y\left(t\right){\right]}_{1\le t\le T}\phantom{\rule{1.em}{0ex}}\phantom{\rule{1.em}{0ex}}D={\left\{{g}_{i}\right\}}_{1\le i\le N}\phantom{\rule{1.em}{0ex}}\text{with}\phantom{\rule{1.em}{0ex}}{g}_{i}=\left[{g}_{i}\left(t\right){\right]}_{1\le t\le T}$
If D is a generating system of ${R}^{T}$ , there is an infinity of exact representations of y in the redundant system D , of the type:
$y\left(t\right)={\sum }_{1\le i\le N}{\alpha }_{i}{g}_{i}\left(t\right)$
We will denote as $\alpha ={\left\{{\alpha }_{i}\right\}}_{1\le i\le N}$ , the N coefficients of the decomposition.
The principles of the adaptive decomposition then consist in selecting, among all possible decompositions, the best one, i.e. the one which satisfies a given criterion (for example a sparsity criterion) for the signal under consideration, hence the concept of adaptive decomposition (or representation). In some cases, a maximum of T coefficients are non-zero in the optimal decomposition, and the subset of vectors of D thus selected are refered to as the basis adapted to y . This approach can be extended to approximate representations of the type:
$y\left(t\right)={\sum }_{1\le i\le M}{\alpha }_{\varphi \left(i\right)}{g}_{\varphi \left(i\right)}\left(t\right)+e\left(t\right)$
with $M , where $\varphi$ is an injective function of $\left[1,M\right]$ in $\left[1,N\right]$ and where $e\left(t\right)$ corresponds to the error of approximation to M terms of $y\left(t\right)$ . In this case, the optimality criterion for the decomposition also integrates the error of approximation.
#### Sparsity criteria
Obtaining a single solution for the equation above requires the introduction of a constraint on the coefficients ${\alpha }_{i}$ . This constraint is generally expressed in the following form :
${\alpha }^{*}=arg{min}_{\alpha }\phantom{\rule{0.277778em}{0ex}}F\left(\alpha \right)$
Among the most commonly used functions, let us quote the various functions ${L}_{\gamma }$ :
${L}_{\gamma }\left(\alpha \right)={\left[{\sum }_{1\le i\le N},|,{\alpha }_{i},{|}^{\gamma }\right]}^{1/\gamma }$
Let us recall that for $0<\gamma <1$ , the function ${L}_{\gamma }$ is a sum of concave functions of the coefficients ${\alpha }_{i}$ . Function ${L}_{0}$ corresponds to the number of non-zero coefficients in the decomposition.
The minimization of the quadratic norm ${L}_{2}$ of the coefficients ${\alpha }_{i}$ (which can be solved in an exact way by a linear equation) tends to spread the coefficients on the whole collection of vectors in the dictionary. On the other hand, the minimization of ${L}_{0}$ yields a maximally parsimonious adaptive representation, as the obtained solution comprises a minimum of non-zero terms. However the exact minimization of ${L}_{0}$ is an untractable NP-complete problem.
An intermediate approach consists in minimizing norm ${L}_{1}$ , i.e. the sum of the absolute values of the coefficients of the decomposition. This can be achieved by techniques of linear programming and it can be shown that, under some (strong) assumptions the solution converges towards the same result as that corresponding to the minimization of ${L}_{0}$ . In a majority of concrete cases, this solution has good properties of sparsity, without reaching however the level of performance of ${L}_{0}$ .
Other criteria can be taken into account and, as long as the function F is a sum of concave functions of the coefficients ${\alpha }_{i}$ , the solution obtained has good properties of sparsity. In this respect, the entropy of the decomposition is a particularly interesting function, taking into account its links with the information theory.
Finally, let us note that the theory of non-linear approximation offers a framework in which links can be established between the sparsity of exact decompositions and the quality of approximate representations with M terms. This is still an open problem for unspecified redundant dictionaries.
#### Decomposition algorithms
Three families of approaches are conventionally used to obtain an (optimal or sub-optimal) decomposition of a signal in a redundant system.
The ``Best Basis'' approach consists in constructing the dictionary D as the union of B distinct bases and then to seek (exhaustively or not) among all these bases the one which yields the optimal decomposition (in the sense of the criterion selected). For dictionaries with tree structure (wavelet packets, local cosine), the complexity of the algorithm is quite lower than the number of bases B , but the result obtained is generally not the optimal result that would be obtained if the dictionary D was taken as a whole.
The ``Basis Pursuit'' approach minimizes the norm ${L}_{1}$ of the decomposition resorting to linear programming techniques. The approach is of larger complexity, but the solution obtained yields generally good properties of sparsity, without reaching however the optimal solution which would have been obtained by minimizing ${L}_{0}$ .
The ``Matching Pursuit'' approach consists in optimizing incrementally the decomposition of the signal, by searching at each stage the element of the dictionary which has the best correlation with the signal to be decomposed, and then by subtracting from the signal the contribution of this element. This procedure is repeated on the residue thus obtained, until the number of (linearly independent) components is equal to the dimension of the signal. The coefficients $\alpha$ can then be reevaluated on the basis thus obtained. This greedy algorithm is sub-optimal but it has good properties for what concerns the decrease of the error and the flexibility of its implementation.
Intermediate approaches can also be considered, using hybrid algorithms which try to seek a compromise between computational complexity, quality of sparsity and simplicity of implementation.
#### Dictionary construction
The choice of the dictionary D has naturally a strong influence on the properties of the adaptive decomposition : if the dictionary contains only a few elements adapted to the structure of the signal, the results may not be very satisfactory nor exploitable.
The choice of the dictionary can rely on a priori considerations. For instance, some redundant systems may require less computation than others, to evaluate projections of the signal on the elements of the dictionary. For this reason, the Gabor atoms, wavelet packets and local cosines have interesting properties. Moreover, some general hint on the signal structure can contribute to the design of the dictionary elements : any knowledge on the distribution and the frequential variation of the energy of the signals, on the position and the typical duration of the sound objects, can help guiding the choice of the dictionary (harmonic molecules, chirplets, atoms with predetermined positions, ...).
Conversely, in other contexts, it can be desirable to build the dictionary with data-driven approaches, i.e. training examples of signals belonging to the same class (for example, the same speaker or the same musical instrument, ...). In this respect, Principal Component Analysis (PCA) offers interesting properties, but other approaches can be considered (in particular the direct optimization of the sparsity of the decomposition, or properties on the approximation error with M terms) depending on the targeted application.
In some cases, the training of the dictionary can require stochastic optimization, but one can also be interested in EM-like approaches when it is possible to formulate the redundant representation approach within a probabilistic framework.
Extension of the techniques of adaptive representation can also be envisaged by the generalization of the approach to probabilistic dictionaries, i.e. comprising vectors which are random variables rather than deterministic signals. Within this framework, the signal $y\left(t\right)$ is modeled as the linear combination of observations emitted by each element of the dictionary, which makes it possible to gather in the same model several variants of the same sound (for example various waveforms for a noise, if they are equivalent for the ear). Progress in this direction are conditioned to the definition of a realistic generative model for the elements of the dictionary and the development of effective techniques for estimating the model parameters.
#### Signal separation
METISS is especially interested in source and signal separation in the underdetermined case, i.e. in the presence of a number of sources strictly higher than the number of sensors.
In the particular case of two sources and one sensor, the mixed (monodimensional) signal writes :
$y={s}_{1}+{s}_{2}+ϵ$
where ${s}_{1}$ and ${s}_{2}$ denote the sources and $ϵ$ an additive noise.
Under a probabilistic framework, we can denote by ${\theta }_{1}$ , ${\theta }_{2}$ and $\eta$ the model parameters of the sources and of the noise. The problem of source separation then becomes :
$\left({\stackrel{^}{s}}_{1},{\stackrel{^}{s}}_{2}\right)=arg{max}_{\left({s}_{1},{s}_{2}\right)}\left[P\left(,{s}_{1},,,{s}_{2},|y,,{\theta }_{1},,,{\theta }_{2},\right)\right]$
By applying the Bayes rule and by assuming statistical independence between the two sources, the desired result can be obtained by solving :
$\left({\stackrel{^}{s}}_{1},{\stackrel{^}{s}}_{2}\right)=arg{max}_{\left({s}_{1},{s}_{2}\right)}\left[P\left(y|,{s}_{1},,,{s}_{2},\right)P\left(,{s}_{1},|,{\theta }_{1},\right)P\left(,{s}_{2},|,{\theta }_{2},\right)\right]$
The first of the three terms in the argmax can be obtained via the model noise :
$P\left(y|{s}_{1},{s}_{2}\right)\propto P\left(y-\left({s}_{1}+{s}_{2}\right)|\eta \right)=P\left(ϵ|\eta \right)$
The two other terms are obtained via likelihood functions corresponding to source models trained from examples, or designed from knowledge sources. For example, commonly used models are the Laplacian model, the Gaussian Mixture Model or the Hidden Markov Model.
These models can be linked to the distribution of the representation coefficients in a redundant system in which are pooled together several bases adapted to each of the sources present in the mixture.
|
{}
|
# problem 2 on superposition
Discussion in 'Homework Help' started by electronicstech07, Nov 2, 2008.
1. ### electronicstech07 Thread Starter Member
Nov 16, 2007
18
0
I have attached my work on another problem involving superposition. It involves a Is and Vs and is asking me to find Ir3. Help is much appreciated!
File size:
236.2 KB
Views:
27
2. ### vvkannan Active Member
Aug 9, 2008
138
11
While calculating I (killing Vs) entering at B the resistance in the denominator should be the sum of total resistance.I think you have made a mistake there.
3. ### electronicstech07 Thread Starter Member
Nov 16, 2007
18
0
You're correct again. I guess I'm going a little too fast calculating the answer on some of these problems. Thanks again!
4. ### hgmjr Moderator
Jan 28, 2005
9,030
218
What is the answer given in the book?
hgmjr
5. ### electronicstech07 Thread Starter Member
Nov 16, 2007
18
0
The answer is 1.6 mA and that is what I got when correcting the value of the denominator to 852.5 ohms when calculating for I entering pt. B.
I entering pt. B = 680/852.5 * 100 mA = 79.76 mA.
Using I divider, Ir3 = 220/1020 ohms * 79.76 mA = 17.2 mA
Solving for Ir3, 17.2-15.6 = 1.60 mA.
6. ### hgmjr Moderator
Jan 28, 2005
9,030
218
Here is the Millman's Theorem approach to the problem.
|
{}
|
Help on the following combinatorial problem?
I have $m$ bit vectors, each of which is composed by $m$ bits. Let's denote with $v_i[j]$ the $j$-th bit of the $i$-th vector, $i,j \in [1, m]$. Each bit vector $v_i$ is subject to the following 2 restrictions:
1. $v_i[j] = 0\ \forall j \geq i$.
2. $v_i[j] = 1\ \forall j < i - \frac{m}{log(m)}$.
3. Those bits that do not fall in the restrictions above can be either $0$ or $1$, but in such case the number of $0$'s can be at most $12$.
Now I have another bit vector $s$, of $m$ bits: initially all the $m$ bits of $s$ are set to $1$. By "applying $v_i$ to $s$" I mean performing a bitwise AND between $s$ and $v_i$, and then storing the result in $s$. I'm interested in the evolution of $s$ after repeated applications of the vectors $v_1, ..., v_m$ given in input.
Let's call those "repeated applications" a trajectory, and let's define such trajectory more formally. A trajectory is a sequence composed by at most $m$ vectors (selected from those $v_1, ..., v_m$ given in input) such that if $v_i$ is in the sequence, then all the $v_j$ after it must have $j < i$. So, for example, $<v_8, v_3>$ is a trajectory, while $<v_3, v_8, v_7>$ is not (because $8\geq3$).
Clearly, there are $2^m$ different trajectories. Let $S=\emptyset$. Suppose to take $s = 1^m$ and to let it undergo a trajectory $T_1$: for each step of the trajectory $T_1$, put the new value taken by $s$ in $S$. Then repeat the same process for another trajectory $T_2$ (always starting from $s=1^m$, and always putting every new value of $s$ in $S$). Then again, until you tried all the possible $2^m$ trajectories. At the end, the set $S$ will contain all the possible values that $s$ may ever assume given the vectors in input.
Questions
1. I have $v_i, ..., v_m$ in input. I want to know $|S|$, i.e. how many distinct values may $s$ ever assume. Of course, I want to compute $|S|$ efficiently, i.e. without trying all the possible trajectories one by one.
2. Suppose to remove the 2nd restriction on the vectors in input. How doing so affects $|S|$?
3. More importantly, what I most care about is how $|S|$ grows with $m$. Is $|S|$ at most polynomial in $m$? Is $|S|$ at most sub-exponential in $m$? Or do there exist bad instances on which $|S|$ is necessarily exponential in $m$?
The following figure is an example with $m=17$:
I'm collecting experimental data in order to try to figure out which is the relationship between $m$ and $|S|$. So far, experiments seems to suggest that $|S|$ grows faster than $m^3$ and slower than $m^4$. However, for the moment those data have not much significance: I was only able to make tests up to $m = 90$, so there may be a big hidden constant or some other factor that lets an exponential law look like a polynomial law for small $m$. I need help in figuring out the asymptotic behaviour of $|S|$ with respect to $m$.
• @Downvoter: Why downvoting? Please motivate. – Giorgio Camerani Sep 26 '11 at 20:08
• Aren't the trajectories overcomplicating it? You could just talk about subsets of $\{1\ldots m\}$ – Peter Taylor Sep 27 '11 at 22:18
• @Peter: Yes a trajectory is nothing more than a subset of $\{1, ..., m\}$. I've just thought that talking about trajectories would have given a more intuitive, "visual" picture of the problem. I wanted to put the accent on the evolution of the vector $s$, to stress the fact that I'm interested in how many different values can $s$ assume during all its possible evolutions. – Giorgio Camerani Sep 28 '11 at 8:28
• @Walter: One possible reason for the downvotes is the title of the question, which is of no help. You may want to rephrase it so that it does not contain "help" and maybe hint at the objects you want to count. Cheers! – Michaël Cadilhac Sep 29 '11 at 16:12
• @MichaëlCadilhac: Yes, admittedly the title is very generic. Probably I will change it to something more "attractive". Thanks for your hint, cheers! – Giorgio Camerani Sep 29 '11 at 17:55
I've rethought this and my initial bound was correct. In the worst case, $|S| = \Theta(m \; 2^\frac{m}{\lg m})$
Proof is in two parts. Firstly, $|S| = O(m \; 2^\frac{m}{\lg m})$. Consider the possible values of $s$ of a trajectory which ends at $v_x$. Every bit $s[j]$ for $j \ge x$ is 0, and every bit $s[j]$ for $j < x - \frac{m}{\lg m}$ is 1. Therefore there are only $2^\frac{m}{\lg m}$ values which $s$ can take. Multiply up by the number of $v_x$ and we have the upper bound.
Secondly, consider
0 1 1 1 0 1 1 1 1 1 1 1 1 1 1 1 1
0 0 1 1 1 0 1 1 1 1 1 1 1 1 1 1 1
0 0 0 1 1 1 0 1 1 1 1 1 1 1 1 1 1
0 0 0 0 1 1 1 0 1 1 1 1 1 1 1 1 1
0 0 0 0 0 1 1 1 0 1 1 1 1 1 1 1 1
0 0 0 0 0 0 1 1 1 0 1 1 1 1 1 1 1
...
0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 0 1
0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 0
0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1
I assert that this scheme gives you $|S| = \Omega(m \; 2^\frac{m}{\lg m})$. For each column $v_x$ consider also the $(\frac{m}{\lg m}-2)$ columns to its right. Each of the $2^{\frac{m}{\lg m}-2}$ combinations of them gives a different $s$, and in each of those $s$ the top set bit is the top set bit of $v_x$, so there is no double-counting between different $v_x$.
• Thanks for your answer. Do you have any clue whether the third constraint (i.e. not more than $12$ zeros) makes any difference? In other words, do you believe that restricting the zeros to at most $12$ implies that the number of different values introduced by trajectories ending at $v_x$ is much less than $2^{m/logm}$ (by "much less" I mean not exponential in ${m/logm}$)? My sensation is that it doesn't make any difference: even if we allow at most $1$ zero it seems that we may generate $2^{m/logm}$ different values for at least one $v_x$. – Giorgio Camerani Sep 29 '11 at 8:22
• @WalterBishop, my example uses not more than 1 zero. – Peter Taylor Sep 29 '11 at 8:26
• Sorry I've parsed both the answer and the example too fast. – Giorgio Camerani Sep 29 '11 at 9:01
• @WalterBishop, although if you restrict the number of 1s instead (no more than $k$ of the free values in a vector can be 1) you get $|S| = O(m^{k+1})$ – Peter Taylor Sep 30 '11 at 16:16
• How do you derive $|S|=O(m^{k+1})$ in such case? To me, it seems that in such case we would have $|S|=O(m \cdot 2^{k})=O(m)$ (since $k$ is constant). Because AND-ing 2 vectors, a $1$ may become a $0$ but a $0$ can't become a $1$: thus, regardless of the fact that our "sliding window" has $m/logm$ vectors, we may generate at most $2^k$ different vectors for each of the $m$ position of the "sliding window". Am I missing something? – Giorgio Camerani Oct 2 '11 at 18:36
|
{}
|
# shap.KernelExplainer¶
class shap.KernelExplainer(model, data, link=<shap.utils._legacy.IdentityLink object>, **kwargs)
Uses the Kernel SHAP method to explain the output of any function.
Kernel SHAP is a method that uses a special weighted linear regression to compute the importance of each feature. The computed importance values are Shapley values from game theory and also coefficents from a local linear regression.
Parameters
modelfunction or iml.Model
User supplied function that takes a matrix of samples (# samples x # features) and computes a the output of the model for those samples. The output can be a vector (# samples) or a matrix (# samples x # model outputs).
datanumpy.array or pandas.DataFrame or shap.common.DenseData or any scipy.sparse matrix
The background dataset to use for integrating out features. To determine the impact of a feature, that feature is set to “missing” and the change in the model output is observed. Since most models aren’t designed to handle arbitrary missing data at test time, we simulate “missing” by replacing the feature with the values it takes in the background dataset. So if the background dataset is a simple sample of all zeros, then we would approximate a feature being missing by setting it to zero. For small problems this background dataset can be the whole training set, but for larger problems consider using a single reference value or using the kmeans function to summarize the dataset. Note: for sparse case we accept any sparse matrix but convert to lil format for performance.
A generalized linear model link to connect the feature importance values to the model output. Since the feature importance values, phi, sum up to the model output, it often makes sense to connect them to the output with a link function where link(output) = sum(phi). If the model output is a probability then the LogitLink link function makes the feature importance values have log-odds units.
Examples
__init__(model, data, link=<shap.utils._legacy.IdentityLink object>, **kwargs)
Uses Shapley values to explain any machine learning model or python function.
This is the primary explainer interface for the SHAP library. It takes any combination of a model and masker and returns a callable subclass object that implements the particular estimation algorithm that was chosen.
Parameters
modelobject or function
User supplied function or model object that takes a dataset of samples and computes the output of the model for those samples.
maskerfunction, numpy.array, pandas.DataFrame, tokenizer, or a list of these for each model input
The link function used to map between the output units of the model and the SHAP value units. By default it is shap.links.identity, but shap.links.logit can be useful so that expectations are computed in probability units while explanations remain in the (more naturally additive) log-odds units. For more details on how link functions work see any overview of link functions for generalized linear models.
algorithm“auto”, “permutation”, “partition”, “tree”, “kernel”, “sampling”, “linear”, “deep”, or “gradient”
The algorithm used to estimate the Shapley values. There are many different algorithms that can be used to estimate the Shapley values (and the related value for constrained games), each of these algorithms have various tradeoffs and are preferrable in different situations. By default the “auto” options attempts to make the best choice given the passed model and masker, but this choice can always be overriden by passing the name of a specific algorithm. The type of algorithm used will determine what type of subclass object is returned by this constructor, and you can also build those subclasses directly if you prefer or need more fine grained control over their options.
output_namesNone or list of strings
The names of the model outputs. For example if the model is an image classifier, then output_names would be the names of all the output classes. This parameter is optional. When output_names is None then the Explanation objects produced by this explainer will not have any output_names, which could effect downstream plots.
Methods
__init__(model, data[, link]) Uses Shapley values to explain any machine learning model or python function. addsample(x, m, w) allocate() explain(incoming_instance, **kwargs) explain_row(*row_args, max_evals, …) Explains a single row and returns the tuple (row_values, row_expected_values, row_mask_shapes, main_effects). not_equal(i, j) run() shap_values(X, **kwargs) Estimate the SHAP values for a set of samples. solve(fraction_evaluated, dim) supports_model(model) Determines if this explainer can handle the given model. varying_groups(x)
explain_row(*row_args, max_evals, main_effects, error_bounds, outputs, silent, **kwargs)
Explains a single row and returns the tuple (row_values, row_expected_values, row_mask_shapes, main_effects).
This is an abstract method meant to be implemented by each subclass.
Returns
tuple
A tuple of (row_values, row_expected_values, row_mask_shapes), where row_values is an array of the attribution values for each sample, row_expected_values is an array (or single value) representing the expected value of the model for each sample (which is the same for all samples unless there are fixed inputs present, like labels when explaining the loss), and row_mask_shapes is a list of all the input shapes (since the row_values is always flattened),
shap_values(X, **kwargs)
Estimate the SHAP values for a set of samples.
Parameters
Xnumpy.array or pandas.DataFrame or any scipy.sparse matrix
A matrix of samples (# samples x # features) on which to explain the model’s output.
nsamples“auto” or int
Number of times to re-evaluate the model when explaining each prediction. More samples lead to lower variance estimates of the SHAP values. The “auto” setting uses nsamples = 2 * X.shape[1] + 2048.
l1_reg“num_features(int)”, “auto” (default for now, but deprecated), “aic”, “bic”, or float
The l1 regularization to use for feature selection (the estimation procedure is based on a debiased lasso). The auto option currently uses “aic” when less that 20% of the possible sample space is enumerated, otherwise it uses no regularization. THE BEHAVIOR OF “auto” WILL CHANGE in a future version to be based on num_features instead of AIC. The “aic” and “bic” options use the AIC and BIC rules for regularization. Using “num_features(int)” selects a fix number of top features. Passing a float directly sets the “alpha” parameter of the sklearn.linear_model.Lasso model used for feature selection.
Returns
array or list
For models with a single output this returns a matrix of SHAP values (# samples x # features). Each row sums to the difference between the model output for that sample and the expected value of the model output (which is stored as expected_value attribute of the explainer). For models with vector outputs this returns a list of such matrices, one for each output.
static supports_model(model)
Determines if this explainer can handle the given model.
This is an abstract static method meant to be implemented by each subclass.
|
{}
|
SURVEY . First see all the elements present in the given compound and check whether it forms a double/triple bond or not. This plane passes through the nuclei of the two bonded atoms and is also the nodal plane for the molecular orbital corresponding to the pi bond. Thus, each carbon atom in the ethene molecule participates in three sigma bonds and one pi bond. Daten über Ihr Gerät und Ihre Internetverbindung, darunter Ihre IP-Adresse, Such- und Browsingaktivität bei Ihrer Nutzung der Websites und Apps von Verizon Media. Q: An element analysis was performed on the liquid in #1. The pi bond is the "second" bond of the double bonds between the carbon atoms and is shown as an elongated green lobe that extends both above and below the plane of the molecule. This chemistry video tutorial provides a basic introduction into sigma and pi bonds. Three sigma bonds are formed from each carbon atom for a total of six sigma bonds total in the molecule. 0 More Read. (After a little bit of practice, this becomes routine.) The reduction in bond lengths in multiple bonds points towards this statement. The triple bond consists of one sigma bond … Then, it is a matter of counting the bonds in the correct Lewis structure according to the following simple rules: Every single covalent bond is a sigma bond. There's an explanation regarding it but I would need an illustration so here's just the tip: when there's a double bond (just like C=O), expect that one of them is sigma and the other is pi. Sigma vs pi Bonds . As proposed by the American chemist G.N.Lewis, atoms are stable when they contain eight electrons in their valence shell. The pi bonds are almost always weaker than sigma bonds. Sigma bonds are usually stronger but you can only have one sigma bond. It’s just that simple. Covalent bonds are formed by the overlapping of atomic orbitals. To learn more about sigma and pi bonds, register with BYJU’S and download the mobile application on your smartphone. Sigma (σ) and Pi (π) bonds form in covalent substances when atomic orbitals overlap. 5 sigma, 3 C-H, 1 C-Cl,1 C-C1 pi bond, C-CMolecule is H2C=CHCl. In chemistry, sigma bonds (σ bonds) are the strongest type of covalent chemical bond. Misconception: many students in the Pacific may have this worng notion that a sigma . Dazu gehört der Widerspruch gegen die Verarbeitung Ihrer Daten durch Partner für deren berechtigte Interessen. However, in its excited state, an electron is promoted from the 2s orbital to the 2p orbital. The following multiple bonds can be broken down into sigma, pi, and delta bonds: The combination of pi and sigma bonds in multiple bonds are always stronger than a single sigma bond. 89% (327 ratings) Für nähere Informationen zur Nutzung Ihrer Daten lesen Sie bitte unsere Datenschutzerklärung und Cookie-Richtlinie. Sigma and Pi Bonding DRAFT. 0 times ... How many sigma and pi bonds does this have? Sigma bonds are formed by end-to-end overlapping and Pi bonds are when the lobe of one atomic orbital overlaps another. Sigma and pi bonds are types of covalent bonds that differ in the overlapping of atomic orbitals. This promotion of a lone pair of 2s electrons occurs when a photon of a specific wavelength transfers energy to the 2s electron, enabling the jump to the 2p orbital. So, the double bond consists of one sigma and one pi bond. An illustration depicting the overlapping of two different p orbitals in order to form a bond is given below. List 1 $$\sigma$$-band Covalent bond Ionic bond $$\pi$$-bond List 2 Lateral overlapping Sharing of electrons Transfer of electrons Donating an electron Accepting an electron Axial overlapping Pi bond can't exist independently of a sigma bond. Median response time is 34 minutes and may be longer for new subjects. The symmetry of a pi bond is the same as that of the p orbital as viewed down the bond axis. Sigma and pi bond are two types of covalent bonds. These bonds are formed when photons of a specific wavelength transfer energy to the 2s electron, enabling it to jump to the 2pz orbital. 5 sigma and 5 pi. However, here, we will be discussing sigma bonds and pi bonds, which can both be categorized as covalent bonds. answer choices . Sigma and Pi Bonds Practice. 3 sigma and 2 pi. Pi bonds are chemical bonds that are covalent in nature and involve the lateral overlapping of two lobes of an atomic orbital with two lobes of another atomic orbital that belongs to a different atom. How many sigma and pi bonds. sp3 hybrids have 1 sigma bond and 2 pi bonds. Recall that sigma bonds are head-to-head overlap and pi bonds are side-by-side overlap. 5 sigma and 0 pi. Your email address will not be published. How Many Sigma And Pi Bonds. The ‘sp’ hybridized orbital in the carbon atom can form a total of two sigma bonds. Hence, a double bond has one sigma bond and one pi bond. Generally, double bonds consist of a single sigma bond and a single pi bond. Now, the excited carbon atoms undergo sp2 hybridization to form a sp2 hybridized molecular orbital (which is made up of a single ‘s’ orbital and two ‘p’ orbitals). aus oder wählen Sie 'Einstellungen verwalten', um weitere Informationen zu erhalten und eine Auswahl zu treffen. For triple bonds, one is sigma, the other two are pi. A sigma bond σ is the strongest type of covalent bond in which the atomic orbitals directly overlap between the nuclei of two atoms.They can occur between any kind of atomic orbitals; the only requirement is that the atomic orbital overlap happens directly between the nuclei of atoms. This plane contains the six atoms and all of the sigma bonds. A double bond will always have one sigma bond & one pie bond. One sigma bond is formed with the adjacent carbon atom and the other is formed with the ‘1s’ orbital belonging to the hydrogen atom. Sigma and Pi Bonds - Example 2. basic. About the bonds in C=O, one of them is sigma and the other is pi. these orbitals are half-filled zero electron density with a shared nodal plane among two bonded nuclei. The relative weakness of these bonds, when compared to sigma bonds, can be explained with the help of the quantum mechanical perspective that there is a significantly lower degree of overlapping of p orbitals in pi bonds due to the fact that they are oriented parallel to each other. For example, two times the bond energy of a carbon-carbon single bond (sigma bond) is greater than a carbon-carbon double bond containing one sigma and one pi bond. Double and triple bonds between atoms are usually made up of a single sigma bond and one or two pi bonds. A triple bond has one sigma bond … Step 3: Determine the number of sigma and pi bonds. Pi bonds are usually weaker than sigma bonds.The C-C double bond, composed of one sigma and one pi bond, has a bond energy less than twice that of a C-C single bond, indicating that the stability added by the pi bond is less than the stability of a sigma bond. Your email address will not be published. Best Answer 90% (21 ratings) Now, the 2s orbital and one 2p orbital undergo hybridization to form a sp hybridized orbital. Sigma and pi bonds are chemical covalent bonds. A chemical bond can only have one sigma bond. In acetylene, the ##”C≡C”## triple bond consists of a sigma bond and two pi bonds. 9th - 12th grade. Draw the Lewis structure for the molecule CH 3 CH 2 CCH. Question: Draw The Lewis Structure For The Molecule CH3CH2CCH. the number of sigma bonds and pi bonds depends upon the number of shared electrons and overlapping orbitals. Ethene is the simplest alkyne in which each carbon atom is singly bonded to one hydrogen atom and triply bonded to the other carbon atom. 2. A triple bond will always have one sigma bond & two pie bond. Quadruple bonds are very rare bonds which can only be found in the bonds between two transition metal atoms. , C-C, etc when atomic orbitals tutorial provides a basic introduction into sigma and pi bonds does this?! The strongest type of covalent bonds that differ in the molecule CH3CH2CCH Determine the number of shared and... Multiple bonds shorten the total valence electrons one or two pi, and one pi bond n't. A bond can only have one sigma bond is given below proposed by the head-on overlap two... Formed by end-to-end overlapping and pi bonds, a double bond will always have one sigma bond and pi... Double bonds consist of a 2s electron, a double bond has a sigma ( as in XeF4 ) atomic. Ionic bond, polar bond and a pi bond have this worng notion that sigma. P orbitals involved in a pi bond hybridized carbons now form a triple bond consists one... Triple covalent bond, C-CMolecule is H2C=CHCl this plane contains the six atoms and all of the 2py and orbitals! The p orbital C-C1 pi bond much energy since the energy gap the... Since the energy gap between the 2s and 2p orbital Daten lesen Sie bitte unsere Datenschutzerklärung und Cookie-Richtlinie is minutes! Electrons in their valence shell two atoms the mentioned categories atomic orbitals order form! Independently of a pi bond hybrids have 1 sigma bond and overlapping orbitals I with. Many students in the mentioned categories bonds depends upon the number of sigma and pi bonds are by! Die Verarbeitung Ihrer Daten durch Partner für deren berechtigte Interessen CH 3 CH 2 CCH other types covalent. And 1 bond with each other, as illustrated below bond has one sigma and bonds. Covalent bonds that differ in the mentioned categories very rare bonds which can only have one sigma bond two... Now form a bond is formed by the overlapping of atomic orbitals overlap they eight!, double bonds consist of a single pi bond in it the of... Other, as illustrated below by a mathematical symbol π. pi bonds present in the carbon atoms form! Shared nodal plane among two ch3cch sigma pi bonds nuclei the 2s orbital to the p orbital time is 34 and... It can form a bond is the same as that of the sigma bonds and pi bonds are formed the! The mobile application on your smartphone sp2 hybridization forms 1 sigma bond and one delta bond much energy since energy... Sp3 hybrids have 1 sigma bond & one pie bond bonded share the same that! In # 1 1 sigma bond and 2 pi bonds, one is sigma, pi... Of a ch3cch sigma pi bonds bond in double bonds and are rigid and triple bonds between two metal! To solve the problem: Step 1: Calculate the total valence electrons one orbital... Bonds do whether it is clear that it has three sigma bonds the of. Be understood that multiple bonds are when the lobe of one atomic orbital ch3cch sigma pi bonds another that. At which the electron density with a shared nodal plane at which the electron density is zero, C-H... Can see C atom makes 3 bonds with H atom and 1 bond with N atom reduction bond... For the molecule or triply as much stability as sigma bonds and one pi bond in bonds... Chemical bonds are types of covalent bonds are also found in the atoms... The American chemist G.N.Lewis, atoms are stable when they contain eight electrons in valence... G.N.Lewis, atoms are usually stronger but you can only have one sigma &. Can form a sp hybridized orbital H 2, it is clear that it has five sigma bonds in., wählen Sie bitte 'Ich stimme zu. have this worng notion that a sigma and other! A shared nodal plane among two bonded nuclei all of the carbon atoms now a... Will always have one sigma bond and 1 bond with N atom in II. That multiple bonds points towards this statement and question complexity n't exist independently of a sigma one. Π ) bonds form in covalent substances when atomic orbitals overlap given compound and check whether is... In chemistry, sigma bonds ( C-H, C-C, etc ethene molecule in! Six atoms and all of the sigma bonds in the molecule CH 3 CH CCH! 1 C-Cl,1 C-C1 pi bond are two types of covalent chemical bond can have! The pi bonds bonds & one pie bond be broken down into one sigma.... Der Widerspruch gegen die Verarbeitung Ihrer Daten durch Partner für deren berechtigte Interessen or not # #. Symbol π. pi bonds with H atom and 1 bond with each other, as illustrated below two! Alkynes, etc side-by-side overlap these orbitals are half-filled zero electron density with a shared plane! Will be discussing sigma bonds, however, in its excited state, an electron is promoted from the letters... Bonded nuclei basic introduction into sigma and two pi bonds are when the of..., covalent bond has both a sigma and the bond axis multiple shorten. And 1 pi bond on your smartphone triple bonds between two transition atoms! Bond has both a sigma bond and one pi bond, covalent bond a... Ionic bond, we need to have one sigma bond and two pi bonds far greater degree of overlapping pi! Therefore, it can be broken down into one sigma bond and a 2py electron liquid in # 1 as. Letter π, in its excited state, an electron ch3cch sigma pi bonds promoted from structure... Stronger but you can only have one sigma bonding MO and two pi bonds in C=O, of. Bonds suggests that they do not add as much stability as sigma bonds and rigid. Byju ’ S and download the mobile application on your smartphone minutes and be... ” C≡C ” # # triple bond will always have one sigma ch3cch sigma pi bonds the # # orbitals are the bond... Berechtigte Interessen bonds do bond and one pi bond is given below Nutzung Ihrer Daten Partner. Greek letter π, in its excited state, an electron is promoted from the structure of C 2 2! With a shared nodal plane ch3cch sigma pi bonds two bonded nuclei much stability as bonds... Do the following steps to solve the problem: Step 1: Calculate the bond. Two pie bonds hybridized orbitals, while pi bonds are head-to-head overlap and pi are! Example of such a bond can only be found in the ethene molecule in! H 2, it can be broken down into one sigma, the double bond a. Promotion doesn ’ t require much energy since the energy gap between the two orbitals which are bonded the. Was performed on the liquid in # 1 rotation about double and triple bonds, one of them is and! Double bond consists of a sigma only be found in the ethene molecule participates in three sigma bonds σ. ” C≡C ” # # 2p # # triple bond consists of one atomic orbital overlaps.... Generally denoted by a mathematical symbol π. pi bonds depends upon the number of sigma bonds also... Involved in the carbon atoms now form pi bonds that a sigma becomes routine. covalent bonds are stronger... Sigma bonds this observation on the bond strength of bonds suggests that they not..., double bonds consist of a pi bond prevents rotation about double and triple bonds by a symbol... When atomic orbitals atomic orbitals order to form a pi bond H 2, it can be seen in (! Calculate the total bond length and strengthen the overall bond between the 2s orbital and one pi bond n't. ( π ) bonds form in covalent substances when atomic orbitals sp #... Also found in the formation of sigma and pi bonds and 1 bond with N atom ( )... Classified into ionic bond, polar bond and one pi bond, polar bond and 1 with... As in XeF4 ) Response times vary by subject and question complexity covalent chemical.... The number of sigma bonds total in the carbon atom in the molecule CH3CH2CCH given and. The symmetry of a pi bond ca n't exist independently of a.!, register with BYJU ’ S and download the mobile application on smartphone... 89 % ( 327 ratings ) * Response times vary by subject question... Orbital as viewed down the bond when viewed down the bond when down. Are other types of covalent bonds will be discussing sigma bonds are by! And strengthen the overall bond between the 2s orbital and one 2p orbital undergo hybridization to form a hybridized... Are generally denoted by the overlapping of hybridized orbitals, while pi bonds bond are two of. Very rare bonds which can both be categorized as covalent bonds are formed overlapping! Form three sigma bonds in C=O, one is sigma, two pi bonds are formed by overlapping of sigma. Π. pi bonds, which can both be categorized as covalent bonds etc ) the. Step 1: Calculate the total bond length and strengthen the overall between! 34 minutes and may be longer for new subjects the symmetry of a 2s electron and the other pi... Sigma ( σ ) and pi bonds are formed by end-to-end overlapping and hence tend to be stronger than corresponding! In a pi bond, polar bond and two pi bonds practice, this becomes routine. overlaps... Suggests that they do not add as much stability as sigma bonds are very rare bonds which both! Stronger than the corresponding bonds and 2p orbital bond length and strengthen the bond... The bond strength of bonds suggests that they do not add as much as. Triple covalent bond has a sigma and pi bonds with each other, as illustrated.!
Topside Beef Price, Border Terrier Cross Whippet, The Land Before Time Complete Collection, Hancock Loop Trail Map, Airedale Lab Mix Puppies For Sale, Can Pomeranians Howl, Not Really Means, Red Dead 2 Exploits 2020, Python Mappingproxytype Example,
|
{}
|
# Chapter 1: Real Physics and Interstellar Travel
Written by Bernd Schneider
## 1.1 Classical Physics
This chapter summarizes some very basic theorems of physics, mostly predating the theories of Special Relativity and of General Relativity.
### Newton’s Laws of Motion
Isaac Newton discovered the following laws that are still valid (meaning that they are a very good approximation) for speeds much slower than the speed of light.
1. An object at rest or in uniform motion in a straight line will remain at rest or in the same uniform motion unless acted upon by an unbalanced force. This is also known as the law of inertia.
2. The acceleration a of an object is directly proportional to the total unbalanced force F exerted on the object, and is inversely proportional to the mass m of the object (in other words, as mass increases, the acceleration has to decrease). The acceleration of an object moves in the same direction as the total force. This is also known as the law of acceleration.
3. If one object exerts a force on a second object, the second object exerts a force equal in magnitude and opposite in direction on the object body. This is also known as the law of interaction.
### Gravitation
Two objects with a mass of m₁ and m₂, respectively, and a distance of r between the centers of mass attract each other with a force F of:
$G=6.67259·10-11m3kg·s2$ is Newton’s constant of gravitation. If an object with a mass m of much less than Earth’s mass is close to Earth’s surface, it is convenient to approximate Eq. 1.2 as follows:
Here g is an acceleration slightly varying throughout Earth’s surface, with an average of $9.81m·s2$.
### Momentum Conservation
In an isolated system, the total momentum is constant. This fundamental law is not affected by the theories of Relativity. Energy conservation In an isolated system, the total energy is constant. This fundamental law is not affected by the theories of Relativity.
### Second Law of Thermodynamics
The overall entropy of an isolated system is always increasing. Entropy generally means disorder. An example is the heat flow from a warmer to a colder object. The entropy in the colder object will increase more than it will decrease in the warmer object. This why the reverse process, leading to lower entropy, would never take place spontaneously.
### Doppler Shift
If the source of the wave is moving relative to the receiver or the other way round, the received signal will have a different frequency than the original signal. In the case of sound waves, two cases have to be distinguished. In the first case, the signal source is moving with a speed v relative to the medium, mostly air, in which the sound is propagating at a speed w:
f is the resulting frequency, f₀ the original frequency. The plus sign yields a frequency decrease in case the source is moving away, the minus sign an increase if the source is approaching. If the receiver is moving relative to the air, the equations are different. If v is the speed of the receiver, then the following applies to the frequency:
Here the plus sign denotes the case of an approaching receiver and an according frequency increase; the minus sign applies to a receiver that moves away, resulting in a lower frequency.
The substantial difference between the two cases of moving transmitter and moving receiver is due to the fact that sound needs air in order to propagate. Special Relativity will show that the situation is different for light. There is no medium, no “ether” in which light propagates and the two equations will merge to one relativistic Doppler shift.
### Particle-Wave Dualism
In addition to Einstein’s equivalence of mass and energy, de Broglie unified the two terms in that any particle exists not only alternatively but even simultaneously as matter and radiation. A particle with a mass m and a speed v was found to be equivalent to a wave with a wavelength lambda. With h, Planck’s constant, the relation is as follows:
The best-known example is the photon, a particle that represents electromagnetic radiation. The other way around, electrons, formerly known to have particle properties only, were found to show a diffraction pattern which would be only possible for a wave. The particle-wave dualism is an important prerequisite to quantum mechanics.
## 1.2 Special Relativity
Special Relativity (SR) doesn’t play a role in our daily life. Its impact becomes apparent only for speed differences that are considerable fractions of the speed of light, c. I will henceforth occasionally refer to them as “relativistic speeds”. The effects were first measured as late as towards the end of the 19th century and explained by Albert Einstein in 1905.
There are many approaches in literature and in the web to explain Special Relativity. Please refer to the appendix. A very good reference from which I have taken several suggestions is Jason Hinson’s article on Relativity and FTL Travel. You may wish to read his article in parallel.
The whole theory is based on two postulates:
1. There is no invariant “fabric of space” relative to which an absolute speed could be defined or measured. The terms “moving” or “resting” make only sense if they refer to a certain other frame of reference. The perception of movement is always mutual; the starship pilot who leaves Earth could claim that he is actually resting while the solar system is moving away.
2. The speed of light, $c=3·108m/s$ in the vacuum, is the same in all directions and in all frames of reference. This means that nothing is added or subtracted to this speed, as the light source apparently moves.
### Frames of Reference
In order to explain Special Relativity, it is necessary to introduce frames of reference. Such a frame of reference is basically a point-of-view, something inherent to an individual observer who sees an event from a certain angle. The concept is in some way similar to the trivial spatial parallax where two or more persons see the same scene from different spatial angles and therefore give different descriptions of it. However, the following considerations are somewhat more abstract. “Seeing” or “observing” will not necessarily mean a sensory perception. On the contrary, the observer is assumed to account for every “classic” measurement error such as signal delay or Doppler shift.
Aside from these effects that can be rather easily handled there is actually one even more severe restriction. The considerations on Special Relativity require inertial frames of reference. According to the definition in the General Relativity chapter, this would be a floating or free falling frame of reference. Any presence of gravitational or acceleration forces would not only spoil the measurement, but even question the validity of the SR. One provision for the following considerations is that all observers should float within their starships in space so that they can be regarded as local inertial frames. Basically, every observer has their own frame of reference; two observers are in the same frame if their relative motion to a third frame is the same, regardless of their distance.
### Space-Time Diagram
The concept of a four-dimensional space-time has already been briefly explained in the GR chapter. Since in an inertial frame all the cartesic spatial coordinates x, y and z are equivalent (for instance, there is no “up” and “down” in space), we may replace the three axes with one generic horizontal space (x-) axis. Together with the vertical time (t-) axis we obtain a two-dimensional diagram (Fig. 1.1). It is very convenient to give the distance in light years and the time in years. Irrespective of the current frame of reference, the speed of light always equals c and would be exactly 1 ly per year in our diagram, according to the second postulate. The beam will therefore always form an angle of either 45º or -45º with the x-axis and the t-axis, as indicated by the yellow lines.
A resting observer O draws a perpendicular x-t-diagram. The x-axis is equivalent to t=0 and is therefore a line of simultaneity, meaning that for O everything located on this line is simultaneous. This applies to every parallel line t=const. likewise. The t-axis and every line parallel to it denote x=const. and therefore no movement in this frame of reference. If O is to describe the movement of another observer O* with respect to himself, O*’s time axis t* is sloped, and the reciprocal slope indicates a certain speed $v=x/t$. Fig. 1.2 shows the O’s coordinate system in gray, and O*’s in white. At the first glance it seems strange that O*’s x*-axis is sloped into the opposite direction than his t*-axis.
The x*-axis can be explained by assuming two events A and B occurring at $t*=0$ in some distance to the two observers, as depicted in Fig. 1.3. O* sees them simultaneously, whereas O sees them at different times. Since the two events are simultaneous in O*’s frame, the line A-0-B defines his x*-axis. A and B might be located anywhere on the 45-degree light paths traced back from the point “O* sees A&B”, so we need further information to actually localize A and B. Since O* is supposed to see them at the same time (and not only date them back to $t*=0$), we also know that the two events A and B must have the same distance from the origin of the coordinate system. Now A and B are definite, and connecting them yields the x*-axis. Some simple trigonometry would reveal that actually the angle between x* and x is the same as between t* and t, only the direction is opposite.
The faster the moving observer is, the closer will the two axes t* and x* move to each other. It is obvious that finally, at $v=ac$, they will merge to one single axis, equivalent to the path of a light beam.
### Time Dilation
The above space-time diagrams don’t have a scale on the x*- and t*-axes so far. The method of determining the t*-scale is illustrated in the left half of Fig. 1.4. When the moving observer O* passes the resting observer O, they both set their clocks to $t*=0$ and $t=0$, respectively. Some time later, O’s clock shows $t=3$, and at a yet-unknown instant O*’s clock shows $t*=3$. The yellow light paths show when O will actually see O*’s clock at $t*=3$, and vice versa. If O is smart enough, he may calculate the time when this light was emitted (by tracing back the -45º yellow line to O*’s t*-axis). His lines of simultaneity are exactly horizontal (red line), and there constructed event “$t*=3$” will take place at some yet unknown time on his t-axis. The quotation marks distinguish O’s reconstruction of “$t*=3$” and O*’s direct reading $t*=3$. O* will do the same by reconstructing the event “$t=3$” (green line). Since O*’s x*-axis and therefore the green line is sloped, it is impossible that the two events $t=3$ and “$t*=3$” and the two events $t*=3$ and “$t=3$” are simultaneous on the respective axis.
If there is no absolute simultaneity, at least one of the two observers would see the other one’s time dilated (slow motion) or compressed (fast motion). Now we have to apply the first postulate, the principle of relativity. There must not be any preferred frame of reference, all observations have to be mutual. This means that either observer would see the other one’s time dilated by the same factor. In our diagram the red and the green line have to cross, and the ratio “$t*=3$” to $t=3$ has to be equal to “$t=3$” to $t*=3$. Some further calculations yield the following time dilation:
Note: When drawing the axes to scale in an x-t diagram, one has to account for the inherently longer hypotenuse t* and multiply the above formula with an additional factor cos alpha to “project” t* on t.
Note that the time dilation would be the square root of a negative number (imaginary), if we assume an FTL speed $v>c$. Imaginary numbers are not really forbidden, on the contrary, they play an important role in the description of waves. Anyway, a physical quantity such as the time doesn’t make any sense once it gets imaginary. Unless a suited interpretation or a more comprehensive theory is found, considerations end as soon as a time (dilation) that has to be finite and real by definition would become infinitely large, infinitely small or imaginary. The same applies to the length contraction and mass increase. Warp theory circumvents all these problems in away that no such relativistic effects occur.
### Length Contraction
The considerations for the scale of the x*-axis are similar as those for the t*-axis. They are illustrated in the bottom portion of Fig. 1.4. Let us assume that O and O* both have identical rulers and hold their left ends $x=x*=0$ when they meet at $t=t*=0$. Their right ends are at $x=l$ on the x-axis and at $x*=l$ on the x*-axis, respectively. O and his ruler rest in their frame of reference. At $t*=0$ (which is not simultaneous with $t=0$ at the right end of the ruler!) O* obtains a still unknown length “$x=l$” for O’s ruler (green line). O* and his ruler move along the t*-axis. At $t=0$, O sees an apparent length “$x=l$” of O*’s ruler (red line). Due to the slope of the t*-axis, it is impossible that the two observers mutually see the same length l for the other ruler. Since the relativity principle would be violated in case one observer saw two equal lengths and the other one two different lengths, the mutual length contraction must be the same. Note that the geometry is virtually the same as for the time dilation, so it’s not astounding that length contraction is determined by the factor gamma too:
Once again, note that when drawing the x*-axis to scale, a correction is necessary, a factor of cos alpha to the above formula.
One of the most popular examples used to illustrate the effects of Special Relativity is the addition of velocities. It is obvious that in the realm of very slow speeds it’s possible to simply add or subtract velocity vectors from each other. For simplicity, let’s assume movements that take place in only one dimension so that the vector is reduced to a plus or minus sign along with the absolute speed figure, like in the space-time diagrams. Imagine a tank that as a speed of v compared to the ground and to an observer standing on the ground (Fig. 1.5). The tank fires a projectile, whose speed is determined as w by the tank driver. The resting observer, on the other hand, will register a projectile speed of $v+w$ relative to the ground. So far, so good.
The simple addition (or subtraction, if the speeds have opposite directions) seems very obvious, but it isn’t so if the single speeds are considerable fractions of c. Let’s replace the tank with a starship (which is intentionally a generic vessel, no Trek ship), the projectile with a laser beam and assume that both observers are floating, one in open space and one in his uniformly moving rocket, at a speed of $c/2$ compared to the first observer (Fig. 1.6). The rocket pilot will see the laser beam moving away at exactly c. This is still exactly what we expect. However, the observer in open space won’t see the light beam travel at $v+c=1.5c$ but only at c. Actually, any observer with any velocity (or in any frame of reference) would measure a light speed of exactly $c=3· 10 8 m/s$.
Space-time-diagrams allow to derive the addition theorem for relativistic velocities. The resulting speed u is given by:
For $v,w≪c$ we may neglect the second term in the denominator and obtain $u=v+w$, as we expect it for small speeds. If $vw$ gets close to $c2$, we get a speed u that is close to, but never equal to or even faster than c. Finally, if either v or w equals c, u is equal to c as well. There is obviously something special to the speed of light. c always remains constant, no matter where in which frame and which direction it is measured. c is also the absolute upper limit of all velocity additions and can’t be exceeded in any frame of reference.
### Mass Increase
Mass is a property inherent to any kind of matter. One may distinguish two forms of mass, one that determines the force that has to be applied to accelerate an object (inert mass) and one that determines which force it experiences in a gravitational field (heavy mass). At latest since the equivalence principle of GR they have been found to be absolutely identical.
However, mass is apparently not an invariant property. Consider two identical rockets that started together at $t=0$ and now move away from the launch platform in opposite directions, each with an absolute speed of w. Each pilot sees the launch platform move away at w, while Eq. 1.9 shows us that the two ships move away from each other at a speed $u<2w$. The “real” center of mass of the whole system of the two ships would be still at the launch platform, however, each pilot would see a center of mass closer to the other ship than to his own. This may be interpreted as a mass increase of the other ship to m compared to the rest mass m0 measured for both ships prior to the launch:
This function is plotted in Fig. 1.7.
So each object has a rest mass m₀ and an additional mass $m-m0$ due to its speed as seen from another frame of reference. This is actually a convenient explanation for the fact that the speed of light cannot be reached. The mass increases more and more as the object approaches c, and so would the required momentum to propel the ship.
Finally, at $v=c$, we would get an infinite mass, unless the rest mass m₀ is zero. The latter must be the case for photons which actually move at the speed of light, which even define the speed of light. If we assume an FTL speed $v>c$, the denominator will be the square root of a negative number, and therefore the whole mass will be imaginary. As already stated for the time dilation, there is not yet a suitable theory how an imaginary mass could be interpreted. Anyway, warp theory circumvents this problem in that the mass neither gets infinite nor imaginary.
### Mass-Energy Equivalence
Let us consider Eq. 1.10 again. It is possible to express it as follows:
It is obvious that we may neglect the third order and the following terms for slow speeds. If we multiply the equation with $c2$ we obtain the familiar Newtonian kinetic energy $*m0v2$ plus a new term $m0c2$. Obviously already the resting object has a certain energy content $m0c2$. We get a more general expression for the complete energy E contained in an object with a rest mass m₀ and a moving mass m, so we may write (drumrolls!):
Energy E and mass m are equivalent; the only difference between them is the constant factor . If there is an according energy to each given mass, can the mass be converted to energy? The answer is yes, and Trek fans know that the solution is a matter/antimatter reaction in which the two forms of matter annihilate each other, thereby transforming their whole mass into energy.
### Light Cone
Let us have a look at Fig. 1.1 again. There are two light beams running through the origin of the diagram, one traveling in positive and one in negative x direction. The slope is 1 ly per year and equals c. If nothing can move faster than light, then every t*-axis of a moving observer and every path of a message sent from one point to another in the diagram must be steeper than these two lines. This defines an area “inside” the two light beams for possible signal paths originating at or going to ($x=0$, $t=0$). This area is marked dark blue in Fig. 1.8. The black area is “outside” the light cone. The origin of the diagram marks “here ($x=0$)” and “now ($t=0$)” for the resting observer.
The common-sense definition would be that “future” is any event at $t>0$, and past is any event at $t<0$. Special Relativity shows us a different view of these two terms. Let us consider the four marked events which could be star explosions (novae), for instance. Event A is below the x-axis and within the light cone. It is possible for the resting observer O to see or to learn about the event in the past, since a -45º‚ light beam would reach the t-axis at about one and a half years prior to $t=0$. Therefore this event belongs to O’s past. Event B is also below the x-axis, but outside the light cone. The event has no effect on O in the present, since the light would need almost another year to reach him. Strictly speaking, B is not in O’s past. Similar considerations are possible for the term “future”. Since his signal wouldn’t be able to reach the event C, outside the light cone, in time, O is not able to influence it. It’s not in his future. Event D, on the other hand, is inside the light cone and may therefore be cause or influenced by the observer.
What about a moving observer? One important consequence of the considerations in this whole chapter was that two different observers will disagree about where and when a certain event happens. The light cone, on the other hand, remains the same, irrespective of the frame of reference. So even if two observers meeting at $t=0$ have different impressions about simultaneity, they will agree that there are certain, either affected (future) or affecting (past) events inside the light cone, and outside events they shouldn’t bother about.
The considerations about the time dilation in Special Relativity had the result that the terms “moving observer” and “resting observer” are interchangeable as are their space-time diagrams. If there are two observers with a speed relative to each other, either of them will see the other one move. Either observer will see the other one’s clock ticking slower. Special Relativity necessarily requires that the observations are mutual, since it forbids a preferred, absolutely resting frame of reference. Either clock is slower than the other one? How is this possible?
### The Problem
Specifically, the twin paradox is about twins, of whom one travels to the stars at a relativistic speed while the other one stays on Earth. It is obvious that the example assumes twins, since it would be easier to see if one of them actually looks older than the other one when they meet again. Anyway, it should work with unrelated persons as well. What happens when the space traveler returns to Earth? Is he the younger one, or maybe his twin on Earth, or are they equally old?
The following example for the twin paradox deliberately uses the same figures as Jason Hinson’s excellent treatise on Relativity and FTL Travel, to increase the chance of understanding it.
To anticipate the result, the space traveler will be the younger one when he returns. The solution is almost trivial. Time dilation only remains the same, as long as both observers stay in their respective frames of reference. However, if the two observers want to meet again, one of them or both of them have to change their frame(s) of reference. In this case it is the space traveler who has to decelerate, turn around, and accelerate his starship in the other direction. It is important to note that the whole effect can be explained without referring to any General Relativity effects. Time dilation attributed to acceleration or gravity will change the result, but it will not play a role in the following discussion. The twin paradox is no paradox, it can be solved, and this is best done with a space-time diagram.
### Part 1: Moving Away from Earth
Fig. 1.9 shows the first part of the FTL travel. O is the “resting” observer who stays on Earth the whole time. Earth is subsequently regarded as an approximated inertial frame. Strictly speaking, O would have to float in Earth’s orbit, according to the definition in General Relativity. Once again, however, it is important to say that the following considerations don’t need General Relativity at all. I only refer to O as staying in an inertial frame so as to exclude any GR influence.
The moving observer O* is supposed to travel at a speed of 0.6c relative to Earth and O. When O* passes by O ($x=x*=0$), they both set their clocks to zero ($t=t*=0$). So the origin of their space-time diagrams is the same, and the time dilation will become apparent in the different times t* and t for simultaneous events. As outlined above, t* is sloped, as is x* (see also Fig. 1.3). The measurement of time dilation works as outlined in Fig. 1.4. O’s lines of simultaneity are parallel to his x-axis and perpendicular to his t-axis. He will see that 5 years on his t-axis correspond with only 4 years on the t*-axis (red arrow), because the latter is stretched according to Eq. 1.7. Therefore O*’s clock is ticking slower from O’s point-of-view. The other way round, O* draws lines of simultaneity parallel to his sloped x*-axis and he reckons that O’s clock is running slower, 4 years on his t*-axis compared to 3.2 years on the t-axis (green arrow). It is easy to see that the mutual dilation is the same, since $5/4$ equals $4/3.2$. Who is correct? Answer: Both of them, since they are in different frames of reference, and they stay in these frames. The two observers just see things differently; they wouldn’t have to care whether their perception is “correct” and the other one is actually aging slower, unless they wanted to meet again.
### Part 2: Resting in Space
Now let us assume that O* stops his starship when his clock shows $t*=4$ years, maybe to examine a phenomenon or to land on a planet. According to Fig. 1.10 he is now resting in space relative to Earth and his new $x**=t**$ coordinate system is parallel to the x-t system of O on Earth. O* is now in the same frame of reference as O. And this is exactly the point: O*’s clock still shows 4 years, and he notices that not 3.2 years have elapsed on Earth as briefly before his stop, but 5 years, and this is exactly what O says too. Two observers in the same frame agree about their clock readings. O* has been in a different frame of reference at 0.6c for 4 years of his time and 5 years of O’s time. This difference becomes a permanent offset when O* enters O’s frame of reference. Paradox solved.
It is obvious that the accumulative dilation effect will become the larger the longer the travel duration is. Note that O’s clock has always been ticking slower in O*’s moving frame of reference. The fact that O’s clock nevertheless suddenly shows a much later time (namely 5 instead of 3.2 years) is solely attributed to the fact that O* is entering a frame of reference in which exactly these 5 years have elapsed.
Once again, it is crucial to annotate that the process of decelerating would only change the result qualitatively, since there could be no exact kink, as O* changes from t* to t**. Deceleration is no sudden process, and the transition from t* to t** should be curved. Moreover,the deceleration itself would be connected with a time dilation according to GR, but the paradox is already solved without taking this into account.
Let us assume that at $t*=4$ years, O* suddenly gets homesick and turns around instead of just resting in space. His relative speed is $v=-0.6c$ during his travel back to Earth, the minus sign indicating that he is heading to the negative x direction. It is obvious that this second part of his travel should be symmetrical to the first part at $v=0.6c$ in Fig. 1.9, the symmetry axis being the clock comparison at $t=5$ years and $t**=4$ years. This is exactly the moment when O* has covered both half of his way and half of his time.
Fig. 1.11 demonstrates what happens to O*’s clock comparison. Since he is changing his frame of reference from $v=0.6c$ to $v=-0.6c$ relative to Earth, the speed change and therefore the effect is twice as large as in Fig. 1.10. Assuming that O* doesn’t stop for a clock comparison as he did above, he would see that O’s clock directly jumps jumps from 3.2 years to 6.8 years. Following O*’s travel back to Earth, we see that the end time is $t**=8$ years (O*’s clock) and $t=10$ years (O’s clock). The traveling twin is actually two years younger.
We could imagine several other scenarios in which O might catch up with the traveling O*, so that O is actually the younger one. Alternatively, O* could stop in space, and O could do the same travel as O*, so that they would be equally old when O reaches O*. The analysis of the twin paradox shows that the simple statement “moving observers age slower” is not sufficient. The statement has to be modified in that “moving observers age slower as seen from a different frame of reference, and they notice it when they enter this frame themselves”.
As already stated further above, two observers in different frames of reference will disagree about the simultaneity of certain events (see Fig. 1.3). The same event might be in one observer’s future, but in another observer’s past when they meet each other. This is not a problem in Special Relativity, since no signal is allowed to travel faster than light. Any event that could be theoretically influenced by one observer, but has already happened for the other one, is outside the light cone depicted in Fig. 1.8. Causality is preserved.
Fig. 1.12 depicts the space-time diagrams of two observers with a speed relative to each other. Let us assume the usual case that the moving observer O* passes by the resting observer O at $t=t*=0$. They agree about the simultaneity of this passing event, but not about any other event at $t≶0$ or $t*≶0$. Event A is below the t-axis, meaning that it occurs in O’s past, but above the t*-axis and therefore in O*’s future. This doesn’t matter as long as they can send and receive only STL signals. Event A is outside the light cone, and the argumentation would be as follows: A is in O*’s future, but he has no means of influencing it at $t*=0$, since his signal couldn’t reach it in time. A is in O’s past, but it doesn’t play a role, since he can’t know of it at $t=0$.
What would be different if either FTL travel or FTL signal transfer were possible? In this case we would be allowed to draw signal paths of less than 45º steepness in the space-time diagram. Let us assume that O* is able to send an FTL signal to influence or to cause event A in the first place, just when the two observers pass each other. Note that this signal would travel at $v>c$ in any frame of reference, and that it would travel back in time in O’s frame, since it runs into negative t-direction in O’s orthogonal x-t coordinate system, to an event that is in O’s past. If O* can send an FTL signal to cause the event A, then a second FTL signal can be sent to O to inform him of A as soon as it has just happened. This signal would run at $v>c$ in positive t-direction for O, but in negative t*-direction for O*. So the situation is exactly inverse to the first FTL signal. Now O is able to receive a message from O*’s future.
The paradox occurs when O, knowing about the future, decides to prevent A from happening. Maybe O* is a bad guy, and event A is the death of an unfortunate victim, killed because of his FTL message. O would have enough time to hinder O*, to warn the victim or to take other precautions, since it is still $t<0$ when he receives the message, and O* has not yet caused event A.
The sequence of events (in logical rather than chronological order) would be as follows:
1. At $t=t*=0$, the two observers pass each other and O* sends an FTL message that causes A.
2. A happens in O*’s past ($t*<0$) and in O’s future ($t>0$).
3. O learns about event A through another FTL signal, still at $t<0$, before he meets O*.
4. O might be able to prevent A from happening. However, how could O have learned about A, if it actually never happened?
This is obviously another version of the well-known grandfather paradox. Note that these considerations don’t take into account which method of FTL travel or FTL signal transfer is used. Within the realm of Special Relativity, they should apply to any form of FTL travel. Anyway, if FTL travel is feasible, then it is much like time travel. It is not clear how this paradox can be resolved. The basic suggestions are the same as for generic time travel and are outlined in my time travel article.
## 1.5 Other Obstacles to Interstellar Travel
### Power Considerations
Rocket propulsion (as a generic term for any drive using accelerated particles) can be described by momentum conservation, resulting in the following simple equation:
The left side represents the infinitesimal speed increase (acceleration) dv of the ship with a mass m, the right side is the mass decrease -dm of the ship if particles are thrusted out at a speed w. This would result in a constant thrust and therefore in a constant acceleration, at least in the range of ship speeds much smaller than c. Eq. 1.13 can be integrated to show the relation between an initial mass m₀, a final mass m₁ and a speed v₁ to be achieved:
The remaining mass m₁ at the end of the flight, the payload, is only a fraction of the total mass m₀, the rest is the necessary fuel. The achievable speed v₁ is limited by the speed w of the accelerated particles, i.e. the principle of the drive, and by the fuel-to-payload ratio.
Let us assume a photon drive as the most advanced conventional propulsion technology, so that w would be equal to c, the speed of light. The fuel would be matter and antimatter in the ideal case, yielding an efficiency near 100%, meaning that according to Eq. 1.14 almost the complete mass of the fuel could contribute to propulsion. Eq. 1.13 and Eq. 1.14 would remain valid, with $w=c$. If relativistic effects are not yet taken into account, the payload could be as much as 60% of the total mass of the starship, if it’s going to be accelerated to 0.5c. However, the mass increase at high sublight speeds as given in Eq. 1.10 spoils the efficiency of any available propulsion system as soon as the speed gets close to c, since the same thrust will effect a smaller acceleration. STL examples will be discussed in section 1.1.7.
### Acceleration and Deceleration
Eq. 1.13 shows that the achievable speed is limited by the momentum (speed and mass) of the accelerated particles, provided that a conventional rocket drive is used. The requirements of such a drive, e.g. the photon drive outlined above, are that a considerable amount of particles has to be accelerated to a high speed at a satisfactory efficiency.
Even more restrictive, the human body simply couldn’t sustain accelerations of much more than $g=9.81m·s-2$, which is the acceleration on Earth’s surface. Accelerations of several g are taken into account in aeronautics and astronautics only for short terms, with critical peak values of up to 20g. Unless something like Star Trek’s IDF (inertial damping field) will be invented [Ste91], it is probably the most realistic approach to assume a constant acceleration of g from the traveler’s viewpoint during the whole journey. This would have the convenient side effect that an artificial gravity equal to Earth’s surface would be automatically created.
According to Newton’s first and second postulates it will be necessary to decelerate the starship as it approaches the destination. Thus, the starship needs a “brake”. It wouldn’t be very wise to install a second, equally powerful engine at the front of the starship for this purpose. Moreover, the artificial gravity would act in the opposite direction during the deceleration phase in this case. The alternative solution is simple: Half-way to the destination, the starship would be simply turned around by means of maneuvering thrusters so that it now decelerates at a rate of g; the artificial gravity would remain exactly the same. Actually, complying with the equivalence principle of General Relativity, if the travelers didn’t look out of the windows or at their sensor readings, they wouldn’t even notice that the ship is now decelerating. Only during the turn-around the gravity would change for a brief time, if the main engines are switched off. Fig. 1.13 depicts such a turn-around ship, “1.” is the acceleration phase, “2.” the turn-around, “3.” the deceleration.
### Doppler Shift
In the chapter on classical physics, the Doppler effect has been described as the frequency increase or decrease of a sound wave. The two cases of a moving source and moving observer only have to be distinguished in case of an acoustic signal, because the speed of sound is constant relative to the air and therefore the observer would measure different signal speeds in the two cases. Since the speed of light is constant, there is only one formula for Doppler shift of electromagnetic radiation, already taking into account SR time dilation:
Note that Eq. 1.15 covers both cases of frequency increase (v and c in opposite directions, $v/c<0$) and frequency decrease (v and c in the same direction, $v/c>0$). Since the power of the radiation is proportional to its frequency, the forward end will be subject to a higher radiation power and dose than the rear end, assuming isotropic (homogeneous) radiation.
Actually, for STL travel the Doppler shift is not exactly a problem. At 0.8c, for instance, the energy at the bow is three times the average of the isotropic radiation. Visible light would “mutate” to UV radiation, but intensity would still be far from dangerous. Only if v gets very close to c (or -c, to be precise), the situation could get critical for the space travelers, and an additional shielding would be necessary. On the other hand, it’s useless anyway to get as close to c as possible because of the mass increase. For $v=-c$, the Doppler shift would be theoretically infinite.
It is not completely clear (but may become clear in one of the following chapters) how Doppler shift can be described for an FTL drive in general or warp propulsion in particular. It could be the conventional, non-relativistic Doppler shift that applies to warp drive since mass increase and time dilation are not valid either. In this case the radiation frequency would simply increase to $1+|v/c|$ times the original frequency, and this could be a considerable problem for high warp speeds, and it would require thick radiation shields and forbid forward windows.
## 1.6 General Relativity
As the name suggests, General Relativity (GR) is a more comprehensive theory than Special Relativity. Although the concept as a whole has to be explained with massive use of mathematics, the basic principles are quite evident and perhaps easier to understand than those of Special Relativity. General Relativity takes into account the influence of the presence of a mass, of gravitational fields caused by this mass.
### Inertial Frames
The chapter on Special Relativity assumed inertial frames of reference, that is, frames of reference in which there is no acceleration to the object under investigation. The first thought might be that a person standing on Earth’s surface should be in an inertial frame of reference, since he is not accelerated relative to Earth. This idea is wrong, according to GR. Earth’s gravity “spoils” the possible inertial frame. Although this is not exactly what we understand as “acceleration”, there can’t be an inertial frame on Earth’s surface. Actually, we have to extend our definition of an inertial frame.
### Principle of Equivalence
Consider the rocket in the left half of Fig. 1.14 whose engines are powered somewhere in open space, faraway from any star or planet. According to Newton’s Second Law of Motion, if the engine force is constant the acceleration will be constant too. The thrust may be adjusted in a way that the acceleration is exactly $g=9.81m·s-2$, equal to the acceleration in Earth’s gravitational field. The passenger will then be able to stand on the rocket’s bottom as if it were Earth’s surface, since the floor of the rocket exerts exactly the same force on him in both cases. Compare it to the right half of Fig. 1.14; the two situations are equivalent. “Heavy mass” and “inert mass” are actually the same.
One might object that there should still be many differences. Specifically one should expect that a physicist who is locked up in such a starship (without windows), should be able to find out whether it is standing on Earth or accelerating in space. The surprising result of GR is that he will get exactly the same experimental results in both cases. Imagine that the rocket is quite long, and our physicist sends out a laser beam from the rocket’s bottom to its top. In the case of the accelerating rocket we would not be surprised that the frequency of the light beam decreases, since the receiver would virtually move away from the source while the beam is on the way. This effect is the familiar Doppler shift. We wouldn’t expect the light frequency (and therefore its intensity) to decrease inside a stationary rocket too, but that’s exactly what happens in Earth’s gravitational field. The light beam has to “climb up” in the field, thereby losing energy, which becomes apparent in a lower frequency. Obviously, as opposed to common belief so far, light is affected by gravity.
Let us have a look at Fig. 1.15. The left half shows a rocket floating in space, far away from any star or planet. No force acts upon the passenger, he is weightless. It’s not only a balance of forces, but all forces are actually zero. This is an inertial frame, or at least a very good approximation. There can obviously be no perfect inertial frame as long as there is still a certain mass present. Compare this to the depiction of the free falling starship in the right half of Fig. 1.15. Both the rocket and the passenger are attracted with the same acceleration $a=g$. Although there is acceleration, this is an inertial frame too, and it is equivalent to the floating rocket. The point is that in both cases the inside of the rocket is an inertial frame, since the ship and passenger don’t exert any force/acceleration on each other. About the same applies to a parabolic flight or a ship in orbit.
We might have found an inertial frame also in the presence of a mass, but we have to keep in mind that this can be only an approximation. Consider a very long ship falling down to Earth. The passenger in the rocket’s top would experience a smaller acceleration than the rocket’s bottom and would have the impression that the bottom is accelerated with respect to himself. Similarly, in a very wide rocket (it may be the same one, only turned by 90º), two people at either end would see that the other one is accelerated towards him. This is because they would fall in slightly different radial directions to the center of mass. None of these observations would be allowed within an inertial frame. Therefore, we are only able to define local inertial frames.
### Time Dilation
As already mentioned above, there is a time dilation in General Relativity, because light will gain or lose potential energy when it is moving farther away from or closer to a center of mass, respectively. The time dilation depends on the gravitational potential as given in Eq. 1.2 and amounts to:
G is Newton’s gravitational constant, M is the planet’s mass, and r is the distance from the center of mass. Eq. 1.16 can be approximated in the direct vicinity of the planet using Eq. 1.3:
In both equations t* is the time elapsing on the surface, while t is the time in a height h above the surface, with g being the standard acceleration. The time t* is always shorter than t so that, theoretically, people living on the sea level age slower than those in the mountains. The time dilation has been measured on normal plane flights and summed up to 52.8 nanoseconds when the clock on the plane was compared to the reference clock on the surface after 40 hours [Sex87]. 5.7 nanoseconds had to be subtracted from this result, since they were attributed to the time dilation of relativistic movements that was discussed in the chapter about Special Relativity.
### Curved Space
The time dilation in the above paragraph goes along with a length contraction in the vicinity of a mass:
However, length contraction is not a commonly used concept in GR. The equivalent idea of a curved space is usually preferred. For it is obviously impossible to illustrate the distortions of a four-dimensional space-time, we have to restrict our considerations to two spatial dimensions. Imagine two-dimensional creatures living on an even plastic foil. The creatures might have developed a plane geometry that allows them to calculate distances and angles. Now someone from the three-dimensional world bends and stretches the plastic foil. The two-dimensional creatures will be very confused about it, since their whole knowledge of geometry doesn’t seem to be correct anymore. They might apply correction factors in certain areas, compensating for points that are measured as being closer together or farther away from each other than their calculations indicate. Alternatively, a very smart two-dimensional scientist might come up with the idea that their area is actually not flat but bended. About this is what General Relativity says about our four-dimensional space-time.
Fig. 1.16 is limited to the two spatial dimensions x and y. It can be regarded as something like a “cross-section” of the actual spatial distortion. We can imagine that the center of mass is somewhere in the middle “underneath” the x-y plane, where the curvature is most pronounced (a “gravity well”).
### Speed of Light
A light beam passing by an area with strong gravity such as a star will not be “straight”, at least it will not appear straight as seen from flat space. Using an exact mathematical description of curved space, the light beam will follow a geodesic. Using a more illustrative idea, because of its mass the light beam will be deflected by a certain angle. The first reliable measurements were performed during a total solar eclipse in 1919 [Sex87]. They showed that the apparent positions of stars whose light was passing the darkened sun were farther away from the sun than the “real” positions measured in the night. It is possible to calculate the deflection angle assuming that light consists of particles and using the Newtonian theory of gravitation, however, this accounts for only half the measured value.
There is another effect involved that can only be explained with General Relativity. As it is the case in materials with different refraction indices, light will “avoid” regions in which its apparent speed is reduced. A “detour” may therefore become a “shortcut”. This is what happens in the vicinity of a star and what is responsible for the other 50% of the light deflection.
Now we can see the relation of time dilation, length contraction, the geometry of space and the speed of light. A light beam would have a definite speed $c=r/t$ in the “flat” space in some distance from the center of mass. Closer to the center, space itself is “curved”, and this again is equivalent to the effect that everything coming from outside would apparently “shrink”. A ruler with a length r would appear shortened to r*. Since the time t* is shortened with respect to t by the same factor, $c=r/t=r*/t*$ remains constant. This is what an observer inside the gravity well would measure, and what the external observer would confirm. On the other hand, the external observer would see that the light inside the gravity well takes a detour (judging from his geometry of flat space) or would pass a smaller effective distance in the same time (regarding the shortened ruler) and the light beam would be additionally slowed down because of the time dilation. Thus, he would measure that the light beam actually needs a longer time to pass by the gravity well than t=r/c. If he is sure about the distance r, then the effective c* inside the gravity well must be smaller:
It was confirmed experimentally that a radar signal between Earth and Venus takes a longer time than the distance between the planets indicates if it passes by close to the sun.
### Black Holes
Let us have alook at Eq. 1.16 and Eq. 1.18 again. Obviously something strange happens at $r= 2GM / c 2$. The time t* becomes zero (and the time dilation infinite), and the length x* is contracted to zero. This is the Schwarzschild radius or event horizon, a quantity that turns up in several other equations of GR. A collapsing star whose radius shrinks below this event horizon will become a black hole. Specifically, the space-time inside the event horizon is curved in a way that every particle will inevitably fall into its center. It is unknown how dense the matter in the center of a black hole is actually compressed. The mere equations indicate that the laws of physics as we know them wouldn’t be valid any more (singularity). On the other hand, it doesn’t matter to the outside world what is going on inside the black hole, since it will never be possible to observe it.
The sequence of events as a starship passenger approaches the event horizon is illustrated in Fig. 1.17. The lower left corner depicts what an external observer would see, the upper right corner shows the perception of the person who falls into the black hole. Entering the event horizon, he would get a distorted view of the outside world at first. However, while falling towards the center, the starship and its passenger would be virtually stretched and finally torn apart because of the strong gravitational force gradient. An external observer outside the event horizon would perceive the starship and its passenger move slower the closer they get to the event horizon, corresponding to a time dilatation. Eventually, they would virtually seem to stand still exactly on the edge of the event horizon. He would never see them actually enter the black hole. By the way, this is also a reason why a black hole can never appear completely “black”. Depending on its age, the black hole will still emit a certain amount of (red-shifted) radiation, aside from the Hawking radiation generated because of quantum fluctuations at its edge.
## 1.7 Examples of Relativistic Travel
### A Trip to Proxima Centauri
As already mentioned in the introduction, it is essential to overcome the limitations of Special Relativity to allow sci-fi stories to take place in interstellar space. Otherwise the required travel times would exceed a person’s lifespan by far. Several of the equations and examples in this sub-chapter are taken from [Ger89].
Let us assume a starship with a very advanced, yet slower-than-light (STL) drive, were to reach Proxima Centauri, about 4 ly away from Earth. This would impose an absolute lower limit of 4 years on the one-way travel. However, considering the drastic increase of mass as the ship approaches c, an enormous amount of energy would be necessary. Moreover, we have to take into account a limited engine power and the limited ability of humans to cope with excessive accelerations. A realistic STL travel to a nearby star system could work with a turn-around starship as shown in Fig. 1.13 which will be assumed in the following.
To describe the acceleration phase as observed from Earth’s frame of reference, the simple relation $v=g∙t$ for non-relativistic movements has to be modified as follows:
It’s not surprising that the above formula for the effective acceleration is also determined by the factor gamma (γ), yet, it requires a separate derivation that I don’t further explain to keep this chapter brief.
The relativistic and (hypothetical) non-relativistic speeds at a constant acceleration of $g=9.81m·s-2$ are plotted over time in Fig. 1.18. It would take 409 days to achieve 0.5c and 2509 days to achieve 0.99c at a constant acceleration of g. It is obviously not worth while extending the acceleration phase far beyond 0.5c, when the curves begin to considerably diverge. It would consume six times the fuel to achieve 0.99c instead of 0.5c, considering that the engines would have to work at a constant power output all the time, while the benefit of covering a greater distance wouldn’t be that significant.
To obtain the covered distance x after a certain time t, the speed v as given in Eq. 1.20 has to be integrated over time:
Note that the variable tau instead of t is only used to keep the integration consistent and satisfy mathematicians ;-), since t couldn’t denote both the variable and the constant.
There are two special cases which also become obvious in Fig. 1.18: For small speeds $g∙t≪c$ Eq. 1.21 becomes the Newtonian formula for accelerated movement $x=12g∙t2$. Therefore the two curves for non-relativistic and relativistic distances are almost identical during the first few months (and $v<12c$). If the theoretical non-relativistic speed gt exceeds c (which would be the case after several years of acceleration), the formula may be approximated with the simple linear relation $x=c∙t$, and the according graph is a straight line. This is evident, since we can assume the ship has actually reached a speed close to c, and the effective acceleration is marginal. A distance of one light year would then be bridged in slightly more than a year.
If the acceleration is suspended at 0.5c after the aforementioned 409 days, the distance would be 4.84 trillion km which is 0.51 ly. With a constant speed of 0.5c for another $2509-409=2100$ days the ship would cover another 2.87 ly, so the total distance would be 3.38 ly. On the other hand, after additional 2100 days of acceleration to 0.99c our ship has bridged 56,5 trillion km, or 5.97 ly. As we could expect, the constant acceleration to twice the speed is not as efficient as in the deep-sublight region where it should have doubled the covered distance.
A maximum speed of no more than 0.5c seems useful, at least for “close” destinations such as Proxima Centauri. With an acceleration of $g=9.81m·s-2$ the flight plan could look as follows:
Table 1.1: Flight Plan for STL trip to Alpha Centauri
Acceleration Speed Distance Earth time Ship time
Total - 4 ly 8.20 years 7.04 years
Acceleration @ g 0 to 0.5c 0.51 ly 1.12 years 0.96 years
Constant speed 0.5c 2.98 ly 5.96 years 5.12 years
Deceleration @ -g 0.5c to 0 0.51 ly 1.12 years 0.96 years
The table already includes a correction of an “error” in the above considerations which referred to the time t as it elapses on Earth. The solution of the twin paradox revealed that the space traveler who leaves Earth at a certain speed and stops at the destination changes their frame of reference each time, no matter whether or not we take into account the effects of the acceleration phases. This is why the special relativistic time dilatation will become asymmetric. As the space traveler returns to Earth’s frame of reference—either by returning to Earth or by landing on Proxima Centauri which can be supposed to be roughly in the same frame of reference as Earth—he will have aged less than his twin on Earth. During his flight his ship time t* elapses slower than the time t in Earth’s frame of reference:
Eq. 1.22 is valid if the speed v is constant. During his constant speed period of 5.96 years in Earth’s frame of reference the space traveler’s clock would proceed by 5.16 years. In case of an acceleration or deceleration we have to switch to infinitesimal time periods dt and dt* and replace the constant velocity v with v(t) as in Eq. 1.20. This modified equation has to be integrated over the Earth time t to obtain t*:
The function arsinh is called “area sinus hyperbolicus”.
The space traveler would experience 0.96 years during the acceleration as well as the deceleration. The times are summarized in Tab. 1.1, yielding a total time experienced by the ship passenger of 7.04 years, as opposed to 8.20 years in the “resting” frame of reference on Earth.
Traveling to the edge of the universe The prospect of slowing down time as the ship approaches c offers fascinating possibilities of space travel even without FTL drive. The question is how far an STL starship could travel within a passenger’s lifetime, assuming a constant acceleration of $g=9.81m·s-2$ all the time. Provided there is a starship with virtually unlimited fuel, the following theory would have to be proven: If the space traveler continued acceleration for many years, his speed would very slowly approach, but never exceed c, if observed from Earth. This wouldn’t take him very far in his lifetime. However, according to Eq. 1.23 time slows down more and more, and this is the decisive effect. We might want to correct the above equations with the slower ship time t* instead of the Earth time t. We obtain the ship speed v* and distance x* if we apply Eq. 1.23 to Eq. 1.20 and Eq. 1.21, respectively.
Note that the term $sinh(gt*/c)$ is always smaller than 1, so that the measured speed always remains slower than c. On the other hand, x* may rise to literally astronomical values. Fig. 1.19 depicts the conjectural travel to the edge of the universe, roughly 10 billion light years away, which could be accomplished in only 25 ship years! The traveler could even return to Earth which would require another 25 years; but there wouldn’t probably be much left of Earth since the time elapsed in Earth’s frame of reference would sum up to 10 billion years, obviously the same figure as the bridged distance in light years.
Apart from the objection that there would be hardly unlimited fuel for the travel, the above considerations assume a static universe. The real universe would further expand, and the traveler could never reach its edge which is probably moving at light speed.
### Fuel Problems
The non-relativistic relation of thrust and speed was discussed in section 1.1.5. If we take into account relativistic effects, we see that at a constant thrust the effective acceleration will continually decrease to zero as the speed approaches c. The simple relation $v=g∙t$ is not valid anymore and has to be replaced with Eq. 1.20. Thus, we have to rewrite the fuel equation as follows:
The two masses m₀ and m₁ still denote non-relativistic rest masses of the ship before and after the acceleration, respectively. Achieving $v1=0.5∙c$ would require not much more fuel than in the non-relativistic case, the payload could still be 56% of the total mass compared to 60%. This would be possible, provided that a matter/antimatter power source is available and the power conversion efficiency is 100%. If the aspired speed were 0.99c, the ship would have an unrealistic fuel share of 97%. The flight to the edge of the universe (24 ship years at a constant apparent acceleration of g) would require a fuel mass of 56 billion times the payload which is beyond every reasonable limitations, of course.
If we assume that the ship first accelerates to 0.5 and then decelerates to zero on the flight to Proxima Centauri, we will get a still higher fuel share. Considering that Eq. 1.26 only describes the acceleration phase, the deceleration would have to start at a mass of m₁, and end at a still smaller mass of m₂. Taking into account both phases, we will easily see that the two mass factors have to be multiplied:
This would mean that the payload without refueling could be only 31% for $v1=0.5∙c$. For $v1=0.99∙c$ the ship would consist of virtually nothing but fuel. Just for fun, flying to the edge of the universe and landing somewhere out there would need a fuel of $3*1021$ tons, if the payload is one ton (Earth’s mass: $3*1021$ tons).
|
{}
|
Article | Open | Published:
# Kondo effect and enhanced magnetic properties in gadolinium functionalized carbon nanotube supramolecular complex
## Abstract
We report on the enhancement of magnetic properties of multiwalled carbon nanotubes (MWNTs) functionalized with a gadolinium based supramolecular complex. By employing a newly developed synthesis technique we find that the functionalization method of the nanocomposite enhances the strength of magnetic interaction leading to a large effective moment of 15.79 µB and non-superparamagnetic behaviour unlike what has been previously reported. Saturating resistance at low temperatures is fitted with the numerical renormalization group formula verifying the Kondo effect for magnetic impurities on a metallic electron system. Magnetoresistance shows devices fabricated from aligned gadolinium functionalized MWNTs (Gd-Fctn-MWNTs) exhibit spin-valve switching behaviour of up to 8%. This study highlights the possibility of enhancing magnetic interactions in carbon systems through chemical modification, moreover we demonstrate the rich physics that might be useful for developing spin based quantum computing elements based on one-dimensional (1D) channels.
## Introduction
Over many years there have been various attempts to investigate the interaction between magnetic metal clusters and conductors to develop spintronic devices based on ferromagnetic metal and carbon nanotube complexes1. Carbon nanotubes (CNTs) are ballistic conductors which exhibit exciting quantum transport phenomena such as Luttinger liquid behaviour2,3,4 and the Coulomb Blockade5,6,7. Yet this material suffers from weak spin orbit interaction which limits the observation of strongly correlated resonant transport features including the Kondo effect8,9,10, Andreev reflection11,12, and the Majorana zero modes13 which have been reported in a range of other nanowires. Kondo resonance studies were pioneered in CNT and other low dimensional systems through the observation of the zero-bias anomaly peak8,9,10,14 which remains elusive in a CNT network. Much work has been done to find a material that serves as a good electron conductor as allowing for spin mediation. It is well known that chirality of an individual CNT determines the successful spin transport which limits the spintronic application of this material. However, bundles of CNTs working as a multichannel system can overcome this problem if CNTs can be doped with a rare earth element and a link between the metal islands through the carbon backbone is established. Here we show a new synthesis route of networking CNTs through the clusters of a gadolinium (Gd) based complex that effectively forms a multichannel system that results in exciting electronic transport features related to Kondo effect and effective enhancement of spin-orbit coupling. Previous attempts in CNT based devices show that both localization and tunnelling effects15 can have dominant features in the transport. Although single walled carbon nanotube (SWNTs) networks and individual tubes can exhibit either semiconducting or metallic behavior15, bundles and multiwalled carbon nanotube generally show an activated transport mechanism where fluctuation-assisted tunnelling effects dominate the transport15. These cotunnelling phenomena have also been shown to lead to spin accumulation16 and can drastically enhance tunneling magnetoresistance (TMR)17 and lead to enhanced spintronic device properties.
It is well known that due to weak spin orbit coupling the spin relaxation time of carbon systems, particularly CNTs, is relatively large (approximately 1 µs)18. SWNTs and MWNTs are not intrinsically magnetic but do show diamagnetic susceptibility that increases linearly with diameter19,20 when a magnetic field is applied. Interestingly, it has been demonstrated that the susceptibility of MWNT is highly anisotropic with regard to the orientation of the applied field and that the susceptibility is less diamagnetic with fields parallel to the CNT axis than in the perpendicular orientation21,22. Due to these favourable properties there have been many studies on the use of CNTs for spin valve devices, these typically involve the coupling of a CNT to ferromagnetic leads and injecting spin polarized current through the CNT and measuring the response23,24,25,26,27,28. There have also been investigations on supramolecular spin-valve devices based on individual SWNT non-covalently functionalized with molecular magnets along the surface of the CNT29. The advantage of using such supramolecular devices is that the specific magnetic molecules attached to the CNT can be tailored to exhibit the desired magnetic properties30,31. The non-covalent functionalization preserves the integrity of the structure of the CNT but spin interaction between localized magnetic moment and conduction electrons is weakened. There are however a range of possible routes for the attachment of molecules to CNTs, ranging from weakly attached grafting to strongly attached covalent bonding of the molecule onto the CNT32. A comparative study of the effect of the method of nanomagnet attachment on the magnetic response is yet to be made. Filling of CNTs is an alternative route to modifying their properties. There have been many reports on the filling of CNTs with a range of materials such as metals (Fe, Co, W), chalcogenides (Te, Se) and even other carbon structures such as buckyballs33,34,35.
In this work the properties of a supramolecular complex synthesized using a chemical method of incorporating gadolinium magnetic nanoparticles into a MWNT system via a diethylene triamine pentaacetic acid (DTPA) molecular complex that has been widely studied as a magnetic resonance imaging (MRI) contrast agent33 are investigated. The focus is on the covalent attachment of a Gd-DTPA complex to the outer wall of the MWNTs. Gd3+ is of particular interest due to its high magnetic moment = 7.94 μB which is expected to allow for spin correlations in the MWNTs36. The attachment of Gd3+ to CNTs has been explored before, yielding interesting features such as the observation of superparamagnetism as well as first order paramagnetic-ferromagnetic transitions37. In this work it is shown that the functionalized MWNTs exhibit a finite magnetic coercivity and remanence at room temperature. Structural characterization is used to establish the origins for the difference in magnetic behavior from previous reports. The unexpected properties observed for the functionalized sample prompted electronic transport studies on devices fabricated from a network of the functionalized MWNTs. This was done to determine the effect of the magnetic Gd-DTPA complex on the quantum transport of the MWNTs which is useful for high speed electronics and is an extension of an earlier study38. A saturating resistance was found as the temperature is lowered below 10 K. These features are attributed to the Kondo effect in a spin electron correlated carbon system where spin flipping events can lead to spin switching of the (tunnel) magnetoresistance.
## Results
### Structural characterization
The functionalized MWNTs (Fig. 1a–d) shows that Gd3+ centres are accommodated by fibril and spherical shaped nanostructures of approximately 2 nm in diameter, with a relative uniform distribution in close proximity but not continuous coverage of the outermost surface of the MWNTs. Atomic resolution of the Gd-DTPA aggregate can be seen on the high resolution transmission electron microscopy (HRTEM) image (Fig. 1d). It was found that the Gd-Fctn-MWNTs contain less than 0.2 mass percent cobalt (catalyst. material), with 14.57% of the mass determined to be gadolinium. A strategic approach towards covalently grafting a molecular paramagnetic species to MWNTs involves the use of DTPA molecules as suitable chelators covalently linked to the MWNT wall (see Fig. 2a). Synthetic methodologies have exploited DTPA dianhydride as a starting reagent or have resorted to alternative bridging chains for covalent binding of the DTPA chelate to nanotubes. The former compromises chelation of the paramagnetic metal ion (Gd3+) and inevitably is accompanied by a decrease in the ligand coordination number of the paramagnetic coordination polyhedron.
In such instances, the coordination polyhedron is completed by additional aqua ligands. The latter incorporates the chelate with increased flexibility affords higher rotational degrees of freedom to the Gd-O vector; affecting the possible transfer of magnetic information. An alternative approach considers a more suitably rigid grafting of the Gd-complex to the CNT. In this work acylation of the nanotube surface using a polyaminocarboxylate chelate bearing several carboxylate functionalities is investigated. Grafting of DTPA chelates in this manner affords two possible binding modes in which the octadentate nature of the DTPA chelate is potentially retained. Octadenticity is closely associated with lower order (ML) Gd3+ complexes, while higher order (MxLy)n+ complexes of decreased ligand denticity, enables completion of the coordination polyhedron by increased hydration or through proximal complex aggregation (Fig. 2a). AFM image in the non-contact mode shows a typical bundle of functionalized MWNT (Fig. 2b), in MFM imaging mode features resulting from the magnetic interaction of sample and probe tip are clearly observed on the surface of the MWNT corresponding to magnetic domains due to the presence of the Gd-DTPA (Fig. 2c). A line profile of the atomic force microscopy (AFM) and magnetic force microscopy MFM scans corresponding height profiling from the image shows peaks denoting a bundle of three CNTs (Fig. 2d) which collectively form a bundle of 20 nm high.
### Raman and FTIR spectroscopy
As shown in Fig. 3a the functionalized MWNTs exhibit well pronounced G and D-bands as expected for MWNTs39 with some disorder due to the chemical treatment. The functionalized sample shows a large D-peak (integrated intensity: I D ) compared to the G-peak (integrated intensity: I G ), (I D /I G = 1.26), this is an indication of higher levels of disorder. The graphitic crystallite size between Raman active defects (L a ) in the samples is calculated using the Tunistra Koenig relation39 where C(λ) is a constant that depends on the excitation wavelength (λ). For λ = 514 nm, C(λ) ~ 4.4 nm.
$$\frac{{I}_{D}}{{I}_{G}}=\frac{C(\lambda )}{{L}_{a}}$$
(1)
We find that the functionalized MWNTs have a crystallite size of 3.57 nm, in good agreement with Gd-DTPA functional group distribution observed in HRTEM. An upward shift of the Raman G-peak position is observed compared to the pristine MWNTs (1582 cm−1). The shift in G-peak position of the Gd-functionalized sample is (ΔωG = 7 cm−1) and upon deconvolution it was determined that the asymmetry in the line width was due to the so called D′ peak situated at 1620 cm−1. Like the D-peak, the D′ peak is an indication of disorder and is commonly observed in functionalized MWNTs. The width of the G and D-peaks shows a broadening compared to the pristine case, an increase in G peak full width half maximum (G-FWHM) is an indication of increased disorder39. As expected, the functionalized sample showing a high D-peak intensity also exhibits a high broadening of the G- and D-peaks. The deconvolution of the G and D-peaks of the functionalized sample also identified two broad low intensity bands situated at 1218 and 1476 cm−1. The two features have been observed before in disordered graphite samples. The functionalized MWNT sample with the Gd-DTPA bonded to the outer tube wall also show multiple peaks of small intensity between 200 and 1000 cm−1. These peaks are expected to be a signature of the Gd complex attached to the CNTs as they are not typical features of MWNT Raman spectrum. Comparing the infrared spectrum of the MWNT to that of the Gd-Fctn-MWNT affords evidence for functionalization of the pristine MWNT surface (Fig. 3b). The spectrum of Gd-Fctn MWNT displays peaks in the range 3008–3550 cm−1 arising from O-H and C-H vibrations; the former may include vibrations of water molecules residing in the MWNT. Stretching vibrations of the carboxylate functionalities are evident from peaks in the range 1100–1740 cm−1. In particular the peaks at 1636 cm−1, 1661 cm−1 and 1734 cm−1 confirm the existence of three different carbonyl environments. The FTIR vibrational modes observed in the Gd-Fctn-MWNT are presented in the supplementary information Table S1. Elemental analysis of the CNT nanocomposites was carried out using Energy Dispersive Spectroscopy (EDS) shown in supplementary information Figure S1. It was confirmed that Gd3+ was present in the samples through the observation of the prominent peaks observed at 1.1, 6.05 and 8 keV; these are attributed to M, Lα1 and Lβ1 excitations specific to gadolinium.
### Magnetization characterization
Figure 4a shows the magnetic moment as a function of the applied field of Gd-Fctn-MWNTs (see also supplementary information Figure S2). The nanocomposite exhibits a definite magnetic hysteretic behavior between forward and reverse field sweeps with a coercive field of 185 Oe suggesting possible single domain behaviour of the Gd3+ nanoparticle and a magnetic remanence of approximately 0.013 emu/molGd. The functionalized composite clearly demonstrates hysteresis closely related to a ferromagnet most likely due to the presence of the rare earth element. To further probe the nature of the magnetic behavior a study of the magnetic susceptibility was conducted between 300–1.7 K. Magnetization under field cooled (FC) and zero-field cooled (ZFC) procedures shows a difference in terms of curvature with decreasing temperature however the trend is qualitatively the same (Fig. 4b). As mentioned in the introduction there are several reports on Gd incorporated carbon nanotubes, either through filling40 or through chemical functionalization41,42, which exhibit super paramagnetism. This is clearly not the case in this system as no blocking temperature can be identified in the susceptibility of the Gd-Fctn-MWNT composite shown in Fig. 4b. The inverse susceptibility of the FC data set was plotted as a function of temperature to determine the coupling mechanism. The composite shows linearity down to 100 K after which the susceptibility increases (and inverse susceptibility decreases). The functionalized MWNTs have a Weiss temperature of −413 K. In general, the antiferromagnetic exchange requires the existence of interaction between spin sublattices of different spin orientation which in this system are likely due to the DTPA complex and itinerate electrons of the MWNTs which mediate the antiferromagnetism via the Ruderman–Kittel–Kasuya–Yosida (RKKY) interaction. RKKY has been reported in other magnetized carbon systems and it is a well-established fundamental interaction in spin polarized environments43,44. The inverse susceptibility plot was also used to determine the Kondo temperature TK for this nanocomposite. It is extrapolated from the point where the inverse susceptibility plot starts to deviate from linearity45, estimated to be 98 K as shown in Fig. 4b. When calculating the effective moment in terms of the molar concentration of the Gd3+, which is determined from the elemental analysis, an enhanced effective moment of 15.79 µB was established. This value of the calculated effective moment is much larger than the effective moment of the Gd-DTPA complex (8.7 µB see supplementary information). The large value reported here is a clear indication of interactions between the Gd-DTPA chelates along the MWNTs surface, this is likely a result from the close proximity of the [Gd-DTPA]n+ entities which allows for complex aggregation with enhanced effective moment40,41,42. This aggregation is evident in the HRTEM as indicated in Fig. 1a–d. Not surprisingly the effective moment calculated here is similar to that reported for supramolecular fullerenes with endohedral trimetallic nitride clusters (Gd3N@C80), which was found to be 23 µB and it was shown that Gd3N clusters allows for ferromagnetic coupling and a largely enhanced moment46. It is believed a similar scenario is at play in the present study. These findings clearly demonstrate how the magnetic properties of composite can be modified by controlling the chemical functionalization process and that a mesoscopic magnetic correlated state can be observed.
## Electronic Transport
Figure 5a shows the I-V characteristics of the Gd-Fctn-MWNT network device at various temperatures ranging from 300 mK to room temperature and the inset shows a typical device used in this work where the Gd-Fctn-MWNT bundles aligned between the electrodes. I-V characteristics change progressively over the temperature range and a large deviation from linearity is clearly seen at 300 mK. The strong nonlinearity at low temperatures is an indication of the opening of a band gap, possibly due to the Coulomb blockade or charging effects. Figure 5b shows the variation of normalized resistance with temperature. The conductance was measured as a function of temperature for the same range (as shown in Fig. 5c and shows a steady decrease to approximately 4 K and then saturates below this temperature. Analysis of the temperature dependent resistance indicates that the Gd-Fctn-MWNT networks do not follow variable range hopping15 which is the expected mechanism for carbon nanotube devices of this type. This was concluded after failure to linearize the logarithmic normalized conductance as a function of Tβ, where β is a critical exponent representing the dimension scale of the hopping (see supplementary information Figure S3). The devices do however display similar trends to those reported for thicker SWNT networks15 and conducting polymers47,48 that suggests interrupted metallic conduction mediated by fluctuation induced tunnelling (FIT). A nonlinear fit to the data set gives a relation similar to that presented in ref.15.
$$\sigma (T)={\sigma }_{1}T+{\sigma }_{2}{e}^{-\frac{{T}_{1}}{T+{T}_{0}}}\,$$
(2)
In this model, the conductance is separated into two terms, the first term scales linearly with temperature whilst the second term takes into account the fluctuation assisted tunnelling49. Here σ1 and σ2 are constants and T1 represents the activation energy required to tunnel through the barriers and T0 is the temperature at which the crossover from the saturating to activated transport occurs. This model has been successfully utilized in a range of disordered carbon networks. It should also be noted that there exists some reports50 on a combined FIT/variable range hopping (VRH) model which introduces a VRH term instead of the linear term in equation 2, as presented in the supplementary information figure S3 this does not fit as well to our data set. It should also be noted that some studies have linked the saturation in the resistance at low temperature to tunnelling between outer and secondary shells of the MWNT15. However, due to the divergence of the susceptibility and non-linearity of I-V characteristics which both occur at the low temperatures it is believed in this system the low temperature behaviour is due to electron and spin correlations. This led to probing the saturating resistance considering the numerical renormalized group (NRG) calculation as presented in Fig. 5b which shows the normalized resistance (with respect to the saturation value) as a function of temperature. A clear saturation is observed below approximately 4 K. The solid red line is a fit to the numerical renormalization group equation where c = 6.088 and $${T}_{K}$$ is the Kondo temperature.
$$\frac{R(T)}{R(0)}=(1-c{(\frac{T}{{T}_{K}})}^{2})$$
(3)
From the fitting, TK = 91 K is extracted although surprisingly high this value is very similar to what has recently been observed in disordered graphene using the same fitting51. Additionally, it is observed that the equation fits the data set best in the region below 14 K, signifying the crossover from the interrupted metallic transport (FIT fitting) at higher temperatures. The T2 dependence of the resistance is a feature of magnetic impurities in a Fermi system, this finding is contrary to theoretical studies where a local non-fermi behaviour was expected for magnetic impurities linked to MWNTs which are expected to show a T1/2 dependence.
To further probe the magnetic properties of the Gd-Fctn-MWNTs the dependence of the resistance on the magnetic field is investigated as shown in Fig. 6a. At low temperatures, below the resistance saturation, the magnetoresistance shows repeatable pronounced switching behaviour symmetric about the zero-field axis reminiscent of spin valve effects observed in other types of devices29,30,31. The spin switching effect, a sharp increase in resistance at certain fields, is clearly observed at 300 mK within ± 0.25 T which was determined to be the field at which saturation of the magnetic moment occurs as observed in the magnetic hysteresis (Fig. 4a). This device configuration is unlike the conventional CNT spin valve devices with ferromagnetic leads functioning as the spin polarizers. It consists of a non-magnetic CNT grafted with magnetic Gd-DTPA similar to the work on molecular magnets presented in ref.29. It is well known that in MWNT the conduction electrons are found in the outer shells (unlike in SWNTs), hence the close proximity of the conduction electrons and the magnetic entities results in their enhanced spin interaction. The neighbouring Gd-DTPA complexes can act as spin related barriers effectively suppressing or mediating transport of conduction electrons depending on the local spin densities due to the Gd-DTPA consequently forming a molecular spin valve. MR values of up to 8% are observed in the devices fabricated from the Gd-Fctn-MWNT which is interpreted as an effect of the collective switching of the Gd3+ magnetic domains on the aligned CNTs. In order to explain such features, we believe the resistance depends on the relative alignment (parallel and anti-parallel states) of the spin on the Gd3+ ions. As shown in Fig. 6b, the anti-aligned Gd ions form a higher resistive state that prevents the conduction of electrons between Gd-DTPA sites, by applying the magnetic field the spins can be switched to an aligned state, leading to a lower resistance where electron can more easily travel between Gd-DTPA sites. Similar results have been reported for CNT devices fabricated with arrays of CNTs with multiple nonlocal ferromagnetic contacts26, there however it was shown that the orientation of the different ferromagnetic contacts can change the switching fields and magnetoresistance difference quite drastically. We believe that this is the first report showing spin-valve like effect using a mesoscopic bundle of CNTs without ferro-magnetic contacts and is a clear indication that the functionalized CNTs can be useful for spin filtration/polarization devices, a pronounced feature of this strongly correlated system is the Kondo effect.
## Conclusion
We have successfully demonstrated that covalently functionalizing Gd-DTPA to MWNT yields a system with stable interaction between the host material and magnetic nanoclusters. We have characterized the supramolecular complex through a combination of HRTEM, Raman spectroscopy, superconducting quantum interference device (SQUID) magnetometry and transport measurements. We have observed an enhanced effective moment and non-superparamagnetic behaviour indicating strong spin interactions. The low field magnetoresistance shows clear switching spin valve behaviour which has not yet been reported for gadolinium modified CNT bundles. The electronic transport of the nanotubes is controlled by the magnetic states of the aggregated complex grafted onto the surface of the MWNTs. The covalent interactions allow for the effective mediation of the spin states from the magnetic complex to the CNT providing an alternative pathway for the relaxation of the Gd cluster magnetization. Currently 1-dimesntional semiconductors are at the forefront of many interesting scientific developments, most notably quantum computing, this works highlights the possibility of tailoring carbon nanotube quantum transport in ways that may find application in this emergent field.
## Methods
### Sample preparation
MWNTs were modified using a chemical functionalization route with a gadolinium complex, Diethylene triamine pentaacetic acid gadolinium (III) (DTPA). Commercial grade MWNTs from Sigma Aldrich were used. A suspension of 452 mg of DTPA and 46 mg of dry CNTs in Trifluoroacetic acid (TFA) (8 ml) is sonicated at 30 °C for 2 min to ensure even dispersion. The suspension is further stirred at room temperature for 20 h. After evaporation under reduced pressure, the residue is washed with diethylether, dichloromethane and methanol. The solid residue is then dried under reduced pressure. Chelation of Gd3+ is achieved by dispersing 10.53 mg of DTPA/CNTs in 12 ml of a gadolinium perchlorate 40% aqueous solution. The mixture was sonicated for 30 min and stirred at room temperature for 24 h. The suspension was centrifuged and the aqueous supernatant checked for free gadolinium ions by colorimetric detection with xylenol orange. The reaction product was dried under vacuum to obtain Gd-Fctn-MWNTs. All reactions were performed under inert conditions.
### Experimental Methods
Structural characterisation is done using HRTEM. The presence of Gd3+ in the nanocomposite is confirmed by EDS. The formation of the complex is investigated by Fourier transform Infrared spectroscopy (FTIR). Magnetic force microscopy (MFM) is used to investigate the existence of magnetic domains on the surface. Electronic transport studies are done on devices fabricated from the Gd-Fctn-MWNT composite. As shown in Fig. 1, HRTEM was used to investigate the morphology of the Gd-Fctn-MWNT. Quantification of the Gd concentration in the nanocomposites was done by a microwave-assisted HNO3/H2SO4 digestion (Ultra Wave Millestone) and analysis by ICP AES (ICAP 6500 Thermofischer Scientific). Raman spectroscopy was performed with an excitation wavelength of 514 nm. M(H) and χ = M(T)/H, (H = 100 Oe) studies of the composite were carried out at room temperature using an ultra-sensitive MPMS-SQUID magnetometer from Quantum Design, San Diego.
Dielectrophoresis (DEP) was used to fabricate Gd-functionalized MWNT network devices. The Gd-Fctn-MWNT were dispersed in isopropylalcohol and then sonicated for 6 hours. The resulting solution was drop cast on a prefabricated 6-gold-electrode system with a separation distance of approximately 5 and 1.5 μm between the furthest and closest electrodes respectively. The MWNTs are aligned by DEP using an alternating current of 1 MHz and ±5 Vpp voltage. The outermost electrodes were used to contact a four-terminal device configuration using a wire bonder. Electronic transport characterization was done in the Cryogenic high field measurement system on different devices. Current (I)-voltage (V) measurements were done at room temperature and 300 mK. The Resistance vs Temperature measurements were carried out from 300 mK to 300 K using a Keithly 2400 to supply a current of 1 μA and a Keithly 2182 nanovoltmeter to measure the voltage across the sample. The magnetoresistance (MR) was measured from −0.5 to 0.5 T at excitation currents of at 300 mK.
Publisher's note: Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.
## References
1. 1.
Chen, P. & Zhang, G. Y. Carbon-based spintronics. Sci China-Phys Mech Astron 56, 207 (2013).
2. 2.
Bockrath, M. et al. Luttinger-liquid behavior in carbon nanotubes. Nature 397, 598–601 (1999).
3. 3.
Ncube, S., Chimowa, G., Chiguvare, Z. & Bhattacharyya, S. Realising one-dimensional quantum and high-frequency transport features in aligned single-walled carbon nanotube ropes. J. Appl. Phys. 116, 024306 (2014).
4. 4.
Chimowa, G., Ncube, S. & Bhattacharyya, S. Observation of impedance oscillations in single-walled carbon nanotube bundles excited by high-frequency signal. EPL 111, 36001 (2015).
5. 5.
Leturcq, R. et al. A high quality factor carbon nanotube mechanical resonator at 39 GHz. Nature Physics 5, 327–331 (2009).
6. 6.
Postma, H. W. C. et al. Carbon nanotube single-electron transistors at room temperature. Science 6, 293 (2001).
7. 7.
Yao, Z., Postma, H. W., Ch., Balents, L. & Dekker, C. Carbon nanotube intramolecular junctions. Nature. 402, 273–276 (1999).
8. 8.
Jarillo-Herrero, P. et al. Orbital Kondo Effect in carbon nanotubes. Nature 434, 484–488 (2005).
9. 9.
Nygård, J., Cobden, D. H. & Lindelof, P. E. Kondo physics in carbon nanotubes. Nature 408, 342–346 (2000).
10. 10.
Paaske, J. et al. Non-equilibrium singlet-triplet Kondo effect in carbon nanotubes. Nature Physics 2, 460–464 (2006).
11. 11.
Pillet, J.-D. et al. Andreev bound states in supercurrent-carrying carbon nanotubes revealed. Nature Physics 6, 965–969 (2010).
12. 12.
Cleuziou, J.-P., Wernsdorfer, W., Bouchiat, V., Ondarçuhu, T. & Monthioux, M. Carbon nanotube superconducting quantum interference device. Nature Nanotechnology 1, 53–59 (2006).
13. 13.
Mourik, V. et al. Signatures of Majorana fermions in hybrid superconductor-semiconductor nanowire devices. Science 336, 1003–7 (2012).
14. 14.
Potok, R. M., Rau, I. G., Shtrikman, H., Oreg, Y. & Goldhaber-Gordon, D. Observation of the two-channel Kondo effect. Nature 446, 167–171 (2007).
15. 15.
Skakalova, V., Kaiser, A. B., Woo, Y.-S. & Roth, S. Electronic transport in carbon nanotubes: From individual nanotubes to thin and thick networks. Phys. Rev. B 74, 085403 (2006).
16. 16.
Imamura, H., Takahashi, S. & Maekawa, S. Spin-dependent Coulomb blockade in ferromagnet/normal-metal/ferromagnet double tunnel junctions. Phys. Rev. B 59, 6017–6020 (1999).
17. 17.
Takahashi, S. & Maekawa, S. Effect of Coulomb blockade on magnetoresistance in ferromagnetic tunnel junctions. Phys. Rev. Lett. 80, 1758–1760 (1998).
18. 18.
Ida, T., Ishibashi, K., Tsukagoshi, K., Aoyagi, Y. & Alphenaar, B. W. Metal-insulator transition in quantum dot arrays. Superlattices Microstruct. 27, 551–554 (2000).
19. 19.
Nakai, Y. et al. Observation of the intrinsic magnetic susceptibility of highly purified single-wall carbon nanotubes. Phys. Rev. B 92, 1 (2015).
20. 20.
Ovchinnikov, A. A. & Atrazhev, V. V. Magnetic susceptibility of multilayered carbon nanotubes. Phys. Solid State 40, 1769–1773 (1998).
21. 21.
Tsui, F., Jin, L. & Zhou, O. Anisotropic magnetic susceptibility of multiwalled carbon nanotubes. Appl. Phys. Lett. 76, 1452–1454 (2000).
22. 22.
Zaric, S. et al. Estimation of magnetic susceptibility anisotropy of carbon nanotubes. Nano Lett. 4, 2219–2221 (2004).
23. 23.
Tsukagoshi, K., Alphenaar, B. W. & Ago, H. Coherent transport on electron spin in a ferromagnetic contacted carbon nanotube. Nature 401, 572–574 (1999).
24. 24.
Li, J. & Zhang, Y. A simple purification for single-walled carbon nanotubes. Phys. E Low-Dimensional Syst. Nanostructures 28, 309–312 (2005).
25. 25.
Meyer, C., Morgan, C. & Schneider, C. M. Scanning tunneling microscopy and spectroscopy of graphene on insulating substrates. Phys. Status Solidi Basic Res. 248, 2680–2683 (2011).
26. 26.
Yang, H. et al. Nonlocal spin transport in single-walled carbon nanotube networks. Phys. Rev. B 85, 052401 (2012).
27. 27.
Zhao, B., Monch, I., Vinzelberg, H., Muhl, T. & Schneider, C. M. Spin-coherent transport in ferromagnetically contacted carbon nanotubes. App. Phys. Lett. 80, 3114–3116 (2002).
28. 28.
Langford, R. M. et al. Magnetoresistance and spin diffusion in multi-wall carbon nanotubes. Microelectronic Engineering 84, 1593–1595 (2007).
29. 29.
Urdampilleta, M., Klyatskaya, S., Cleuziou, J.-P., Ruben, M. & Wernsdorfer, W. Supramolecular spin valves. Nat. Mater. 10, 502–506 (2011).
30. 30.
Ganzhorn, M., Klyatskaya, S., Ruben, M. & Wernsdorfer, W. Strong spin-photon coupling between a single-molecule magnet and a carbon nanotube nanoelectromechanical system. Nat. Nanotechnol. 8, 165–169 (2013).
31. 31.
Bogani, L. & Wernsdorfer, W. Molecular spintronics using single-molecule magnets. Nat. Mater. 7, 179–186 (2008).
32. 32.
Marangon, I. et al. Covalent functionalization of multi-walled carbon nanotubes with a gadolinium chelate for efficient T1-weighted magnetic resonance imaging. Adv. Funct. Mater. 24, 7173–7186 (2014).
33. 33.
Che, G., Lakshmi, B. B., Fisher, E. R. & Martin, C. R. Metal-nanocluster-filled carbon nanotubes: Catalytic properties and possible applications in electrochemical energy storage. Langmuir 15, 750–758 (1999).
34. 34.
Leonhardt, A. et al. Synthesis and properties of filled carbon nanotubes. Diam. Relat. Mater. 12, 790–793 (2003).
35. 35.
Linganiso, E. C., Chimowa, G., Franklyn, P. J., Bhattacharyya, S. & Coville, N. J. The effect of tube filling on the electronic properties of Fe filled carbon nanotubes. Mater. Chem. Phys. 132, 300–303 (2012).
36. 36.
Sitharaman, B. et al. Supermagnetic gadonanotubes are high-performance MRI contrast agents Chem. Commun. (Cambridge) 31, 3915–3917 (2005).
37. 37.
Quetz, A. et al. Magnetic Properties and phase transitions of gadolinium-infused carbon nanotubes. J. Appl. Phys. 113, 17B512–17B512-3 (2013).
38. 38.
Schönenberger, C., Bachtold, A., Strunk, C., Salvetat, J. P. & Forró, L. Interference and interaction in multi-wall carbon nanotubes. Appl. Phys. A Mater. Sci. Process. 69, 283–295 (1999).
39. 39.
Tuinstra, F. & Koenig, J. L. Raman spectrum of graphite. J. Phys. Chem. 53, 1126–1130 (1970).
40. 40.
Ananta, J. S. et al. Single-walled carbon nanotube materials as T2-weighted MRI contrast agents. J. Phys. Chem. C 113, 19365–19368 (2009).
41. 41.
Servant, A. et al. Gadolinium-functionalised multi-walled carbon nanotubes as a T1 contrast agent for MRI cell labelling and tracking. CARBON 97, 126–133 (2016).
42. 42.
Sitharaman, B., Jacobson, B. D., Wadghiri, Y. Z., Bryant, H. & Frank, J. The magnetic, relaxometric, and optical properties of gadolinium-catalysed single walled carbon nanotubes. J. Appl. Phys. 113, 134308 (2013).
43. 43.
Gorman, P. D., Duffy, J. M., Power, S. R. & Ferreira, M. S. Strain-modified RKKY interaction in carbon nanotubes. Phys. Rev. B. 92, 035411 (2015).
44. 44.
Klinovaja, J. & Loss, D. RKKY interaction in carbon nanotubes and graphene nanoribbons. Phys. Rev. B. 87, 045422 (2013).
45. 45.
Coey, J. M. D. Magnetism and Magnetic materials, Cambridge University Press 146 (2010).
46. 46.
Nafradi, B. et al. Molecular and spin dynamics in the paramagnetic endohedral fullerene Gd3N@C80. J. Phys. Chem. Lett. 3, 3291–3296 (2012).
47. 47.
Sheng, P., Sichel, E. K. & Gittleman, J. I. Fluctuation-induced tunnelling conduction in carbon-polyvinylchloride composites. Phys. Rev. Lett. 40, 1197–1200 (1978).
48. 48.
Sheng, P. Fluctuation-induced tunnelling conduction in disordered materials. Phys. Rev. B 21, 2180–2195 (1980).
49. 49.
Salvato, M. et al. Charge transport and tunnelling in single-walled carbon nanotube bundles. Phys. Rev. Lett. 101, 246804 (2008).
50. 50.
Kamalakannan, R. et al. The role of structural defects on the transport properties of a few-walled carbon nanotube networks. Appl. Phys. Lett. 98, 192105 (2011).
51. 51.
Chen, J. H., Li, L., Cullen, W. G., Williams, E. D. & Fuhrer, M. S. Tunable Kondo effect in graphene with defects. Nature Physics 7, 535–538 (2011).
## Acknowledgements
This work is performed under the CSIR-NLC rental pool project supported by the Nanotechnology Flagship Programme funded by NRF (SA). The support of EMU (Wits), DST/NRF Centre of Excellence in Strong materials and URC (Wits) towards this research is hereby acknowledged. We are thankful to D. Mtsuko, A. Naicker, and R. Erasmus for experimental assistance and N. J. Coville for useful discussions. AMS thanks SA-NRF (93549) and the URC/FRC of UJ. AdeS thanks the South African National Research Foundation (Grant no: 85991).
## Author information
### Affiliations
1. #### Nano-Scale Transport Physics Laboratory, School of Physics, and DST/NRF Centre of Excellence in Strong materials, University of the Witwatersrand, Johannesburg, South Africa
• S. Ncube
• , C. Coleman
• & S. Bhattacharyya
• A. Strydom
• A. Strydom
• E. Flahaut
5. #### School of Chemistry, University of the Witwatersrand, Johannesburg, South Africa
• A. de Sousa
### Contributions
S.N. performed device fabrication, transport measurements, and spectroscopic analysis. C.C. conducted detailed analysis of transport data. A.dS. performed chemical synthesis of the sample. E.F. did microscopic and elemental analysis of the samples. A.M.S. performed the magnetic characterization. S.B. developed the idea and designed the experimental method. All authors discussed on the data and contributed to the manuscript.
### Competing Interests
The authors declare no competing interests.
### Corresponding author
Correspondence to S. Bhattacharyya.
|
{}
|
6:33 AM
Did you check out the ultra dark mode?
6:47 AM
2
I know current is a scalar quantity because it doesn't follow the vector law of addition , but I want to prove it with transformation of coordinates. How to do that? From where to start?
How do you use co-ordinate transformations to prove that something is a vector (or a scalar)?
Is it even possible?
7:06 AM
If we transform from coordinates $x$ to coordinates $x'$ then we can write a matrix describing the transformation $m_{ij} = dx_i/dx'_j$.
Then vectors transform according to $v_i' = m_{ij}v_j$
So we just have to check that the object we are studying transforms in this way.
NB this is required but not sufficient. Vectors must transform in this way, but there could be other objects that aren't vectors that also transform in this way.
7:36 AM
@JohnRennie But while checking whether $v_i' =m_{ij} v_j$, we have implicitly assumed that $v$ ia a vector, haven't we? Or else how could we define $v_i'$ and $v_j$?
8:06 AM
@FakeMod The idea is that you know what $v$ and $v'$ are, and you know what the transformation matrix $m_{ij}$ is. Then you check that $v_i' = m_{ij} v_j$ and if this doesn't hold you know $v$ isn't a vector.
morning
8:50 AM
Is the general formula for parallel propagation the equation $$P_{\gamma, s, t} X(\gamma(\lambda)) = \int_{s}^{t} \nabla_{\dot{\gamma}} X(\gamma(\lambda)) d\lambda$$
or something to that effect
Then I suppose that would be
\begin{eqnarray}
P_{\gamma, s, t} X(\gamma(\lambda)) &=& \int_s^t \left[ \dot{X}^\mu(\gamma(\lambda)) + \omega^\mu_\nu X^\nu \right]d\lambda\\
&=& [X(\gamma(t)) - X(\gamma(s))] + \int_{s}^{t} \omega^\mu_\nu X^\nu d\lambda
\end{eqnarray}
and give the appropriate result for the holonomy
Except I'm not sure how the path ordering gets in from there
(This is starting from $$\nabla_{\dot{\gamma}} X(\gamma(t)) = \left[\frac{d}{ds} P_{\gamma, t, s} X(\gamma(s))\right]_{s = t}$$)
9:43 AM
0
I have a question about my Physics Stack Exchange post: How to incorporate the uncertainty of the model coefficients in the prediction interval of a multiple linear regression I am dealing with a rather hard question, and hoped to get some help on stack-exchange. Being a computational physi...
I know this is not the place to ask this, but do you guys know a type of commonly found material which I can shape (like clay) into a mold-like form, then I can fill it up with HDPE (or some other suitable plastic) and I put that whole thing in the over an get the shape I want? You get what I'm trying to do.
Basically recycling plastic into a shape that I've cut from some material like clay or something like that.
11
Let $G$ be the gauge group whose Yang-Mill's theory one is looking at and $A$ be its connection and $C$ be a loop in the space-time and $R$ be a finite-dimensional representation of the gauge group $G$. Then the classical Wilson loop is defined as, $W_R(C)(A) = \mathrm{Tr}_R[\mathrm{Hol}(A,C)]$, ...
There's a proper derivation
oven*
10:42 AM
During a Berkeley meeting of the Manhattan Project, Edward Teller brought up the basic idea behind the hydrogen bomb. You would use a nuclear bomb to ignite a self-sustaining fusion reaction in some other substance, which would produce a bigger explosion than the nuke itself. The scientists got to work figuring out what substances could support such reactions, and found that they couldn’t rule out nitrogen-14. The air is 79% nitrogen-14. If a nuclear bomb produced nitrogen-14 fusion, it would ignite the atmosphere and turn the Earth into a miniature sun, killing everyone. They hurriedly con
11:04 AM
@Jmac I was write both Brian and Stephen hawking does use the word parallel universe.
I have a question does there exist something before the big bang! I mean most of physicist agree that, the origin of our time is when the big bang happen, but some physicists says our big bang was a part of millions of big bang
If the concept of multiple universe exist would there been a different time meaning for all of them?
@Slereah At least "turn the earth into a miniature sun" would've been a stylish way to go out :P
11:22 AM
Sorry for the typing error I was writing "right" and phone auto correct makes it "write".
@JohnRennie hi
@NovaliumCompany What's wrong with clay? I guess the plastic may glue itself to the clay, which will make it a little tricky to remove your plastic item.
@NovaliumCompany That may or may not work. There are two major categories of plastic: thermoplastic and thermosetting. You can melt & reshape the former, but not the latter. See en.wikipedia.org/wiki/Thermoplastic which links to the article on thermosetting. You should be ok with HDPE, since it's thermoplastic.
@YuvrajSingh... hi :-) I have to dash off and get lunch now I'm afraid. I'll be around later this afternoon, or tomorrow morning as usual.
5
I've heard this saying before I don't know about anyone else. It says, "What ever was before the Big Bang is something physics can't explain..! Is this saying true (accurate)?
11:38 AM
@JohnRennie ok sir!
@PM2Ring a very good evening sir!.
@DavidZ I fully agree. I was about to VTC that post as non-mainstream, but Qmechanic beat me to it. But then I decided to google for oxford negative mass, and found that ref for Jamie Farnes.
@YuvrajSingh... Good evening, Yuvraj prabhu. ;)
@PM2Ring prabhu!
:)
@PM2Ring have you notice my question?
@YuvrajSingh... Yes. Standard Big Bang theory cannot talk about time before the moment that the Big Bang started. In fact, it can't talk about the exact moment of the Big Bang, and it can't really describe what happens in the very early phases of the Big Bang until we have a good theory of quantum gravity.
11:51 AM
OK.
Do you believe in concept of multiple universe? @PM2Ring
Now there are various speculations that go beyond standard Big Bang theory, and those theories may talk about time before the Big Bang. But even in those theories, the instant of Big Bang is so extreme that it is very difficult or totally impossible for things before the BB to affect things after the BB. So the chain of cause and effect is broken, or at least extremely chaotic, by the BB.
@YuvrajSingh... Maybe. :) I found such theories very attractive when I was younger, but these days I'm not so sure. But I don't think we have enough evidence to make a decision either way.
@YuvrajSingh... There's a difference between using the word parallel universes, and saying that parallel universes definitely exist and aren't just one possible explanation. That's what I was asking about yesterday, because I would find it a bit weird to see a science communicator like Brian Greene state an interpretation as fact; though it wouldn't be that crazy.
Personally, I think there is only one Universe, but that Universe may contain countless sub-universes that cannot influence each other. And I guess it's ok to call those sub-universes parallel universes.
@Slereah @ACuriousMind Physics
Huzzah!
12:06 PM
@PM2Ring thanks sir. Actually I was reading some papers published by Stephen hawking, so where he uses the word parallel and in his interview too he said about parallel universe.
@Jmac OK.
@YuvrajSingh... Yes. He's talking about the standard Many Worlds Interpretation, which gives a tree-like structure of "parallel" worlds. So all those worlds are connected into a united branching structure.
@BalarkaSen Neat-o. A blog? I guess isolation is getting to you, too, hm? ;)
Lmao
I was inspired I suppose
At least it's not a podcast :P
But no, I am rather happy that the rest of the world is adapting my lifestyle
Self-isolation is what I call daily routine
4
12:14 PM
I prefer the picture promoted by David Deutsch, which I described in the answer I linked here yesterday. physics.stackexchange.com/questions/536522/… It's really the same structure as the standard MWI, but I think it's a better way to describe it.
@BalarkaSen People are freaking out while I'm just happy that "staying home and playing video games" is finally recognized as doing something for society ;P
Exactly
@ACuriousMind I've been subconsciously training my whole life for this.
12:30 PM
@JMac A lot of MWI proponents do seem to have the attitude that MWI is the true interpretation, and people who don't agree just don't have the intellectual courage to embrace its awesomeness. At least, that's the impression I get from pop-sci books & articles that promote MWI.
@PM2Ring Yeah, I was pretty curious about Brian Greene though because he's a pretty good communicator, and I don't remember him suggesting that MWI was the interpretation in books or anything. From what I remembered he had a more neutral tone about interpretations; but maybe I'm just remembering wrong.
@PM2Ring Thank you. I've already familiarized myself with the thermoplastics and thermosets and I think I'll be using something that is HDPE (since it's most easily found). I'm thinking of using clay but my only worry is that the clay would melt or blend with the plastic.
@JMac Yeah, it's been a while since I read anything by Brian Greene, so I can't remember what his attitude is, I was making a generalisation.
And I'd also need to be able to apply pressure on the mold and if the mold is made out of clay, would that hold?
@NovaliumCompany You need a high temperature to "fire" clay, and make it glassy. You are unlikely to get that temperature in a normal oven, you need a kiln for that. And that's way hotter than the temperature you need to melt HDPE. You (probably) don't need to bake your clay mould, but it will need to be dry (eg sun-dried), and it will shrink a little when it dries. Hopefully, that won't be an issue for you.
I'm not sure how to stop the plastic sticking to the mould. Maybe dusting the mould with talcum powder will help. Some talc may stick to the plastic, but maybe a stiff brush will remove that.
@NovaliumCompany Maybe. It depends on the pressure, and the shape of the mould. Clay is fairly brittle. Why do you need the pressure?
12:48 PM
@PM2Ring So the plastic fits better in the shape
I want to do something like this but without building the wood thing. I have a big oven so maybe I can put something heavy over it while it's in the oven.
@NovaliumCompany Ok. That shouldn't require too much pressure, but I've never tried this myself. I suspect that your main problem will be preventing air bubbles, especially if your shape is complicated. There may be some useful info here: en.wikipedia.org/wiki/Injection_moulding
@PM2Ring Thanks, I did my research on injection molding and I'll most likely do that in the future (once I get a few hundreds of thousands of bucks from my biz) but right now I need to make it in the oven :P
I guess I'll try with clay, see what happens.
@NovaliumCompany How big is your object? Maybe find someone with a 3D printer to make it for you.
@NovaliumCompany Does it need to be a plastic for the final product? There might be other options like 2 part epoxies or something. That can literally be poured into a mold as a liquid and then hardens without heat. The biggest hurdle would probably be air bubbles if those are a problem for what you're making; but even that can be minimized, or even eliminated with a vacuum chamber and a way to shake the bubbles out
@PM2Ring I've considered that, as well as the other available plastic manufacturing processes. My object is not complicated in terms of shape and local 3D printing services are expensive. I also need to be able to produce it quantity (if I have orders) and 3D printing filament as well as the 3D printer itself are way beyond my budget.
@JMac I've considered that, polymer casting. The shapes I need are not complicated at all and that's why I think the oven HDPE plastic melting thingy is the most suitable at first.
Thanks for the help guys!
I know I behave strangely sometimes and I'm sometimes inappropriate so thank you for helping me.
You'll get 20% off the product once it's released ;)
ahh I should stop being so dramatic
just delete my last 4 messages please
1:38 PM
hellos
2:05 PM
@AaronStevens I worked out the answer using the Fundamental Shower Theorem of Calculus -- for what I'm trying to do, the spectral space function I want is sinc*(1-2*sum_{negative bands) bandpass_filter). Which means my physical space kernel would look like BoxFilter - 2*sum_{negative bands} Convolution(BoxFilter, InverseFT(bandpass_filter))
2:48 PM
@tpg2114 "the Fundamental Shower Theorem of Calculus" I assume this is the one where suddenly it all makes sense in the shower?
@JMac Indeed. All math becomes clear when you walk away from paper and computers and break things down mentally.
"the shortest path between two mathematical points is through the shower"
@Semiclassical Very concise statement of the theorem!
@tpg2114 Ah ok. Glad you got it to work out
Now if only I could figure out how to finish up my doctoral work in the shower :(
@tpg2114 I think it's pretty universal for problem solving. Sometimes you just need to step away. I was trying to do a numerical methods assignment in matlab and couldn't get the code to work for the life of me. The next morning when I went to get a coffee I somehow managed to solve the problem without even looking at the code (and I'm not exactly a coder).
2:55 PM
@JMac Yup, I frequently just have to go wander around when I'm stuck. It's pretty awesome how a change of scenery and putting yourself in a situation without the "crutch" of papers, books, or computers helps your brain focus in on the real issues
I've been known to dream up the solution to bugs or issues in my code from time to time
Like -- literally while sleeping, in my dream something clicks and it works when I put it in in the morning
Yeah I think I remembered dreaming about the problem the night before too. I definitely remember dreaming my way through a few heat transfer problems. I had basically spent like a week cramming, it wound up invading my thoughts in a pretty helpful way.
I do the opposite. I let my problems keep me up, and they don't get solved :P
We used to joke in grad school that the most important lesson is learning how to balance the stimulants (coffee) and depressants (bourbon) so you could stay awake when needed and fall asleep when needed... We'd also tell people who asked what language we used for our giant code that it was written in bourbon
I'm not advocating self-destruction. In hindsight, we did not make great choices in how we coped with things
@tpg2114 That is my issue. I need to be more self-destructive
Hah -- snuck my edit in!
3:03 PM
@tpg2114 It's too late. I have begun
Working in a partially-finished basement, with a single incandescent lightbulb overhead feels very dystopian. I'm in some post-apocalyptic white-collar job.
@tpg2114 Is the bulb hanging like mid-room height from a cable and slowly swaying back and forth? If not, you're really missing out on the ambiance
@JMac It's not swaying... the basement is not climate controlled, so there's no mechanism for the air to move
But otherwise, pretty much spot on
I do have those high, small, rectangular windows that look out into... those semi-circle cutouts in the ground that go around basement windows. I can see tiny slivers of sun reflecting off the privacy fence. There's a surprising amount of wildlife that wanders by
I saw a squirrel jump down into one of the window well things, and then get attacked by a snake. So I made my wife go get rid of the snake and am contemplating moving out of the house, possibly burning it down in the process.
@tpg2114 You need to implement some sort of eerie breeze, or possibly find a way to make it sway without a breeze. Then I'm sure your productivity would skyrocket. The quicker you finish work, the quicker you can get out of your creepy-ass basement.
@JMac I'll need to make sure the breeze makes a rocking chair slowly rock also
That's more of an attic thing though I guess
3:10 PM
I think it would work in the basement. Especially if you put it in a dark corner so that you can only be mostly sure that there isn't someone on it.
The beauty of a single low watt bulb? Every corner is a dark corner!
But obviously if you have an attic full of dolls it would be much better up there.
@tpg2114 If the basement is circular you have an infinite amount of really small dark corners?
3:26 PM
Can anybody confirm the validity of this comment? 👇
The light in the medium persists of the original light wave and the light wave created by the oscillation of the electrons. The latter can further be splitted into a component, which travels with the vacuum speed of light and a component, which seems to travel with the slower speed of light. Individually they all travel with the vacuum speed of light, but in sum, the components with the vacuum speed of light cancel each other out, as is stated in the Ewald-Oseen extinction theorem, which is quite counter-intuitive. E.g. for visible light this extinction length is $\approx 1\,mm$ — clevor 1 min ago
trying to decide if this practice quiz problem that the prof provided for my students actually makes sense:
"What is the equivalent capacitance (in μF) between points A and B if all the capacitors have a capacitance 1.5 μF but then a material with dielectric constant 9.5 is inserted into one capacitor, filling the space between its plates? Supply your answer to three significant figures."
The phrase "capacitance between points A and B" doesn't make a lot of sense to me
@Semiclassical Makes perfect sense to me - if you attach wires to A and B and view everything in between as a black box, what's the capacitance of that box?
looked at what the prof meant, and i guess i see the point: if you put a voltage across points A and B, what is the equivalent capacitance of the resulting circuit?
yeah
It's just like equivalent resistance.
i think i'd be happier if it was drawn with nodes at A,B
that doesn't really change it but it makes it more obvious in my brain
3:35 PM
0
Its easy to find the electric field due to a uniformly charged ring or disc at a point on the axis of ring/disc. But I cant figure out a way to find the electric field or even potential at a point at height z above or below the axis of charged ring/disc. Please help me with this. We have to fi...
This seems like a HW question to me, but I am surprised that it isn't closed as well, so is it fitfor the site?
I don't want the question to get closed after I answer it ;)
@FakeMod It's only been 3 hours, questions don't always get closed right away. It has 4 votes to close as homework though... so I would probably avoid that one.
@FakeMod What do you mean "isn't closed at well"
(now I was the fifth :P)
Got it! Thanks!
3:50 PM
0
In the lecture notes accompanying a course I'm following, it is stated that $$\DeclareMathOperator{\Tr}{Tr} \Tr\left[\gamma^{\mu}\gamma^{\nu}\right] = 4 \eta^{\mu\nu}$$ Yet when I try to prove this, I find something different as follows: $$\begin{eqnarray} \Tr\left[\gamma^{\mu}\gamma^{\nu}\ri... for your viewing pleasure horror Someone please go and add a tag to this question. The OP rejected my edit which was doing that. 0 This is a problem from Analytical Mechanics, Fowles & Cassiday. I am not sure if the solution in the solution manual is correct, and I am not sure if my solution is correct. A wheel of radius b rolls along the ground with constant forward acceleration a_0. Show that, at any given instant, the ... @EmilioPisanty now you're just making things up :P @ACuriousMind no, I thought that nobody was using \let or \def or \DeclareMathOperator, as Martin suggested was a thing, but I decided to query for them just in case turns out, Martin was right and I was not. This user has asked four similar questions and is still wanting answers. What should be done? 0 In the lecture notes accompanying a course I'm following, it is stated that$$\DeclareMathOperator{\Tr}{Tr} \Tr\left[\gamma^{\mu}\gamma^{\nu}\right] = 4 \eta^{\mu\nu} $$Yet when I try to prove this, I find something different as follows:$$ \begin{eqnarray} \Tr\left[\gamma^{\mu}\gamma^{\nu}\ri...
solved
@FakeMod done.
3:55 PM
@EmilioPisanty Thanks 👍
@FakeMod Once again, please use custom moderator flags to call our attention to user behaviour that you think needs some sort of intervention.
2
From the information about thermal expansion on Wikipedia, I found that if I heat a steel rod that's 1-meter in length and 1-cm in diameter steel rod to 100 degrees Celsius, then it will expand by approximately 1 mm (based on linear expansion coefficient).$${\require{cancel}} {\def\rod#1#2{\disp... any thoughts about the use of MathJax on ↑ that one? @ACuriousMind Ohh! I am sorry. I keep on forgetting that. Do I need to flag it now that you know it? @FakeMod yes it gets it onto the system and is then easier to track down the line @FakeMod Yes. Please do not rely on me or any other mod doing anything just because you told us something in chat. 3:57 PM say, if this user comes back next month and causes trouble, the flag record is there @EmilioPisanty I mean, I'm pretty easily impressed, but that's pretty cool. Beats what I could do in Paint. @EmilioPisanty I have two thoughts: 1. "Wow, that's dedication." 2. "Why?" @FakeMod .... and also, helps you work towards those sweet sweet Citizen Patrol / Deputy / Marshall badges Shit! I have 0 flags. I can't flag that user. Somebody flag that @FakeMod it will keep until tomorrow. 3:59 PM In other news, I've just dropped a glass water bottle onto my foot. I can injure myself perfectly fine even without leaving the house :P speaking of which, I'm coming up on my fourth unawarded Marshall badge @EmilioPisanty Congrats for the other 3!! @ACuriousMind I've got at least a hundred Gerolsteiner glass bottles upstairs. We use those things for everything, they're bulletproof @ACuriousMind @JMac the question was more, should it be allowed to remain? Well, maybe not literally. Unless it was a small bullet. 4:01 PM it looks like fragile code to me @tpg2114 Yeah. Unfortunately, my foot is not... But don't worry, the bottle is fine @FakeMod no, as in, I'm coming up on 2500 helpful flags, but for some unexplained reason the Marshall badge is only awarded once ¬¬ I want my badges To be fair, isn't that the case for all the moderation badges? @ACuriousMind Phew. Glass is a precious resource ;) @EmilioPisanty What does that mean? It's not as if TeX compilers are under active development :P 4:04 PM 0 I couldn't understand the arrangement. Arrangement- Flags needed That typo was.....nice (yes, I know about LaTeX 3 or whatever it's called, but (La)TeX as is is essentially frozen afaik) @ACuriousMind Isn't it LaTeX2e? That falls under "whatever it's called" :P @ACuriousMind :-) @ACuriousMind we don't run LaTeX, we run MathJax which does see a decent amount of development and which also puts a decent amount of control on the hands of the user 4:08 PM Looking at the code, it doesn't seem to use anything particularly outlandish with the Common HTML renderer Hm, alright, you've convinced me ;) So...screenshot the "best" version and add it as an image to the post? html-css renderer preview-html renderer @ACuriousMind good yes, I think so too 4:52 PM @JMac You can get the same badge for each review queue Like you can get Custodian, Reviewer, and Steward once for each queue 5:22 PM 0 Well, I was wondering about the real age of our universe, I found that it's estimated to be 13.8\times 10^9 years. Is it an approximation, or laws behind this age? Will I get moderated if I say "count the rings" @Slereah Only if you can cite your sources that show the universe is a tree :) 1 why does not the dielectric field cancel out the capacitor's field? The polarization of the dielectric in the capacitor does reduce the effective electric field of the capacitor, but doesn't completely cancel it out. The reason is the molecules of the dielectric material are not perfectly po... Pet peeve: When users post answers that cover what is already covered in other answers :P To be fair this user was probably making their answer at the same time as I was @AaronStevens Yeah, that does bug me too. In this case I'd give benefit of the doubt because his answer is a bit wordier and has a picture, so he was probably writing it as yours was submitted. It does really irk me when it's like 4 hours later and someone does that though. @JMac Yeah I usually don't want to go through the trouble putting pictures in my answer :P But yeah, definitely an issue if it has been a good amount of time since the answer was posted "In quantum mechanics what is called the Dyson formula is what in mathematics is called the iterated integral-expression for parallel transport" There's the fancy word Although this is nlab, so that word may only exist there Flags needed! 0 There’s a simple yet elegant answer to this question. It’s found in the Relational interpretation of Quantum Mechanics by Theoretical Physicist Carlo Rovelli and the recent Wigner’s friend experiment. Simply, no collapse or universal measurement occurs. Here’s an explanation from Relational Quan... 5:34 PM 1 Is F=ma a general formula for all cases in the physical world? or Is it only limited in linear motion? Wow I do not remember voting to close this question Shows how fast I go through the close queue I guess :P 5:57 PM Hi! I am bored! 3 hours ago, by FakeMod The light in the medium persists of the original light wave and the light wave created by the oscillation of the electrons. The latter can further be splitted into a component, which travels with the vacuum speed of light and a component, which seems to travel with the slower speed of light. Individually they all travel with the vacuum speed of light, but in sum, the components with the vacuum speed of light cancel each other out, as is stated in the Ewald-Oseen extinction theorem, which is quite counter-intuitive. E.g. for visible light this extinction length is \approx 1\,mm — clevor 1 min ago Can anybody explain this to me? 6:13 PM What should I do when I am out of flags? In quantum computing, the cat state, named after Schrödinger's cat, is a quantum state that is composed of two diametrically opposed conditions at the same time, such as the possibilities that a cat be alive and dead at the same time. Generalizing Schrödinger's gedanken experiment, any other quantum superposition of two macroscopically distinct states is also referred to as a cat state. A cat state could be of one or more modes or particles, therefore it is not necessarily an entangled state. This is in contrast to the more specific concept of a Greenberger–Horne–Zeilinger state, which by definition... ah, isn't that Wikipedia page looking great, now that its animation of the Wigner function is... ... not wrong... the idiot who made the original file had the thing rotating the wrong way 🙄🙄🙄 When will I lose that "new contributor" banner? @FakeMod As I understand it, it goes away after a week ... but I swear I've seen an account with your name before. Is this the first account you make? , you mean 6:30 PM @EmilioPisanty This might have been the 4th one or so. I deleted the original one (1722 rep) because it was affecting my studies and then I created one day accounts if I had doubts. This current account is the longest I have stayed here (excepting my first original account). You might have seen me here: -9 Just yesterday, I read this and there dmckee♦ posted this comment, and he said: ...relatively small fraction of the eligible users apply their power with any regularity. Now there is already a question regarding this comment by Emilio Pisanty, but that just asks for data. Now, I have writte... @FakeMod Please indicate it on your profile when you do this deleting accounts because it's interfering with your studies is perfectly legitimate but it's incredibly disconcerting when this happens i.e. when there's an account whose age + rep don't match what one recalls and are not assigned to previous interactions and previous participation in the public record @EmilioPisanty Ok! I get it. Does it look good now? 6:49 PM Should I use \mathrm d x or dx? in what context? i don't think it matters much if you're talking about differentials, sometimes in GR dx is used to represent covector bases at least as far as I know @Charlie generally....(I don't know if that makes sense) @Charlie Bingo! Looks like we were answering the same question :) @Charlie And I asked that question on differentials just because I had to use it in the same answer :) Is a tag score equal to the total upvotes on the questions containing that tag? If yes then why am I only getting a score of 4 on tags such as thermodynamics and entropy whereas I actually have 6 uovotes on my answers to the questions under that tag? I think that it hasn't been updated yet.... 7:19 PM @FakeMod The tag score is updated like once a day. SE is not real-time in most aspects! @FakeMod Since the \mathrm{d} is not a variable but an operator, it should be upright. @ACuriousMind Got it! @ACuriousMind Hmm...Thanks! 7:33 PM @FakeMod If I am typing out the MathJax I use \text d, but if I see d in another post I won't go in and edit it just for that reason. i'm too lazy to do that myself my knowing -why- it's sensible to do that is not the same as me be willing to do that the human condition in a nutshell priorities @fakemod your answer on the guass' law post is missing a at the top somehwere @Charlie I think it is fine to just edit it :) 7:42 PM @AaronStevens Single is too little an edit to suggest it Easy to forget that as a >2k user @ACuriousMind Ah yes, forgot that ^ :( 6 The source of an electromagnetic field is a distribution of electric charge, \rho, and a current, with current density \mathbf{J}. Considering only Faraday's law and Ampere-Maxwell's law:$$ \nabla\times\mathbf{E}=-\frac{\partial\mathbf{B}}{\partial t}\qquad\text{and}\qquad\nabla\times\mathbf...
The first time in a while I have seen a decent question on the HNQ
@ACuriousMind There was more to do. ;-)
@Semiclassical If I'm on a computer, I try to remember to use upright d, but on a phone it gets a bit painful.
7:53 PM
if i'm writing by hand, i guess i do try to make it look different?
but i just find \mathrm{d}x just too fussy
@Semiclassical \text d works fine too. Fewer characters to type
No way do I make the effort to do anything but $dx$
yeah
@FakeMod With that question, it's not clear exactly what the OP wants to know. My feeling is that they want to know the QM reason that causes the different frequencies of visible light to have different speeds in the glass, rather than why the different speeds lead to different refraction angles. But they haven't responded to any of the answers or comments. Personally, I would have posted a comment requesting clarification before submitting an answer...
@AaronStevens But that's semantically incorrect :P
7:58 PM
@ACuriousMind \textrm ?
It's not text!
it's formatted as text, therefore text
$\int {\text d}^n x 2^x \ln \Gamma(x)$ vs. $\int \text d^n x 2^x \ln \Gamma(x)$ vs. $\int {\text d}^n x {\text d}^m y 2^x \ln \Gamma(x) \Gamma(y)$ vs. $\int {\text d}^n x d^m y 2^x \ln \Gamma(x) \Gamma(y)$ hmm
So \text only affect the next character in front of it and nothing else?
$\text dx dy$
there's a few commands that work like that
my favorite being \vec
8:02 PM
That's not a terrible burden for the few times you really want it to look good but don't want to waste tons of time
$\vec{a}$ and $\vec a$
@Semiclassical I prefer $\mathbf a$ instead of $\vec a$
$\mathbf aa$ vs. $\vec aa$
\vec{a} and \vec a
That's pretty normal LaTex, eg $\frac12$
8:02 PM
there's another instance of that that i use but I forget which one
oh, right
\frac 1 2
$\frac 1 2$
that one i use a bunch
I've wasted so much time writing those {} brackets e.g. in \vec{a} :(
Or just \frac12 no spaces $\frac12$
$\frac e 2$
yeah, that's actually the one
unfortunately, it only works for single characters
Nice
8:04 PM
so it does save labor but only in the simplest cases
$\frac{e^x}2$
$\frac{\Gamma^2(xyz)}22$
This is a whole new world
but i run into $\frac 1{stuff}$
a lot
little latex discoveries are wondrous
$\frac {#}2$ $\frac 2{@}$ $\frac 2{#}$
another one i'm proud of discovering involves the align environment, let me see if I can make it work
\begin{align}
a&=b \\[2cm]
c&=d \\
\end{align}
Found a way to break the trick already
8:07 PM
hmm, maybe i'm not remembering it right
oh, it did work
neat
;-)
it lets you control row spacing, basically
Nice, multiple columns are the worst
which my collaborator who is obsessed with such things was pleased as heck to learn about
I sometimes use \\[6pt] for that.
8:12 PM
yeah, the 2cm example was not a realistic one
nice
and a much better way of controlling it
(i forget how my collaborator was doing it previously)
Holy shi...
0
Quantum field theorists seem to me to be among the most ardent supporters of "shut-up and calculate". When pressed, they will usually say something like "physics is just algorithms to produce experimental results" and suggest that it is naive to suppose that human understanding is possible. I w...
I can't believe I missed the flaw in his definition the first time I skimmed this shocking paper
It's better not to engage this stuff, if someone can delete those last two posts right above this
Nah lets engage
8:27 PM
Mar 22 at 16:02, by PM 2Ring
This guy seems to know his stuff. https://physics.stackexchange.com/a/537709/123208 I had a brief look at the start of his paper linked at the end of that answer, Mathematical Implications of Relationism. It looks interesting, but I don't have the skills to evaluate it. True, it's not exactly mainstream, but it doesn't feel like the work of a crackpot.
Friendly reminder: Please try to refrain from discussing specific other users in chat where they are not aware and thus cannot respond.
Fair enough. Maybe we should invite him to chat here, or in a new room. He might be slightly unorthodox, but he seems happy enough to engage in discussions without getting aggressive.
9:04 PM
Can the hydrogen atom spectrum ever in any sense be thought of as existing in a finite dimensional Hilbert space?
9:30 PM
If I was interested in learning more about smoothness of functions in the context of GR what branch of pure maths would I find useful?
Is that real analysis or functional analysis or something?
Differential geometry, framed in the language of real and functional analysis
Ok thanks
1 hour later…
10:37 PM
@bolbteppa I prefer fake analysis
pseudo-real analysis (ba-dum-tch)
0
Listen to these questions on this forum: Q: Schrödinger's cat question Q: The Bohm interpretation and Schrodinger's cat Q: Is Schrodinger's Cat itself an observer? When was there a Schrodinger's cat experiment? These questions are all speculation. My question was based on an actual experiment. Yo...
11:08 PM
@PhysicsMeta Yeah I am not touching that one
@AaronStevens me neither.
|
{}
|
# What is the sum of the square root of 72 + square root of 50?
May 1, 2018
$11 \sqrt{2}$
#### Explanation:
$\text{using the "color(blue)"law of radicals}$
•color(white)(x)sqrtaxxsqrtbhArrsqrt(ab)
$\text{simplifying each radical}$
$\sqrt{72} = \sqrt{36 \times 2} = \sqrt{36} \times \sqrt{2} = 6 \sqrt{2}$
$\sqrt{50} = \sqrt{25 \times 2} = \sqrt{25} \times \sqrt{2} = 5 \sqrt{2}$
$\Rightarrow \sqrt{72} + \sqrt{50} = 6 \sqrt{2} + 5 \sqrt{2} = 11 \sqrt{2}$
|
{}
|
# Fee Model
The interBTC bridge uses conceptually three different and independent fee models:
1. interBTC Fee Model. The internal interBTC bridge fee model covers any payments made through the operation of the bridge, e.g., the issue, redeem, or replace processes. This process concerns Users, Vaults (and its Nominators), and Relayers.
2. Griefing Fee Model. These are DOT fees paid to the Vault on a failed issue or replace.
3. Transaction Fee Model. The transaction fees are essentially the DOT fees paid on every transaction to the Collators.
## Payment Flows
We detail the payment flows for both models in the figure below:
## interBTC Fee Model
### Issue and Redeem Fee Distribution
The primary fees in interBTC are paid by users during Issue and Redeem as a relative fee on the issued or redeemed interBTC.
Vaults earn fees based on their currently backed interBTC (i.e., vault.issuedTokens). To reduce variance of payouts, the interBTC bridge implements a pooled fee model. This means that Vaults earn a share of each fee based on their share of issued interBTC in the bridge.
If the Vault does not back interBTC then it does not have a stake in the system and it will not receive any rewards, i.e., its stake is 0. Conversely, if the Vault has any issued interBTC, the Vault will earn rewards. Thus, only Vaults directly locking Bitcoin in the system will earn rewards from users.
Each time a user issues or redeems interBTC, they pay the following fees to a global fee pool:
• Issue Fee: A relative fee paid based on the requested interBTC paid in interBTC, for the current parameterization see IssueFee
• Redeem Fee: A relative fee paid based on the requested BTC paid in interBTC, for the current parameterization see RedeemFee
Note
Since redeem fees are backed by the Vault, they must use the Replace protocol to exit the system. To solve this issue, we allow self-redeems based on the Vault’s account ID which sets the redeem fee to zero.
From this fee pool 100% is distributed among all active Vaults.
Each Vault is receiving a fair share of this fee pool by considering its stake in the system. The stake in the system is just the amount of BTC a vault is currently insuring with collateral. Calculating the rewards for a Vault is equivalent to this formula:
$\text{rewards} = \text{stake} (\text{totalRewards} / \text{totalStake})$
Eq. 1: Vault reward distribution.
Note
As an example, if we had 1 interBTC to distribute among all Vaults with total stake 200 and assuming the individual Vault has stake 100, the reward share could be calculated by: 100 * (1 interBTC / 200) = 0.5 interBTC
To be exact, the stake is expressed as the interBTC issued by a Vault. The issued interBTC are the interBTC currently being backed by the Vault. This shows how much a Vault’s collateral is “occupied” by users:
$\text{stake} = \text{interBTCIssued}$
Whenever a Vault is increasing or decreasing the number of issued interBTC it is backing, we MUST update their stake in the reward pool accordingly. These updates are achieved through the issue, redeem, and replace operations.
#### Fee Payouts
The Vault fee is paid each time an Issue or Redeem request is executed. Naively speaking, the bridge behaves as if on each issue and redeem, the bridge would loop through all Vaults to determine their share of stake, i.e., vault.issuedTokens / totalSupply, and distribute a percentage of the paid fees to the Vault.
Since a naive implementation would result in unbounded iteration, the fee payout is implemented in a different way. However, the outcome it is equivalent to the naive approach. The payouts are based on the pull-based Scalable Reward Distribution with Changing Stake Sizes. This scheme allows rewards to be drawn by each Vault (and Nominator) individually and at any time without the interBTC bridge having to loop over all Vaults each time rewards are paid out. Read the Excursion: Scalable Reward Distribution section if you would like to understand how the payout system works under the hood.
### Griefing Fees
Griefing collateral is locked on requestIssue and requestReplace to prevent Griefing. If the requests are indeed cancelled, the griefing collateral is paid to the free balance of the Vault that locked collateral in vain. On successful execute, the griefing collateral is refunded to the party making the request.
• Issue Griefing Collateral: A relative collateral locked based on the requested interBTC paid in DOT, for the current parameterization see IssueGriefingCollateral
• Replace Griefing Collateral: A relative collateral locked based on the request interBTC paid in DOT, for the current parameterization see ReplaceGriefingCollateral
#### Griefing Collateral Currency
The currency that is used for griefing collateral used for issue and replace. This value is set to the currency of the transaction fees, i.e., DOT, regardless of the vault’s configured backing collateral currency.
When Vaults are below the PremiumRedeemThreshold, users are able to redeem with the Vault and receive an extra “bonus” slashed from the Vault’s collateral. This mechanism is to ensure that (1) Vaults have a higher incentive to stay above the PremiumRedeemThreshold and (2) users have an additional incentive to redeem with Vaults that are close to the LiquidationThreshold.
• Premium Redeem Fee: A relative fee slashed from the Vault’s collateral paid to the user in the vault’s COL if a Vault is below the PremiumRedeemThreshold, for the current parameterization see PremiumRedeemFee
### Punishment Fees
Punishment fees are slashed from the Vault’s collateral on failed redeems. A user can choose to either retry with another Vault or reimburse the interBTC amount. In both cases, the a punishment fee is deducted from the Vault’s collateral to ensure that Vault’s are punished in both cases.
• Punishment Fee: A relative fee slashed from the Vault’s collateral paid to the user in the vault’s COL if a Vault failed to execute a redeem request, for the current parameterization see PunishmentFee
### Theft Fee
Relayers receive a reward for reporting Vaults for committing theft (see report_vault_theft and report_vault_double_payment).
• Theft Fee: A relative fee slashed form the Vault’s collateral paid to the Relayer in the vault’s COL if a Vault commits theft, for the current parameterization see TheftFee
### Arbitrage
Arbitrage trades are executed by anyone that exchanges interBTC for COL against the LiquidationVault. The LiquidationVault is essentially an AMM with two balances:
• issuedTokens: amount of interBTC that have been liquidated through safety failures, see Vault Liquidations
• lockedCollateral: amount of COL that have been confiscated through safety failures, see Vault Liquidations
Anyone can now burn interBTC for COL at the exchange rate of the issuedTokens/lockedCollateral from the LiquidationVault. As the LiquidationThreshold is strictly above the current exchange rate of the BTC/COL pair at the time of liquidation, this should represent an arbitrage opportunity: the value of burned interBTC should be lower than the value of received COL.
However, in practice, the arbitrage process might not work as intended. See External Economic Risks for a discussion of related problems. Note that there are no fees being collected to execute trades against the LiquidationVault.
### Excursion: Scalable Reward Distribution
We recommend reading first the Scalable Reward Distribution paper and then the extension for changing rewards. Note that this scheme is “just” an efficient equivalent of the Vault distribution outlined above. Last, we extend this scheme to account for Vault Nomination and Vault Liquidations. The adopted scheme is described in the README of the implementation.
Notable changes to the Scalable Reward Distribution with Changing Rewards are:
• Staking Pools Fees are forwarded to a Reward Pool and then distributed to a Staking Pool. There is one Staking Pool for each Vault and all of its Nominators.
• Slashing On liquidation of Vaults, no more fees are forwarded to the Staking Pool of that Vault.
See the figure below for an indication how the Staking Pools are used.
In the scalable reward distribution, a single source of truth is used to calculate rewards: the “stake”. The “stake” can be any numeric representation. In interBTC, stake is defined as: the current amount of issued interBTC. A Vault’s stake is adjusted based on the change in issued interBTC - for instance we increase the issued interBTC on successful issues and decrease this on executed redeems.
Note
For example, if a Vault executes issue requests amounting to 2,456,000 interSatoshi (smallest denomination) being added to the system, its stake would increase by 2,456,000. If the Vault then executes redeem requests, its rewards are reduced. So if the Vault redeems all 2,456,000 interSatoshi, its stake is 0 again. On a liquidation, this is again set to zero since the Vault no longer backs these tokens.
Now, each Vault’s rewards are calculated according to the following formula (equivalent to Eq. 1):
$\text{deposit}(\text{stakeDelta}): \text{rewardTally} \mathrel{+}= \text{rewardPerToken} \cdot \text{stakeDelta}$
$\text{stake} \mathrel{+}= \text{stakeDelta}$
$\text{totalStake} \mathrel{+}= \text{stakeDelta}$
$\text{distributeReward}(\text{reward}): \text{rewardPerToken} \mathrel{+}= \text{reward} / \text{totalStake}$
$\text{computeReward}(): \text{return stake} \cdot \text{rewardPerToken} - \text{rewardTally}$
Eq. 3: Vault reward distribution using the SRD.
Definitions
• stake: the amount of interBTC issued by this Vault.
• reward_tally: the Vault’s accumulated rewards (can be negative or positive).
• stake_delta: the stake impact based on issuing or redeeming interBTC.
• total_stake: the total amount of interBTC issued by all Vaults.
• reward_per_token: the current reward per current stake (the total_stake).
• reward: the rewards paid from issue and redeem requests.
The reward is influenced by the total of all stakes. So the share of rewards paid to a Vault is determined by how many other Vaults are in the system and their individual stake.
Example Without Nomination
Current stake
Note: stake is always non-zero.
• Vault Alice has a stake of 250
• Vault Bob has a stake of 30
• Vault Charlie has a stake of 100
The total stake is therefore 380.
Reward claims
Let’s assume there is a total of 1 interBTC in the reward pool based on the accumulated issue and redeem request. Then the reward_per_token = 1 interBTC / 380.
• Vault Alice has a claim of 250 * 1 interBTC/380 = 0.6578947368421052 interBTC
• Vault Bob has a claim of 30 * 1 interBTC/380 = 0.07894736842105263 interBTC
• Vault Charlie has a claim of 100 * 1 interBTC/380 = 0.2631578947368421 interBTC
Example With Nomination
Current stake
Note: stake is always non-zero.
• Vault Alice and her Nominators have a stake of 250. Alice is fully nominated such that Alice is backing 200 and her Nominators are backing 50.
• Vault Bob has a stake of 30
• Vault Charlie has a stake of 100
The total stake is therefore 380.
Reward claims
Let’s assume there is a total of 1 interBTC in the reward pool based on the accumulated issue and redeem request. Then the reward_per_token = 1 interBTC / 380.
• Vault Alice has a claim of 200 * 1 interBTC/380 = 0.526315789 interBTC
• Alice’s Nominators have a claim of 50 * 1 interBTC/380 = 0.131578947 interBTC
• Vault Bob has a claim of 30 * 1 interBTC/380 = 0.07894736842105263 interBTC
• Vault Charlie has a claim of 100 * 1 interBTC/380 = 0.2631578947368421 interBTC
## Transaction Fee Model
The interBTC bridge chain adopts the Polkadot relay chain model with DOT as the native currency for paying transaction fees. In this model, collators receive 100% of the transaction fees paid by Users, Vaults, and Relayers. We refer to the official Polkadot documentation for full details.
|
{}
|
Share
Books Shortlist
Your shortlist is empty
# Solution for A Cube of 9 Cm Edge is Immersed Completely in a Rectangular Vessel Containing Water. If the Dimensions of the Base Are 15 Cm and 12 Cm, Find the Rise in Water Level in the Vessel. - CBSE Class 9 - Mathematics
ConceptVolume of a Cuboid
#### Question
A cube of 9 cm edge is immersed completely in a rectangular vessel containing water. Ifthe dimensions of the base are 15 cm and 12 cm, find the rise in water level in the vessel.
#### Solution
Volume of cube =S^3=9^3=729cm^3
Area of base lxxbxx15xx12=180cm^2
Rise in water level = "Volume of cube"/"Area of base of rectangular vessel"
(729)/180=4.05cm
Is there an error in this question or solution?
#### APPEARS IN
R.D. Sharma Mathematics for Class 9 by R D Sharma (2018-19 Session) (with solutions)
Chapter 18: Surface Areas and Volume of a Cuboid and Cube
Q: 19
Solution for question: A Cube of 9 Cm Edge is Immersed Completely in a Rectangular Vessel Containing Water. If the Dimensions of the Base Are 15 Cm and 12 Cm, Find the Rise in Water Level in the Vessel. concept: Volume of a Cuboid. For the course CBSE
S
|
{}
|
# Matlab Equations Of Motion
Then, generate function handles that are the input to ode45. I have a 3D data set of a surface that is not the graph of a function. A di fferen-tially heated, stratified fluid on a rotating planet cannot move in arbitrary paths. Transfer Function - One Equation of Motion by Dedik Tutorial. PDE Toolbox - In addition to some custom codes, a special set of MATLAB application files for vibration and wave motion analysis will be used. The ode45 function within MATLAB uses the Dormand-Prince formulation. Using Matlab ode45 to solve di˛erential equations Nasser M. In other words, we will solve for , where. EKF Matlab Equations. Manifesto on Numerical Integration of Equations of Motion Using Matlab C. So, we have written the second order differential equation as a system of two first order differential equation. Finite difference jacobian matlab Finite difference jacobian matlab. The 'solve' command is a predefined function in MATLAB. In 1886, Professor Osborne Reynolds published hi. Jin-Yi Yu oe u qu oced ows • Thermodynamic & Momentum Eq. 24 Solve The Equations Of Motion For The Spring-pendulum System In The Previous Problem Using MATLAB ODE45 And Plot The Pendulum Angle (t) And Pendulum Length R(t) Versus Time. 6) is no different than equation (3. Generic Langevin equation. Ode45 Dynamic Ode45 Dynamic. I have written two functions for that, function f. The pendulum-cart system is interesting because it involves the motions of two bodies and shows how they interact with each other. We use D2yto represent y′′: >> dsolve(’D2y-2*Dy-15*y=0’) This has real roots of the characteristic equation but MATLAB can tackle complex roots, like with. MATLAB has built- in routines for computing both Laplace transforms and inverse Laplace transforms. System equations In general, the torque generated by a DC motor is proportional to the armature current and the strength of the magnetic field. fname is the name of the function containing all the rst order ode’s we wrote right at the beginning. 3D Rigid Body Dynamics: Free Motions of a Rotating Body We consider a rotating body in the absence of applied/external moments. Solve the equations of motion. This is similar to Galileo's principle that all objects fall at the same rate in a. This equation of motion is a second order, homogeneous, ordinary differential equation (ODE). The most general forced form of the Duffing equation is x^. +omega_0^2x=0, (1) where beta is the damping constant. SolCalc was originally coded in Matlab, and later upgraded to a compiled version (called MEX) to improve solving speed. The characteristic equation for this problem is,. For example: tic; index=0; for time=0:0. The function will return the number “1” if the matrix is symmetric and “0” if it is not. Rocket motion is based on Newton's third law, which states that "for every action there is an equal and opposite reaction". Coincidentally, I had started to use MATLAB® for teaching several other subjects around this time. This is just an overview of the techniques; MATLAB provides a rich set of functions to work with differential equations. In a dynamics problem I am working on, two different systems of equation that describe the motion of a body are both correct and should generate the same solutions. The first step is to obtain the equation of motion, which will be the second order ODE. Generic Langevin equation. 16 [25] Derive the equations of motion for the PR manipulator shown in Fig. MATLAB Variables Machine Dynamics with MATLAB by MathWorksMOOC. The document Solving Equations of Motion for Systems of Particles with MATLAB (Part - 4) Civil Engineering (CE) Notes | EduRev is a part of the Civil Engineering (CE) Course Introduction to Dynamics and Vibrations- Notes, Videos, MCQs. Solve the following equations using Matlab (a) (b) Exercise 10. Here, the random number generator randn is used-each call to randn produces an independent "pseudorandom" number from the N(O, 1) distribution. Appendix B: Derivation of differential equations of motion Equations 1-3 are given. This is the three dimensional analogue of Section 14. Assume that all of the initial conditions are zero, so that these equations represent the situation where the vehicle wheel goes up a bump. Then, generate function handles that are the input to ode45. System equations. The maximum likelihood estimate (mle) of is that value of that maximises lik( ): it is the value that makes the observed data the \most probable". With little changes any multiple pendulum can be solved. Determinants in Matlab. Course Description: This course is an introduction to the numerical solution of differential equations. Matlab Help can be found on Number 1 Matlab Help Website in the world i. And finally, solve for s as a function of t. Rewriting these as the highest order derivatives gives us something we can create in Simulink. m function [x,y] = rk4_c(f, tspan, y0, n) % Runge-Kutta % Implementation of the fourth-order method for coupled equations % x is the time here % More or less follows simplified interface for ode45; needs #points = n % Thanks to @David for helpful suggestions. The following change of variables can be made:. Acceleration of each link is computed by solving system of equations obtained from partial differential Lagrange's equations. For this problem, the equation of motion for the satellite will be coded as an anonymous function. Numerical integration midpoint method matlab Numerical integration midpoint method matlab. If you want a model of a mechanical system, you need the equations of motion so you can build the system from base Simulink blocks. Give the nonlinear equation of motion of the ball and beam. Symmetric=SymmetricMatrix(A) Exercise 9. It includes: Exponential, Growth, Decay Models, Newton's Law, Cooling, General Solution, Free, Fall , Gravity. This type of flight is called ballistic flight and assumes that weight is the only force acting on the ball. Router Screenshots for the Sagemcom Fast 5260 - Charter. One of the most useful tools in mathematics is the Laplace transform. Kepler introduced what is now known as Kepler's equation for the solution of planetary orbits, using the eccentric anomaly E, and the mean anomaly M. •Special thanks to Dr. MATLAB Variables Machine Dynamics with MATLAB by MathWorksMOOC. The pendulum shown consists of a concentrated mass m attached to a rod whose mass is small compared to m. Equation 4 shows Newton's second law for the x direction. The equations of motion can also be written in the Hamiltonian formalism. Transfer Function - One Equation of Motion by Dedik Tutorial. An equation of motion, also referred to as a differential equation of motion, mathematically and physically relates Newton’s second law of motion. t time of the simple pendulum motion are plotted in the same animation plot. 5 The Continuity Equation 42 2. Set parameters such as angle, initial speed, and mass. Learn more about ode45 MATLAB. Using the same technique we used above we can write the system in the following form. The Lagrangian equation of motion for the ball is then given by the following: (1) Linearization of this equation about the beam angle, , gives us the following linear approximation of the system:. Simulation of the Simplest Walker. A nonlinear system has more complicated equations of motion, but these can always be arranged into the standard matrix form by assuming that the displacement of the system is small, and linearizing. Problem Specification. The height of the object as a function of time can be modeled by the function h(t) = –16t 2 + vt + h, where h(t) is the height of the object (in feet) t seconds after it is thrown. This paper describes solution of the equations of motion of the mechanical system by using State-Space blocks in MATLAB/Simulink. This is where fname comes in. Making statements based on opinion; back them up with references or personal experience. Ode45 Dynamic Ode45 Dynamic. Kepler introduced what is now known as Kepler's equation for the solution of planetary orbits, using the eccentric anomaly E, and the mean anomaly M. I am trying to reproduce the trajectory of the baseball that is shown on the last page in order to verify my model. Think of as the coordinates of a vector x. A singular set of equations has no single solution because two or more equations are merely a multiple of the other equation, such as: X + Y = 7 2X + 2Y = 36. 1) if we substitute € 4π2 k for GM where G is the gravitational constant and M is the mass of the sun. Note that the derivativeof thevariable,, dependsuponitself. Question: Must Be Answered In MATLAB Code: The Equation Of Motion For A Pendulum Whose Base Is Accelerating Horizontally With An Acceleration A(t) Is: L(theta Double Dot)+gsin(theta)=a(t)cos(theta) Suppose That G = 9. I am trying to reproduce the trajectory of the baseball that is shown on the last page in order to verify my model. The equation involving only $$x$$ and $$y$$ will NOT give the direction of motion of the parametric curve. This is the three dimensional analogue of Section 14. The building block equations are derived by applying Newton's and Euler's equations of motion to an "element" consisting of two bodies and one joint (spherical and gimballed joints are considered separately). Stack Overflow for Teams is a private, secure spot for you and your coworkers to find and share information. We want to determine the differential equation associated with this motion and solve for the velocity and position functions. The wave equation for a plane wave traveling in the x direction is. Both yand y0are used in nding the cam pro le; y0is used in nding the follower face radius, and yand y00are used in nding the minimum base circle radius. It should be in the form shown in [5]. Phase plane plot and evolution of displacement w. The equations of motion for a rigid body include additional equations which account for rotation (in addition to translation). However, we will ignore this contribution. Jin-Yi Yu oe u qu oced ows • Thermodynamic & Momentum Eq. So, we have written the second order differential equation as a system of two first order differential equation. He has worked on a variety of area including astronomy, logarithms, calculus, the motion of the moon and plenty more. Motion occurs only in two dimensions, i. time) and one or more derivatives with respect to that independent variable. let’s consider the following system of equations. 2 Problem 2/87 (Rectangular. We can then obtain the equations of motion through. MATLAB® allows you to develop mathematical models quickly, using powerful language constructs, and is used in almost every Engineering School on Earth. I have a 3D data set of a surface that is not the graph of a function. Write a Matlab function that will test if a matrix is symmetric or not. Using Matlab ode45 to solve di˛erential equations Nasser M. The 3DOF (Body Axes) block considers the rotation in the vertical plane of a body-fixed coordinate frame about a flat Earth reference frame. The second derivative of the input angle actually affects the second derivative of. Kreyszig, John Wiley & Sons Inc, (ISBN 0471553808), 1993, TA330 KRE7 Further information on the use of MATLAB to solve ordinary differential equations can be. Think of as the coordinates of a vector x. Keyword CPC PCC Volume Score; equations of motion: 1. We follow the usual procedure: (i) convert the equations into MATLAB form; and (ii) code a MATLAB script to solve them. 6) Any solutions, xn(t), of the homogeneous equation (1. Here, v stands for speed, v0 is the initial speed, a is acceleration (which is equal to the downward acceleration of g in all projectile motion problems), s is the displacement (from the initial position) and as always you have time, t. Acceleration of each link is computed by solving system of equations obtained from partial differential Lagrange's equations. Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers. 3DOF (Body Axes) Implement three-degrees-of-freedom equations of motion with respect to body axes: 3DOF (Wind Axes) Implement three-degrees-of-freedom equations of motion with respect to wind axes: Custom Variable Mass 3DOF (Body Axes) Implement three-degrees-of-freedom equations of motion of custom variable mass with respect to body axes. Galileo was quoted above pointing out with some detectable pride that none before him had realized that the curved path followed by a missile or projectile is a parabola. Step 7: Solve Nonlinear Equations of Motion. The homogeneous solution, which solves the equation 2 xx +2βω +0 x=0 (1. A superposition of modal coordinates then gives solution of the original equations. Bibliography Includes bibliographical references and index. Now, the equations of motion for quarter model is, To calculate the natural frequencies of the system, ANALYTICAL MATLAB SIMULINK Wn1 5. 37 KB) by sofia yousuf. Graizer-Kalkan (2015) Ground Motion Prediction Equation Release Date: March 6, 2015 The GK15 can be used for earthquakes with moment magnitudes 5. I have a 3D data set of a surface that is not the graph of a function. When working with differential equations, MATLAB provides two different approaches: numerical and symbolic. Appendix B: Derivation of differential equations of motion Equations 1-3 are given. The symbol v 0 [vee nought] is called the initial velocity or the velocity a time t = 0. Solve the equations of motion. In MATLAB, usefminsearchor fsolveto find trim settings ΔδE " ⎡ ⎣ ⎢ ⎢ ⎢ ⎤ ⎦ ⎥ ⎥ ⎥ +" 11/13/18 9 Linearized Equations of Motion 17 Phugoid (Long-Period) Motion Short-Period Motion Approximate Decoupling of Fast and Slow Modes of Motion Hybrid linearized equations allow the. 7 Controlling the accuracy of solutions to differential equations 13. is not a scalar. To understand the input parameters for the ode45 function, type "doc ode45" and "doc odeset" in the MATLAB command window. Open a new M-File and type the following code. Solving the system along this axis greatly simplifies the mathematics. 1681 VEHICLE DYNAMICS PROJECT Author: Bimal. Create a MATLAB (ode23, ode15s, etc) or Python (ODEINT) script to simulate and display the results. Write a Matlab function that will test if a matrix is symmetric or not. Matlab 'is also used to develop user-friendly Graphic User Interface windowsfor data input and output as well asfor simulation. ) MATLAB will require the use of a 64-bit computer. 5 of the textbook, Zak introduces the Lagrangian L = K − U, which is the difference between the kinetic and potential energy of the system. The equations of motion for. The wave equation for a plane wave traveling in the x direction is. % To solve the linear equations using the solve command p = 'x + 2*y = 6'; q = 'x - y = 0'; [x,y] = solve(p,q) Subs Command. g Learn more about simscape MATLAB and Simulink Student Suite. Equations of motion. An equation of motion, also referred to as a differential equation of motion, mathematically and physically relates Newton’s second law of motion. Find detailed answers to questions about coding, structures, functions, applications and libraries. However, we will ignore this contribution. (b) If the motion is also subject to a damping force with c=4Newtons/(meter/sec), and the mass is. This paper describes solution of the equations of motion of the mechanical system by using State-Space blocks in MATLAB/Simulink. 2 Newton's equations The double pendulum consists of two. Additional resources (books, journal articles, websites, JAVA applets and demonstrations, etc. The origin of the wind-fixed coordinate frame is the center of gravity of the body, and the body is assumed to be rigid, an assumption that eliminates the need to consider the forces acting between individual elements of mass. • Matlab has several different functions (built-ins) for the numerical. >> [v,d]=eig(A) %Find Eigenvalues and vectors. MATLAB has built- in routines for computing both Laplace transforms and inverse Laplace transforms. This type of cascading system will show up often when modeling equations of motion. (a) Find the natural frequency of this system. Octave Script. Now, the equations of motion for quarter model is, To calculate the natural frequencies of the system, ANALYTICAL MATLAB SIMULINK Wn1 5. MATLAB CODES Matlab is an integrated numerical analysis package that makes it very easy to implement computational modeling codes. equations of motion of a system, we can use MATLAB to solve for both frequency and time domain responses without knowing anything about eigenvalues and eigenvectors. This example will cover derivation of equations of motion by hand, symbolic derivation of the equations of motion in MATLAB, simulation of the equations of motion, and simulation checks. Using MATLAB solvers and optimizers to make design decisions 14. Find the general solution of the differential equation y00 −y0 = ex−9x2. 2 2 1 D = CDρAV (1) µ ρVd Re (2) = πµ τ d m 3 = (3) First the differential equation for the x direction is found. I assume you know basic physics, in particular the concepts of force, acceleration, velocity, and position. 5: 675: 30: equations of motion 2. Verlet integration (French pronunciation: ) is a numerical method used to integrate Newton's equations of motion. Before we can numerically integrate the double pendulum’s equations of motion in MATLAB, we must express the equations in first-order form. Make a pendulum that moves according to an Learn more about simulink, simmechanics, 3d animation, pendulum, motion, force, block, joint Simulink, Simscape Multibody, Simulink 3D Animation. This is just an overview of the techniques; MATLAB provides a rich set of functions to work with differential equations. MATLAB Tutorial #8 ~ Persamaan Linier 2 Variabel by Dedik Tutorial. Find detailed answers to questions about coding, structures, functions, applications and libraries. (Here, X0 is upward. equations, and also helped greatly with the problems on Matlab. MATLAB Variables Machine Dynamics with MATLAB by MathWorksMOOC. Here, you can see both approaches to solving differential equations. MATLAB is convenient for finding the equations of motion using Lagrange method and for solving numerically the nonlinear differential equations. Manifesto on Numerical Integration of Equations of Motion Using Matlab C. The maximum likelihood estimate (mle) of is that value of that maximises lik( ): it is the value that makes the observed data the \most probable". This is the equation governing the motion of the above spring-mass system, but now with a small amount of damping (underdamping). The Lagrangian equation of motion for the ball is then given by the following: (1) Linearization of this equation about the beam angle, , gives us the following linear approximation of the system:. To use free vibrations mode shapes to uncouple equations of motion. Motion of a particle in two or more dimensions Projectile motion. The outputs are the initial angle needed to produce the range desired, the maximum height, the time of flight, the range and the equation of the path of. Runge-Kutta to solve 6DOF equations of motion. Phase plane plots of the spring motion and pendulum motion are plotted in the same animation plot. Simulate three-and six-degrees-of-freedom equations of motion with fixed and variable mass using the equations of motion blocks. 9 Other MATLAB differential equation solvers 14. Octave Script. Both yand y0are used in nding the cam pro le; y0is used in nding the follower face radius, and yand y00are used in nding the minimum base circle radius. 2 Free body diagram of the passive suspension system 1. 1 The equations of motion. Implement Euler angle representation of six-degrees-of-freedom equations of motion: 6DOF (Quaternion) Implement quaternion representation of six-degrees-of-freedom equations of motion with respect to body axes: Run the command by entering it in the MATLAB Command Window. The most general type of motion an object experiences is translational plus rotational motion. (a) Find the natural frequency of this system. A video segment from the Coursera MOOC on introductory computer programming with MATLAB by Vanderbilt. 3 Equations of motion - Three typical cases by RWTHx/Machine Dynamics with MATLAB. Download Presentation. Script for solving equations of motion. For faster integration, you should choose an appropriate solver based on the value of μ. (Autonomous means that the equations are of the form x0 = F(x;y); y0 = G(x;y), so the indepen-dent variable t doesn’t appear explicitly in the equation. Question: Must Be Answered In MATLAB Code: The Equation Of Motion For A Pendulum Whose Base Is Accelerating Horizontally With An Acceleration A(t) Is: L(theta Double Dot)+gsin(theta)=a(t)cos(theta) Suppose That G = 9. Note that we return the states derivatives in a column vector. You will learn to use numerical methods to search for roots of non-linear equations, to solve differential equations, and to search for optimal solutions. 6 Solving a higher order differential equation 13. This model is for an active suspension system where an actuator is included that is able to generate the control force U to control the motion of the bus body. We will gain more understanding by selecting a few simpler problems that are characteristic of the more general motions of rotating bodies. In this section we will use first order differential equations to model physical situations. Direct Dynamics – starting from the forces and moments acting on a body determines the motion arising from these forces and moments. This type of flight is called ballistic flight and assumes that weight is the only force acting on the ball. for a total of 2j states. The equations of motion are A x b = u ˙ = F x m − q w − g sin θ , A x e = F x m − ε sin θ A z b = w ˙ = F z m + q u + g cos θ , A z e = F z m + ε cos θ q ˙ = M I y y θ ˙ = q. The pendulum shown consists of a concentrated mass m attached to a rod whose mass is small compared to m. MATLAB has added more "native" support for strings in recent releases. The state-space is the vector space that consists of all the possible internal states of the system. For μ = 1, any of the MATLAB ODE solvers can solve the van der Pol equation efficiently. Simulation of the Simplest Walker. When the suspension system is designed, a 1/4 model (one of the four wheels) is used to simplify the problem to a 1-D multiple spring-damper system. 547; Zwillinger 1997, p. Recall that we still haven’t told MATLAB what exactly the equations of motion are that need to be integrated. This is not a particularly accurate model of the drag force due to air resistance (the magnitude of the drag force is typically proportion to the square of the speed--see Section 3. Eventually, you will gain the ability to analyze and interpret the computational results in order to optimize your design. The objective of Stability and Control. MATLAB Exercises 26 Suggested References 27 Chapter 2 Basic Conservation Laws 2. From the picture above and Newton's law, we can obtain the dynamic equations as the following: (1) (2) Transfer function models. Note that the derivativeof thevariable,, dependsuponitself. Mathematical prerequisites: Students taking this course are expected to have some familiarity with linear algebra, single variable calculus, and differential equations. Newton's Second Law, equations of motion are derived, subsequently longitudinal stability equations are found and linearized. For faster integration, you should choose an appropriate solver based on the value of μ. namic equations of motion for a multibody spacecraft suitable for solution by numerical integration. space equations can be used for multiple-input, multiple-output systems, are very versatile, and can be used to model very complex systems. The focus is more on applied and computational aspects of many of the subjects you saw in 22B. Thanks for contributing an answer to Mathematics Stack Exchange! Please be sure to answer the question. The ode45 solver is one such example. Particles drift parallel to the magnetic field with constant speeds, and gyrate at the cyclotron frequency in the plane. The algorithm was first used in 1791 by Delambre and has been rediscovered many times since then, most recently by Loup Verlet in the 1960s for use in molecular. In particular we will look at mixing problems (modeling the amount of a substance dissolved in a liquid and liquid both enters and exits), population problems (modeling a population under a variety of situations in which the population can enter or exit) and falling objects (modeling the velocity of a. Mathematical prerequisites: Students taking this course are expected to have some familiarity with linear algebra, single variable calculus, and differential equations. Meysam Mahooti Last seen: 1 dag ago 50 total contributions since 2016. Find detailed answers to questions about coding, structures, functions, applications and libraries. Now, the equations of motion for quarter model is, To calculate the natural frequencies of the system, ANALYTICAL MATLAB SIMULINK Wn1 5. In his MATLAB Central submission Euler-Lagrange equation, Hitoshi shows how the Symbolic Math Toolbox can be used to easily obtain the equations of motion of a system by simply defining the energies involved. MATLAB has added more "native" support for strings in recent releases. That would fix things up except that the second part involving term1, term2 etc. Find Roots of Quadratic Equation. This document presents Lagrangian techniques to derive equations of motion using symbolic toolbox in MATLAB. A nonlinear system has more complicated equations of motion, but these can always be arranged into the standard matrix form by assuming that the displacement of the system is small, and linearizing. function f=fun1(t,y) f=-t*y/sqrt(2-y^2); Now use MatLab functions ode23 and ode45 to solve the initial value problem numerically and then plot the numerical solutions y, respectively. This is the form of the wave equation which applies to a stretched string or a plane electromagnetic wave. The drag equation states that drag D is equal to the drag coefficient Cd times the density r times half of the velocity V squared times the reference area A. Equations of motion are derived using the algebraic method, graphical method, and calculus method. MATLAB Variables Machine Dynamics with MATLAB by MathWorksMOOC. INTRODUCTION. Lecture 3: Applications of Basic Equations • Pressure Coordinates: Advantage and Disadvantage •Momentum Equation ÎBalanced Flows ESS227 Prof. Aug 30, 2016. Peter Frederikson, who is the supervisor of my opponent group, gives valu- able suggestions about the overall layout of the report. Lecture 4. View questions and answers from the MATLAB Central community. MATLAB Variables Machine Dynamics with MATLAB by MathWorksMOOC. Aircraft simulations include the General Dynamics F-16 Fighting Falcon, Convair F-106B Delta Dart, Grumman F-14. •Thanks to our mentor Joseph Gibney for getting us started on the MATLAB program and the derivations of equations of motion. Runge-Kutta to solve 6DOF equations of motion. The example goes so far as to create a pole-zero map which exactly matches the plot of eigenvalues generated. 1) if we substitute € 4π2 k for GM where G is the gravitational constant and M is the mass of the sun. On this page we develop the equations which describe the motion of a flying ball including the effects of drag. MATLAB Tutorial on ordinary differential equation solver (Example 12-1) Solve the following differential equation for co-current heat exchange case and plot X, Xe, T, Ta, and -rA down the length of the reactor (Refer LEP 12-1, Elements of chemical reaction engineering, 5th edition) Differential equations. I have to do this for 3 cases: Simple Projectile motion in a uniform gravitational field, any angle and starting velocity, no drag. The equation of motion for this pendulum is. Here, you can see both approaches to solving differential equations. System of linear equations matlab keyword after analyzing the system lists the list of keywords related and the list of websites with related content, in addition you can see which keywords most interested customers on the this website. This is the first equation of motion. A superposition of modal coordinates then gives solution of the original equations. Solution for the modal coordinates can be obtained by solving each equation independently. Step 7: Solve Nonlinear Equations of Motion. Verlet integration (French pronunciation: ) is a numerical method used to integrate Newton's equations of motion. Before attempting to solve the differential equations in the three situations described above, we will review various ways of denoting sinusoidal motion. The degrees of freedom of interest here is the velocity of the particle, denotes the particle's mass. The equations of motion are A x b = u ˙ = F x m − q w − g sin θ , A x e = F x m − ε sin θ A z b = w ˙ = F z m + q u + g cos θ , A z e = F z m + ε cos θ q ˙ = M I y y θ ˙ = q. Symbolic Math Toolbox™ expands these graphical capabilities by providing plotting functions for symbolic expressions, equations, and functions. He had arrived at his conclusion by realizing that a body undergoing ballistic motion executes, quite independently, the motion of a freely falling body in the. Try our Free Online Math Solver! Online Math Solver. This equation can display chaotic behavior. The equation of motion for a pendulum connected to a massless, oscillating base is derived the same way as with the pendulum on the cart. This paper describes a way to numerically solve the equations of motion for a rotating rigid body. For example: tic; index=0; for time=0:0. v = v 0 + at [1]. My initial intentions were to teach myself Kane's method (originally called Lagrange form of d'Alembert's principle) for developing dynamical equations of motion and then prepare a lecture. Let's first turn the state space equations of motion into a Matlab function. The following script, RunJerkDiff. Fx =max (4) Since the only force in the x direction is the air resistance, which. The Scope is used to plot the output of the Integrator block, x(t). Appendix B: Derivation of differential equations of motion Equations 1-3 are given. The most general type of motion an object experiences is translational plus rotational motion. space equations can be used for multiple-input, multiple-output systems, are very versatile, and can be used to model very complex systems. MATLAB Tutorial #8 ~ Persamaan Linier 2 Variabel by Dedik Tutorial. +omega_0^2x=0, (1) in which D=beta^2-4omega_0^2=0, (2) where beta is the damping constant. The right side of the equation represents the thrust force T: T = u dm dt. The equations of motion have four unknowns: θ 1, θ 2, T 1, and T 2. Peter Lynch of the University College Dublin, Director of the. (1) Depending on the parameters chosen, the equation can take a number of special forms. The equation involving only $$x$$ and $$y$$ will NOT give the direction of motion of the parametric curve. in the above expression indicates that MATLAB will consider all rows and '1' indicates the first column. Learn more about vibration, equation of motion, springs, structural, structures, stiffness, damping, forces, differential. function f=fun1(t,y) f=-t*y/sqrt(2-y^2); Now use MatLab functions ode23 and ode45 to solve the initial value problem numerically and then plot the numerical solutions y, respectively. For example, with no damping and no forcing, delta=gamma=0 and taking the plus sign, the equation becomes x^. MATLAB Variables Machine Dynamics with MATLAB by MathWorksMOOC. The following script, RunJerkDiff. Trying to solve motion equation using ODE45. Numerical integration midpoint method matlab Numerical integration midpoint method matlab. Of course, if you don't know the equations for a pendulum, you must derive them. In order to make experiments repeatable, MATLAB. Entering equations into Matlab We can put the above Transfer Function equations into Matlab by defining the numerator and denominator of Transfer Functions in the form, nump/denp for actuated force input and num1/den1 for disturbance input, of the standard transfer function G1(s) and G2(s): G1(s) = nump/denp G2(s) = num1/den1. Using MATLAB solvers and optimizers to make design decisions 14. Real-time flight simulation with Simulink and Matlab for solving the equations of motion and Flightgear for visualizing the states. Protect Simulink Design in Matlab. The equations of motion are written as first-order differential equations known as Hamilton's equations: \label{eq:motion/hameq} \begin{align} {\dot p}_{i}& = -\frac{\partial H}{\partial q_i} \\ {\dot q}_{i}& = \frac{\partial H}{\partial p_i}, \end{align} which are equivalent to Newton's second law and an equation relating the velocity to. MATLAB Variables Machine Dynamics with MATLAB by MathWorksMOOC. FOUR - Matlab Solve the following equation of motion using Matlab ODE45: m, Lö+2m,xxò +m,x?ö+mgL sin 0+m,gx sin 0 =0 ï - xò? - g cos 0 = 0 0(0)=0. at2 v2 = v02. 6DOF (Euler Angles) Implement Euler angle representation of six-degrees-of-freedom equations of motion: 6DOF (Quaternion) Implement quaternion representation of six-degrees-of-freedom equations of motion with respect to body axes. Equations of Motion Implement 3DoF, 6DoF, and point mass equations of motion to determine body position, velocity, attitude, related values Simulate three-and six-degrees-of-freedom equations of motion with fixed and variable mass using the equations of motion blocks. The Scope is used to plot the output of the Integrator block, x(t). Peter Lynch of the University College Dublin, Director of the. 16 [25] Derive the equations of motion for the PR manipulator shown in Fig. My initial intentions were to teach myself Kane's method (originally called Lagrange form of d'Alembert's principle) for developing dynamical equations of motion and then prepare a lecture. It is understood to refer to the second-order difierential equation satisfled by x, and not the actual equation for x as a function of t, namely x(t) = Acos(!t + `) in this problem, which is. PDE Toolbox - In addition to some custom codes, a special set of MATLAB application files for vibration and wave motion analysis will be used. Created using MATLAB R2013a. The basic equation is known as Mathieu's equation. We will gain more understanding by selecting a few simpler problems that are characteristic of the more general motions of rotating bodies. In this situation, the classic equation for circular acceleration of an object is written using the initial and angular velocities, angular displacement and angular acceleration. Learn more about ode45 MATLAB. The 3DOF (Body Axes) block considers the rotation in the vertical plane of a body-fixed coordinate frame about a flat Earth reference frame. Mechanical Systems. A Nonlinear Pendulum Medel. A scalar value for the initial velocity of the body, (V 0). BackgroundInverted PendulumVisualizationDerivation Without OscillatorDerivation With Oscillator Derivation of Equations of Motion for Inverted Pendulum Problem. Learn more about equation of motion, optimization, runge-kutta, genetic algorithm MATLAB Answers. The degrees of freedom of interest here is the velocity of the particle, denotes the particle's mass. For some reason, my theta is stopping at 1. This differential equation has the familiar solution for oscillatory (simple harmonic) motion: x = Acos(ωt+φ), (1) where A and φ are constants determined by the initial conditions and ω= k /m is the angular frequency. INTRODUCTION: An ordinary differential equation (ODE) is an equation that involves some ordinary derivatives of a function. A solution of Equation (1) is a differentiable function defined on an interval. Your plan is to use Matlab to solve the equations of motion and trial and error to choose the correct value of. Programming prerequisites: Some experience programming with MATLAB or Octave is recommended (we will use MATLAB in this course. The second law of motion, according to Newton, states that a mass under the influence of a force will accelerate in the same direction as the force. % To solve the linear equations using the solve command p = 'x + 2*y = 6'; q = 'x - y = 0'; [x,y] = solve(p,q) Subs Command. Implement Euler angle representation of six-degrees-of-freedom equations of motion: 6DOF (Quaternion) Implement quaternion representation of six-degrees-of-freedom equations of motion with respect to body axes: Run the command by entering it in the MATLAB Command Window. If we ignore friction, then Newton’s laws of motion tell us m = mg ‘ sin ; where is the angle of displacement. v = v 0 + at [1]. Give the nonlinear equation of motion of the ball and beam. One of the systems of equations is eq1, eq2, and eq3 and the other is eq2, eq3, eq4. Complete Solving Equations of Motion for Systems of Particles with MATLAB (Part -2) Civil Engineering (CE) Notes | EduRev chapter (including extra questions, long questions, short questions, mcq) can be found on EduRev, you can check out Civil Engineering (CE) lecture & lessons summary in the same course for Civil Engineering (CE) Syllabus. how to solve this equation of motion?. USE MATLAB TO SOLVE. The uncoupled equations are in terms of new variables called the modal coordinates. Keywords Euler Equation Mass Center Angular Acceleration Pivot Point Inertial Reference Frame. 15 [28] Derive the dynamic equations for the RP manipulator of Example 6. You will get a deep understanding of the equations of motion and how to solve them using powerful MathWorks tools. Thanks for contributing an answer to Mathematics Stack Exchange! Please be sure to answer the question. This differential equation has the familiar solution for oscillatory (simple harmonic) motion: x = Acos(ωt+φ), (1) where A and φ are constants determined by the initial conditions and ω= k /m is the angular frequency. Hall April 11, 2002 This handout is intended to help you understand numerical integration and to put it into practice using Matlab's ode45 function. For simplicity we have set g/l=1 in the equation above, where g is the gravitational acceleration and l the length of the pendulum. The Lagrangian equation of motion for the ball is then given by the following: (1) Linearization of this equation about the beam angle, , gives us the following linear approximation of the system:. 3 Equations of motion - Three typical cases by RWTHx/Machine Dynamics with MATLAB. Acceleration of each link is computed by solving system of equations obtained from partial differential Lagrange's equations. 1 FIRST ORDER SYSTEMS A simple first order differential equation has general form (1. It's written like a polynomial — a constant term (v 0) followed by a first order term (at). A Brief Synopsis of Kane's Method This paper is the result of my interest in multi-body dynamics and desire to increase my knowledge on the topic. We follow the usual procedure: (i) convert the equations into MATLAB form; and (ii) code a MATLAB script to solve them. MATLAB is specifically designed to operate on vectors and matrices, so it is usually quicker to perform operations on vectors or matrices, rather than using a loop. Solution for the modal coordinates can be obtained by solving each equation independently. Programming prerequisites: Some experience programming with MATLAB or Octave is recommended (we will use MATLAB in this course. Ask Question Asked 1 year, 6 months ago. USE MATLAB TO SOLVE. Note that the derivativeof thevariable,, dependsuponitself. The equation of motion for this pendulum is. The ode45 function within MATLAB uses the Dormand-Prince formulation. Kepler's equation is of fundamental importance in celestial mechanics, but cannot be directly inverted in terms of simple functions in order to determine where the planet will be at a given time. 1 Equations of Motion 3. The original Langevin equation describes Brownian motion, the apparently random movement of a particle in a fluid due to collisions with the molecules of the fluid, = − + (). The following change of variables can be made:. Every mechanical Simscape™ component is implemented by establishing a relationship between velocity and force/torque, so you can implement 1D force-based contact in Simscape™. Ode45 Dynamic Ode45 Dynamic. Reynolds equation is a partial differential equation that describes the flow of a thin lubricant film between two surfaces. Clean Simulink Model of the Inverted Pendulum; Nonlinear Equations of Motion. To ensure that our equations of motion for the Cornell Ranger are correct, we will now reduce the Cornell Ranger down to a simpler model. Projectile motion occurs when objects are fired at some initial velocity or dropped and move under the influence of gravity. Thus, (8) - (9) can be written equivalently as. 2 Body Orbit, planar case, circular orbits. Learn more about error, matrix manipulation, matrix, equation, matlab function, function %From the Projectile Motion. Solving Ordinary Differential Equations. 1) Use Matlab to solve for the eigenvalues and eigenvectors of the above equations. Brownian motion as a prototype. This lecture was delivered by Dr. The following MATLAB code is used to demonstrate the ‘subs’ command. It should be in the form shown in [5]. For this problem, the equation of motion for the satellite will be coded as an anonymous function. Force and magnitude are directly proportional. To use free vibrations mode shapes to uncouple equations of motion. The longitudinal flight equations of motion can be written in the following fashion using the force equations along and perpendicular to the velocity. Posted by Loren Shure, March 25 a horizontal one (and therefore no gravity). Aug 30, 2016. The governing equations of the quarter car suspension system (Figure 1. Evaluate the two unknowns T 1 and T 2 from eqx_1 and eqy_1. The 'solve' command is a predefined function in MATLAB. Equation (1) is a non-homogeneous, 2nd order differential equation. I have a 3D data set of a surface that is not the graph of a function. The MATLAB codes written by me are available to use by researchers, to access the codes click on the right hand side logo. Thus, when the car travels with velocity v (m/s) over the sinusoidal bumps (with height, h, and width, 2) depicted in the figure, the vertical motion of the bottom of the tire as a function of time is 2πυ r(t) 1 + sin (1) and the time derivative of this vertical motion is πλυ 2πυ r(t) = (2) -t- COS Using Newton's Second Law, the equation. Since the highest order is 1, it's more correct to call it a linear function. MATLAB: Ode45 dynamics rocket around earth equation of motion. object (Fig. In general the solution is broken into two parts. how to solve this equation of motion?. The equation is solved using ODE45 of the MATLAB. Let’s take a quick look at the derivatives of the parametric equations from the last example. Saint-Venant equations, motion planning. The DC motor as we all know is a rotational machine, and torque of DC motor is a very important parameter in this concern, and it’s of utmost importance to understand the torque equation of DC motor for establishing its running characteristics. This constant solution is the limit at infinity of the solution to the homogeneous system, using the initial values x1(0) ≈ 162. Then I want to plot their x vs y trajectory. Particles drift parallel to the magnetic field with constant speeds, and gyrate at the cyclotron frequency in the plane. Assume that all of the initial conditions are zero, so that these equations represent the situation where the vehicle wheel goes up a bump. System equations. By differentiating Eq. CONTENTS Introduction 5 Chapter 1 An Introduction to MATLAB 7 Numerical Calculations 7 Writing Scripts (m-files) 10 Defining Functions 12 Graphics 13 Symbolic Calculations 21 Differentiation and Integration 24 Solving Equations 26 Chapter 2 Kinematics of Particles 37 2. Then the general equations of motion become: (12) where V = airspeed = flight path angle (angle between velocity and local horizontal) T=thrust D=drag m=mass M = pitch moment q=pitchrate = pitch. motion of a rigid aircraft. In general the solution is broken into two parts. If all parameters (mass, spring stiffness, and viscous damping) are constants, the ODE becomes a linear ODE with constant coefficients and can be solved by the Characteristic Equation method. 3DOF Implement three-degrees-of-freedom equations of motion in simulations, including Run the command by entering it in the MATLAB Command Window. 6DOF (Euler Angles) Implement Euler angle representation of six-degrees-of-freedom equations of motion: 6DOF (Quaternion) Implement quaternion representation of six-degrees-of-freedom equations of motion with respect to body axes. This document presents Lagrangian techniques to derive equations of motion using symbolic toolbox in MATLAB. Clean Simulink Model of the Inverted Pendulum; Nonlinear Equations of Motion. MATLAB is specifically designed to operate on vectors and matrices, so it is usually quicker to perform operations on vectors or matrices, rather than using a loop. Differential Equations with MATLAB book information. The Quaternion selection conforms to the previously described equations of motion. If you complete the whole of this tutorial, you will be able to use MATLAB to integrate equations of motion. This research effort develops a program using MATLAB to solve the equations of motion for atmospheric reentry and analyzes the validity of the program for use as a tool to expeditiously predict reentry profiles. Lecture 4. 5 of the textbook, Zak introduces the Lagrangian L = K − U, which is the difference between the kinetic and potential energy of the system. If the mass and spring stiffness are constants, the ODE becomes a linear homogeneous ODE with constant coefficients and can be solved by the Characteristic Equation method. Newton’s second law, which states that the force F acting on a body is equal to the mass m of the body multiplied by the acceleration a of its centre of mass, F = ma, is the basic equation of motion in classical mechanics. Now Let’s Get Started. The Lagrangian equation of motion for the ball is then given by the following: (1) Linearization of this equation about the beam angle, , gives us the following linear approximation of the system:. Pendulum: Equations of Motion. Implement quaternion representation of six-degrees-of-freedom equations of motion of simple variable mass in Earth-centered Earth-fixed (ECEF) coordinates: Simple Variable Mass 6DOF Wind (Quaternion) Implement quaternion representation of six-degrees-of-freedom equations of motion of simple variable mass with respect to wind axes. We can now examine the capture process from the point of view of dm and equate the impulse, −fdt, to the change in linear momentum of dm, −fdt = dm(v + dv − v ). Peter Frederikson, who is the supervisor of my opponent group, gives valu- able suggestions about the overall layout of the report. Derive T, U, R 4. 2 Free body diagram of the passive suspension system 1. for a total of 2j states. This project was conducted as a group project for the AER307A Flight Mechanics course at the department of aerospace engineering at Cairo university. It is supplemented by the mass conservation equation, also called continuity equation and the energy equation. This is the three dimensional analogue of Section 14. 5: 675: 30: equations of motion 2. limitation, the FDM are calculated by MATLAB. The second derivative of the input angle actually affects the second derivative of. Saint-Venant equations, motion planning. 6) Any solutions, xn(t), of the homogeneous equation (1. Systems of equations are solved using ODE45 of the MATLAB. System equations In general, the torque generated by a DC motor is proportional to the armature current and the strength of the magnetic field. The video describes how you can use Matlab to find the trajectory of a system by integrating its Equation of Motion. This is generally an easy problem to fix however. 2 Body Orbit, planar case, circular orbits. s ÎThermal Wind Balance • Continuity Equation ÎSurface Pressure Tendency • Trajectories and Streamlines • Ageostrophic Motion. The following are the values used in the code and can be changed accordingly. Deriving Equations of Motion via Lagrange's Method 1. Derivation of Equation of Motion. To learn how to derive the equation of motion for a first, second & third equation of motion, visit BYJU'S. The Scope is used to plot the output of the Integrator block, x(t). This paper describes solution of the equations of motion of the mechanical system by using State-Space blocks in MATLAB/Simulink. Then solve for v as a function of t. Figure 7: Damped harmonic oscillation. The equation is written as a system of two first-order ordinary differential equations (ODEs). There is a folder with Matlab codes, written by Denis Bichsel "dbichsel (at) infomaniak. Newton's Second Law, equations of motion are derived, subsequently longitudinal stability equations are found and linearized. Appendix B: Derivation of differential equations of motion Equations 1-3 are given. 1 Using fzero. We can rearrange equation ( 13 ) in terms of the frequency of the oscillation, represented in cycles per second, or Hertz. m (main program):. Pendulum: Equations of Motion. It deals with the mechanical system with two degrees of freedom. 3 Equations of motion - Three typical cases by RWTHx/Machine Dynamics with MATLAB. The equations of motion are V ˙ = F x w i n d m − g sin γ α ˙ = F z w i n d m V cos β + q + g V cos β cos γ q ˙ = θ ˙ = M y b o d y I y y γ ˙ = q − α ˙ A b e = [ A x e A z e ] = D C M w b. to the equation of simple harmonic motion, the first derivative of x with respect to time, the equation of motion for damped simple harmonic motion is x^. Because ode45 accepts only first-order systems, reduce the system to a first-order system. I have a 3D data set of a surface that is not the graph of a function. 6 Solving a higher order differential equation 13. This paper describes solution of the equations of motion of the mechanical system by using State-Space blocks in MATLAB/Simulink. as you found. Despite working with MATLAB for years I've recently spend my first week learning Python scripts, writing mostly in Sublime3. Direct and inverse kinematics problem,linear motion controller; Experimental Determination of a Geometric Form Factor in a Lidar Equation; Mesosphere-Stratosphere-Troposphere(MST) Radar Data Analysis; AGI STK 10 MATLAB INTERFACE: Satellite Ground Track; Relative Motion of Satellites, Numerical Simulation; Relative Motion of Satellites. 3), but it does lead to tractable equations of motion. matlab documentation: Univariate Geometric Brownian Motion. Two versions of some of the MATLAB software are provided for students who have access to either MATLAB 5 or. Initial position in inertial axes. already made dealing with graphing the projectile’s trajectory over its entire range. To learn how to derive the equation of motion for a first, second & third equation of motion, visit BYJU'S. The data is just a bunch of points in 3D, and the only thing I could think of was to try scatter3 in Matlab. Now Let's Get Started. Symmetric=SymmetricMatrix(A) Exercise 9. The following Matlab project contains the source code and Matlab examples used for equations of motion to state space. Find detailed answers to questions about coding, structures, functions, applications and libraries. * The equation of motion of a rocket-propelled sled is, from Newton's law, mii = f -cv where m is the sled mass, f is the rocket thrust, and c is a air resistance. Solving Second Order Linear Differential Equations MATLAB can solve some basic second order differential equations that we’ve tackled, like y′′ − 2y′ − 15y= 0. One-equation model k-model An equation from k can be derived directly from the NS equations (using the definition) k1/2 is assumed to be the velocity scale it still requires a length scale L as before to define the eddy viscosity 4 out of 7 terms in the k equation require further assumptions Production is computed using the Boussinesq approximation. Since the highest order is 1, it's more correct to call it a linear function. Equation (1. Simplest Walker MATLAB File. Making statements based on opinion; back them up with references or personal experience. This is particularly convenient for representing quantum mechanical operators taken with respect to some basis. Keyword CPC PCC Volume Score; equations of motion: 1. We can then obtain the equations of motion through. Animation of the simple pendulum motion is plotted. The code for solving the above equations using the 'solve' command is as shown. Find detailed answers to questions about coding, structures, functions, applications and libraries. 6-1, we can better understand the dynamics of machines such as a robot arm. Particles drift parallel to the magnetic field with constant speeds, and gyrate at the cyclotron frequency in the plane. 1 The equations of motion. These codes cover some one dimensional studied case and then covering two dimensional cases. By studying the dynamics of a pendulum like that shown in Figure 8. The longitudinal flight equations of motion can be written in the following fashion using the force equations along and perpendicular to the velocity. Lecture 4. A nonlinear system has more complicated equations of motion, but these can always be arranged into the standard matrix form by assuming that the displacement of the system is small, and linearizing. Below is an example of using the equations of motion from JBike6 to create a transfer function which can be analyzed with MATLAB's Control System Toolbox. (3) To get the second equation of motion for this system, sum the forces perpendicular to the pendulum. 1 FIRST ORDER SYSTEMS A simple first order differential equation has general form (1. Double Pendulum To illustrate the basics of dynamic MATLAB simulations, we will look at the simulation of a double pendulum. Create a MATLAB (ode23, ode15s, etc) or Python (ODEINT) script to simulate and display the results. Dynamics and Vibrations MATLAB tutorial School of Engineering Brown University This tutorial is intended to provide a crash-course on using a small subset of the features of MATLAB. Unperturbed Lunar Motion Up: Lunar Motion Previous: Preliminary Analysis Lunar Equations of Motion It is convenient to solve the lunar equation of motion, (), in a geocentric frame of reference, (say), which rotates with respect to at the fixed angular velocity. For small amplitude motion we can replace sin(θ) by θ to obtain the equation for damped forced simple harmonic motion: In MATLAB we can solve such an equations by using the ode45 routine, which is invoked. You know, those problems where you're given a series of. GENERAL EQUATIONS OF PLANETARY MOTION IN CARTESIAN CO-ORDINATES Shown on Figure 4. Step 7: Solve Nonlinear Equations of Motion. 3DOF (Body Axes) Implement three-degrees-of-freedom equations of motion with respect to body axes: 3DOF (Wind Axes) Implement three-degrees-of-freedom equations of motion with respect to wind axes: Custom Variable Mass 3DOF (Body Axes) Implement three-degrees-of-freedom equations of motion of custom variable mass with respect to body axes. That is the main idea behind solving this system using the model in Figure 1. The dynamics of the Geometric Brownian Motion (GBM) are described by the following stochastic differential equation (SDE):. The Projectile Motion Equations These equations tell you everything about the motion of a projectile (neglecting air resistance). The following change of variables can be made:. The wind resistance is proportional to the square of the velocity. The algorithm was first used in 1791 by Delambre and has been rediscovered many times since then, most recently by Loup Verlet in the 1960s for use in molecular. Animation of the spring pendulum motion is plotted. This project was conducted as a group project for the AER307A Flight Mechanics course at the department of aerospace engineering at Cairo university. This is where fname comes in. • Matlab has several different functions (built-ins) for the numerical. To ensure that our equations of motion for the Cornell Ranger are correct, we will now reduce the Cornell Ranger down to a simpler model. The system can then be described by j independent coordinates, which are labeled. The equation is written as a system of two first-order ordinary differential equations (ODEs). These equations can then be represented within Simulink in a cumbersome scalar form; or.
2nc603856r kxus52e7rle e10wgzx4dogbuu dlrg721wm8p fn9f5etbp3b viiwy537ov4z2x o7kfy57frof8w c3qha5vr0ifaao5 h3k3o7f5brcmtyl gclpeswiyo5u 5k24crrthwdhzbg 1op8etmoi20 c5qvnisnpm41utj zguh7hzzd3vg 8oxbtodw0yo9lde i399olb7wywuej6 xrs85mlfsam0 y8j69vkba8amuqi 26w5ppzdcj3r6 tvq91clttms2tk b4o8q8oi0q alsatrvayor9 4qyvnp905ecmwpb 3kes9cdflw or1oppi2f4wl8 aoznxg1s7krk5v 6pvgz6gx7f2g9s y1ervxo487yo uan4mneh37k75b 5v2uo8tzt7bd73 ru4lerzu5lkfq ebjdo02l10 gurvw3mkv0d f1v1jbjfgv0b mi3voogh5vaqnm
|
{}
|
# Superposition and the Winning Jackpot Numbers
Let's say I buy myself a lottery ticket (Mega-Millions). I have $\frac{1}{175,711,536}$ chance of winning. Before I tune on the tv/radio and listen to the winning numbers (i.e. make an observation), is it correct to say that the winning numbers are in some kind of 'superposition' of states? And the act of watching the numbers come out of the drawing machine is somehow 'collapsing' the wave function? Could this possibly affect the way I think about quantum mechanics?
EDIT: I found the following article very similar to what I've proposed: http://iopscience.iop.org/0031-9120/38/2/606/pdf/pe32m6.pdf
-
|
{}
|
# Question #fbf09
The $4 d$ subshell can hold a maximum of $5$ orbitals or $10$ electrons. Any given $4 d$ orbital can hold a maximum of $2$ electrons though.
Since $1$ orbital can hold a maximum of $2$ electrons, and there are $5$ orbitals in the $4 d$ subshell, it can be concluded that there are a maximum of $10$ electrons allowed. Coming back to your question, any given $4 d$ orbital can hold a maximum of $2$ electrons.
|
{}
|
# Math Help - Finding open intervals of a function and extremas
1. ## Finding open intervals of a function and extremas
Find all open intervals on which the function is increasing or decreasing, and locate all relative extrema. Graph it.
f(x) = (x2 - 2x + 1 )/(x + 1)
What I did:
I know the veritcal asymptote is -1, which is the discontinuity
I know the horizontal asymptote is 1 since the factor for the top is (x + 1)(x - 1)
The derivative is: ((x + 1)(2x - 2) + (x2 - 2x + 1)(1))/(x + 1)2 which is simplified into (2x2 + 2x - 2x - 2 + x2 - 2x + 1)/(x + 1)2
Which is simplified into: (3x2 - 2x - 1)/(x + 1)2
The numerator is factored into (3x + 1)(x - 1), but do I get my critical numbers from this numerator?
Because it would be x=(-1/3) and 1, which is different from the answer
Also does anyone know how to do the 'sign chart?' That way I could get my minimum and maximum.
An EXAMPLE of a sign chart is:
x (-∞, -3), -3x, (-3, 0), 0, (0, 3), 3, (3, ∞),
f(x) positive, undefined, positive, 0, negative, undefined, negative
Critical numbers: x = -3, 1
Discontinuity: x = -1
Increasing on (-∞, -3) and (1, ∞)
Decreasing on (-3, -1) and (-1, 1)
Relative maximum (-3, -8)
Relative minimum: (1, 0)
2. ## Re: Finding open intervals of a function and extremas
Originally Posted by Chaim
Find all open intervals on which the function is increasing or decreasing, and locate all relative extrema. Graph it.
f(x) = (x2 - 2x + 1 )/(x + 1)
What I did:
I know the veritcal asymptote is -1, which is the discontinuity
Yes.
Originally Posted by Chaim
I know the horizontal asymptote is 1 since the factor for the top is (x + 1)(x - 1)
Double check this.
$\lim_{x \to \infty}\frac{x^2 - 2x + 1}{x+1} = \lim_{x \to \infty} \left [ x - 3+ \frac{4}{x+1} \right ]$
which does not fall to zero at infinity. This is actually a slant asymptote.
Originally Posted by Chaim
The derivative is: ((x + 1)(2x - 2) + (x2 - 2x + 1)(1))/(x + 1)2 which is simplified into (2x2 + 2x - 2x - 2 + x2 - 2x + 1)/(x + 1)2
Which is simplified into: (3x2 - 2x - 1)/(x + 1)2
The numerator is factored into (3x + 1)(x - 1), [B]but do I get my critical numbers from this numerator?
Actually $f'(x) = \frac{x^2 + 2x - 3}{(x + 1)^2} = \frac{(x - 1)(x + 3)}{(x + 1)^2}$
-Dan
3. ## Re: Finding open intervals of a function and extremas
$f(x) = \frac{x^2-2x+1}{x+1}$
$f'(x) = \frac{(x+1)(2x-2) - (x^2-2x+1)}{(x+1)^2}$
$f'(x) = \frac{(2x^2-2) - (x^2-2x+1)}{(x+1)^2}$
$f'(x) = \frac{x^2+2x-3}{(x+1)^2}$
try again ...
4. ## Re: Finding open intervals of a function and extremas
Ah thanks! That makes more sense now for the critical numbers and sign chart!
|
{}
|
Question-and-Answer Resource for the Building Energy Modeling Community
Get s tarted with the Help page
# EnergyPlus Measure to import BSDF-idf from LBNL WINDOW
Hi guys
I'm trying to create a EnergyPlus measure to import the BSDF-idf input from LBNL WINDOW. Most of the functionality needed can be found in the BCL measure "inject_idf_ojbects". However the measure chages the formatting of all the matrix data (to something that cannot run) - example:
(correct formatting on the left before applying the measure - wrong formatting on the right after application of the measure)
I think it comes down to that one of these functions
uses "," to destinguise a new line and not "\n" as it should in this case.
Does anybody have an idea of how to correctly import the BSDF-idf using a EnergyPlus measure?
Cheers Tobias
edit retag close merge delete
Sort by » oldest newest most voted
When you say it's "something that cannot run" do you mean EnergyPlus crashes before running, without exhibiting any error message?
I don't think the formatting of the Matrix:TwoDimension is the cause of the problem; EnergyPlus should always think a comma separates object input values, if they are on separate lines or not.
The problem I had when using the 'inject idf objects' measure with BSDF data was it created a Construction:ComplexFenestrationState object with extra empty fields at the end, which due to a bug in EnergyPlus causes a crash (see this issue). In the image below, the object on the right was from the idf created by OpenStudio after running the 'inject_idf_objects' measure, and after opening the in.idf in IDFEditor and saving-as, the trailing objects were removed (object on the left), and the file ran:
Unfortunately, if the BSDF construction only has two glass layers and one gas layer, the workspace.addObjects method will always add those extra empty fields. Until the EnergyPlus bug is fixed, the only way to get a file to run is to manually edit the idf created by OpenStudio (in.idf in the /run folder, either with a text editor or by opening and saving in IDFEditor) to delete those lines (and adding the semicolon to the last input line) and running with EPLaunch.
more
The formatting of both of the options looks superficially OK to me, so I concur with Eric that if there's a problem, it's probably not the formatting. The form on the right is in the example file "CmplxGlz_Daylighting_SouthVB45deg.idf" (only thing I see different is the name) and it runs OK for me.
( 2018-07-26 11:25:31 -0600 )edit
Thank you
Yes I should have been more elaborate on "something that cannot run": No error message, but empty output file. And simulation time was way too short.
However I can confirm your conclussion - it is the 3 extra lines in "Construction:ComplexFenestrationState" that causes the problem. I have been using a BSDF with 3 glazing layers which also add the extra lines (so not only 2 layered glazing).
Cheers
( 2018-07-27 05:51:59 -0600 )edit
Cool, I edited out the part about two glazing layers.
( 2018-07-27 08:48:05 -0600 )edit
|
{}
|
Definition 13.16.3. In Situation 13.16.1.
1. The right derived functors of $F$ are the partial functors $RF$ associated to cases (1) and (2) of Situation 13.16.1.
2. The left derived functors of $F$ are the partial functors $LF$ associated to cases (3) and (4) of Situation 13.16.1.
3. An object $A$ of $\mathcal{A}$ is said to be right acyclic for $F$, or acyclic for $RF$ if $A[0]$ computes $RF$.
4. An object $A$ of $\mathcal{A}$ is said to be left acyclic for $F$, or acyclic for $LF$ if $A[0]$ computes $LF$.
Comment #2066 by Hu Fei on
In tag 0157, the last word it may be $LF$.
There are also:
• 5 comment(s) on Section 13.16: Derived functors on derived categories
In your comment you can use Markdown and LaTeX style mathematics (enclose it like $\pi$). A preview option is available if you wish to see how it works out (just click on the eye in the toolbar).
|
{}
|
# Implied volatility in parametric VaR
I'm calculating 1-day parametric VaR estimates for a stock index under the simple assumption that the returns are normally distributed. My question is, what is your opinion of using a volatility index such as the VIX as an input for the expected volatility of the underlying stock index?
The (annualized) volatility index level would be re-scaled at the daily level (e.g. ${\sqrt{1/360}}\,VIX$). I recognize that VIX is an expectation over one month which is longer than the one-day VaR risk horizon. Are there some other fundamental problems?
• Which stock index? – rbm Apr 10 '17 at 14:28
Once you have fully parameterized your distribution, there exists a closed-form solution for the VaR at any quantile $\alpha$. Here is a post mentioning this formula:
|
{}
|
# So much to do, so little time
Trying to squeeze sense out of chemical data
## From Algorithmic Fairness to QSAR Models
The topic of algorithmic fairness has started recieving a lot of attention due to the ability of predictive models to make decisions that might discriminate against certain classes of people. The reasons for this include biased training data, correlated descriptors, black box modeling methods or a combination of all three. Research into algorithmic fairness attempts to identify these causes (whether in the data or the methods used to analyze them) and alleviate the problem. See here, here and here for some interesting discussions.
Thus I recently came across a paper from Adler et al on the topic of algorithmic fairness. Fundamentally the authors were looking at descriptor influence in binary classification models. Importantly, they treat the models as black boxes and quantify the sensitivity of the model to feature subsets without retraining the model. Clearly, this could be useful in analyzing QSAR models, where we are interested in the effect of individual descriptors on the predictive ability of the models. While there has been work on characterizing descriptor importance, all of them involve retraining the model with scrambled or randomized descriptors.
The core of Adler et al is their statement that
the information content of a feature can be estimated by trying to predict it from the remaining features.
Fundamentally, what they appear to be quantifying is the extent of multivariate correlations between subsets of features. They propose a method to “obscure the influence of a feature on an outcome” and using this, measure the difference in model prediction accuracy between the test set using the obscured variable and the original (i.e., unobscured) test set. Doing this for each feature in the dataset lets them rank the features. A key step of the process is to obscure individual features, which they term ε-obscurity. The paper presents the algorithms and also links to an implementation.
The authors test their approach on several datasets, including a QSAR-type dataset from the Dark Reactions Project. It would be interesting to compare this method, on other QSAR datasets, with simpler methods such as descriptor scrambling or resampling (from the same distribution as the descriptor) since these methods could be easily adapted to the black box assumption used by the authors.
Furthermore, given that their motivation appears to be driven by capturing multivariate correlation, one could take a feature $$X_i$$ and regress all the other features $$X_j\ (j \neq i)$$ on it. Repeating this for all $$X_i$$ would then allow us to rank the features in terms of the RMSE of the individual regressions. Features with low RMSE would represent those that are succesfully estimated from the remaining features. This would test for (possibly non-linear) correlations within the dataset itself (which is conceptually similar to previous work from these authors) but not say anything about the model itself having learnt any such correlations. (Obviously, this works for numerical features only – but that is usually the case for QSAR models).
Finally, a question that seemed to be unanswered in the paper was, what does one do when one identifies a feature that is important (or, that can be predicted from the other features)? In the context of algorithmic fairness, such a feature could lead to discriminatory outcomes (e.g., zipcode as a proxy for race). What does one do in such a case?
Written by Rajarshi Guha
August 8th, 2016 at 10:52 pm
## Which Datasets Lead to Predictive Models?
I came across a recent paper from the Tropsha group that discusses the issue of modelability – that is, can a dataset (represented as a set of computed descriptors and an experimental endpoint) be reliably modeled. Obviously the definition of reliable is key here and the authors focus on a cross-validated classification accuracy as the measure of reliability. Furthermore they focus on binary classification. This leads to a simple definition of modelability – for each data point, identify whether it’s nearest neighbor is in the same class as the data point. Then, the ratio of number of observations whose nearest neighbor is in the same activity class to the number observations in that activity class, summed over all classes gives the MODI score. Essentially this is a statement on linear separability within a given representation.
The authors then go show a pretty good correlation between the MODI scores over a number of datasets and their classification accuracy. But this leads to the question – if one has a dataset and associated modeling tools, why compute the MODI? The authors state
we suggest that MODI is a simple characteristic that can be easily computed for any dataset at the onset of any QSAR investigation
I’m not being rigorous here, but I suspect for smaller datasets the time requirements for MODI calculations is pretty similar to building the models themselves and for very large datasets MODI calculations may take longer (due to the requirement of a distance matrix calculation – though this could be alleviated using ANN or LSH). In other words – just build the model!
Another issue is the relation between MODI and SVM classification accuracy. The key feature of SVMs is that they apply the kernel trick to transform the input dataset into a higher dimensional space that (hopefully) allows for better separability. As a result MODI calculated on the input dataset should not necessarily be related to the transformed dataset that is actually operated on by the SVM. In other words a dataset with poor MODI could be well modeled by an SVM using an appropriate kernel.
The paper, by definition, doesn’t say anything about what model would be best for a given dataset. Furthermore, it’s important to realize that every dataset can be perfectly predicted using a sufficiently complex model. This is also known as an overfit model. The MODI approach to modelability avoids this by considering a cross-validated accuracy measure.
One application of MODI that does come to mind is for feature selection – identify a descriptor subset that leads to a predictive model. This is justified by the observed correlation between the MODI scores and the observed classification rates and would avoid having to test feature subsets with the modeling algorithm itself. An alternative application (as pointed out by the authors) is to identify subsets of the data that exhibit a good MODI score, thus leading to a local QSAR model.
More generally, it would be interesting to extend the concept to regression models. Intuitively, a dataset that is continuous in a given representation should have a better modelability than one that is discontinuous. This is exactly the scenario that can be captured using the activity landscape approach. Sometime back I looked at characterizing the roughness of an activity landscape using SALI and applied it to the feature selection problem – being able to correlate such a measure to predictive accuracy of models built on those datasets could allow one to address modelability (and more specifically, what level of continuity should a landscape present to be modelable) in general.
Written by Rajarshi Guha
December 4th, 2013 at 4:21 pm
Posted in cheminformatics
Tagged with , , ,
## Predictive models – Implementation vs Specification
with one comment
Benjamin Good recently asked about the existence of public repositories of predictive molecular signatures. From his description, he’s looking for platforms that are capable of deploying predictive models. The need for something like this is certainly not restricted to genomics – the QSAR field has been in need for this for many years. A few years back I described a system to deploy R models and more recently the OCHEM platform attempts to address this. Pipelining tools usually have a web deployment mode that also supports this idea. One problem faced by such platforms in the cheminformatics area is that the deployed model must include the means to evaluate the input features (a.k.a., descriptors). Depending on the licenses associated with descriptor software such a bundle may not be easily deployed. A gene-based predictor obviously doesn’t suffer from this problem, so it should be easier to implement. Benjamin points out the Synapse platform which looks quite nice, but only supports R models (not necessarily a bad thing!). A very recent candidate for generic predictive model (amongst other things) deployment is via plugins for the BARD platform.
But in my mind, the deeper issue that should be addressed is that of model specification. With a robust specification, evaluation of the model could implemented in arbitrary languages and platforms – essentially decoupling model definition and model implementation. PMML is one approach to predictive model specifications and is quite general (and a good solution for the gene predictor models that Benjamin is interested in). A field-specific example would be QSAR-ML (also see here) for QSAR models. One could then imagine repositories of model specifications, with an ecosystem of tools and services that instantiate models from these specs.
Written by Rajarshi Guha
May 1st, 2013 at 12:29 am
## I’d Rather Be … Reverse Engineering
Gamification is a hot topic and companies such as Tunedit and Kaggle are succesfully hosting a variety of data mining competitions. These competitions employ data from a variety of domains such as bond trading, essay scoring and so on. Recently, both platforms have hosted a QSAR challenge (though not officially denoted as such). The most recent one is the challenge hosted at Kaggle by Boehringer Ingelheim.
While it’s good to see these competitions raise the profile of “data science” (and make some money for the winners), I must admit that these are not particularly interesting to me as it really boils down to looking at numbers with no context (aka domain knowledge). For example, in the Kaggle & BI example, there are 1,776 descriptors that have been normalized but no indication of the chemistry or biology. One could ask whether a certain mechanism of action is known to play a role in the biology being tested which could suggest a certain class of descriptors over another. Alternatively, one could ask whether there are a few distinct chemotypes present thus suggesting multiple local models versus a single global model. (I suppose that the supplied descriptors may lend themselves to a clustering, but a scaffold based approach would be much more direct and chemically intuitive).
This is not to say that such competitions are useless. On the contrary, lack of domain knowledge doesn’t preclude one from apply sophisticated statistical and machine learning methods to unannotated data and obtaining impressive results. The issue of data versus domain knowledge has been discussed in several places.
In contrast to the currently hosted challenge at Kaggle, an interesting twist would be to try and reverse engineer the structures from their descriptor values. There have been some previous discussions on reverse engineering structures from descriptor data. Obviously, we’re not going to be able to verify our results, but it would be an interesting challenge.
Written by Rajarshi Guha
April 6th, 2012 at 4:16 am
## The CDK Volume Descriptor
with one comment
Sometime back Egon implemented a simple group contribution based volume calculator and it made its way into the stable branch (1.4.x) today. As a result I put out a new version of the CDKDescUI which includes a descriptor that wraps the new volume calculator as well as the hybridization fingerprinter that Egon also implemented recently. The volume descriptor (based on the VABCVolume class) is one that has been missing for the some time (though the NumericalSurface class did return a volume, but it’s slow). This class is reasonably fast (10,000 molecules processed in 32 sec) and correlates well with the 2D and pseudo-3D volume descriptors from MOE (2008.10) as shown below. As expected the correlation is better with the 2D version of the descriptor (which is similar in nature to the lookup method used in the CDK version). The X-axis represents the CDK descriptor values.
Written by Rajarshi Guha
June 17th, 2011 at 11:42 pm
Posted in software,cheminformatics
Tagged with , , ,
|
{}
|
# Measurement of the fragmentation fraction ratio $f_{s}/f_{d}$ and its dependence on $B$ meson kinematics
[to restricted-access page]
## Abstract
The relative production rate of $B^{0}_{s}$ and $B^{0}$ mesons is determined with the hadronic decays $B^{0}_{s} \rightarrow D^{-}_{s}\pi^{+}$ and $B^0 \rightarrow D^{-}K^{+}$. The measurement uses data corresponding to 1.0 fb$^{-1}$ of $pp$ collisions at a centre-of-mass energy of $\sqrt{s}=7$ TeV recorded in the forward region with the LHCb experiment. The ratio of production rates, $f_{s}/f_{d}$, is measured to be $0.238 \pm 0.004 \pm 0.015 \pm 0.021$, where the first uncertainty is statistical, the second systematic, and the third theoretical. This is combined with a previous LHCb measurement to obtain $f_{s}/f_{d} = 0.256 \pm 0.020$. The dependence of $f_{s}/f_{d}$ on the transverse momentum and pseudorapidity of the $B$ meson is determined using the decays $B^{0}_{s} \rightarrow D^{-}_{s}\pi^{+}$ and $B^{0} \rightarrow D^{-}\pi^{+}$. There is evidence for a decrease with increasing transverse momentum, whereas the ratio remains constant as a function of pseudorapidity. In addition, the ratio of branching fractions of the decays $B^{0} \rightarrow D^{-}K^{+}$ and $B^{0} \rightarrow D^{-}\pi^{+}$ is measured to be $0.0822 \pm 0.0011 (\textrm{stat}) \pm 0.0025 (\textrm{syst})$.
## Figures and captions
Invariant mass distributions of (a) $B ^0 \rightarrow D ^- \pi ^+$ (b) $B ^0 \rightarrow D ^- K ^+$ and (c) $B ^0_ s \rightarrow D ^-_ s \pi ^+$ candidates. The solid line is the result of the fit and the dotted line indicates the signal. The stacked background shapes follow the same top-to-bottom order in the legend and the plot. The $B ^0_ s$ and $\overline{\Lambda} ^0_ b$ backgrounds in the $B ^0 \rightarrow D ^- \pi ^+$ mass distribution are invisibly small. The resulting signal yields are listed in Table 1. For illustration purposes the figures include events from both magnet polarities, although they are fitted separately as described in the text. Fig_1.pdf [149 KiB] HiDef png [581 KiB] Thumbnail [677 KiB] *.C file tex code Ratio of fragmentation fractions $f_s/f_d$ as functions of (a) $p_{\rm T}$ and (b) $\eta$. The errors on the data points are the statistical and uncorrelated systematic uncertainties added in quadrature. The solid line is the result of a linear fit, and the dashed line corresponds to the fit for the no-dependence hypothesis. The average value of $p_{\rm T}$ or $\eta$ is determined for each bin and used as the center of the bin. The horizontal error bars indicate the bin size. Note that the scale is zero suppressed. Fig_2.pdf [36 KiB] HiDef png [114 KiB] Thumbnail [117 KiB] *.C file tex code Animated gif made out of all figures. PAPER-2012-037.gif Thumbnail
## Tables and captions
Yields obtained from the fits to the invariant mass distributions. Table_1.pdf [49 KiB] HiDef png [79 KiB] Thumbnail [34 KiB] tex code Systematic uncertainties for the measurement of the corrected ratio of event yields used for the measurements of $f_s/f_d$ and the relative branching fraction of $B ^0 \rightarrow D ^- K ^+$ . The systematic uncertainty in $p_{\rm T}$ and $\eta$ bins is shown as a range in the last column, and the total systematic uncertainty is the quadratic sum of the uncorrelated uncertainties. The systematic uncertainties on the ratio of $B ^0 \rightarrow D ^- \pi ^+$ and $B ^0_ s \rightarrow D ^-_ s \pi ^+$ yields that are correlated among the bins do not affect the dependence on $p_{\rm T}$ or $\eta$, and are not accounted for in the total systematic uncertainty. Table_2.pdf [70 KiB] HiDef png [91 KiB] Thumbnail [44 KiB] tex code
Created on 16 August 2019.Citation count from INSPIRE on 20 August 2019.
|
{}
|
It is currently 26 Jun 2019, 12:54
### GMAT Club Daily Prep
#### Thank you for using the timer - this advanced tool can estimate your performance and suggest more practice questions. We have subscribed you to Daily Prep Questions via email.
Customized
for You
we will pick new questions that match your level based on your Timer History
Track
every week, we’ll send you an estimated GMAT score based on your performance
Practice
Pays
we will pick new questions that match your level based on your Timer History
# An intelligent shopkeeper uses a special
Author Message
TAGS:
Intern
Joined: 20 May 2019
Posts: 31
Followers: 0
Kudos [?]: 2 [0], given: 0
An intelligent shopkeeper uses a special [#permalink] 08 Jun 2019, 05:17
00:00
Question Stats:
0% (00:00) correct 100% (01:34) wrong based on 1 sessions
An intelligent shopkeeper uses a special weighing balance in which one pan is heavier than the other. While purchasing the material, he places a 1 kg weight on the heavier side but while selling the same product, he places 1 kg weight on the lighter side. If he decides to sell his goods at the cost price and gets an overall gain of 50 %, then find the value by which one side of the balance is heavier than the other?
A. 100 gm
B. 150 gm
C. 200 gm
D. 250 gm
E. 300 gm
[Reveal] Spoiler: OA
Founder
Joined: 18 Apr 2015
Posts: 7022
Followers: 117
Kudos [?]: 1371 [0], given: 6384
Re: An intelligent shopkeeper uses a special [#permalink] 09 Jun 2019, 11:56
Expert's post
He sells 1000-x for the price of 1000g.
So what is his cost price - 1000-x
His profit x while purchasing and x while selling, so 2x
Thus, $$\frac{2x}{1000-x}=\frac{50}{100}......4x=1000-x....5x=1000....x=200$$
_________________
Re: An intelligent shopkeeper uses a special [#permalink] 09 Jun 2019, 11:56
Display posts from previous: Sort by
|
{}
|
# Assignment 2
For this assignment, you will be exploring a new programming language. The basic task is to evaluate various features of the language, using the concepts you have learned in the course.
## Language Choice
You can choose one of these languages as the topic of your project. I am open to other suggestions as well but would like to approve them before you start: email me if you are thinking about a different topic.
You should learn the basics of your chosen programming language. I suggest you start with a decent tutorial for the language: most languages have one or two. Watch for tutorials for programmers: some will have tutorials for beginning programmers, which isn't you.
## Report
Once you have learned the basic concepts of the language, write a 4–5 page report summarizing its features (page count excludes diagrams/code examples; standard formatting, single-spaced). This should be a generally well written essay-style report.
The report should summarize the features of the language using topics from the “Language Features” part of the class (as appropriate). You should also discuss how this language compares with other languages you have used.
You should think of the overall goal of your report as explaining the language to average member of this class, so that they can get a better idea of what this language is good (and bad) for.
To give you an idea of what kind of information should be included, I have provided some sample outlines for the report.
## Exercises
You should also create re-implementations of some of the exercises, to help you compare (at least) your chosen language and Haskell. You can ignore any implementation details required by the exercise (like “recursive” or “using foldl”): just create a function/method that calculates the same result. Write implementations of these functions:
• Exercise 2 questions 3, 4, and 5 (the divisors, primes, join, and pythagorean functions).
• Exercise 4 questions 2, 5 (the hailSeq and mergesort functions). For mergesort, be as general as you can with one implementation in your language: don't worry about being able to sort every type if that's difficult.
• Exercise 5 question 4 (the fib function: calculate the value with a linear running time if you can).
Of course, you should adapt the data types and argument/return values as appropriate to your language.
Provide a main function (or whatever the code that runs first is called in your language) to demonstrate calling these functions/methods.
## Sample Programs
You should write some additional sample programs in the language. These programs should demonstrate the critical features of the language as well as its strengths.
These programs are up to you. They do not have be large projects: you should have probably 3 or 4 examples that are a little more involved than a weekly exercise question. Try to provide at least one example of a problem that your language solves better (faster, more elegantly, etc.) than Haskell or C++. Look for another where it's worse.
Of course, these programs should be your work, not examples from tutorials or Wikipedia. Please comment your code well enough that we can figure out what it's supposed to be doing.
## Submitting
As with any work submitted at University, the report and code should be your own work.
Submit your files through CourSys for Assignment 2. For the report, you must submit a PDF file. For the code parts, create archives (ZIP, RAR, or TGZ) file containing your work.
Updated Fri Sept. 28 2018, 09:21 by ggbaker.
|
{}
|
## 0.7 Eigenvalues and eigenvectors
Given an operator A, an eigenvector is a non-zero vector |v\rangle such that A|v\rangle = \lambda|v\rangle for some \lambda\in\mathbb{C} (which is called the corresponding eigenvalue). We call the pair (\lambda,|v\rangle) an eigenpair, and we call the set of eigenvalues the spectrum of A, denoted by \sigma(A). It is a surprising (but incredibly useful) fact that every operator has at least one eigenpair.15 Geometrically, an eigenvector of an operator A is a vector upon which A simply acts by “stretching”.
Rewriting the defining property of an eigenpair (\lambda,|v\rangle), we see that (A-\lambda\mathbf{1})|v\rangle = 0 which tells us that the operator A-\lambda\mathbf{1} has a non-zero kernel, and is thus non-invertible. This gives a useful characterisation of the spectrum in terms of a determinant: \sigma(A) = \{\lambda\in\mathbb{C} \mid \det(A-\lambda\mathbf{1})=0\}.
1. You can prove this for an (n\times n) matrix A by considering the set \{|v\rangle,A|v\rangle,A^2|v\rangle,\ldots,A^n|v\rangle\} of vectors in \mathbb{C}^n. Since this has n+1 elements, it must be linearly dependent, and so (after some lengthy algebra) we can construct an eigenpair.↩︎
|
{}
|
## Note: The voting phase has begun on php.net. If you have an svn account somewhere on php.net, vote and share your opinion: wiki.php.net SPLClassLoader Vote
Recently there has been a rather heated and intense discussion on whether the PSR-0 autoloader "standard" should be included as part of the PHP core (in ext/spl to be exact). I've tried to stay out of the discussion and have successfully done so. Until today. I feel that there's something that's been missing to the discussion. So rather then posting this to the internals list, I feel it's better served by a blog post on the subject. So here's my take on it.
TL;DR: I don't think it should be included in the core.
## Why I Am Posting This
This comment on the internals list led me to write this post:
With the point to being included in /ext/spl/; is to give a sense of "justification" of this standard and a base in which to push forward.
IMHO, that's the exact opposite of a proper justification. That's saying "we want to justify the standard, so include it in the language" instead of what you should be saying in that "the standard is justified, so the language should support it". We're talking about a language level implementation here, not adding capability to the language... It's 100% possible to do everything you need to in PHP code, so it's not like you're adding support for it. You're adding the implementation for it.
I can see 3 main issues with implementing PSR-0 in core at this time:
## Issue #1 - It is inconsistent
It does not have any way of handling or even acknowledging edge cases such as the case sensitivity issue that was brought up earlier. Because of that, it has internal inconsistencies with respect to how PHP handles things. This alone should be enough to kill any language level implementation. PHP has enough language level inconsistencies without adding more. At least the current autoloader implementation in the core is consistent in that all filenames are lowercased. PSR-0 doesn't even address that. Sure, you could say that falls under the pervue of coding standards, but that's not the job of the language. The language is supposed to provide implementation without bias. Implementing PSR-0 here would bias the language towards a specific coding syntax and style (considering that if you don't follow that style, it won't work and things will sporadically break on different operating systems). So the argument of while (consistency) learning_curve-- is actually one for keeping this out of the core since the implementation has several inconsistencies with PHP itself (case sensitivities being the most obvious).
## Issue #2 - It is not a standard
PSR-0 is not a standard in the true sense of the word. From my knowledge, there was no public RFC for it, and it's missing quite a bit from what other communities require in a standard. First off, there's no listed scope or motivation explicitly listed (which would then nail down what the standard is trying to accomplish). Instead, it's just loosely defined based off the implementation. Secondly, considerations such as security, backwards-compatibility and performance implications are not actually expressed in the standard. This is a major problem since it doesn't even appear that these were considered (most RFCs have these listed explicitly for that reason). Third, there are no acknowledgement or references at all. While this may not seem like an issue, it is because right now there is no way of knowing who to contact or if there was research done to actually justify the standard.
Remember, just because some people come to a conclusion doesn't make it a standard. Almost everything we call a standard has had a formal RFC process with all of these steps (Such as RFC2616 and RFC4329). While I think standardizing this is good for the community, I think doing it as a formal standard is extremely important. Why is that? Because a formal RFC shows the community what went into the proposal and exactly what was considered. Right now, the only groups that really knew anything prior to it being accepted were those involved in constructing it. How many non-project developers were talked to or reached out to (in this context, non-project refers to developers who have no vested interest in any open-source (or closed) projects. More those that are developing applications and one-offs, not frameworks)? Were considerations made for those developers who are building one-off or custom implementations? Were considerations made for those who already have implementations on other systems (such as spl_autoload for example)? This wasn't mentioned on any of the php.net lists until May of this year, after it was accepted and when it was asked to be included in the core...
Don't get me wrong, I think that creating standards is great and I don't want to knock the intent of the team that put this together. In fact I think it's very important to do. But now the standard is trying to be pushed into and onto the general community. That's where the problem comes. This "standard" (quotes indicating the above issues with that word) was created informally for and by a subset of developers (realistically, a very small subset). Now that standard is trying to be applied to the community as a whole. It doesn't work that way. It shouldn't work that way. If all the framework developers want to standardize their implementations, more power to them! But if you're looking to enforce that standard beyond the scope of those that created and agree (which you are here), that's when it becomes a problem. The language shouldn't enforce standards of the few. That's not its job. Its job is to support all use cases that it chooses. Given PHP's history, that usecase is pretty well defined, and it's a significantly larger superset of usecases than most frameworks are targeting.
## Issue #3 - There's nothing for the core to gain
PSR-0 is not perfect. It doesn't try to be, but it still is not. It's far worse and more counter-productive to force a one-size-fits-all solution on all projects than to take a neutral stance. Aside from enforcing the standard, there is *nothing* practically that will be gained by including it in the core. So I would argue it's more counter-productive to the eco-system to enforce a one-size-fits-all solution that doesn't take into account the needs of the eco-system (frameworks are a very small part of that. A vocal part, but a very small one) than it is to let one or more "standards" exist and be chosen between.
## Conclusion
In conclusion, let me make one plea:
Keep core PHP interests separate from framework interests. PHP is a language with a complete different set of goals and constraints than the frameworks that are developed for it. If they overlap, great. But don't confuse them. They are distinctly different...
And apparently I'm not the only one who thinks this way... There are tons of blogs and posts along these lines, include one from @go_oh: Why the PSR-0 Classloader does not belong in SPL. If you have an opinion on this matter, let it be heard! Leave a comment, or write your own post and let me know (I'll keep a list going here if people get back to me on it)...
## Edit - Some Explanation Of Inconsistencies Of PSR-0
It seems like people still aren't grasping the inconsistencies with PSR-0 and the rest of the PHP language. Let me go through a few examples...
### Case Sensitivity
Identifiers in PHP (such as class names) are case insensitive. Some filesystems however are case sensitive (NTFS being the most common, but not the only one). The problem here is that the mapping from PHP identifiers to filesystem identifiers in PSR-0 is case sensitive. So it's completely possible to create code that works on some machines and not others, or that breaks in certain circumstances but not others.
Let's say we have a file stored in Foo.php:
new Foo();
new foo();
That will work on all systems and at all times with PSR-0. However, if we switch the two around, we run into trouble:
new foo();
new Foo();
That will work fine on case insensitive filesystems such as NTFS, but fail on case sensitive ones. So you can develop code that works quite fine on Windows, but when you push to Linux will fail.
### Doesn't play nice with other loaders
If a file doesn't exist, PSR-0 doesn't play nice with other autoloaders. It will try to require the file, but then the require will fail and fatal error out. This is a problem since a later autoloader may know how to load it. So it's not following the normal convention of "if you can't load it, don't error out". This is fine if all code that lives in the application follows PSR-0 guidelines, but it makes interoperating with code using a different loader system/standard potentially difficult. Here's an example using the SPLClassLoader specified in PSR-0:
Let's say you have a loader defined as new SplClassLoader('foo', '/lib/foo/');. So that would only load classes from \foo\* namespace (which is good practice to limit it). Now what happens if I need to add a class to that namespace (such as \foo\bar() stored in /lib/myfoo/foo/bar.php). Note that it's 100% valid and allowed PHP to do so. Now, when I do:
new \foo\bar;
What happens depends on the order of the autoloaders. If I load mine first and then the foo one, it will work fine. But if I load the foo one (such as provided by a framework), the whole application will fatal error.
Now, I know you're thinking, "it's not a good idea to do that". But there are examples of cases similar to that happening right now (Kohana for one). The point is, the language supports that 100%. So why add something that could *fail* if you're doing something that's otherwise valid... And we're not talking about just not working, we're talking about throwing a fatal error...
### Multiple Classes Map To The Same File
With PSR-0, multiple classes actually map to the same file. For example, all of the following map to the same file (Foo/Bar/Baz.php):
• \Foo\Bar\Baz
• \Foo\Bar_Baz
• \Foo_Bar_Baz
So, assuming the three classes didn't all actually live in that one file (for example, they could be autoloaded by another autoloader), consider the following code:
new \Foo\Bar\Baz;
new \Foo\Bar_Baz;
new \Foo_Bar_Baz;
PSR-0 will *not* play nice here. It will try to load the same file 3 times. And when it does, it will fail since it's using require over require_once... So it'll fatal error because it included the same file twice (and get duplicate class definition errors, etc). Something that's 100% valid PHP (those 3 classes are distinct) and can have valid use cases (interacting with PEAR for example) would mysteriously raise unrelated fatal errors...
There are other inconsistencies, but those are more related to how the class is structured itself rather than the "standard" (example: you can set the namespace separator to something that will completely bork other included libraries)...
|
{}
|
# $|\vec a|=2 , |\vec b|=5$ and $|\vec c|=7$ and $\vec a+ \vec b + \vec c=0$ what is $\vec a\cdot\vec b+ \vec b\cdot\vec c+ \vec a\cdot\vec c$?
We have the vectors $\vec a$ ,$\vec b$ and $\vec c$ of lengths $|\vec a|=2 , |\vec b|=5$ and $|\vec c|=7$. If $\vec a+ \vec b + \vec c=0$ , find $\vec a\cdot\vec b+ \vec b\cdot\vec c+ \vec a\cdot\vec c$.
-
By 'modules' do you mean length, and what do you mean by $a*b+c*c+a*c$? – copper.hat Nov 9 '12 at 8:35
yes,i mean length by modules.Find the value of a*b +b*c+c*a,thats all. "*" means multiplication – nicegirl Nov 9 '12 at 8:36
And *' means '.' (dot/scalar product) multiplication, or $\times$' (cross/vector product) product? – Tapu Nov 9 '12 at 8:40
scalar my dear,scalar. – nicegirl Nov 9 '12 at 8:40
Are $a,b,c$ scalars or vectors? – copper.hat Nov 9 '12 at 8:43
let $P=\vec a.\vec b+\vec b.\vec c+\vec a.\vec c$
Then $P=\vec a.(\vec b+\vec c)+\vec b.\vec c$
$\vec a+\vec b+\vec c=0$ then $\vec b+\vec c=-\vec a$
So $P=\vec a.(-\vec a)+\vec b.\vec c=-|\vec a|^2+\vec b.\vec c$ $\space\space\space\space\space\space\space(1)$
Similarily :
$P=-|\vec b|^2 + \vec a.\vec c$ $\space\space\space\space\space\space\space(2)$
$P=-|\vec c|^2+ \vec b.\vec a$ $\space\space\space\space\space\space\space(3)$
Then summing $(1)+(2)+(3)$ you get
$3P = -(|\vec a|^2+|\vec b|^2+|\vec c|^2) + P$
Then
$P= -\frac12(|\vec a|^2+|\vec b|^2+|\vec c|^2)$
-
This answer is absolutely correct with the explanation that $\vec x . \vec x$ = $|\vec x |^2$ – Souvik Dey Nov 9 '12 at 8:56
Well, we have the formula: $$(a+b+c)^2=a^2+b^2+c^2+2(ab+bc+ca)$$ Now use the given values of $a,b,c$ and $a+b+c=0$.
-
they are vectors... – nicegirl Nov 9 '12 at 8:43
No, $|a|$'s are scalar and so is $(a+b+c)^2=(a+b+c).(a+b+c)$. – Tapu Nov 9 '12 at 8:44
Since $|a|+|b|=|c|$, they must be collinear. Let $u$ be a unit vector in the direction of $a$, then we have $a = 2u$, $b = \pm 5 u$ and $c = \pm 7u$. Since $a+b+c =0$, we must have $b=5u, c=-7u$.
Then $a \cdot b+b \cdot c + c \cdot a = 2u \cdot 5u+5u \cdot (-7 u) + (-7u) \cdot 2u =10 -35-14 = -39$.
|
{}
|
07508262658/07487614692
### how to find the rule of a table
When in doubt choose the simplest rule that makes sense, but also mention that there are other solutions. ... it may be a list of the winners' numbers ... so the next number could be ... anything! For example, the 25th term can be found by "plugging in" 25 wherever n is. While you’re building an Excel pivot table, you don’t have an option to set a name for your pivot table. So, the relation between the input and output values is Output = Input - 1. 3. Here is a blank Values Table you can print out or project onto a whiteboard to practice making Values tables from algebra rules. 1. Created: Jul 13, 2016. docx, 15 KB. About this resource. You can find the rule directly on top of the input-output table. The form rule is applied, and then the table rule is applied. All fields are required. Practice: Chain rule with tables. Info. Mutually exclusive events will have a probability of zero. Integration can be used to find areas, volumes, central points and many useful things. Name. Create a table with headings n and a n where n denotes the set of consecutive positive integers, and a n represents the term corresponding to the positive integers. A RULE is very much like a check constraint; except that they only work in T-SQL and Microsoft has deprecated them. When the rule is given, it is the same rule for every row of the table in that problem. Test your rule on each row of the input/output table. Learn to evaluate and write function rules for an input - output table. Year 7-8 worksheet find the rule from a table of values. Excel will create a name, and it’s easy to change the pivot table name at any time. (3 ÷ 3) + 2 = 3, not 9. Create a Pivot Table. @\begin {align*}x+4\end {align*}@ First, substitute the input values in for @\begin {align*}x\end {align*}@ to see if you get … Interpreting the table. Find the value of 'b' in the slope intercept equation. Find the rule. So, choice 3 does not work. The product rule for derivatives states that given a function #f(x) = g(x)h(x)#, the derivative of the function is #f'(x) = g'(x)h(x) + g(x)h'(x)#. We find if the function is increasing or decreasing. So, we can write the relationship between input and output as a rule, Output = input. a n = a 1 + (n - 1) d. Steps in Finding the General Formula of Arithmetic and Geometric Sequences. Values Table for Practicing Questions. Year 7-8 worksheet find the rule from a table of values. You can use most CSS properties on table elements. We find if the function is increasing or decreasing. Video: Input Output TablesGrade Levels: 4th Grade - 5th Grade Check out our ever-growing library of math songs at https://www.numberock.com. We need to be able to find the Rule for Sets of (x,y) pairs, and for any straight line graphs we have drawn, so that: Derivative definition; Derivative rules; Derivatives of functions table; Derivative examples; Derivative definition. 1 worksheet, 4 pages Directions: Find the pattern for each table, complete the chart and circle the Rule. Notice that only table 1 matches our table. They will then make a table, and from the table, make a graph. We first identify the input and the output variables and their values. Calculates the table of the specified function with two variables specified as variable data table. f(x,y) is inputed as "expression". Because you add 6 to every input to get the correct output, the equation is n 6 b. In this lesson you will learn how to find the rule for a function machine by using a vertical table. The formula to write a function rule from a table is. Q9 Find a rule for the table. For the right hanging height, position the bottom of the chandelier about 30-32 inches above the table, adjusting to work with the size of the table and the overall scale of your space. The product rule is used primarily when the function for which one desires the derivative is blatantly the product of two functions, or when the function would be more easily differentiated if looked at as the product of two functions. Determine the rule followed by each function table. Find the value of 'b' in the slope intercept equation. For example, suppose you apply the following rule to a date field in a table: <#01/01/2010# Calculate the values of and . (3 × 1) + 2 = 5, not 9. Determining Whether a given Relation is a Function-Gr 8-Solved Examples, Classifying Relations as Linear or Nonlinear-Gr 8-Solved Examples, Identifying Functions-Gr 8-Solved Examples, Graphing Linear Functions for a Given Domain-Gr 8-Solved Examples, Graphing Linear Functions based on an x/y Table-Gr 8-Solved Examples, Graphing Linear Equations-Gr 8-Solved Examples, Solving Problems Using Rate of Change-Gr 8-Solved Examples, Representing Exponential Functions Using Tables or Graphs-Gr 8-Solved Examples. Sometimes it helps to find the differences between each pair of numbers ... this can often reveal an underlying pattern. Sometimes we can just look at the numbers and see a pattern: Answer: they are Squares (12=1, 22=4, 32=9, 42=16, ...). This is also the default if no rule number is specified. But it is often used to find the area underneath the graph of a function like this: The integral of many functions are well known, and there are useful rules to work out the integral … Example 7 : Examine the given table and determine if … A SQL Server RULE specifies the acceptable values that can be inserted into a database column. RULES, an HTML 4.0 attribute, indicates if there should be internal borders in the table.We’ll go over each of the values of RULES and demonstrate how they are used.RULES and FRAME have an annoying way of changing each other’s defaults. In this non-linear system, users are free to take whatever path through the material best serves their needs. Interpreting the table. The differences are always 2, so we can guess that "2n" is part of the answer. Virtual Nerd's patent-pending tutorial system provides in-context information, hints, and links to supporting tutorials, synchronized with videos, each 3 to 7 minutes long. By dividing the values in column X by 4, we get the corresponding values in Column Y. Build a set of equations from the table such that . If you use a thead, the whole table will be wrapped in that until it find a tbody, then it will auto-close the thead if you don’t, and wrap the rest in tbody (also optional to close). x^2*y+x*y^2 ) The reserved functions are located in " Function List ". So, we have three perfectly reasonable solutions, and they create totally different sequences. Complete the output for the given rule. If we graph any of these input and output (x,y) values, a straight line will be created. For example, a student generated rule might be: Out = 3(In) + 4. Possible rule: Add 6. you will notice the differences increase linearly. Look at the differences 11-6, 18-11, 27-18 etc. A. multiply by 8 B. divide by 4 C. subtract 5 D. add 10. I like to begin with some tables and rules they have generated in past lessons; I start with one of their examples. Each number in the sequence is called a term (or sometimes "element" or "member"), read Sequences and Series for a more in-depth discussion. Derivatives of functions table. A SQL Server RULE is intended to check information as new rows are inserted or … Important Style Rules for Tables. If the function is increasing, it means there is either an addition or multiplication operation between the two variables. We already know term 5 is 21 and term 4 is 13, so: One of the troubles with finding "the next number" in a sequence is that mathematics is so powerful we can find more than one Rule that works. Here are the steps required to plot any straight line graph from an algebra rule. Example 7 : Examine the given table and determine if … The Rule tells us the “Relationship” between all of the x and y values. So by "trial-and-error" we discovered a rule that works: Sequence: 1, 2, 4, 7, 11, 16, 22, 29, 37, ... Read Sequences and Series to learn about: In truth there are too many types of sequences to mention here, but if there is a special one you would like me to add just let me know. Derivative of aˣ (for any positive base a) Derivative of logₐx (for any positive base a≠1) Practice: Derivatives of aˣ and logₐx. To establish a rule for a number pattern involving ordered pairs of x and y, we can find the difference between every two successive values of y. After 3 and 5 all the rest are the sum of the two numbers before. Mutually exclusive events will have a probability of zero. Solutions. To find a missing number in a Sequence, first we must have a Rule. Mathematics; Mathematics / Number / Addition and subtraction; Rule: Add 5. Integration can be used to find areas, volumes, central points and many useful things. To simplify your life, here’s a rule of thumb: if you use RULES also use FRAME and BORDER.It’s easier to avoid getting confused. Derivative rules and laws. In our case the difference is 1, so let us try just n22: We are close, but seem to be drifting by 0.5, so let us try: n22 â n2, The formula n22 â n2 + 1 can be simplified to n(n-1)/2 + 1. Each function is a rule, so each function table has a rule that describes the relationship between the inputs and the outputs. (ex. Correct Answer is : divide by 4. A function rule such as cost = p + 0.08p is an equation that describes a functional relationship. In most cases, the “something else” carries a sense of urgency, such as the need […] If p is the price you pay for an item and 0.08 is the sales tax, the function rule above is the cost of the item. With second differences we multiply by n22. Example: Iptables insert rule at top of tables. I post just the rule on the board. 8 = k(16) 1 / 2 = k. So, the constant of proportionality is 1 / 2. Rule: Subtract 7. In this lesson, we find the function rule given a table of ordered pairs. Watch this video to see the steps for creating a pivot table, using the Recommended Pivot Tables command. We can use a Rule to find any term. These unique features make Virtual Nerd a viable alternative to private tutoring. Then, we have y = k / x Substitute 16 for x and 8 for y. Summary of Plotting from a Rule. When we look at the above table when x gets increased, y gets decreased, so it is inverse proportion. You may pick only the first five terms of the sequence. Solution 2: After 1 and 2, add the two previous numbers, plus 1: Solution 3: After 1, 2 and 4, add the three previous numbers. This means the original function is quadratic - so you can find the equation of the quadratic from any 3 x-y pairs and check it on a fourth pair (I'd suggest the first 3 to solve for the coefficients and the last pair to check the equation). On observing the table it is found that 2 =, So, the equation that represents the table is, On observing the table it is found that 4 =. Step: 1. Write the rule as an expression. 301) for regulations codified in the Code of Federal Regulations. If your rule holds true, you can write an equation for the rule. If the table is more restrictive than the form, the rule defined for the table field takes precedence. Compare the labels and values in this table with the tables given in the question. When we look at the above table when x gets increased, y gets decreased, so it is inverse proportion. ): Solution 1: Add 1, then add 2, 3, 4, ... (That rule looks a bit complicated, but it works). You may already be familiar with Robert’s Rules and the motion to Lay on the Table, the highest-ranking subsidiary motion. If you are given a table, usually you have to carefully examine the table to see what the function rule is. Email confirmation. Take a look at the following function rule and determine if it is a rule for the data in the table below. Improve your math knowledge with free questions in "Multiplication input/output tables: find the rule" and thousands of other math skills. Mathematics; Mathematics / Number / Addition and subtraction; Parallel Table of Authorities and Rules for the Code of Federal Regulations and the United States Code. The Parallel Table of Authorities and Rules lists rulemaking authority (except 5 U.S.C. Here are three solutions (there can be more! The derivative of a function is the ratio of the difference of function value f(x) at points x+Δx and x with Δx, when Δx is infinitesimally small. The above command will insert rule in the INPUT chain as the given rule number. There is always a pattern in the way input values (x) and the output values (y) are related which is given by the function rule. The last row shows that we are always wrong by 5, so just add 5 and we are done: OK, we could have worked out "2n+5" by just playing around with the numbers a bit, but we want a systematic way to do it, for when the sequences get more complicated. The rule for the pattern is subtract 12 from the number in column A to get the number in column B. In this lesson, we find the function rule given a table of ordered pairs. Email address. Year 7-8 worksheet find the rule from a table of values. To find a missing number, first find a Rule behind the Sequence. Create your free account Teacher Student. If the difference pattern is the same, then the coefficient of x in the algebraic rule (or formula) is the same as the difference pattern. Worked example: Derivative of log₄(x²+x) using the chain rule. 1. On observing the table, it is found that the output 5 = 6 - 1, 10 = 11 - 1, 14 = 15 - 1 and 6 = 7 - 1. xn means "term number n", so term 3 is written x3. Improve your math knowledge with free questions in "Multiplication input/output tables: find the rule" and thousands of other math skills. The RULES Attribute. All inclusive means that there is nothing outside of those two events: P(A or B) = 1. So, choice 2 does not work. 8 = k(16) 1 / 2 = k. So, the constant of proportionality is 1 / 2. Categories & Ages. We first identify the input and the output variables and their values. Worked example: Derivative of 7^(x²-x) using the chain rule. Password. 2. So, the rule for the pattern is subtract 12 from the number in column A to get the number in column B. So, if the rule number is 1, the rule or rules are inserted at the head of the chain. Certain things can be determined from the joint probability distribution. Remember 'b' is the y-intercept which, luckily, was supplied to us in the table. Did you see how we wrote that rule using "x" and "n" ? Derivative rules. Learn how to use an input-output table to evaluate a given function rule. Each number in the sequence is called a term (or sometimes "element" or "member"), read Sequences and Seriesfor a more in-depth discussion. This motion is used to temporarily set aside a pending main motion, permitting something else to be addressed or done. 8 Input / Output Charts for students to complete Prior knowledge of patterns, addition, subtraction, multiplication and division are required to complete this lesson. All inclusive means that there is nothing outside of those two events: P(A or B) = 1. All inclusive events will have a zero opposite the intersection. If the function is increasing, it means there is either an addition or multiplication operation between the two variables. Rule: Add 9. So, 'multiply by 2 and add 3' is the rule for the table. On observing the table it is found that the output 5 = 5, 6 = 6, 7 = 7, 8 = 8 and 9 = 9. The rule consists of 2 variables using addition, division, multiplication, and/or subtraction. By dividing the values in column X by 4, we get the corresponding values in Column Y. Created: Jul 13, 2016. docx, 15 KB. ... the whole guts of the table will be wrapped in tbody. Then, we have y = k / x Substitute 16 for x and 8 for y. Create a new teacher account for LearnZillion. About this resource. I am going to INSERT the following rule at of filter table and FORWARD chain: Report a problem. Function Table Rules. But it is often used to find the area underneath the graph of a function like this: The integral of many functions are well known, and there are useful rules to work out the integral … A good rule of thumb is to make sure your chandelier is one-half to three-quarters the width of your table. Q10 Identify the equation that represents the values in the function table shown. y = mx + b y = 4x + b Since our table gave us the point (0, 3) we know that 'b' is 3. To find if the table follows a function rule, check to see if the values follow the linear form . All inclusive events will have a zero opposite the intersection. Certain things can be determined from the joint probability distribution. It means "the previous term" as term number n-1 is 1 less than term number n. So term 6 equals term 5 plus term 4. Remember 'b' is the y-intercept which, luckily, was supplied to us in the table. That is 3 + 5 = 8, 5 + 8 = 13 etc, which is part of the Fibonacci Sequence: Now what does xn-1 mean? A Sequence is a set of things (usually numbers) that are in order. Categories & Ages. If the rules are mutually exclusive, they prevent you from entering any data at all. Year 7-8 worksheet find the rule from a table of values. A function table has values of input and output and a function rule.In the function rule, if we plug in different values for the input, we get corresponding values of output. Share . A Sequenceis a set of things (usually numbers) that are in order. Report a problem. Info. y = mx + b y = 4x + b Since our table gave us the point (0, 3) we know that 'b' is 3. Let’s see how to find out if a RULE is bound to a column in SQL Server and how to remove them. In the sequence {1, 2, 4, 7, 11, 16, 22, ...} we need to find the differences ... ... and then find the differences of those (called second differences), like this: The second differences in this case are 1. A student generated rule might be: out = 3 ( in ) + 4 or b =. Example: Derivative of 7^ ( x²-x ) using the Recommended pivot tables command a List the! Volumes, central points and many useful things steps for creating a pivot table name any! To find areas, volumes, central points and many useful things they have generated in past ;... Dividing the values follow the linear form the width of your table, 27-18 etc alternative to private.... Free questions in function List 27-18 etc tables: find the rule defined for the table be List..., 'multiply by 2 and add 3 ' is the y-intercept which, luckily, was supplied to us the... 4Th Grade - 5th Grade check out our ever-growing library of math at... The highest-ranking subsidiary motion, how to find the rule of a table 9 first find a missing number, find... Practice making values tables from algebra rules free to take whatever path the! Could be... anything be found by plugging in '' 25 wherever is... A database column the Sequence the 25th term can be inserted into a database column to how to find the rule of a table values... On top of tables set of things ( usually numbers ) that are in order their... Given table and determine if … look at the differences between each pair of numbers so! Be created when the rule defined for the table to see if function... Each table, using the chain rule... the whole guts of the x 8. With free questions in function List must have a rule, so we can write the between... Solutions, and it ’ s see how to find areas, volumes, central points and useful. Has deprecated them we first identify the equation is n 6 b in. Function List you see how we wrote that rule using x '' and thousands of other skills! Input and output values is output = input, usually you have to examine. Between the inputs and the output variables and their values of log₄ ( x²+x ) the.: find the rule is applied row of the Sequence represents the follow. Y values math skills or decreasing n is we have y = k / x 16. Make sure your chandelier is one-half to three-quarters the width of your.! Follow the linear form the form, the highest-ranking subsidiary motion 11-6 18-11! So the next number could be... anything is either an addition multiplication! The joint probability distribution following function rule is applied given a table of values y^2... Is applied how to find the rule of a table and they create totally different sequences the y-intercept which, luckily, was supplied us! How we wrote that rule using x '' and thousands of other math skills the output and. Rule behind the Sequence Derivative definition ; Derivative rules ; Derivatives of functions table ; Derivative ;! So we can guess that 2n '' is part of the chain rule behind the Sequence also... Rule directly on top of tables take whatever path through the material best serves their.. This video to see the steps for creating a pivot table name at any.. Can write the relationship between input and the motion to Lay on table! This table with the tables given in the slope intercept equation numbers this...... the whole guts of the Sequence, a student generated rule might be: out 3! Of 7^ ( x²-x ) using the Recommended pivot tables command ) using the Recommended tables... Rule using x '' and thousands of other math skills can find the function rule and determine if look... Corresponding values in column y correct output, the constant of proportionality is 1 / =... Output variables and their values the width of your table some tables and rules have. Supplied to us in the question can be determined from the joint probability distribution find the rule is the... Rule of thumb is to make sure your chandelier is one-half to three-quarters the width of your table year worksheet. Column b how to find the rule of a table, so each function table shown to plot any straight line will be wrapped in.! Improve your math knowledge with free questions in function List find the! Lists rulemaking authority ( except 5 U.S.C increasing or decreasing the pattern is subtract 12 the! Rule tells us the “ relationship ” between all of the chain rule a... Mutually exclusive events will have a zero opposite the intersection equation that represents the values in the will. Any term solutions ( there can be found by plugging in '' 25 wherever is. '' and thousands of other math skills can be inserted into a database column they create totally different sequences,. If … look at the differences between each pair of numbers... so the next number could be...!... As a rule behind the Sequence find if the function is a is... Tables and rules they have generated in past lessons ; i start with one of their examples values follow linear... By 2 and add 3 ' is the same rule for the pattern for each table, using the.. Each function table shown creating a pivot table name at any time rules are inserted at the differences each... Be found by plugging in '' 25 wherever n is add 6 to every input to get corresponding... Mutually exclusive events will have a zero opposite the intersection probability distribution of 2 variables using addition,,. 16 ) 1 / 2 have three perfectly reasonable solutions, and it ’ s and... Inserted at the differences between each pair of numbers... so the next number could be... anything number! Thousands of other math skills Grade check out our ever-growing library of math songs at https //www.numberock.com. Functions are located in multiplication input/output tables: find the rule values table you use. A Sequence is a rule that makes sense, but also mention that there is either an or. 5Th Grade check out our ever-growing library of math songs at https: //www.numberock.com did see. Table has a rule first find a missing number in column x by 4, we find the from. Values is output = input - 1 opposite the intersection make sure chandelier... Chart and circle the rule '' and thousands of other math skills values tables from algebra rules, users free... plugging in '' 25 wherever n is 1 worksheet, 4 pages:. Found by plugging in '' 25 wherever n is to find out if rule. Always 2, so each function table shown ( 16 ) 1 2! Look at the following function rule and determine if it is inverse proportion prevent you from entering any at. Are given a table, usually you have to carefully examine the given table and if. Output as a rule is bound to a column in SQL Server and how to find out a... In the Code of Federal regulations one-half to three-quarters the width of your table table how to find the rule of a table be in. And determine if how to find the rule of a table look at the above table when x gets increased, y ) values a! Properties on table elements form rule is given, it means there is either an addition or multiplication between. Each function table shown written x3 with the tables given in the table below input-output table of.... S easy to change the pivot table, using the chain rule function given... Always 2 how to find the rule of a table so each function is increasing or decreasing and y values has... An input - output table and their values rule how to find the rule of a table thumb is to sure... Subsidiary motion how to remove them table such that, a how to find the rule of a table line from. Deprecated them private tutoring tells us the “ relationship ” between all of the x y! Be more x^2 * y+x * y^2 ) the reserved functions are located . System, users are free to take whatever path through the material best serves needs... Table elements you may pick only the first five terms of the x and 8 for.. 1 / 2 = 3, not 9 = 1 print out or project onto whiteboard... Can find the value of ' b ' is the y-intercept which, luckily, was to..., permitting something else to be addressed or done motion to Lay on the table field takes.. Be... anything exclusive, they prevent you from entering any data at all that... And how to remove them highest-ranking subsidiary motion located in function List table with the tables in! ( 16 ) 1 / 2 * y+x * y^2 ) the reserved functions are located ... Example 7: examine the given table and determine if … look at the function... They create totally different sequences, luckily, was supplied to us in Code! '' is part of the winners ' numbers... this can often reveal an underlying pattern events! The Recommended pivot tables command the relationship between the inputs and the to! For a function rule from a table of values using a vertical table you from entering any data at.... So each function table has a rule behind the Sequence knowledge with free questions in function List b... Rules are inserted at the above table when x gets increased, y ) is inputed as expression... Addition or multiplication operation between the inputs and the motion to Lay on the such. Things can be used to find if the table, complete the chart and circle the rule for the.! Alternative to private tutoring set of things ( usually numbers ) that are in order 3 ) 2...
|
{}
|
2 added 4 characters in body edited Jun 4 '12 at 20:29 emrea 81644 silver badges1212 bronze badges I can see that this problem can be modeled with Bayesian networks. First, you need to decide which dependencies are there in your problem. As you said, (1) v depends on a,b,c,d,e (2) x depends on a,b,c,d,e,v (3) y depends on a,b,c,d,e,x and finally, (4) z depends on a,b,c,d,e,v,x,y Second, you need to implement these distributions. For example, for (1), you need to model P(v|a,b,c,d,e) how you do this is upto you. You can train a classifier, learn a regressor, etc. You will also need to model the prior probabilities of a,b,c,d,e. At this point, you can write the full joint distribution of all your variables using the conditional probabilities you have. Finally, you can answer any inference query with what you have. For example, let's say you're interested in answering P(z>q), the probability of revenue being higher than q. $$P(Z>q) = \int_q^\infty P(z)dz$$. $$P(z) = \sum_q \sum_b \sum_c \sum_d \sum_e \sum_v \sum_x \sum_y P(z,a,b,c,d,e,v,x,y)$$ where the joint factors into your conditional densitiesprobabilities: $$P(z,a,b,c,d,e,v,x,y) = P(z|a,b,c,d,e,v,y,x) P(v|a,b,c,d,e) \dots$$ Hope this helps. I can see that this problem can be modeled with Bayesian networks. First, you need to decide which dependencies are there in your problem. As you said, (1) v depends on a,b,c,d,e (2) x depends on a,b,c,d,e,v (3) y depends on a,b,c,d,e,x and finally, (4) z depends on a,b,c,d,e,v,x,y Second, you need to implement these distributions. For example, for (1), you need to model P(v|a,b,c,d,e) how you do this is upto you. You can train a classifier, learn a regressor, etc. You will also need to model the prior probabilities of a,b,c,d,e. At this point, you can write the full joint distribution of all your variables using the conditional probabilities you have. Finally, you can answer any inference query with what you have. For example, let's say you're interested in answering P(z>q), the probability of revenue being higher than q. $$P(Z>q) = \int_q^\infty P(z)dz$$. $$P(z) = \sum_q \sum_b \sum_c \sum_d \sum_e \sum_v \sum_x \sum_y P(z,a,b,c,d,e,v,x,y)$$ where the joint factors into your conditional densities: $$P(z,a,b,c,d,e,v,x,y) = P(z|a,b,c,d,e,v,y,x) P(v|a,b,c,d,e) \dots$$ Hope this helps. I can see that this problem can be modeled with Bayesian networks. First, you need to decide which dependencies are there in your problem. As you said, (1) v depends on a,b,c,d,e (2) x depends on a,b,c,d,e,v (3) y depends on a,b,c,d,e,x and finally, (4) z depends on a,b,c,d,e,v,x,y Second, you need to implement these distributions. For example, for (1), you need to model P(v|a,b,c,d,e) how you do this is upto you. You can train a classifier, learn a regressor, etc. You will also need to model the prior probabilities of a,b,c,d,e. At this point, you can write the full joint distribution of all your variables using the conditional probabilities you have. Finally, you can answer any inference query with what you have. For example, let's say you're interested in answering P(z>q), the probability of revenue being higher than q. $$P(Z>q) = \int_q^\infty P(z)dz$$. $$P(z) = \sum_q \sum_b \sum_c \sum_d \sum_e \sum_v \sum_x \sum_y P(z,a,b,c,d,e,v,x,y)$$ where the joint factors into your conditional probabilities: $$P(z,a,b,c,d,e,v,x,y) = P(z|a,b,c,d,e,v,y,x) P(v|a,b,c,d,e) \dots$$ Hope this helps. 1 answered Jun 4 '12 at 19:14 emrea 81644 silver badges1212 bronze badges I can see that this problem can be modeled with Bayesian networks. First, you need to decide which dependencies are there in your problem. As you said, (1) v depends on a,b,c,d,e (2) x depends on a,b,c,d,e,v (3) y depends on a,b,c,d,e,x and finally, (4) z depends on a,b,c,d,e,v,x,y Second, you need to implement these distributions. For example, for (1), you need to model P(v|a,b,c,d,e) how you do this is upto you. You can train a classifier, learn a regressor, etc. You will also need to model the prior probabilities of a,b,c,d,e. At this point, you can write the full joint distribution of all your variables using the conditional probabilities you have. Finally, you can answer any inference query with what you have. For example, let's say you're interested in answering P(z>q), the probability of revenue being higher than q. $$P(Z>q) = \int_q^\infty P(z)dz$$. $$P(z) = \sum_q \sum_b \sum_c \sum_d \sum_e \sum_v \sum_x \sum_y P(z,a,b,c,d,e,v,x,y)$$ where the joint factors into your conditional densities: $$P(z,a,b,c,d,e,v,x,y) = P(z|a,b,c,d,e,v,y,x) P(v|a,b,c,d,e) \dots$$ Hope this helps.
|
{}
|
Tuesday, June 7, 2011
In the previous post, I kind of glossed over the problem with using the built in delay function. I said that it would be better to use interrupts so I'll go more in depth about that.
The problem with using the built in delay is that CPU clock cycles are essentially wasted. In such a simple program like we had in the previous post, we are not worried about conserving clock cycles but you can imagine that in a very complex program you would want every clock cycle to do something. Once interrupts are set up and enabled, they will "interrupt" the program when a certain condition is met. In the case of delay, a timer counts clock cycles and once a certain number is reached, the program is interrupted and carries out a "service routine" specified by the programmer. Once the service routine is finished, the program returns to the line of code it was executing when the interrupt occurred.
To illustrate the difference between the two types of delays, I wrote a program that does the exact same thing as the program in the previous post but it uses interrupts rather than the built in delay. This program simply makes the built in LEDs turn on and off at a rate that is perceptible to the human eye:
#include <avr/io.h>
#include <avr/interrupt.h>
int main(void)
{
DDRB = 0xFF; //PORT B (LEDs) output
TCNT0 = 0; //timer starts at zero
OCR0 = 200; //and counts up to 200
TCCR0 = 0b00001101; //CTC mode, internal clk, 1024 prescaler
sei(); //global interrupt enable
TIMSK = (1<<OCIE0); //timer0 overflow interrupt enable
while(1)
asm("nop"); //stay here....
}
ISR (TIMER0_COMP_vect)
{
PORTB ^= 0xFF; //toggle PORTB (LEDs)
}
|
{}
|
# If x is a random variable with the expected value of 5 and the variance of 1, then the expected value of x2 is
This question was previously asked in
GATE PI 2020 Official Paper
View all GATE PI Papers >
1. 24
2. 25
3. 26
4. 36
Option 3 : 26
## Detailed Solution
Concept:
For any random variable x the variance of x is the expected value of the squared difference between x and its expected value, i.e.
Var(x) = E(x2) - (E(x))2
E(x2) = Var(x) + (E(x))2
Where, E(x2) = Expected squared value; E(x) = Expected value;
Calculation:
Given:
Var(x) = 1; E(x) = 5;
E(x2) = Var(x) + (E(x))2 = 1 + (5)2
E(x2) = 26
|
{}
|
# Probabilistic notation is the worst (Part III)
## Harlan Ichikawa
“We were somewhere around Barstow, on the edge of the desert, when the drugs began to take hold.” ― Hunter S. Thompson, Fear and Loathing in Las Vegas
This post is the third in a three part series
In part II I discussed how probability theory deserves its own category, the same way that other sub fields of mathematics have their own category. I showed how the standard definition does not transform properly under restriction, and prohibits the the formation of a category. This motivated us to consider an alternative definition. However, I never illustrated the category which results. The present post accomplishes one thing: we will make a category for probability theory and tie it to the classical foundations.
## The category of measurable spaces
A measurable space consists of a pair, $(X,\Sigma)$, where $X$ is a set and $\Sigma \subset 2^X$ is a $\sigma$-algebra. We think of the elements of $\Sigma$ as events when we talk about probability. Informally, a $\sigma$-algebra is just the algebraic entity which encodes the notion of a space of events. For the formal definition see the wikipedia link. Given two $\sigma$-algebras, $(X,\Sigma_1)$ and $(Y,\Sigma_2)$, we say that $f:X \to Y$ is measurable if $f^{-1}(E) \in \Sigma_1$ for every $E \in \Sigma_2$. The collection of all measurable spaces forms a category where the arrows are given by measurable maps.
## The category of measure cones
A measure on a measurable space, $(X,\Sigma)$, is just a map $\mu: \Sigma \to \mathbb{R}^+ \cup \{ \infty\}$ such that
where $\uplus$ denotes disjoint union. We denote the space of measures over a $(X,\Sigma)$ by $\mathcal{M}(X,\Sigma)$ and we will call such a space a measure-space.
Note that given two measures $\mu_1,\mu_2 \in \mathcal{M}(X,\Sigma)$ we can sum them to get a measure $\mu_1 + \mu_2 \in \mathcal{M}(X,\Sigma)$ so that $\mathcal{M}(X,\Sigma)$ forms a convex cone.
The assignment “$(X,\Sigma) \mapsto \mathcal{M}(X,\Sigma)$” is actually a functor, but to clarify that I need to describe the arrows.
## Arrows between measure cones
Not that for each event $E \in \Sigma$, we can describe a new $\sigma$-algebra $(E, E \cap \Sigma)$ where $E \cap \Sigma := \{ E \cap \bar{E} \mid \bar{E} \in \Sigma \}$. In fact this characterizes all the sub-algebras of $\Sigma$. So we see each $\sigma$-algebra is equipped with a set of inclusion maps from it’s sub-algebras.
The inclusion map $\iota: E \cap \Sigma \hookrightarrow \Sigma$ can be lifted to a map which embeds $\mathcal{M}(E \cap \Sigma) \hookrightarrow \mathcal{M}(\Sigma)$. It’s a measureable map after all. A posterior measure is a map, $m: \mathcal{M}(\Sigma_1) \to \mathcal{M}(\Sigma_2)$ such that for any $E \in \Sigma_1$ there exists a unique map $m_E : \mathcal{M}(E \cap \Sigma_1) \to \mathcal{M}(\Sigma_2)$ which makes the diagram
commute. Sidetrack: Something here is eerily reminiscent of a pre-sheaf.
The correspondence with the classical notion of a posterior measure might not be obvious. In the case where $X$ is a manifold, a classical posterior measure, $m(B \mid A)$ where $A \subset X$ and $B \in \Sigma_2$ induces a map which sends a measure $\mu_1 \in \mathcal{M}(X,\Sigma_1)$ to a measures $\mu_2 \in \mathcal{M}(Y,\Sigma_2)$ by $\mu_2(B) := \int m(B \mid x) \mu_1(x) dx, \forall B \in \Sigma_2$. In the discrete case, the integral just becomes a sum. This mapping satisfies the commutative diagram, so we at least see the classical posteriors as special cases, and so have illustrated one direction of this equivalence.
The other direction can be demonstrated as well. This mapping from $\mathcal{M}(X,\Sigma_1)$ to $\mathcal{M}(Y,\Sigma_2)$ completely characterizes the posterior $\mu(B\mid A)$. This is most easily illustrated in the case where $\Sigma_1$ is finite. Then you can take $A$ to be a singleton set, $\{ x \}$ for some $x \in X$, in which case $\mu$ is just a scalar which we’ll call $\mu_x \in \mathbb{R}^+$. The measure $\iota_*(\mu)$ has support on a single point, namely $x$, and the comutativity of the diagram implies that for any $B \in \Sigma_2$ that $m[i_*\mu] (B) = \lambda_x(B) \mu_x$ for some measure $\lambda_x \in \mathcal{M}(\Sigma_2)$. However, all measures in $\mathcal{M}(\Sigma_1)$ are direct sums of measures of the form $\iota_* \mu$ where $\iota$ is the immersion of a singleton set. Therefore, for a generic $\mu \in \mathcal{M}(\Sigma_1)$ we have $m[\mu](B) = \sum_{x \in X} \lambda_x(B) \mu(x)$. The measure $\lambda_x (B)$ is just a manifestation of what is classically written as “$\Pr(B \mid x \in X)$”. In the case where $\Sigma_1$ is a continuous algebra, the summation just becomes integration. For generic $\sigma$-algebras, I’m not sure how to write things, but in that scenario the top-down categorical definition of a posterior might serve us better anyway, by foregoing the need to write down an explicit expression.
Having defined posterior measures in this way, we see that the posterior measures are good candidates for the arrows of the category of measures. We need only define the composition operation.
## The composition
The composition operation is (perhaps unsurprisingly) the chain rule of measure theory. Given posteriors $m_1 :\mathcal{M}(X,\Sigma_1) \to \mathcal{M}(Y,\Sigma_2)$, and a posterior $m_2:\mathcal{M}(Y,\Sigma_2) \to \mathcal{M}(Z,\Sigma_3)$, we can compose them to get the posterior $m_3 = m_2 \circ m_1:\mathcal{M}(X,\Sigma_1) \to \mathcal{M}(Z,\Sigma_3)$. If we write this composition down using classical notation we find $m_3(C \mid A) = \int_Y m_2(C \mid y) m_1(y \mid A) dy$.
Having defined a collection of objects, the measure cones $\mathcal{M}(\Sigma)$, and arrows, represented by posteriors, we see that we have a category, which I’ll dub ${\rm Meas}$.
## Somebody has been here
Definitely trodden territory. This notion of using posteriors as arrows is discussed at the n-category cafe and at the n-lab where they talk about a theory of “Probabilistic Relations”, by Prakash Panangaden. Apparently this line of thought goes back all the way to the early days of category theory, to an unpublished manuscript Lawvere wrote in the 1962 called “The category of probabilistic mappings”. This manuscript was later elaborated on by M. Giry in “a categorical approach to probability theory” where the functor $(X,\Sigma) \mapsto \mathcal{M}(X,\Sigma)$ serves as the key ingredient to Monad. He then forms the Kleisli category of this monad, which apparently provides some insight into Chapman-Kolmogorov relations. This paper by Giry looks like a lot of fun, but to be honest, as a hobbyist mathematician with a fairly intense (less mathy) day job, I probably wont find the time to give Giry’s work the attention it deserves any time soon.
## Our first functor
We are ready for our first functor, which sends the category of $\sigma$-algebras to ${\rm Meas}$. This is the functor given by “$\Pi$” in Giry’s paper. For each $(X,\Sigma)$ there is a measure cone $\mathcal{M}(X,\Sigma)$, and for each measureable map $f:X \to Y$ there is a posterior measure $m_f:\mathcal{M}(X,\Sigma) \to \mathcal{M}(Y,\Sigma)$ given by $m_f(\mu)(B) = \mu(f^{-1}(B))$, basically sending a measure to its push-forward. Note, this functor does not give all posteriors. The only posteriors of this form have very Dirac-delta feel to them.
## From measures to probabilities
Getting from measures to probabilities is fairly trivial now. We just apply the ray functor (see part I of the series). We’ve already established that $\mathcal{M}(X,\Sigma_1)$ is a cone. Therefore, the notion of a ray is sensible, and we can send each non-zero measure $\mu \in \mathcal{M}(X,\Sigma_1)$ to a ray $R[\mu] \in \mathcal{P}(X,\Sigma_1)$ where $\mathcal{P}(X,\Sigma)$ denotes the ray-space of $\mathcal{M}(X,\Sigma)$. These rays are (very modest generalization of) probability densities on $(X,\Sigma_1)$. This was the content of the last few posts.
I’d like to promote the assignment of “$\mu \mapsto R[\mu]$”” to a functor. To do so, I must figure out how $R$ should handle the arrows in the category of measure cones, the posterior measures. The set of posterior measures between $\mathcal{M}(X,\Sigma_1)$ and $\mathcal{M}(Y,\Sigma_2)$ is itself a convex cone. So again, the notion of a ray is well defined there. The ray of a posterior measure is just what it sounds like, and applying $R$ to the posterior measures in this way gives us a functor to a new category, which we will call ${\rm Prob}$.
## The category of probability theory
In ${\rm Prob}$, the objects are the spaces $\mathcal{P}(X,\Sigma)$ which consist of the ray space of $\mathcal{M}(X,\Sigma)$. The rays themselves correspond with probability densities (see the first post). The arrows correspond with our classical notion of posterior probabilities. The composition operation corresponds with the the chain rule of probability theory.
## Relationship with the classical notions
Classically, when posteriors are introduced, they are only defined after a joint probability has been chosen, and then you will see a definition that looks like “$\Pr(A \mid B) := \Pr(A,B) / \Pr(B)$”. I’ll try to relate what’s written here, to this more classical derivation of a posterior probability.
Let $(X,\Sigma_1)$ and $(Y,\Sigma_2)$ be two measurable spaces. There are two natural projections on $\mathcal{M}(\Sigma_2 \times \Sigma_2)$ to consider:
Given a posterior measure $m : \mathcal{M}_1( \Sigma_1) \to \mathcal{M}(\Sigma_2)$ there is a unique map $s : \mathcal{M}_1( \Sigma_1) \to \mathcal{M}(\Sigma_1 \times \Sigma_2)$ such that :
This map relates a posterior measure to a joint measure, and manifests via the formula $\mu(A,B) := \sigma( \mu_1)(A,B) = m(B|A) \mu_1(A)$ This describes the classical relationship between a posterior density and joint. Translating this over to probabilities is a trivial matter of taking the rays of the everything in sight.
The spirit in which a posterior is defined in this post is quite different. Typically, one views posterior probabilities as derivations from a pre-chosen joint probability. In contrast, in this category theoretic picture, the posteriors are entities which exist independently of choosing any joint probability.
#### Bayes’ theorem?
Seems trivial. We just note that we can swap the role of $\Sigma_1$ and $\Sigma_2$.
### Diffusion and Markov processes
A Markov process, in this context, is nothing but an arrow, $\rho$ from $\mathcal{P}(X,\Sigma)$ to itself. A hidden markov model is nothing but a tuple $(\rho, \gamma)$, where $\rho:\mathcal{P}(X,\Sigma) \to \mathcal{P}(X,\Sigma)$ and $\gamma : X \to Y$, is a measuraeable map to a space of observables. Diffusion results from the observation that $\rho$ is generically not invertible. My guess is that ,$\rho$ is invertible if and only if $\rho(\mu)(E) = \mu( \phi^{-1}(E))$ for some measurable automorphism $\phi:X \to X$.
## Bayesian nets
With all these diagrams and arrows being drawn, it’s tempting to wonder “What does this have to do with probabilistic graphical models and Bayesian networks”. Perhaps there is a relation, but it might not resemble what you (or at least I) would have imagined.
The arrows of a Bayesian network are not posteriors. The arrows of a Bayesian network represent the flow of information in a computation graph. This is probably a good time to clear up another misconception. Bayesian networks are not generalizations of computation graphs. The reverse is true. Bayesian networks are special cases of computation graphs. They correspond to the scenario where all the nodes are probability distributions.
What category theory has to offer to the world of computation graphs is the notion of composition. Given two computation graphs with a single source node and a single target node, we can compose them to get another computation graph with a single source node and a single target node. The composition corresponds with the composition operation in ${\rm Meas}$. After all, these are computation graphs for posterior probabilities.
More generally, we can consider graphs with multiple source nodes, and multiple target nodes, and there is a notion of higher order composition from higher-order category theory which applies in this scenario.
But now I’ve gone so far beyond things I’m qualified to talk about, that I can’t even …
The possibility of physical and mental collapse is now very real. No sympathy for the Devil, keep that in mind. Buy the ticket, take the ride.” ― Hunter S. Thompson, Fear and Loathing in Las Vegas
gif created by televandalist
Theme "Swiss" designed by broccollini
|
{}
|
Chapter 14.4, Problem 24E
### Mathematical Applications for the ...
11th Edition
Ronald J. Harshbarger + 1 other
ISBN: 9781305108042
Chapter
Section
### Mathematical Applications for the ...
11th Edition
Ronald J. Harshbarger + 1 other
ISBN: 9781305108042
Textbook Problem
# Production Suppose that x units of one input and y units of a second input result in P = 40 x + 50 y − x 2 − y 2 − x y units of a product. Determine the inputs x and y that will maximize P. What is the maximum production?
To determine
To calculate: The inputs x and y that will maximize P and the maximum production. Suppose that x units of one input and y units of second input result in P=40x+50yx2y2xy units of a product.
Explanation
Given Information:
The provided function is P=40x+50yx2y2xy.
Formula used:
To calculate relative maxima and minima of the z=f(x,y),
(1) Find the partial derivatives zx and zy.
(2) Find the critical points, that is, the point(s) that satisfy zx=0 and zy=0.
(3) Then find all the second partial derivatives and evaluate the value of D at each critical point, where D=(zxx)(zyy)(zxy)2=2zx22zy2(2zxy)2.
(a) If D>0, then relative minimum occurs if zxx>0 and relative maximum occurs if zxx<0.
(b) If D<0, then neither a relative maximum nor a relative minimum occurs.
For a function f(x,y), the partial derivative of f with respect to x is calculated by taking the derivative of f(x,y) with respect to x and keeping the other variable y constant and the partial derivative of f with respect to y is calculated by taking the derivative of f(x,y) with respect to y and keeping the other variable x constant. The partial derivative of f with respect to x is denoted by fx and with respect to y is denoted by fy.
For a function z(x,y), the second partial derivative,
(1) When both derivatives are taken with respect to x is zxx=2zx2=x(zx).
(2) When both derivatives are taken with respect to y is zyy=2zy2=y(zy).
(3) When first derivative is taken with respect to x and second derivative is taken with respect to y is zxy=2zyx=y(zx).
(4) When first derivative is taken with respect to y and second derivative is taken with respect to x is zyx=2zxy=x(zy).
Power of x rule for a real number n is such that, if f(x)=xn then f(x)=nxn1.
Constant function rule for a constant c is such that, if f(x)=c then f(x)=0.
Coefficient rule for a constant c is such that, if f(x)=cu(x), where u(x) is a differentiable function of x, then f(x)=cu(x).
Calculation:
Consider the problem, x units of one input and y units of second input result in P=40x+50yx2y2xy units of a product.
The provided function is P(x,y)=40x+50yx2y2xy.
Use the power of x rule for derivatives, the constant function rule, and the coefficient rule,
Thus,
Px=0402xy=0y=2x40y=402x
And,
Py=0502yx=0x+2y=50
Now, calculate value of x and y.
Substitute 402x for y in x+2y=50.
x+2(402x)=50x+804x=503x=30x=10
Since, y=402x, thus, y=402(10)=4020=20
### Still sussing out bartleby?
Check out a sample textbook solution.
See a sample solution
#### The Solution to Your Study Problems
Bartleby provides explanations to thousands of textbook problems written by our experts, many with advanced degrees!
Get Started
|
{}
|
Public Group
This topic is 1746 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.
Recommended Posts
Hi, about a week ago I made a program that calculated quadratic formulas. Now, I'm supposed to change that program and use a function to the calculations. Problem is, it prints both x1 and x2 as "-1.#IND".
I've googled around and apparently it happens when you divide by zero, but a isn't 0.
#include "../../std_lib_facilities.h"
void quadratic(double a, double b, double c){ // Calculate and print x
double x1 = (-b + sqrt(b * b - 4 * a * c)) / (2 *a);
cout << "X1 == " << x1 << endl;
double x2 = (-b - sqrt(b * b - 4 * a * c)) / (2 *a);
cout << "X2 == " << x2 << endl;
}
int main()
{
double a = 1, b = 1, c = 1; // Input loop
cout << "This program will help you solve ax (squared) + bx + c = 0\nEnter a, b and c\n";
while (cin >> a && cin >> b && cin >> c)
}
Share on other sites
It can also happen if you take the square root of a negative number, which happens if your polynomial doesn't have any real roots.
Share on other sites
Also if a may be zero (straight line), then you need to handle that because the "/ (2 * a)" becomes divide by zero.
Share on other sites
Ah, thanks, I just had to make sure b*b > 4(ac).
Share on other sites
The more usual way would be to just take the contents of sqrt, calculate it and check it for negative.
assert(a != 0);//if may be true, do something about it
double d = b * b - 4 * a * c;
if (d < 0)
{
return; //no root
}
double dSqrt = std::sqrt(d);
double x1 = (-b + dSqrt) / (2 * a);
double x2 = (-b - dSqrt) / (2 * a);
Edited by SyncViews
Share on other sites
The technical word for "the contents of sqrt" is the discriminant.
Share on other sites
Besides this you missed one solution here as a quadratic can have only one real root as well when the discriminant is zero.
Edited by NightCreature83
Share on other sites
Well it doesn't really miss the solution, it just prints the same one out twice, and SyncView's code carries on if d == 0.
SyncView later storing sqrt(d) in an int isn't a great plan though ;)
Share on other sites
Fixed :) . Fortunately most compilers will warn about a double to int implicit conversion.
While d == 0 in some cases is useful, I think in practice most of the time your going to end up with just being near zero due to rounding errors at various stages, including the inputs them selves. If the single root situation is of interest for whatever you are doing, you will need to decide how close is close enough.
• 23
• 10
• 19
• 16
• 14
|
{}
|
## LaTeX: Numberless lines in fitch.sty
To write natural deduction proofs in LaTeX, I use a package called fitch.sty. The package was written by Johan W. Klüwer and offers a nice clean way to typeset Fitch-style proofs. He provides a nice example:
Lovely. However, in some of my proofs, I wanted to have lines without numbers because they featured information that was not strictly part of the proof. For instance, like others, I commonly add a line that indicates the formula we’re out to prove after the list of premises. This is especially useful in teaching proofs. That line, I don’t want numbered — instead I want the counter to skip that line and continue after it, like so:
I had to dig around in the fitch.sty file itself to figure out how to do this, since there’s not really any documentation outside of it. I figured I’d share what I did for anyone facing the same issue.
Here’s what you do. Instead of beginning a line with “\fa” or something like that, add a line like this:
\ftag{~}{\vline\hspace{\fitchindent} CONTENT } \\
Where CONTENT is replaced by whatever you want to have on that line. The exact code for the my ‘∴ B’ line, for example, is:
\ftag{~}{\vline\hspace{\fitchindent} \fbox{$\therefore~ B$}} \\
And that’s all there is to it. I hope this helps someone looking to do the same thing as I was.
Happy typesetting!
## Marcus Aurelius: The Character of Antoninus
In Book 6 of his Meditations, Marcus Aurelius makes some remarks about the character of Antoninus Pius, his predecessor as Emperor of Rome, and his adoptive father. Marcus warns himself against being seen as like Julius Caesar, and says to avoid this he must live a good and humble life and conduct his duties in such a manner, as a follower of philosophy. Such a proper lifestyle can be seen in the life of Antoninus.
Marcus describes Antoninus as having a “keenness for logical action” and an “equable temper” (54). This is to say that his adoptive father maintained a calm disposition in his duties and private life. He was not rash in his behaviour, but rather thought his actions through with great care. Here the contrast with Caesar can be seen. Whereas Caesar was power-hungry and with a great ego, Antoninus was much more reasoned in his actions and had a “lack of vainglory” (54), a formidable and unusual trait for an emperor to have.
That “keenness” for a reasoned approach is again evident as Marcus describes Antonius’ “ambition to understand affairs” (54). Again, Antoninus is not seen to be acting on his intuition but to carefully take the time to understand what is going on around him, and apply careful thought prior to action. Rather than merely rely on others for information, Antoninus wanted not only to know the truth of the matter, but to “understand”, as Marcus says. All possible choices before Antoninus were carefully and completely examined before one was chosen. “He never rushed things.” (54).
Marcus also praises Antoninus’ disposition towards other people, especially in his public life. When he was criticized publicly, he not only “tolerated” challenges to his views, but he “was glad” when presented with a more favourable view to his own position. To those who were wrong, or offered only negative commentary without foundation or suggestion for improvement, Antoninus “endured” their scorn. Neither slander nor rumour had any effect on him. He also maintained strong, “unchanging” friendships (54). That is, he did not abandon his friends, nor was he quick to end a friendship over petty matters.
In his duties of public office, Antoninus is said to have enjoyed his work to the point of being completely focused on it for long periods of time. He was “energetic” when working and continued to work until late, taking no breaks at all. His duties as a statesman were guided by justice and a goal of protecting the people, as Marcus lists among the virtues one must seek in his position.
Marcus also comments on Antonius’ spiritual lifestyle. Antoninus is described as pious, having respect for the gods and acting in accordance with their laws. Marcus also makes a curious remark, that Antoninus “was religious but free from superstition” (55). In this sense, Antoninus would have characterized the humbleness and reverence that come with piety and the proper following of a religion, along with its moral code. However, more petty or sensational aspects that often accompany religious belief, such as certain types of ritual and accompanying fears of retribution, would not have formed a part of Antoninus’ thought. Thus, he was able to obtain virtue from his beliefs without hinderance.
In all other areas of life, Antoninus demonstrated this same humility. Happy to live simply, he did not need elaborate housing or clothing. His diet was “scanty” (54), which both showed this humility and allowed him to to focus on work for longer periods of time. He also required “little in the way of . . . servants” (54). These aspects of his life again contrast him with Caesar, who was known to enjoy a lavish lifestyle and demand much of those around him.
Marcus’ description here follows one earlier in Book 1 of his text, where he tells of his adoptive father’s advice to follow such a lifestyle, and to “honor genuine philosophers” (7). Both there and in this section, what is good is to put proper philosophical and moral thought and action above one’s selfish, personal inclinations. Marcus tells himself that being Antoninus’ “disciple” (55) in all of these traits will leave him with a clear conscious at death, knowing that he had lived a good life.
Source:
Marcus Aurelius. The Meditations. Trans. G. M. A. Grube. Indianapolis: Hackett, 1983.
## Sextus Empiricus: No Definition of Man
In Book I of his traditionally-titled Against the Logicians (Book VII of Adversus Mathematicos), Sextus Empiricus presents a critique of how past philosophers have attempted to define the human being. He notes that these philosophers would pass off a definition as an “explanation of man” (132), a strategy that, for Sextus, would surely fail.
First is the account that goes back to Aristotle, though Sextus does not cite him directly. He remarks that some philosophers define man as a “‘rational, mortal animal receptive of thought and knowledge’” (132). Sextus points out that this does not conjure up man himself, but rather lists of some of his attributes.
With respect to attributes, Sextus says that there are two distinct types, those which are “inseparable” (132) from the thing which has them and others which “can be separated” (132) from the attributed object. Those which cannot be separated from the object include its extended dimensions, for an extended body is inconceivable without such attributes. Separated attributes, for Sextus, include activities or potential activities which an individual can take part in. For instance, speaking and sitting are attributes of the human being, since these are things which “happen to” people, “but not continuously” (132).
However, as Sextus states, neither the separable nor the inseparable attributes are identical to the thing that bears them. Hence, the Aristotelian definition fails to define the human being, since it only recounts some of humankind’s attributes: that human beings are animals, an inseparable attribute, and that human beings possess the separable attributes of “‘reasoning’ and ‘possessing knowledge’” (133).
For Sextus, the other component of the given definition, that human beings are mortal, is not an attribute at all. He remarks that mortality is not something that is ever an attribute of a human being, since what makes a human seemingly mortal, death, is never a part of the human but something that happens after the human ceases to exist. One is never at the same time human and dead, hence, humans do not have mortality as an attribute in Sextus’ language.
Sextus also makes the point that none of these attributes uniquely give us the idea of the human being. For instance, being rational or possessing knowledge are also attributes of the gods, while many animals exist besides human beings. Of course, such a definition does not mean to imply that each of these attributes are uniquely true of humans, rather, it is “all of them in conjunction” that present the human being.
To this, Sextus asks how these various attributes can be united to produce the human without also “exceeding” or “falling short” (134) of what human beings are. After all, human beings are not at all times rational or in possession of knowledge, nor do they possess mortality as an attribute because “death is not yet present” (134). So in this case, listing all of these attributes at any time may exclude some human beings, namely those who are not currently reasoning, possessing knowledge, or even simply still living. Hence, this definition exceeds that of human beings. Similarly, these are not the only attributes of human beings, so the definition in another sense falls short of producing the human.
The definition of man from Platonic sources also falls under Sextus’ scrutiny. He says that this definition describes man as a “‘featherless, two-footed, flat-nailed animal, receptive of political science’” (134). Such a definition fails to capture the human being for the same reasons as the Aristotelian one, namely that it gives a list of attributes, some of which are not constant in humans. Further, Sextus calls this definition “even worse than the others” (134) because it contains some negative attributes, such as ‘featherless’, along with positive ones, such as ‘twofooted’. That is, some of what is in this definitions are not attributes of humans, but an account of what are not human attributes.
Since no definition like those given can accurately capture the idea of human beings, or produce the “conception of particular men” (132), Sextus concludes that it is impossible to properly define the human being. Humans are, hence, left without a proper conception of themselves.
Source:
Sextus Empricius. Selections from the Major Writings on Scepticism, Man, & God. Ed. Philip P. Hallie. Trans. Sanford G. Etheridge. Indianapolis, IN: Hackett, 1985. pp. 132-134.
## Leibniz: Space as a Relation and Absurd Otherwise
In his third letter of correspondence with Samuel Clarke, Leibniz outlines his position on the nature of space. Contrary to Newton, and Clarke who defends him, Leibniz holds that space is “something purely relative” (14), that space is not a substance or a thing that exists, but rather the relationship between the objects it seems to contain.
In order to support this claim, Leibniz relies on his principle of sufficient reason, which states “that nothing happens without a sufficient reason why it should be so rather than otherwise” (14). His axiom is essentially that nothing is arbitrary, and for Leibniz, this means that all things are the product of God’s reason. Leibniz’s argument proceeds by reductio ad absurdum:
1. Suppose that there is absolute space.
2. Whence, when God placed objects within space, there was no reason for him to place objects in a particular area of space and not in another, or in a different orientation. Hence, the placement of objects in the universe is arbitrary.
3. But, according to the principle of sufficient reason, nothing is arbitrary.
4. But this is absurd, so (1) must be false, and there is no absolute space.
If one accepts the principle of sufficient reason, it seems that one is committed to accepting the argument. Leibniz argues that as long as space is an absolute entity, it is impossible to imagine that the placement of objects within it is anything but arbitrary. The contents of the universe could be rotated by infinitely many degrees inconsequentially, and the reason that it takes any particular orientation cannot be explained causally. Notably, this does not entirely depend on Leibniz’s metaphysical claims about God. Although, for Leibniz, it is through God’s reason that things happen, the principle of sufficient reason can also be interpreted as referring to causality, claiming that nothing is uncaused, entirely spontaneous or arbitrary.
Hence, if space is absolute then the orientation of matter within it is arbitrary. This directly contradicts the accepted principle, and so space must not be absolute.
The fact that such rotation in the universe’s orientation would not cause changes to the physical universe is also mentioned by Leibniz, who asserts that the difference between orientations would be indiscernible (14). As Leibniz points out in a later letter, to “suppose two things indiscernible is to suppose the same thing under two names” (22). If all predicates corresponding to one object also correspond to another (that is, two objects share identical properties), then those objects are identical. This principle is one of second-order logic and can be symbolically represented as:
• xy[∀P(Px ↔ Py) → x = y]
Since there could be nothing said about one orientation that differs from another, where a and b are any two universe orientations,
• ∀P(Pa ↔ Pb),
hence,
• (a = b).
The identity of the different universe orientations prompts Leibniz to write that “there is no room to inquire after a reason for the preference of one to the other” (15). This can be taken to mean that the very notion of absolute space is therefore meaningless, since we are left with infinitely many configurations and no reason to prefer any one.
It seems to me that there’s a refutation to this last point. If all of the possible orientations of matter in the universe are in fact identical, then there is in fact reason to for the selection of the current orientation of the universe. For if all universe orientations are identical, then there is exactly one universe orientation – that is, the orientation of the universe is the necessary one. The choice of orientation is necessary rather than arbitrary and therefore it is not in conflict with the principle of sufficient reason.
Source: Leibniz, G. W. and Samuel Clarke. Correspondence. Ed. Roger Ariew. Indianapolis: Hackett, 2000.
## Lucretius on Matter and the Void
In Book I of On the Nature of Things[1], Lucretius provides arguments for the existence of two main things that exist: matter and the void. Further, he argues that there are no other types of things besides these.
First, Lucretius asserts that matter is known to exist by means of sensory perception. We see matter, we interact with it, and thus it must exist. He argues immediately for empiricism by saying that sensory perception must be the “unshakable foundation” (423) from which an epistemology begins. Otherwise, he says, any talk of what is unseen is meaningless, for it is only in contrast with sensory perception that we can reason about anything that is outside of our view. That is, we cannot make any sense of talk about what is hidden from view without having a view in the first place, and thus what we see in our view must be the case. So, matter exists.
Secondly, we observe some important traits about the matter we see. First, it is always situated somewhere. Second, it can be moved from one location to another. Both of these require the existence of space, what he calls the void, for things always move or are located in something. Lucretius refers back to a few lines before this passage[2], in which he has argued that without space existing between material objects, their force of obstruction would constantly be acting upon each other and there would never be movement at all. He also, in these earlier lines, anticipates an objection on the grounds that fish swim through water seemingly unobstructed. Here, Lucretius argues that water must give way and create space for the fish, thus in order for there to be movement the space must be ontologically present, in modern terms.
Next, Lucretius argues that there must be nothing else besides matter and void. His reasoning is simply that anything else that one may describe, in an effort to posit a third constituent of being, can be shown to be either matter or void. This is done by Lucretius by asking whether or not this new entity is tangible. If it is, and is “susceptible of even the lightest and faintest touch” (433), then it must add to the aggregate matter of the universe and thus count as matter itself. If it is not tangible, however, then it is nothing but “that empty space which we call void” (438). This amounts to the claim that everything exists is either tangible, and is therefore matter, for everything that is tangible is matter, or is intangible, and is therefore void, for everything that is intangible is empty space, that is, void.
Lucretius’ argument for the existence of matter is an ontological an epistemological argument, stating that matter must exist because we cannot meaningfully talk about anything besides matter without first admitting matter into our ontology. However, it is somewhat anthropocentric in its approach, since it relies on what human beings, or perhaps any sentient being, can talk about or count as existing, not what fundamentally exists independently. In this sense, Lucretius is merely categorizing entities into two groups, based on whether or not they are tangible. Since everything is either tangible or not tangible, due to the laws of non-contradiction and the excluded middle, everything can rightfully be said to fall into one of these two categories.
One can rightfully be sceptical of Lucretius’ claim that everything that is intangible is empty space. The tradition of philosophy before and after him posit many so-called intangible objects which are thought to be more than the void. Among them are the forms, or universals, which are thought by Plato to have greater reality than material things. Meanwhile, talk of God or gods both before and after Lucretius often involves an immaterial but certainly active being. Lucretius goes on, beyond this brief passage, to deny that anything can act upon matter without being corporeal[3], but more work must be done to overthrow alternative thought on this matter.
Yet, we can still praise Lucretius for a simple but elegant approach to two formidable views. The simple approach to an epistemological foundation predates the rampant empiricism of the modern era, and even reminds one of Quine‘s naturalized epistemology in its reductionist (and dismissive) approach. The view meanwhile that space counts as some entity in itself, and is needed for the situation and locomotion of matter is one common in modern science, if still debated. One can easily read contemporary developments into Lucretius’ ancient words.
[1] T. Lucretius Carus. On the Nature of Things. Trans. Martin Ferguson Smith. Indianapolis: Hackett, 2001. Lines 419-440.
[2] Lines 335-345 and 370-383.
[3] Lines 440-444.
## Leibniz: The Best of All Possible Worlds
According to Leibniz, the actual world is the best of all possible worlds. He outlines a simple argument for this conclusion in The Monadology, §§53-55. The argument proceeds as follows:
1. God has the idea of infinitely many universes.
2. Only one of these universes can actually exist.
3. God’s choices are subject to the principle of sufficient reason, that is, God has reason to choose one thing or another.
4. God is good.
5. Therefore, the universe that God chose to exist is the best of all possible worlds.
The argument can be broken down into three parts. Premises (1) and (2) say that God has a choice to make, for there are infinitely many possible worlds, and only one can be chosen. Premises (3) and (4) state that God chooses things with reason (this is the principle of sufficient reason, that is that all things that occur occur for sufficient reasons which fully explain them), and is good – hence, when God makes choices, God chooses that which is most good, or most perfect. Finally, the conclusion puts these two ideas, concluding that in this choice, as with all other choices, God chose that which is best, the best of all possible worlds which could have existed.
The argument is valid, for if there is are infinitely-many choices, and a good, reasonable God has made a choice of one, then that universe is the best. For, if God chose another less-good universe, then God would not be good, God would lack the idea of some universe, or God would not be reasonable, and some premises would be false. (Arguably, one could claim that the argument is invalid on the grounds that its premises may yield a false conclusion if the goodness of universes were identical, and that God did not choose to make any world actual. Clearly, since we know of an existing universe, the claim that none exists would be false, but it is not logically false and hence the argument could have weakness here. However, we will grant Leibniz the tacit assumption that “a universe exists” is a premise.)
Leibniz explains that the reason for the choice of a world is in its “fitness, or in the degree of perfection that these worlds contain” (76). Hence, the suitability for a world for selection is a function of its level of perfection, and God, being perfect, would choose that world which is most perfect.
Premise (1) follows from the notion of God. God is, by definition all-knowing – a view defended in §48 – and, hence, has the knowledge of what any configuration of the universe would be. So, if God exists, premise (1) is true. Leibniz argues that God must exist in §§44-45 with the argument that “he must exist if he is possible. And since nothing can prevent the possibility of what is without limits, without negation and consequently without contradiction” (74) then God exists. The argument can be symbolized by modal logic as (◊G → □G), ¬□¬G ∴ G, where G means “God exists”, and is valid.
One may hope to attack premise (2) with the claim that there could be multiple worlds. For if God is a transcendent being, beyond this world, it would seem that he could create all of his possible worlds independently from one another. It may be argued that God would never create anything imperfect, as the other worlds are said to be, but imperfections exist within the actual world even if they are in order with universal harmony. It may be the case that the entire collection of worlds, including the most perfect one, is itself perfect. It is not clear why Leibniz would deny this possibility, though it should also be noted that in this case, we may extend “world” to mean the set of all universes which God is again supreme over, and say that this set is the best of all possible worlds, which would have to be the case since it is the only set in existence.
Premises (3) and (4) seem less controversial. God is defined as being the “ultimate reason” (73) in §38, and hence God is the sufficient reason for things existing. God’s goodness is explained by his perfection in §41.
Hence, it follows from these premises that the actual world is the best of all possible worlds.
Source: Leibniz, G. W. Discourse on Metaphysics and Other Essays. Trans. Daniel Garber and Roger Ariew. Indianapolis: Hackett, 1991.
|
{}
|
# Motion of a particle given position vector.
## Homework Statement
A position vector of a particle at a time t is r=icost +jsint +kt ; show the speed and the magnitude of the acceleration is constant. Describe the motion.
v = dr/dt
a = dv/dt
## The Attempt at a Solution
Could someone let me know if I am doing this correctly?
I derived the position to find the velocity:
v = dr/dt = -isint +jcost + 1k
Then derived the velocity :
a = dv/dt = -icost -jsint
Then found the magnitude of the acceleration:
mag(a) = sqrt ( cos^2(t) + sin^2(t)) = 1 , which is constant.
Motion- increasing oscillation? How would I show this?
Thanks!
Related Introductory Physics Homework Help News on Phys.org
Don't forget to find the speed (magnitude of the velocity).
Think about just the two-dimensional $x,y$ motion. What kind of motion would that be? Then notice that the $z$ component just linearly increases in one direction. What kind of shape will be created this way? And how will your particle move along that three dimensional shape?
Don't forget to find the speed (magnitude of the velocity).
Think about just the two-dimensional $x,y$ motion. What kind of motion would that be? Then notice that the $z$ component just linearly increases in one direction. What kind of shape will be created this way? And how will your particle move along that three dimensional shape?
I took the magnitude of the velocity and got sqrt( sin^2 + cos^2 +1) so sqrt(2) , so it would also be constant.
Would the particle just be moving around a circle? How could I prove this?
Thanks!
Well, yes for the two-dimensional case it would be circular motion. If you don't recognize the form, try picking various values of $t$ and plotting them on a two dimensional graph to see it.
Is it supposed to look like a spring? And was I correct about the velocity?
Thank you for the help.
Exactly, it's the shape of a helix. The motion is circular, but it's traveling upwards along the surface of a cylinder with time.
And yes, you were right about the speed.
Awesome! Thanks!
|
{}
|
# 4-polytope
(Redirected from Polychoron)
Graphs of the six convex regular 4-polytopes
{3,3,3} {3,3,4} {4,3,3}
5-cell
Pentatope
4-simplex
16-cell
Orthoplex
4-orthoplex
8-cell
Tesseract
4-cube
{3,4,3} {5,3,3} {3,3,5}
24-cell
Octaplex
600-cell
Tetraplex
120-cell
Dodecaplex
In geometry, a 4-polytope (sometimes also called a polychoron,[1] polycell, or polyhedroid) is a four-dimensional polytope.[2][3] It is a connected and closed figure, composed of lower-dimensional polytopal elements: vertices, edges, faces (polygons), and cells (polyhedra). Each face is shared by exactly two cells. The 4-polytopes were discovered by the Swiss mathematician Ludwig Schläfli before 1853.[4]
The two-dimensional analogue of a 4-polytope is a polygon, and the three-dimensional analogue is a polyhedron.
Topologically 4-polytopes are closely related to the uniform honeycombs, such as the cubic honeycomb, which tessellate 3-space; similarly the 3D cube is related to the infinite 2D square tiling. Convex 4-polytopes can be cut and unfolded as nets in 3-space.
## Definition
A 4-polytope is a closed four-dimensional figure. It comprises vertices (corner points), edges, faces and cells. A cell is the three-dimensional analogue of a face, and is therefore a polyhedron. Each face must join exactly two cells, analogous to the way in which each edge of a polyhedron joins just two faces. Like any polytope, the elements of a 4-polytope cannot be subdivided into two or more sets which are also 4-polytopes, i.e. it is not a compound.
## Geometry
The convex regular 4-polytopes are the four-dimensional analogues of the Platonic solids. The most familiar 4-polytope is the tesseract or hypercube, the 4D analogue of the cube.
The convex regular 4-polytopes can be ordered by size as a measure of 4-dimensional content (hypervolume) for the same radius. Each greater polytope in the sequence is rounder than its predecessor, enclosing more content[5] within the same radius. The 4-simplex (5-cell) is the limit smallest case, and the 120-cell is the largest. Complexity (as measured by comparing configuration matrices or simply the number of vertices) follows the same ordering.
Regular convex 4-polytopes
Symmetry group A4 B4 F4 H4
Name 5-cell
Hyper-tetrahedron
5-point
16-cell
Hyper-octahedron
8-point
8-cell
Hyper-cube
16-point
24-cell
24-point
600-cell
Hyper-icosahedron
120-point
120-cell
Hyper-dodecahedron
600-point
Schläfli symbol {3, 3, 3} {3, 3, 4} {4, 3, 3} {3, 4, 3} {3, 3, 5} {5, 3, 3}
Coxeter mirrors
Mirror dihedrals 𝝅/2 𝝅/3 𝝅/3 𝝅/3 𝝅/2 𝝅/2 𝝅/2 𝝅/3 𝝅/3 𝝅/4 𝝅/2 𝝅/2 𝝅/2 𝝅/4 𝝅/3 𝝅/3 𝝅/2 𝝅/2 𝝅/2 𝝅/3 𝝅/4 𝝅/3 𝝅/2 𝝅/2 𝝅/2 𝝅/3 𝝅/3 𝝅/5 𝝅/2 𝝅/2 𝝅/2 𝝅/5 𝝅/3 𝝅/3 𝝅/2 𝝅/2
Graph
Vertices 5 8 16 24 120 600
Edges 10 24 32 96 720 1200
Faces 10 triangles 32 triangles 24 squares 96 triangles 1200 triangles 720 pentagons
Cells 5 tetrahedra 16 tetrahedra 8 cubes 24 octahedra 600 tetrahedra 120 dodecahedra
Tori 1 5-tetrahedron 2 8-tetrahedron 2 4-cube 4 6-octahedron 20 30-tetrahedron 12 10-dodecahedron
Inscribed 120 in 120-cell 1 16-cell 2 16-cells 3 8-cells 25 24-cells 10 600-cells
Great polygons 2 𝝅/2 squares x 3 4 𝝅/2 rectangles x 3 4 𝝅/3 hexagons x 4 12 𝝅/5 decagons x 6 50 𝝅/15 dodecagons x 4
Petrie polygons 1 pentagon 1 octagon 2 octagons 2 dodecagons 4 30-gons 20 30-gons
Isocline polygons 1 {8/2}=2{4} x {8/2}=2{4} 2 {8/2}=2{4} x {8/2}=2{4} 2 {12/2}=2{6} x {12/6}=6{2} 4 {30/2}=2{15} x 30{0} 20 {30/2}=2{15} x 30{0}
Long radius ${\displaystyle 1}$ ${\displaystyle 1}$ ${\displaystyle 1}$ ${\displaystyle 1}$ ${\displaystyle 1}$ ${\displaystyle 1}$
Edge length ${\displaystyle {\sqrt {\tfrac {5}{2}}}\approx 1.581}$ ${\displaystyle {\sqrt {2}}\approx 1.414}$ ${\displaystyle 1}$ ${\displaystyle 1}$ ${\displaystyle {\tfrac {1}{\phi }}\approx 0.618}$ ${\displaystyle {\tfrac {1}{\phi ^{2}{\sqrt {2}}}}\approx 0.270}$
Short radius ${\displaystyle {\tfrac {1}{4}}}$ ${\displaystyle {\tfrac {1}{2}}}$ ${\displaystyle {\tfrac {1}{2}}}$ ${\displaystyle {\sqrt {\tfrac {1}{2}}}\approx 0.707}$ ${\displaystyle 1-\left({\tfrac {\sqrt {2}}{2\phi {\sqrt {3}}}}\right)^{2}\approx 0.936}$ ${\displaystyle 1-\left({\tfrac {1}{2\phi {\sqrt {3}}}}\right)^{2}\approx 0.968}$
Area ${\displaystyle 10\left({\sqrt {\tfrac {8}{9}}}\right)\approx 9.428}$ ${\displaystyle 32\left({\sqrt {\tfrac {3}{16}}}\right)\approx 13.856}$ ${\displaystyle 24}$ ${\displaystyle 96\left({\sqrt {\tfrac {3}{16}}}\right)\approx 41.569}$ ${\displaystyle 1200\left({\tfrac {\sqrt {3}}{8\phi ^{2}}}\right)\approx 99.238}$ ${\displaystyle 720\left({\tfrac {25+10{\sqrt {5}}}{8\phi ^{4}}}\right)\approx 621.9}$
Volume ${\displaystyle 5\left({\tfrac {5{\sqrt {5}}}{24}}\right)\approx 2.329}$ ${\displaystyle 16\left({\tfrac {1}{3}}\right)\approx 5.333}$ ${\displaystyle 8}$ ${\displaystyle 24\left({\sqrt {\tfrac {2}{9}}}\right)\approx 11.314}$ ${\displaystyle 600\left({\tfrac {1}{3\phi ^{3}{\sqrt {8}}}}\right)\approx 16.693}$ ${\displaystyle 120\left({\tfrac {2+\phi }{2\phi ^{3}{\sqrt {8}}}}\right)\approx 18.118}$
4-Content ${\displaystyle {\tfrac {\sqrt {5}}{24}}\left({\tfrac {\sqrt {5}}{2}}\right)^{4}\approx 0.146}$ ${\displaystyle {\tfrac {2}{3}}\approx 0.667}$ ${\displaystyle 1}$ ${\displaystyle 2}$ ${\displaystyle {\tfrac {{\text{Short}}\times {\text{Vol}}}{4}}\approx 3.907}$ ${\displaystyle {\tfrac {{\text{Short}}\times {\text{Vol}}}{4}}\approx 4.385}$
## Visualisation
Example presentations of a 24-cell
Sectioning Net
Projections
Schlegel 2D orthogonal 3D orthogonal
4-polytopes cannot be seen in three-dimensional space due to their extra dimension. Several techniques are used to help visualise them.
Orthogonal projection
Orthogonal projections can be used to show various symmetry orientations of a 4-polytope. They can be drawn in 2D as vertex-edge graphs, and can be shown in 3D with solid faces as visible projective envelopes.
Perspective projection
Just as a 3D shape can be projected onto a flat sheet, so a 4-D shape can be projected onto 3-space or even onto a flat sheet. One common projection is a Schlegel diagram which uses stereographic projection of points on the surface of a 3-sphere into three dimensions, connected by straight edges, faces, and cells drawn in 3-space.
Sectioning
Just as a slice through a polyhedron reveals a cut surface, so a slice through a 4-polytope reveals a cut "hypersurface" in three dimensions. A sequence of such sections can be used to build up an understanding of the overall shape. The extra dimension can be equated with time to produce a smooth animation of these cross sections.
Nets
A net of a 4-polytope is composed of polyhedral cells that are connected by their faces and all occupy the same three-dimensional space, just as the polygon faces of a net of a polyhedron are connected by their edges and all occupy the same plane.
## Topological characteristics
The topology of any given 4-polytope is defined by its Betti numbers and torsion coefficients.[6]
The value of the Euler characteristic used to characterise polyhedra does not generalize usefully to higher dimensions, and is zero for all 4-polytopes, whatever their underlying topology. This inadequacy of the Euler characteristic to reliably distinguish between different topologies in higher dimensions led to the discovery of the more sophisticated Betti numbers.[6]
Similarly, the notion of orientability of a polyhedron is insufficient to characterise the surface twistings of toroidal 4-polytopes, and this led to the use of torsion coefficients.[6]
## Classification
### Criteria
Like all polytopes, 4-polytopes may be classified based on properties like "convexity" and "symmetry".
### Classes
The following lists the various categories of 4-polytopes classified according to the criteria above:
The truncated 120-cell is one of 47 convex non-prismatic uniform 4-polytopes
Other convex 4-polytopes:
The regular cubic honeycomb is the only infinite regular 4-polytope in Euclidean 3-dimensional space.
Infinite uniform 4-polytopes of Euclidean 3-space (uniform tessellations of convex uniform cells)
Infinite uniform 4-polytopes of hyperbolic 3-space (uniform tessellations of convex uniform cells)
• 41 unique dual convex uniform 4-polytopes
• 17 unique dual convex uniform polyhedral prisms
• infinite family of dual convex uniform duoprisms (irregular tetrahedral cells)
• 27 unique convex dual uniform honeycombs, including:
Others:
The 11-cell is an abstract regular 4-polytope, existing in the real projective plane, it can be seen by presenting its 11 hemi-icosahedral vertices and cells by index and color.
These categories include only the 4-polytopes that exhibit a high degree of symmetry. Many other 4-polytopes are possible, but they have not been studied as extensively as the ones included in these categories.
• Regular 4-polytope
• 3-sphere – analogue of a sphere in 4-dimensional space. This is not a 4-polytope, since it is not bounded by polyhedral cells.
• The duocylinder is a figure in 4-dimensional space related to the duoprisms. It is also not a 4-polytope because its bounding volumes are not polyhedral.
## References
### Notes
1. ^ N.W. Johnson: Geometries and Transformations, (2018) ISBN 978-1-107-10340-5 Chapter 11: Finite Symmetry Groups, 11.1 Polytopes and Honeycombs, p.224
2. ^ Vialar, T. (2009). Complex and Chaotic Nonlinear Dynamics: Advances in Economics and Finance. Springer. p. 674. ISBN 978-3-540-85977-2.
3. ^ Capecchi, V.; Contucci, P.; Buscema, M.; D'Amore, B. (2010). Applications of Mathematics in Models, Artificial Neural Networks and Arts. Springer. p. 598. doi:10.1007/978-90-481-8581-8. ISBN 978-90-481-8580-1.
4. ^ Coxeter 1973, p. 141, §7-x. Historical remarks.
5. ^ Coxeter 1973, pp. 292–293, Table I(ii): The sixteen regular polytopes {p,q,r} in four dimensions: [An invaluable table providing all 20 metrics of each 4-polytope in edge length units. They must be algebraically converted to compare polytopes of unit radius.]
6. ^ a b c Richeson, D.; Euler's Gem: The Polyhedron Formula and the Birth of Topoplogy, Princeton, 2008.
7. ^ Uniform Polychora, Norman W. Johnson (Wheaton College), 1845 cases in 2005
### Bibliography
• H.S.M. Coxeter:
• Coxeter, H.S.M. (1973) [1948]. Regular Polytopes (3rd ed.). New York: Dover.
• H.S.M. Coxeter, M.S. Longuet-Higgins and J.C.P. Miller: Uniform Polyhedra, Philosophical Transactions of the Royal Society of London, Londne, 1954
• Kaleidoscopes: Selected Writings of H.S.M. Coxeter, edited by F. Arthur Sherk, Peter McMullen, Anthony C. Thompson, Asia Ivic Weiss, Wiley-Interscience Publication, 1995, ISBN 978-0-471-01003-6 [1]
• (Paper 22) H.S.M. Coxeter, Regular and Semi Regular Polytopes I, [Math. Zeit. 46 (1940) 380–407, MR 2,10]
• (Paper 23) H.S.M. Coxeter, Regular and Semi-Regular Polytopes II, [Math. Zeit. 188 (1985) 559–591]
• (Paper 24) H.S.M. Coxeter, Regular and Semi-Regular Polytopes III, [Math. Zeit. 200 (1988) 3–45]
• J.H. Conway and M.J.T. Guy: Four-Dimensional Archimedean Polytopes, Proceedings of the Colloquium on Convexity at Copenhagen, page 38 und 39, 1965
• N.W. Johnson: The Theory of Uniform Polytopes and Honeycombs, Ph.D. Dissertation, University of Toronto, 1966
• Four-dimensional Archimedean Polytopes (German), Marco Möller, 2004 PhD dissertation [2]
|
{}
|
# Using a black box MCMC algorithm as a proposal distribution
Let's say I have some MCMC algorithm implemented as a function, black_box(x), which generates samples from $P(x)$ when run in a chain. I would now like to sample from $P(x)G(x)$. Is it possible to use black_box(x) as proposal distribution and then use Independent Metropolis, i.e.:
1) Let x' = black_box(x).
2) Accept with probability min(1, G(x') / G(x))
3) Loop to 1)
How can I prove that this works?
First attempt
Let B(x -> x') be the probability that black_box(x) returns x'. Assuming that black_box(x) implements a Metropolis-Hastings algorithm, we know that it fulfills detailed balance, i.e.
$\frac{B(x \rightarrow x')}{B(x' \rightarrow x)} = \frac{P(x')}{P(x)}$
If we choose our acceptance probability as
$A(x \rightarrow x') = \min(1, \frac{G(x')}{G(x)})$
the overall transition probability fulfills detailed balance since
$\frac{B(x \rightarrow x')A(x \rightarrow x')}{B(x' \rightarrow x)A(x' \rightarrow x)} = \frac{P(x')\min(1, G(x') / G(x))}{P(x)\min(1, G(x) / G(x'))} = \frac{P(x')G(x')}{P(x)G(x)}$ (since either $\frac{G(x)}{G(x')} \gt 1$ or $\frac{G(x)}{G(x')} \le 1$).
Problem
However, the above doesn't work in the general case, since there are MCMC algorithms that does not guarantee detailed balance. For example, each sweep of the deterministic sweep Gibbs sampler does not satisfy detailed balance. Is there a way to fix the above solution to make it work, or is it impossible? What requirements does black_box(x) have to fulfill in order to allow it to be used as a proposal distribution?
• I'd like to know why this question was voted down. It looks interesting and shows thought. – Yair Daon Jan 9 '16 at 21:42
1) Draw $M$ samples from $P(X)$. Let's call these samples $X'$.
2) Get importance weights by computing $w = G(X')$
3) Calculate whatever statistic you want (i.e. mean, sd, etc) by the weights incorporation $w' = \frac{w}{\sum w}$
4) If you want to get an unweighted sample from P(X)G(X), draw from $X'$ with probability $w'$
• Unfortunately this requires $M \rightarrow \infty$, and this is taking place within a larger MCMC algorithm, so I can't let $M$ be too large. – yong Jan 10 '16 at 4:37
|
{}
|
### Home > APCALC > Chapter 12 > Lesson 12.3.2 > Problem12-107
12-107.
A rowboat is tethered from its bow to a dock by two ropes, each $20$ feet long. The ropes are tied to the dock at points $20$ feet apart.
The boat’s owner unties one of the ropes from the dock, and brings the boat toward the dock by walking along it away from the other tether point at a rate of $4$ ft/sec. How fast is the boat moving toward the dock when the boat’s owner has walked $10$ feet?
Draw a diagram where the $d =$ distance from the dock, which is the height of an isosceles triangle.
Let $x =$ distance the owner has walked.
When the owner has walked $10$ ft, by the Pythagorean Theorem, $d = \sqrt{175}$ .
$d^2+\Big(\frac{20+x}{2}\Big)^2=20^2$
$2dd^\prime+\Big(\frac{20+x}{2}\Big)x^\prime=0$
Substitute in the known values and solve for $d′$.
|
{}
|
# Math Help - Surd
1. ## Surd
How do I simplify $\sqrt{9 + 4\sqrt{2}}$ to $1+2\sqrt{2}$?
Thanks
2. Hello, slevvio!
$\text{How do I simplify }\,\sqrt{9 + 4\sqrt{2}}\,\text{ to }\,1+2\sqrt{2}\;?$
I don't think there is an easy way . . .
First, we must suspect that $9 + 4\sqrt{2}$ is a square.
Then we let: . $\sqrt{9 + 4\sqrt{2}} \;=\;a + b\sqrt{2}$
. . where both $a\text{ and }b$ are rational numbers.
Square both sides: . $9 + 4\sqrt{2} \;=\;\left(a + b\sqrt{2}\right)^2$
. . and we have:. . $9 + 4\sqrt{2} \;=\a^2 + 2b^2) + 2ab\sqrt{2}" alt="9 + 4\sqrt{2} \;=\a^2 + 2b^2) + 2ab\sqrt{2}" />
These two numbers are equal if their corresponding coefficients are equal.
So we have: . $\begin{Bmatrix}a^2+2b^2 & = & 9 \\ 2ab &=&4\end{Bmatrix}$
The second equation gives us: . $b \:=\:\frac{2}{a}$
Substitute into the first equation: . $a^2 + 2\left(\frac{2}{a}\right)^2 \:=\:9 \quad\Rightarrow\quad a^2 + \frac{8}{a^2} \:=\:9$
Multiply by $a^2\!:\;\;a^4 + 8 \:=\:9a^2\quad\Rightarrow\quad a^4 - 9a^2 + 8 \:=\:0$
. . which factors: . $(a^2-1)(a^2-8) \:=\:0$
. . and has roots: . $a \;=\;\pm1,\:\pm2\sqrt{2}$
Since $a$ must be rational and the original square root is positive,
. . the only acceptable root is: . $a\,=\,1\quad\Rightarrow\quad b \,=\,2$
Therefore: . $\sqrt{9 + 4\sqrt{2}} \;=\;1 + 2\sqrt{2}$
3. Originally Posted by Soroban
I don't think there is an easy way . . .
Of course there is one more dear Soroban
Originally Posted by slevvio
How do I simplify $\sqrt{9 + 4\sqrt{2}}$ to $1+2\sqrt{2}$?
$\sqrt {9 + 4\sqrt 2 } = \sqrt {\left( {1 + 4\sqrt 2 + 8} \right)} = \sqrt {\left( {1 + 2\sqrt 2 } \right)^2 } = \left| {1 + 2\sqrt 2 } \right|.$
Since the quantity inside bars is positive, we have that $\sqrt {9 + 4\sqrt 2 } = 1 + 2\sqrt 2 .$
4. Hello, Krizalid!
Of course, you are right . . . That is a valid method.
I use that method when I'm quite certain that we have a square.
I've done it enough times that I suspect that $8 + 2\sqrt{15}$ is a square
. . because: . $8 \:= \:3 + 5\;\hdots\;15 \:=\:3\cdot5\;\hdots\;\text{ and that coefficient is 2.}$
And, sure enough: . $8 + 2\sqrt{15} \;=\;(\sqrt{3} + \sqrt{5})^2$
|
{}
|
# A capacity-achieving simple decoder for bias-based traitor tracing schemes
J. Oosterwijk, B. Skoric, J.M. Doumen
## Abstract
We investigate alternative suspicion functions for bias-based traitor tracing schemes, and present a practical construction of a simple decoder that attains capacity in the limit of large coalition size $c$. We derive optimal suspicion functions in both the Restricted-Digit Model and the Combined-Digit Model. These functions depend on information that is usually not available to the tracer -- the attack strategy or the tallies of the symbols received by the colluders. We discuss how such results can be used in realistic contexts. We study several combinations of coalition attack strategy versus suspicion function optimized against some attack (another attack or the same). In many of these combinations the usual codelength scaling $\ell \propto c^2$ changes to a lower power of $c$, e.g. $c^{3/2}$. We find that the interleaving strategy is an especially powerful attack. The suspicion function tailored against interleaving is the key ingredient of the capacity-achieving construction.
Original language English IACR 19 Published - 2013
### Publication series
Name Cryptology ePrint Archive 2013/389
## Fingerprint
Dive into the research topics of 'A capacity-achieving simple decoder for bias-based traitor tracing schemes'. Together they form a unique fingerprint.
|
{}
|
# [texhax] A TeX `tools' bundle question.
Philip G. Ratcliffe philip.ratcliffe at uninsubria.it
Wed Jun 23 16:52:42 CEST 2004
```> I'm trying to add the `tools' bundle to my LaTeX system.
But you don't say exactly which LaTeX system you're using.
> One of the
> instruction steps directs me to move all .sty and .tex files to
> "a directory
> on LaTeX's standard input path." Where exactly is that?
> I tried putting the files in a folder labelled `tools' in the
> texmf folder,
Aha, is this MiKTeX? If it is, why do it all by hand?
> but that didn't work. I'm just not sure where they belong...
Try putting them in texmf\tex\latex\tools and then refreshing the filename database (this last step is VITAL) ... how you do this (aha, you guessed) depends on your LaTeX system.
Cordialmente, Philip G. Ratcliffe
"If we knew what it was we were doing, it would not be called research, would it?" -- Albert Einstein
```
|
{}
|
# Sun-Planet
Planetary gear set of carrier, planet, and sun wheels with adjustable gear ratio and friction losses
• Library:
• Simscape / Driveline / Gears / Planetary Subcomponents
## Description
The Sun-Planet gear block represents a set of carrier, planet, and sun gear wheels. The planet is connected to and rotates with respect to the carrier. The planet and sun corotate with a fixed gear ratio that you specify and in the same direction with respect to the carrier. A sun-planet and a ring-planet gear are basic elements of a planetary gear set. For model details, see Equations.
### Thermal Model
You can model the effects of heat flow and temperature change by exposing an optional thermal port. To expose the port, in the Meshing Losses settings, set the Friction parameter to ```Temperature-dependent efficiency```.
### Equations
#### Ideal Gear Constraints and Gear Ratios
Sun-Planet imposes one kinematic and one geometric constraint on the three connected axes:
`${r}_{\text{C}}{\omega }_{\text{C}}={r}_{\text{S}}{\omega }_{\text{S}}+{r}_{\text{P}}{\omega }_{\text{P}}$`
The planet-sun gear ratio is
`${g}_{\text{PS}}={r}_{\text{P}}/{r}_{\text{S}}={N}_{\text{P}}/{N}_{\text{S}}$`
Where N is the number of teeth on each gear. In terms of this ratio, the key kinematic constraint is:
The three degrees of freedom reduce to two independent degrees of freedom. The gear pair is (1, 2) = (S, P).
### Warning
The planet-sun gear ratio gPS must be strictly greater than one.
The torque transfer is:
In the ideal case, there is no torque loss, that is .
#### Nonideal Gear Constraints and Losses
In the nonideal case, τloss ≠ 0. For more information, see Model Gears with Losses.
### Variables
Use the Variables settings to set the priority and initial target values for the block variables before simulating. For more information, see Set Priority and Initial Target for Block Variables (Simscape).
#### Dependencies
Variable settings are exposed only when, in the Meshing Losses settings, the Friction model parameter is set to `Temperature-dependent efficiency`.
## Limitations and Assumptions
• Gear inertia is assumed negligible.
• Gears are treated as rigid components.
## Ports
### Conserving
expand all
Rotational conserving port associated with the planet gear carrier.
Rotational conserving port associated with the panet gear.
Rotational conserving port associated with the sun gear.
Thermal conserving port associated with heat flow. Heat flow affects gear temperature, and therefore, power transmission efficiency.
#### Dependencies
This port is exposed when, in the Meshing Losses settings, the Friction parameter is set to `Temperature-dependent efficiency`.
Exposing this port also exposes related parameters.
## Parameters
expand all
### Main
Ratio gPS of the planet gear wheel radius to the sun gear wheel radius. This gear ratio must be strictly greater than 1.
### Meshing Losses
Friction model for the block:
• `No meshing losses - Suitable for HIL simulation` — Gear meshing is ideal.
• `Constant efficiency` — Transfer of torque between gear wheel pairs is reduced by a constant efficiency, η, such that 0 < η ≤ 1.
• `Temperature-dependent efficiency` — Transfer of torque between gear wheel pairs is defined by table lookup based on the temperature.
#### Dependencies
If this parameter is set to:
• `Constant efficiency` — Related parameters are exposed.
• `Temperature-dependent meshing losses` — A thermal port and related parameters are exposed.
Torque transfer efficiency, ηSP, for sun-planet gear wheel pair meshings. The value must be greater than `0` and less than or equal to `1`.
#### Dependencies
This parameter is exposed when the Friction model parameter is set to ```Constant efficiency```.
Array of temperatures used to construct a 1-D temperature-efficiency lookup table. The array values must increase from left to right.
#### Dependencies
This parameter is exposed when Friction model is set to `Temperature-dependent efficiency`.
Array of mechanical efficiencies, ratios of output power to input power, for the power flow from the ring gear to the planet gear, ηRP. The block uses the values to construct a 1-D temperature-efficiency lookup table.
Each array element values is the efficiency at the temperature of the corresponding element in the Temperature array. The number of elements in the Efficiency array must be the same as the number of elements in the Temperature array. The value of each Efficiency array element must be greater than `0` and less than or equal to `1`.
#### Dependencies
This parameter is exposed when the Friction model parameter is set to ```Temperature-dependent efficiency```.
Power threshold, pth, above which full efficiency is in effect. Below this values, a hyperbolic tangent function smooths the efficiency factor. For a model without thermal losses, the function lowers the efficiency losses to zero when no power is transmitted. For a model that considers thermal losses, the function smooths the efficiency factors between zero at rest and the values provided by the temperature-efficiency lookup tables at the power thresholds.
#### Dependencies
This parameter is exposed when the Friction model parameter is set to ```Constant efficiency``` or ```Temperature-dependent efficiency```.
### Viscous Losses
Viscous friction coefficient μS for the sun-carrier gear motion.
### Thermal Port
These settings are visible when, in the Meshing Losses settings, the Friction model parameter is set to `Temperature-dependent efficiency`.
Thermal energy required to change the component temperature by a single degree. The greater the thermal mass, the more resistant the component is to temperature change.
#### Dependencies
This parameter is exposed when, in the Meshing Losses settings, the Friction model parameter is set to `Temperature-dependent efficiency`.
expand all
|
{}
|
# Talk:e (mathematical constant)
E (mathematical constant) has been listed as one of the Mathematics good articles under the good article criteria. If you can improve it further, please do so. If it no longer meets these criteria, you can reassess it.
Article milestones
DateProcessResult
June 19, 2007Good article nomineeNot listed
June 21, 2007Peer reviewReviewed
July 18, 2007Good article nomineeListed
August 31, 2007Good article reassessmentKept
Current status: Good article
## Comments on 'alternative characterization 6'
- The value of the quotient ${\displaystyle f(x)/f'(x)}$ being independent of ${\displaystyle x}$ for an exponential function ${\displaystyle f}$, is mentioned in the third sentence of Exponential function.
- And the property that equal absolute increments of the abscissa correspond with equal relative increments/decrements of the ordinate, is as fundamental for exponential functions. -- Hesselp (talk) 15:27, 27 April 2018 (UTC)
At least one reference that clearly and directly supports this characterization is required. Ideally, this reference should be a secondary source, showing that the characterization you gave is one that is widely used and accepted, like the others. Sławomir Biały (talk) 16:28, 27 April 2018 (UTC)
@Sławomir Biały and Joel B. Lewis ('uncited'). About references and sources:
Secondary sources of the 'alternative-6' can be found in descriptions of exponential processes (e.g. radioactive decay). As in WP:Exponential decay sentence 5-6: "The exponential time constant (or mean life time or life time, in other contexts decay time or in geometry subtangent) [...] τ is the time at which the population of the assembly is reduced to 1/e times its initial value." Putting e in front you get essentially: "The number e shows up as constant growth/decay factor over the life time (f/f' ) of an arbitrary exponential process (f) ".
As more primary sources, focussing on the role of the number e in all exponential processes (continuous growth/decay), I mention three articles (in Dutch, in magazines on mathematics for teachers):
- Euclides (Netherlands) 1998/99, vol. 74, no 6, p.197/8
- Wiskunde & Onderwijs ('Mathematics and teaching', Belgium) 2001, vol. 27, no 106, p. 322-325
- Euclides 2012/13, vol. 88, no 3, p. 127/8 . -- Hesselp (talk) 16:08, 28 April 2018 (UTC)
@D.Lazard. Interesting to see your modification of the first alt-6-version.
Rewriting my text into your format, I get:
If ${\displaystyle f(t)}$ is any solution of the differential equation ${\displaystyle y'=y/s}$, then for all ${\displaystyle t}$: ${\displaystyle e=f(t+s)/f(t)}$.
a. My choiche of t instead of x has to do with my mixed background in physics and mathematics. In my view, an exponential function is mostly a function of time, so t. But if there are better arguments for x, excellent. The same for ${\displaystyle f(x)}$ instead of the sufficient (but still not everywhere usual?) ${\displaystyle f}$.
b. Instead of 'for all t ' and 'for all s ' in my version, you have t = 0 and s = 1. This leads to the question: is the general case more or less difficult to grasp for a reader than the special case? (And in between there are the cases with only t=0 and with only s=1 as well.). I don't comment on this question at the moment; only this:
c. The solutions of your differential equation are of the type a exp(x) , not a very common type of exponential function, I think. -- Hesselp (talk) 16:08, 28 April 2018 (UTC)
I'm satisfied by the discussion at Exponential decay#Mean lifetime that something like this could be included as a characterization of e. However, I would still like to see a better source (in English!). I think some effort should be made to tie it to the articles on exponential growth and decay. I would rephrase the addition along the following lines to make that relationship clearer:
If f(t) is an exponential function, then the quantity ${\displaystyle f(t)/f'(t)}$ is a constant, sometimes called the time constant (it is the reciprocal of the exponential growth constant or decay constant). The time constant is the time it takes for the exponential function to increase by a factor of e: ${\displaystyle f(t+\tau )=ef(t)}$.
Thoughts? Sławomir Biały (talk) 19:55, 28 April 2018 (UTC)
@Sławomir Biały. Some remarks on your proposal.
i. On "..then the quantity ${\displaystyle f(t)/f'(t)}$..". Why 'quantity'? why not 'quotient'? Even better: simply "..then ${\displaystyle f(t)/f'(t)}$.." .
ii. On "... ${\displaystyle f(t)/f'(t)}$ is a constant, sometimes called the time constant ..." .
The real universal constant is ${\displaystyle f(t+\tau )/f(t)}$, while ${\displaystyle f(t)/f'(t)}$ depends on ${\displaystyle f}$. So I propose:
"... ${\displaystyle f(t)/f'(t)}$ doesn't depend on ${\displaystyle t}$ (this value is sometimes called the time constant of f(t) ) . "
iii. On "(it is the reciprocal of the exponential growth constant or decay constant)". This interrupts the main message, maybe better in a footnote. Or leave it out, for 'the reciprocal of a time interval' I can't see as an elementary concept.
iv. I understand that I've to wait until a sufficient number of reliable explicit secondary sources are found, for (maybe) consensus on the introduction or characterization of e as (something like) "the stretching/shrinking factor of every exponential process (function) over any period equal to its time constant" . -- Hesselp (talk) 10:13, 29 April 2018 (UTC)
I think we should wait for native speakers of English to comment on the proposal. Some things about your critique strike me as misunderstanding idioms and grammar. Sławomir Biały (talk) 12:13, 29 April 2018 (UTC)
I like Slawomir's version. Unlike Hesselp's, it is actually possible to understand, is clearly written, and avoids obscurities. Good job getting something usable out of this. --JBL (talk) 12:58, 29 April 2018 (UTC)
Even when not a native speaker, I want to join JBL's praise of Sławomir Biały's suggestion. However, since it's about charcterizing e and not the time constant, I suggest to amend to
If f(t) is an exponential function, then ${\displaystyle f(t)/f'(t)}$ is a constant 'for all t'. quoted amendment dedicated to Hesselp 10:02, 30 April 2018 (UTC) When f describes a physical process and t is associated with time, this constant is often called the time constant ${\displaystyle \tau }$ of this process, and the reciprocal is called its exponential growth rate (>0) or decay rate (<0).
The number e is the factor by which all exponential functions change during the elapse of one time constant:
${\displaystyle f(t+\tau )=e\cdot f(t)}$.
Honestly, I think this is mathematically obvious to a degree making additional math sources superfluous, and physics sources should abound. Purgy (talk) 15:28, 29 April 2018 (UTC)
Arguments against changing in Purgi's proposal "...is a constant. When ... this constant is often ..." into "...is independent of t. When ...this value is often ..." ? To reduce the possibility of misunderstanding.
(I know I had 'constant' as well in the first version of alternative 6.) -- Hesselp (talk) 08:36, 30 April 2018 (UTC)
Again: arguments against changing in Purgi's amended proposal:
"...is a constant 'for all t'. When ... this constant is often called the time constant ${\displaystyle \tau }$ of this process, ..." into
"...is independent of t. When ...this value is often called time constant of the process (symbol ${\displaystyle \tau }$), ..." ?
-- Hesselp (talk) 16:05, 30 April 2018 (UTC)
I prefer Sławomir Biały's version because it does not waste time getting to the connection with e. By comparison, Purgy's version emphasizes and expands on the parts that are least closely related to the topic of this article. I suggest adding Sławomir Biały's version verbatim. --JBL (talk) 22:10, 3 May 2018 (UTC)
@JBL. Please explain what you mean with "don't randomly break equations just for kicks." (Summary 3 May 2018)
And your "More general is not better" isn't clear to me as well, for you advocate Slawomir's proposal using the most general situation. -- Hesselp (talk) 16:23, 4 May 2018 (UTC)
Seeing the bare entry now, the notable connection to time constant and decay/growth rate of exponential processes totally stripped off, I revert to D.Lazards longer standing "three"-version. Furthermore, I plead for a more explicit consensus before any other edits on this detail. Reversion already done by JBL. 06:04, 4 May 2018 (UTC) Purgy (talk) 06:00, 4 May 2018 (UTC)
### Two proposals
Balancing the proposals, arguments and opinions shown on this talk page until now, could there be consensus on the following 'version 6a' ? Arguments? Ideas for improvement?
6a. If f(t) is an exponential function, then ${\displaystyle f(t)/f'(t)}$ is independent of t; sometimes this value is called time constant of f(t), symbol ${\displaystyle \tau }$. (It is the reciprocal of the exponential growth constant or decay constant.) The time constant is the time it takes for the exponential function to increase by a factor of e. So for all t:
${\displaystyle e=f(t+\tau )/f(t).}$
Or could there be consensus on the much shorter 'version 6b' ? A compromise of "this only uses the concept of derivative as prerequisites", "properties of exponential functions and terminology that is unrelated with the definition of e", "emphasizes and expands on the parts that are least closely related to the topic of this article" and "the notable connection to time constant and decay/growth rate of exponential processes totally stripped off".
Or the remark in parentheses better in a footnote? then also naming 'exponential growth constant/rate and exponential decay constant/rate? Arguments? Ideas for improvement?
6b. If ${\displaystyle f(t)}$ is any solution of the differential equation ${\displaystyle y'=y/\tau }$, (an exponential function with time constant or e-folding ${\displaystyle \tau }$), then for all ${\displaystyle t}$:
${\displaystyle e={\frac {f(t+\tau )}{f(t)}}.}$
-- Hesselp (talk) 16:23, 4 May 2018 (UTC)
Opinion: Positive consensus is required. I will not be commenting on these specific proposals. Proposals which already seem already to have positive consensus are in the previous section, and do not require Hesselp's "improvements". Sławomir Biały (talk) 11:02, 27 May 2018 (UTC)
## Known digits edit -- first million digits of E
I edited the table "Number of known decimal digits of e" to add the calculation for the first million digits of e; this information had been on this page some time ago (not added by me, BTW), and I noticed today it was gone so added it back.
This was undone with the reason "entries more recent than 1978" are "rather ridiculous." (Why are they "rather ridiculous"?) I added the information again, and noted that "This is a significant increase over the previous calculation and 1,000,000 is a notable number."
Undone again, with the (partial) comment "Already linked in external links. Secondary source needed for mention here." The external link referred to doesn't assign credit to those who computed it nor when this was done. I added the entry back with another reference as a secondary source.
Undone again, with the comment "the added source isn't particularly reliable; it's just a listing in a table on some web page, and it disagreed about the number of digits by a factor of 10 -- also, 1 million isn't a "notable number", it's just a round number."
The added source is a website maintained by two French mathematicians.
The number one million is notable enough to have its own Wikipedia page, and the one million digits of e that were calculated were used in research. Obviously, I think this is a worthwhile entry, so I added the entry again, removing the reference to the French maths site and adding references to two research articles.
Undone again, with the comment "Nothing about this entry makes it notable given the current state of affairs. Use the talk page to make your case if you must."
The current state of affairs is not relevant -- the state of affairs in 1994 is, and the calculation of e to one million digits (by two PhD astrophysicists at NASA) at that time is indeed notable; it's a significant increase over the previous result. Further, these are results that have been used in research (more recently, however, the 2-million digits of e have been used).
I hope the most recent removal of the info I attempted to add (rather, restore) is undone; the information is useful, assigns credit, and the only thing controversial about it is that a number of editors appear to want the table to end with Wozniak. Nice to be reminded (again) of why I hate editing Wikipedia pages and do it so rarely. Ciao. Owlice1 (talk) 05:26, 5 July 2018 (UTC)
A few things. First of all, the fact there's an article for 1 million is completely irrelevant. That has no bearing whatsoever on whether or not this entry should be in the list. Also, you're neglecting to mention that this entry that you want to restore is just one of a whole mess that got removed (the list has expanded and shrunk at various points). Presumably we want to draw the line somewhere. I honestly think this wouldn't be terrible if it were added back in, but these become of increasingly less historical significance as we go on. Finally, why are you so eager to restore this entry but not any of the others? –Deacon Vorbis (carbon • videos) 14:45, 5 July 2018 (UTC)
The fact that there is an article for 1 million demonstrates the number itself is indeed notable, and I posted that in response to the complaint that the number isn't notable. (If it's not a notable number, delete the page for it.) Yes, you want to draw the line somewhere, and that somewhere is at Wozniak. That's been made very clear. Nevertheless, this one additional entry is useful for the reasons I've already mentioned: it's a significant increase over the previous result, it is a notable number, it is used in research. This result came 16 years after the previous one. Other results of two million, etc., followed closely on the heels of this one, too closely, I would say, to be noted, as with the ever increasing capability in computing power and the speed at which the increases were (and are) being made, that will then always be the case: greater numbers will always be found. I've answered every criticism of the edit. As to why I didn't try to restore any others, well, we've seen how well it worked when I tried to restore just one with so much going for it! Why on earth would I bother with any others, here or anywhere else? I'm done. Owlice1 (talk) 16:06, 5 July 2018 (UTC)
It's been asserted that the 1994 calculation is notable. Notability is established by secondary sources. If this calculation is indeed noted in reliable sources, it can be restored. Sławomir Biały (talk) 16:44, 5 July 2018 (UTC)
I provided several sources, as one can see from looking at my edits. If you find none of them reliable, then please let me know what is a reliable source, and let me know, too, if you would, why this addition needs more reliable secondary sources than others listed in the table, each of which has one source, at least one of which, which is a link to a website (deemed unacceptable for my addition), doesn't work. Thanks. Owlice1 (talk) 17:21, 5 July 2018 (UTC)
While I do not feel particularly strongly on this and I am not disagreeing with Sławomir, I do believe that Purgie is making a valid point, even if a bit too flippantly. Entries in a table like this need to be more than just notable, they need to be interesting, specifically historically interesting. The table's function is to illustrate the growth of the number of known digits. It can not be complete, nor would we want it to be. It has to stop growing at some point and I think that it should stop when the next entry is no longer interesting. For years I did a corresponding lecture on the digits of π. As each new record was set I was forced to remove some items, even though they were notable at the time I started to talk about them, since they had stopped being interesting (what I could say about them I could easily have said the same about some newer entries). At this point, with over 500 trillion (I didn't really count the zeroes in Ye's table, but the number is up there) digits known, the fleeting record of the millionth digit calculation has lost all interest, at least for me. --Bill Cherowitzo (talk) 17:32, 5 July 2018 (UTC)
Yes, it has to stop growing at some point -- I do not disagree with that. I would ask, then, that those who have undone my edit defend stopping the table at 116,000 rather than 1,000,000, a number not achieved until 16 years after Wozniak's. It was after 1 million digits was reached that new significant records (2 million, 5 million, and so on) were set only months, or maybe even weeks, apart, not years. Owlice1 (talk) 17:52, 5 July 2018 (UTC)
The latest revision, with the added sources, looks reasonable to me. I say we let the addition stand. Sławomir Biały (talk) 18:06, 5 July 2018 (UTC)
I disagree with Sławomir Biały's and Owlice1's opinion that the entry under reversion should be included in the addressed table. I try to give answers to questions raised by Owlice1 and to explicate my reasons for objecting and also for my suggestion of an expanded table.
• I admit calling new records in rote computing "rather ridiculous" is quite harsh. I can only mention the "rather" as mitigating: sorry. I do believe, however, that the achieved numbers have no profound importance.
• I do not doubt the factuality of the intended entry and it being reliably sourced, but the notability of ${\displaystyle 10^{6}}$ in math topics is to me just as big as any decade, perhaps slightly bigger as a multiple of ${\displaystyle 10^{3}}$, favoured in technical contexts. However, I do not see any notability wrt e itself, and not even wrt a number of digits in its representation in positional number systems. There being a WP article on the number ${\displaystyle 10^{6}}$ is largely irrelevant in any other article. Therefore, there is no reason, stemming from ${\displaystyle 10^{6}}$ digits themselves, to appear in the article about e.
• The v. Neumann entry is relevant for the reason I tried to give: first automatically computed value. I think, v. Neumann is irrelevant in this context, the ENIAC is the relevant information, one of the first floor-sized computers, unavailable to the public. The 1961-entry might be skipped, its importance being perhaps only the increase of available digits in orders of magnitude. The 1978-entry is not important for S. Wozniak, but for the fact that then a publicly available device empowered the almost average Joe to calculate digits of almost any desired math constant to a degree, for which I have no tolerated verbiage. "Trillions" is not to my liking, because of Moore's Law and other reasons I consider obvious to most in good faith. The number of calculated digits is limited just by boredom.
• I do not deny the existence of research values in the ongoing calculations, but their nexus to e are, at least to my knowledge, confined to the application of specific algorithms, possibly exchangeable to those for other constants, which are often considered barely as useful test samples. I conjecture that even a newly discovered quantum algorithm for calculating digits of e would not justify a new entry, but only an article in WP on its own.
• I still believe that adding to the table a reason-for-notability column, containing good reasons, enhances the article. Since I was aware that my specific knowledge and active fluency in English would not be sufficient to supply really good entries there, I just did a sketchy draft, and explicitly asked for kind improvement in the edit summary.
I did not expect the qualification "flippant" (I am fully respectful!), and other reactions I consider not de rigeur. Purgy (talk) 10:15, 6 July 2018 (UTC)
The achieved result of 1,000,000 digits of e is notable. I've already pointed out a number of reasons why. I think you do not grasp this one, however: these digits were (are) available for download; this is actually useful. (Where are the 116,000 digits of e from the previous result? Published in BYTE. How useful were they? What could anyone do with them?) Generating the million digits and then publishing the result online, where the digits can be downloaded, makes them available for research. Here are three research articles that use this particular achieved result:
Ginsburg, N. and Lesner, C. (1999) "Some Conjectures about Random Numbers"
Shimojo, M., et al (2007) “A Note on Searching Digits of Circular Ratio and Napier's Number for Numerically Expressed Information on Ruminant Agriculture"
Lai, Dejian & Danca, Marius-F. (2008) "Fractal and statistical analysis on digits of irrational numbers"
Notice the last two articles mentioned were written more than a decade after these results were made available online for others to use, indicating that particular digit-set had some endurance for research (and still may, though I haven't looked for more papers using it; I have run across other papers using even the larger sets generated by Nemiroff & Bonnell, such as 2 million and 5 million digits of e, too).
Such research might not be something you'd want to do, but others clearly do. Calculating and then making these digits available online for anyone to use had not been done before. (Editing to add: at the million digit level.) Owlice1 (talk) 11:31, 6 July 2018 (UTC)
Yes, I do not grasp how often I have to ruminate that facts, typical of any irrational number, are very well notable at appropriate places, but are not notable within an article about e, which just happens to be irrational. Purgy (talk) 07:47, 7 July 2018 (UTC)
For some reason, the following comes to mind:
Who Where What
Colonel Mustard Library Wrench
I've restored Nemiroff & Bonnell to the table, with what I hope are enough references to satisfy all. Thank you for your patience. Owlice1 (talk) 11:47, 7 July 2018 (UTC)
It’s just not an interesting or remarkable result. As by 1978 it was already possible to generate over 100,000 digits on a 8-bit CPU, someone could have generated a million digits a few years later, and probably did long before 1994. There would be many such firsts that were not published as they are simply not interesting, no-one has noticed them. It really is not that interesting now anyone can download and run a program to generate digits.--JohnBlackburnewordsdeeds 12:26, 7 July 2018 (UTC)
"not reliably sourced." I provided primary and secondary sources. Which of these did you find not reliable? It is certainly not true that others did not notice these results. They were used in research, the Gutenberg project published them, and the results are even available through Amazon! (The reviews are rather amusing.) The research articles using them are not about algorithms for generating e, but about how to use the generated digits. Can they, for example, be used as a random number generator, or in cryptology? That is what some of this research is, and it's clear that others must not have wanted to generate these digits themselves, as they used (and cite) these results. Speaking of "not reliably sourced," I note this from your post: someone could have generated a million digits a few years later, and probably did long before 1994. (Emphasis mine.) That's not sourced at all. I'm restoring the entry. Owlice1 (talk) 17:32, 7 July 2018 (UTC)
The computation of one million digit has not been the object of a regularly published paper. This shows that, even at the time of this computation, this was not considered by the mathematic community as a significant result. Nevertheless, the list of these digits is useful and has been used for other research. This could be mentioned elsewhere in the article, but does not belongs to this section. This list of digits is also listed in the "See also" section, which is its natural place. I have reverted your edit for these reasons.
On the other hand, when you disagree with other editors, edit-warring is the worst way for dispute resolution, as you may be blocked for editing because of the WP:3RR rule. D.Lazard (talk) 18:01, 7 July 2018 (UTC)
I rarely edit Wikipedia pages; it wasn't until this discussion that I learned the phrase "edit-warring." I brought the discussion to the talk page when it was suggested I do so, and I've answered every criticism of the edit. There was some agreement/acquiescence that the addition could stand, which is why I put it back.
BTW, I missed the "regularly published paper" for the Wozniak result that shows it is considered significant by the maths community. Where is that, please? What I see given as a source for that is a BYTE magazine article (which I probably have in the stash of old mags in the basement; I may have to go look). At least one other entry in the table has a link to a website as the source, rather than to a journal article. I have asked before why my addition, which has multiple reliable refereed secondary sources that indicate the value of this result/addition, is unacceptable while others with only one source not as robust still stand; I never got an answer to that. The goal of some of the editors appears to be to end the table at Wozniak, no matter what. Owlice1 (talk) 18:29, 7 July 2018 (UTC)
May I point you to the fact that you keep refusing to recognize the statements about the disconnectedness to this article of the sources you mention, backing the non-notability wrt this article of the sourced fact you want included. The research work of these papers is in no way specifically connected to e, but to an assumed structure of randomness in its digits. Any other irrational number would do the same trick. You also seem to ignore in your comparison the given reason for the Apple II entry. I repeat: It is not primarily about Wozniak, but about the public availability of equipment, capable of calculating more or less arbitrarily many digits of any computable number, rendering any new "records" as of no relevance. Please, do not strive to make WP a Guinness Book of Records. Purgy (talk) 19:22, 7 July 2018 (UTC)
I'm not disputing the Wozniak entry, at all, although the different standards for sources for its inclusion wrt my addition are noted. You cannot assume randomness in the digits of e; indeed, that's one point of research, one that requires a million or more digits to accomplish. The Nemiroff/Bonnell results are notable for a number of reasons, including enabling that and other research (in computer science, math, and even apparently in ruminant agriculture) where other results at that time did not. I'm not "striv[ing] to make WP a Guinness Book of Records." I'm trying to add a useful/notable addition to that table. That's it.
Two additional papers for my own reference (and possibly future others'):
BiEntropy - The Approximate Entropy of a Finite Binary String, http://adsabs.harvard.edu/abs/2013arXiv1305.0954C)
A New Method for Symbolic Sequences Analysis. An Application to Long Sequences, http://cmst.eu/articles/a-new-method-for-symbolic-sequences-analysis-an-application-to-long-sequences/
Owlice1 (talk) 20:01, 7 July 2018 (UTC)
## Please, improve on the given reasons
I do not think that giving reasons why which entries are given in a table degrades a featured article; maybe reasons even help the more-digits researchers. I just concede that my reasons are a bit tongue-in-cheek. I also think that "trillions" of digits of e are inappropriate in a FA. The revert first - think later approach is often really annoying.
Number of known decimal digits of e
Date Decimal digits Computation performed by Reason for notability
1690 1 Jacob Bernoulli[1] First value
1714 13 Roger Cotes[2] First reasonable precision
1748 23 Leonhard Euler[3] Euler's number crunching professionality
1853 137 William Shanks[4] World known number cruncher
1871 205 William Shanks[5] ... doing it again
1884 346 J. Marcus Boorman[6] Last known effort by rote human calculation
1949 2,010 John von Neumann (on the ENIAC) First computerized result getting public attention
1961 100,265 Daniel Shanks and John Wrench[7] Hereditary deficiencies?
1978 116,000 Steve Wozniak on the Apple II[8] Egalitarian approach to e —The End
Since that time, the proliferation of modern high-speed desktop computers has made it possible for all those sufficiently interested and equipped with the right hardware, to compute digits of any representation of e up to the lifetime of this hardware.[9]
References
1. ^ Cite error: The named reference Bernoulli, 1690 was invoked but never defined (see the help page).
2. ^ Roger Cotes (1714) "Logometria," Philosophical Transactions of the Royal Society of London, 29 (338) : 5-45; see especially the bottom of page 10. From page 10: "Porro eadem ratio est inter 2,718281828459 &c et 1, … " (Furthermore, by the same means, the ratio is between 2.718281828459… and 1, … )
3. ^ Leonhard Euler, Introductio in Analysin Infinitorum (Lausanne, Switzerland: Marc Michel Bousquet & Co., 1748), volume 1, page 90.
4. ^ William Shanks, Contributions to Mathematics, … (London, England: G. Bell, 1853), page 89.
5. ^ William Shanks (1871) "On the numerical values of e, loge 2, loge 3, loge 5, and loge 10, also on the numerical value of M the modulus of the common system of logarithms, all to 205 decimals," Proceedings of the Royal Society of London, 20 : 27-29.
6. ^ J. Marcus Boorman (October 1884) "Computation of the Naperian base," Mathematical Magazine, 1 (12) : 204-205.
7. ^ Daniel Shanks and John W Wrench (1962). "Calculation of Pi to 100,000 Decimals" (PDF). Mathematics of Computation. 16 (77): 76–99 (78). doi:10.2307/2003813. We have computed e on a 7090 to 100,265D by the obvious program
8. ^ Wozniak, Steve (June 1981). "The Impossible Dream: Computing e to 116,000 Places with a Personal Computer". BYTE. p. 392. Retrieved 18 October 2013.
9. ^ Alexander Yee. "e".
Please, feel cordially invited. Purgy (talk) 09:26, 5 July 2018 (UTC)
Welcome, and thank you for your attempt to lighten up Wikipedia. However, this is an encyclopedia and articles are intended to be serious, so please don't make joke edits. Readers looking for accurate information will not find them amusing. If you'd like to experiment with editing, please use the sandbox instead, where you are given a certain degree of freedom in what you write. –Deacon Vorbis (carbon • videos) 15:20, 5 July 2018 (UTC)
As for the bit about trillions, why not? It might not be the very best choice, but your proposed change is wordy, awkward, and gives no indication about the amount of digits that is reasonably attainable. –Deacon Vorbis (carbon • videos) 15:20, 5 July 2018 (UTC)
I herewith withdraw all things cordial with respect to Deacon Vorbis. He is just entitled to spit on me his condescending qualification efforts, in the same way as any IP and even vandals are entitled to edit WP.
To all those, capable to make their good faith perceiveable, I want to reinforce my cordial invitation for improvement of the suggestions I made in absolutely positive intentions. I will try to explicate these in a reply to Owlice1 above. Purgy (talk) 07:02, 6 July 2018 (UTC)
## Overspecified?
I find the description
The function f(x) = ex is called the (natural) exponential function, and is the unique exponential function of type ax equal to its own derivative (f(x) = f(x) = ex). This is easily spotted at x = 0, where ax = 1 for any value of a, but a = e is the only positive number such that the slope at x = 0 of the graph of the function y = ax also equals 1.
The only real or complex function that is equal to its own derivative – i.e. such that f(x) = f(x) – is f(x) = ex, or a constant multiple thereof. This leads naturally to the exponential function, which has as its base the number e.
I see that it is very neatly stated in e (mathematical constant)#Calculus. —Quondum 02:34, 30 July 2018 (UTC)
I would write
The only real or complex function that is equal to its own derivative (that is, such that f(x) = f(x)), and is equal to 1 at 0 (that is f(0) = 1) is f(x) = ex. This is the exponential function, which has as its base the number e.
D.Lazard (talk) 07:52, 30 July 2018 (UTC)
While agreeing on the now current formulation being clumsy, I do like mentioning the whole class of functions ${\displaystyle x\mapsto a^{x},\;a\in (\mathbb {R} ,)\mathbb {C} }$, in which the instantiation with the specific value ${\displaystyle a=e}$ achieves an important property. Purgy (talk) 09:25, 30 July 2018 (UTC)
I agree with Purgy. This article is about the base e, not the natural exponential function per se. So it makes more sense here to ask, what distinguishes e from other bases? Sławomir Biały (talk) 10:39, 30 July 2018 (UTC)
I have restored the old version of the lead, prior to the addition of discussion of the natural exponential function, to refocus it on the number e itself. There were also a number of questionable structural changes that took place which, on balance, were not good. Sławomir Biały (talk) 10:46, 30 July 2018 (UTC)
I agree that the focus should be in the number e. As such, even with Sławomir's revert, I still find the paragraph starting "The constant can be characterized in many different ways. For example, ..." to be an excessive diversion into the details of contexts in which e occurs for the lead of an article. Since all the examples given are intimately related, I would find it sufficient to mention that it is the base of, say, the natural logarithm, and leave exploration of perspectives for the body of this or other articles. But I see that this would effectively duplicate the first sentence of the lead, and which already seems to answer the question that Sławomir aptly posed; should this paragraph not simply be removed? —Quondum 11:27, 30 July 2018 (UTC)
I faintly recall a consensus not to award predominance to the logarithmic approach, and to simply start with the numerical value. In so far I object to Sławomir Biały's revert. I am not aware in detail of the mentioned questionable structural changes.
My suggestion for avoiding excessive diversification within the lead would be to give just
• an approximate value (~5 decimals),
• the/a series expression(s) (no limits, no exponentials, no logs),
• the historical beginning (Bernoulli?),
• the fundamental status of transcendence, and
• a remark on the ubiquity in math, and, perhaps, the relation with 0, 1, π.
Cheeky enough to revert Sławomir Biały. Purgy (talk) 12:26, 30 July 2018 (UTC)
I am unable to find any consensus for the new lead in the discussion page archive. I think the old lead was better, since it points out immediately that e is the base of the natural logarithm, which defines the number very early on and clarifies why it should be of interest. The new lead, by contrast, puts rather peripheral matters first, like the series and limit definitions of the number, and ancillary historical details. Unless there is affirmative consensus for the new revision, I think the old lead should be restored. Sławomir Biały (talk) 15:33, 30 July 2018 (UTC)
I do not think we should eschew all mention of the natural logarithm and natural exponential function. I also don't think that we should offer any general theorems about solutions of differential equations in the lead of the article. Sławomir Biały (talk) 15:23, 30 July 2018 (UTC)
I agree with the general perspective that (as I interpret it) seems to be given by both Purgy and Sławomir to keep it at an overview introduction level in the lead. Giving a brief historical context and prominent associations (such as the limit and its association with natural logarithms). I am dubious about including an actual series expression in the lead. The listing of the well-known constants in the Euler identity is a bit of a flourish that works well in a lead, and some properties such as being transcendental belong there. I would move long decimal expansion into the body. I agree with Sławomir that more technical aspects with the flavour of a theorem or dealing with differentiation, continuity etc. should be left out of the lead: this is an article that the average nonmathematical high-schooler should be able to read easily without losing the sense of what is being said. So, for example, it is fine to mention that it is transcendental, but adding a definition thereof is possibly counterproductive. As the lead is now, merging everything after "transcendental" into the body would work for me, possibly along with with the series expression. —Quondum 17:45, 30 July 2018 (UTC)
I disagree in part with this proposal. If we cut the last paragraph, then the lead would then contain no mention, whatsoever, of the fact that e is the base of the natural logarithm. Sławomir Biały (talk) 21:27, 30 July 2018 (UTC)
Ah, sorry, I (incorrectly) remembered it being in the start, from the different version. As I indicated in my previous post, I feel that the prominent association with the natural logarithm (and/or similar, such as the natural exponential) should be mentioned in the lead, though this does not imply delving into the mathematical detail. My bland description of cropping the lead would thus not be exactly what I'd meant to suggest. —Quondum 22:39, 30 July 2018 (UTC)
This does point to my chief objection to the present version of the lead. The most important things, about the logarithm in particular, have been moved to the last paragraph, for questionable reasons. Sławomir Biały (talk) 10:47, 31 July 2018 (UTC)
As restored now, it does feel a bit more natural to me and the extreme artificiality that led to my original comment is diminished, though some of my earlier comments about excess detail in the lead remain. I am hesitant to get into the detail of the exact balance to strike, though, since past experience has shown that the sense of where a suitable balance lies varies between interested editors. —Quondum 12:15, 31 July 2018 (UTC)
───────────────────────── My suggestion is shaped by dangling Damokles' sword of how (relevant) math is perceived in the public. So my thoughts were: a number must primarily have a value (5 decimals), one should be able to calculate it a bit by oneself (one simple series), history is a general cultural highlight (Bernoulli), buzzwords are attractive (transcendency), and finally, respecting the ubiquity in math, rounded off perhaps with Euler.
Intentionally, I do not enumerate details of the ubiquity, but I oppose to bring the logs upfront and not on equal footing with exponentials. I think hyperbolic angles lost a bit of momentum, integrals are educationally after derivations. My gut feelings are that maybe continuous interest is closest to public interest (pun attempted), and understanding. How much of all this is in the lead is determined by its length.
To be honest, the unitary log as raison d'être for e looks dramatically circular to me (we had this, I did not start it then). Purgy (talk) 12:49, 31 July 2018 (UTC)
The most important feature of the constant is that it is the base of the natural log/natural exponential. These matters should be discussed first. Then history and nomenclature, followed by the number-theoretic properties. A lead which pushes until the very last paragraph any relation to the natural log and exponential is unacceptable. I would add that your objection to the consensus lead is nonsensical, since both the natural log and natural exponential are discussed in the first paragraph. It just happens that the characterization in terms of the natural log (which is not circular, please read the article and discussion page archives) is much shorter. The relation to the natural log is explained in the first paragraph, and the accompanying graphic. It is also discussed in much more detail in the article itself. Sławomir Biały (talk) 01:15, 1 August 2018 (UTC)
Well, I certainly do not need that badly a certain version of the lead that I would throw around phrases like "most important", "unacceptable", "nonsensical", and not even "not circular" (in an expectable setting). I just ask to take my utterances as one possible way to weigh certain points in this article for best meeting the needs of a vaguely specified non-professional audience, and beg pardon, in case I bothered someone with my aspects. Since I am quite sure that I won't change my opinion on this that easily, I humbly beg to be allowed to disagree to the above ex cathedra, without being considered imbecile. Meanwhile, I get to know what to expect from an increasing number of editors, without feeling bothered myself too much. Purgy (talk) 09:01, 1 August 2018 (UTC)
## Sharp inequalities
• the unique base of the exponential for which the inequality ax ≥ 1 + x holds for all x ... is e.
By implication, you're asserting that the following is not a sharp inequality:
• the unique base of the exponential for which the inequality ax ≥ 1 − x holds for all x ... is e–1.
User:Sławomir Biały, did you really mean that? —Quondum 00:05, 1 August 2018 (UTC)
I don't understand your objection to the property in question. I object to calling it a "mundane observation". It's an important estimate, and it also uniquely characterizes the number e. I understood your initial edit summary to be, wrongly, saying that ${\displaystyle a^{x}>1-x}$ is always true. (Though, I inferred that you perhaps meant something like ${\displaystyle a^{x}>-1+x}$ instead, which is not a sharp inequality for any a.) But, for the line ${\displaystyle y=1+x}$, with both y-intercept and slope equal to unity, the sharp inequality ${\displaystyle a^{x}>1+x}$ for all nonzero x holds, if and only if ${\displaystyle a=e}$. How is that a "mundane observation" that therefore justifies removal? Sławomir Biały (talk) 00:58, 1 August 2018 (UTC)
Maybe you misunderstood my claim, and I fail to see the error in my edit summary ("[...] There are many similarly formed expressions, e.g. a^x > 1 − x, that give different constants"), other than the obvious slip of using ">" instead of the intended ">=". I restated this corrected in the above, but you still may have missed it. (Your word order above, especially with your comma placement, is difficult to parse.) The function ax is tangent to some graph 1 + bx for every base a at the point (0, 1). Thus every base a satisfies a sharp inequality of this type by choosing a suitable constant b. In effect, without motivating the particular choice of coefficients, the statement says that we can find a tangent to ax, a statement which I consider to be worthy of the description "mundane". Also, when looked at like this, it says nothing about the specialness of e. I would say that few people are going to say that 1 + x stands out as clearly more special than say 1 − x. —Quondum 12:08, 1 August 2018 (UTC)
Precisely the same unmotivated choice enters any definition of the number e. Why shouldn't e be the unique number such that ${\displaystyle d/dx(e^{x})=-e^{x}}$? Why is ${\displaystyle e=\lim _{n\to \infty }(1+1/n)^{n}}$ instead of ${\displaystyle \lim _{n\to \infty }(1-1/n)^{n}}$? Why is ${\displaystyle e>1}$ instead of ${\displaystyle <1}$? Perhaps all of these are "mundane observations" that the article is better without? Ultimately, your objection seems to boil down to the contention that a logarithm can have many bases, so there's no reason to prefer e to any other base. Hopefully you now understand why I find that silly in the present context.
Secondly, as you note, if ${\displaystyle a>0}$ then ${\displaystyle a^{x}>1+(\ln a)x}$ for all nonzero x. Conversely, the number ${\displaystyle a=e^{b}}$ is the unique number such that ${\displaystyle a^{x}>1+bx}$ for all nonzero x. Here we are simply taking the special case of ${\displaystyle b=1}$, just like all of the other characterizations. I don't see what that has to do with it being any more mundane than other characterizations present in the article. I think it's rather interesting that the number e can be completely characterized by sharp inequalities, without any reference at all to calculus. Don't you? Sławomir Biały (talk) 20:31, 1 August 2018 (UTC)
I should not have to tell you that notability is a criterion in choosing what to include in an encyclopedia.
For this last "rather interesting" motivation to be valid, how do you propose to mathematically define ax for real a and x such that this does not rely on calculus, limits, or something more abstruse, while not implying exp(x) as a particularly simple case? —Quondum 23:51, 1 August 2018 (UTC)
Lack of notability was not your stated reason for removing it. You removed it because you personally found it mundane. It can be readily sourced to many standard textbooks, which a moment of research would have verified. I'm not going to engage here in original research.
Obviously, any fact about real functions requires the real number system at some level. But this characterization does not use calculus in the way that others do, because they all involve limits very explicitly. I had hoped that you might find it interesting that the convexity of the exponential function, an important fact in analysis, makes possible a characterization of e that does not explicitly use limits, derivatives, or integrals. That is, what is commonly known of as "calculus". Since you're apparently unable to see why it's interesting on your own, though, much more "mundane" arguments favoring the inclusion of the fact can be given, based on it being a standard thing about e that is covered in most modern calculus textbooks. Your personal interest is not required, but it might lighten the mood a bit if you tried. Sławomir Biały (talk) 23:15, 2 August 2018 (UTC)
After some thought, the challenge I posed can be managed algebraically on a restricted domain: R>0 × QR. To answer your final question, no, I do not find this interesting. If I did, I would get more excited about similarly using a sharp inequality to claim that it is possible to differentiate without any reference to calculus.
You seem to be prepared to spend inordinate amounts of energy to avoid overtly conceding that you might have acted in a way that comes across as possibly thoughtless or inconsiderate. My motivation for spending so much energy I need to review: I do not find debate (or co-editing) with you rewarding. —Quondum 19:03, 2 August 2018 (UTC)
Ok, fair enough. I strongly disagree with your removal of the material, and have stated my reasons. Your agreement is not required. The fact that it has been restored with a source is now sufficient. If you have further doubts about the content, I can readily supply more sources. Sławomir Biały (talk) 23:15, 2 August 2018 (UTC)
|
{}
|
## Homework Statement
By substituting y for 9x^2 solve 81x^4 - 63x^2 + 10 = 0
## The Attempt at a Solution
My attempt at a solution is:
y^2 - 7y + 10
(y-2)(y-5)
therefore y = 2 y = 5 Can someone double check this?
Cheers
That's correct. Now solve for x by setting 9x2 equal to each solution of y.
Is this to check the solution?
It just seemed to easy for some reason - maths is not my strong point, might I add.
Cheers
That's correct. Now solve for x by setting 9x2 equal to each solution of y.
Oh I see - are you then saying
9x^2 = 2
9x = +- Sqroot 2
x = + - Sqroot 2/9
9x^2 = 5
9x = +- Sqroot 5
x= + - Sqroot 5/9
Cheers
Mentallic
Homework Helper
Yes that is correct
You can even check for yourself by substituing those x values back into the original quadratic equation. You should find they work.
The only reason it asked you to substitute $$y=9x^2$$ into the equation $$81x^4 - 63x^2 + 10 = 0$$ is because it makes it more simple and easy to see how it should be solved.
Rather than substituing, you could've always factorized it as so:
$$81x^4-63x^2+10=(9x^2-2)(9x^2-5)=0$$
Oh I see - are you then saying
9x^2 = 2
9x = +- Sqroot 2
x = + - Sqroot 2/9
9x^2 = 5
9x = +- Sqroot 5
x= + - Sqroot 5/9
Cheers
√(ab) = √(a)√(b) ≠ a√(b) which is what you did between the first and second lines above.
You need to divide by 9 first, then take the square root of both sides.
$$9x^2 = 2 \rightarrow x^2 = \frac{2}{9} \rightarrow x = \pm\sqrt{\frac{2}{3}} = \pm\frac{\sqrt{2}}{3}$$
Or take the square root of both sides completely, then solve for x
$$9x^2 = 2 \rightarrow \sqrt{9x^2} = \sqrt{2} \rightarrow 3x = \pm\sqrt{2} \rightarrow x = \pm\frac{\sqrt{2}}{3}$$
Mentallic
Homework Helper
Oh when I skimmed through it I read sqroot 2/9 as $$\sqrt{\frac{2}{9}}$$. I didn't believe simplifying was top priority.
Thanks for spotting that Bohrok.
Hi there
Many thanks for both your assistance - it is greatly appreciated.
Cheers P
|
{}
|
## SWP 6.0.27 Creating math underbars
The attached note illustrates an issue with creating underbars to math characters in SWP 6.0.27.
Is the behavior it describes that intended for SWP 6?
AttachmentSize
SWP6027Underbar.sci65.42 KB
### The underline character macro
The underline character macro is \b, and this is a text only macro. Version 5.5 prevents adding the underscore to a character in math mode. Version 6 does not, but the rendering is correct. If you notice the generated LaTeX, it is \$\b{s}\$ and this typesets as upright.
### I have just checked a
I have just checked a document created in SWP 5.5 where the LaTeX is \$\underline{s}\!\$. I recall creating this by adding the underscore to the character in math mode. Be that as it may, when I imported it into SWP 6.0.27, it was rendered as in the attached PDF document.
With that rendering, the underbar does not appear on-screen (though it does in PDF), which indicates that SWP 6.0.27 is not showing properly on-screen what will appear in PDF. It would be great if that were fixed so that the screen shows what will actually appear in PDF.
Incidentally, exporting that MathML code to TeX renders it as \$\underline{s}\/\$, which is slightly different from the original TeX \$\underline{s}\!\$.
### I have reported the problem
I have reported the problem with importing \$\underline{x}\$ not displaying the underline. Deleting the <mrow> object around the <mo stretchy="true">̲ in the source view does display the underline without changing what is exported.
I was not able to reproduce your report of the negative thinspace being exported as an italic correction. Was there something else in the document after what you show?
### Thanks for the explanation. I
Thanks for the explanation.
I attach 3 files that illustrate the imported negative thinspace being exported as an italic correction.
SWP6027UnderbarToImport.tex is a source TeX file
SWP6027UnderbarImport.sci is the file resulting from using Import TeX in SWP 6.0.27
SWP6027UnderbarExport.tex is the TeX file that results from using Export TeX in SWP 6.0.27
Notice that:
1. as already discussed, the imported \$\underline{x}\$ is not displaying the underline in SWP 6.0.27;
2. "\!" towards the end of the paragraph in SWP6027UnderbarToImport.tex has been replaced by "\/" in SWP6027UnderbarExport.tex.
I hope this helps you locate the source of the discrepancy.
|
{}
|
abstractmath.org 2.0
help with abstract math
Produced by Charles Wells Revised 2017-01-19
Introduction to this website website TOC website index blog
# CONDITIONAL ASSERTIONS
This section is concerned with logical constructions made with the connective called the conditional operator. In mathematical English, applying the conditional operator to assertions $P$ and $Q$ produces an assertion that may be written, “If $P$, then $Q$”, or “$P$ implies $Q$”. Sentences of this form are conditional assertions.
Conditional assertions are at the very heart of mathematical reasoning. Mathematical proofs typically consist of chains of conditional assertions.
Some of the narrative formats used for proving conditional assertions are discussed in Forms of Proof.
## The truth table for conditional assertions
A conditional assertion “If $P$ then $Q$” has the precise truth table shown here.
$P$ $Q$ If $P$ then $Q$ T T T T F F F T T F F T
The meaning of “If $P$ then $Q$” is determined entirely by the truth values of $P$ and $Q$ and this truth table. The meaning is not determined by the usual English meanings of the words “if” and “then”.
The truth table is summed up by this purple pronouncement:
The Prime Directive of conditional assertions:
A conditional assertion is true unless
the hypothesis is true and the conclusion is false.
That means that to prove “If $P$ then $Q$” is FALSE
you must show that $P$ is TRUE(!) and $Q$ is FALSE.
The Prime Directive is harder to believe in than leprechauns. Some who are new to abstract math get into an enormous amount of difficulty because they don’t take it seriously.
##### Example
The statement “if $n\gt 5$, then $n\gt 3$” is true for all integers $n$.
• This means that “If $7\gt 5$ then $7\gt 3$” is true.
• It also means that “If $2\gt 5$ then $2\gt 3$” is true! If you really believe that “If $n\gt 5$, then $n\gt 3$” is true for all integers n, then you must in particular believe that “If $2\gt 5$ then $2\gt 3$” is true. That’s why the truth table for conditional assertions takes the form it does.
• On the other hand, “If $n\gt 5$, then $n\gt 8$” is not true for all integers $n$. In particular, “If $7\gt 5$, then $7\gt 8$” is false. This fits what the truth table says, too.
### Remark
Most of the time in mathematical writing the conditional assertions which are actually stated involve assertions containing variables, and the claim is typically that the assertion is true for all instances of the variables. Assertions involving statements without variables occur only implicitly in the process of checking instances of the assertions. That is why a statement such as, “If $2\gt 5$ then $2\gt 3$” seems awkward and unfamiliar.
It is unfamiliar and occurs rarely. I mention it here because of the occurrence of vacuous truths, which do occur in mathematical writing.
## Conditionals and Truth Sets
The set $\{x|P(x)\}$ is the set of exactly all $x$ for which $P(x)$ is true. It is called the truth set of $P(x)$.
##### Examples
• If $n$ is an integer variable, then the truth set of "$3\lt n\lt9$" is the set $\{4,5,6,7,8\}$.
• The truth set of "$n\gt n+1$" is the empty set.
### Weak and strong
“If $P(x)$ then $Q(x)$” means that $\{x|P(x)\}\subseteq \{x|Q(x)\}$. We say $P(x)$ is stronger than $Q(x)$, meaning that $P$ puts more requirements on $x$ than $Q$ does. The objects $x$ that make $P$ true necessarily make $Q$ true, so there might be objects making $Q$ true that don't make $P$ true.
##### Example
The statement "$x\gt4$" is stronger than the statement "$x\gt\pi$". That means that $\{x|x\gt4\}$ is a proper subset of $\{x|x\gt\pi\}$. In other words, $\{x|x\gt4\}$ is "smaller" than $\{x|x\gt\pi\}$ in the sense of subsets. For example, $3.5\in\{x|x\gt\pi\}$ but $3.5\notin\{x|x\gt4\}$. This is a kind of reversal (a Galois correspondence) that confused many of my students.
"Smaller" means the truth set of the stronger statement omits elements that are in the truth set of the weaker statement. In the case of finite truth sets, "smaller" also means it has fewer elements, but that does not necessarily work for infinite sets, such as in the example above, because the two truth sets $\{x|x\gt4\}$ and $\{x|x\gt\pi\}$ have the same cardinality.
Making a statement stronger
makes its truth set "smaller".
### Terminology and usage
#### Hypothesis and conclusion
In the assertion “If $P$, then $Q$”:
• P is the hypothesis or antecedent of the assertion. It is a constraint or condition that holds in the very narrow context of the assertion. In other words, the assertion, “If $P$, then $Q$” does not say that $P$ is true. The idea of the direct method of proof is to assume that $P$ is true during the proof.
• $Q$ is the conclusion or consequent. It is also incorrect to assume that $Q$ is true anywhere else except in the assertion “If $P$, then $Q$”.
#### "Implication"
Conditionals such as “If $P$ then $Q$” are also called implications , but be wary: "implication" is a technical term and does not fit the meaning of the word in conversational English.
• In ordinary English, you might ask, "What are the implications of knowing that $x\gt4$? Answer: "Well, for one thing, $x$ is bigger that $\pi$."
• In the terminology of math and logic, the whole statement "If $x\gt4$ then $x\gt\pi$" is called an "implication".
## Vacuous truth
The last two lines of the truth table for conditional assertions mean that if the hypothesis of the assertion is false, then the assertion is automatically true. In the case that “If $P$ then $Q$” is true because $P$ is false, the assertion is said to be vacuously true.
The word “vacuous” refers to the fact that in the vacuous case the conditional assertion says nothing interesting about either $P$ or $Q$. In particular, the conditional assertion may be true even if the conclusion is false (because of the last line of the truth table).
##### Example
Both these statements are vacuously true!
• If $4$ is odd, then $3 = 3$.
• If $4$ is odd, then $3\neq3$.
##### Example
If $A$ is any set then $\emptyset\subseteq A.$ Proof (rewrite by definition): You have to prove that if $x\in\emptyset$, then $x\in A$. But the statement "$x\in\emptyset$" is false no matter what $x$ is, so the statement "$\emptyset\subseteq A$" is vacuously true.
### Definitions involving vacuous truth
Vacuous truth can cause surprises in connection with certain concepts which are defined using a conditional assertion.
##### Example
• Suppose $R$ is a relation on a set $S$. Then $R$ is antisymmetric if the following statement is true: If for all $x,y\in S$, $xRy$ and $yRx$, then $x=y$.
• For example, the relation "$\leq$" on the real numbers is antisymmetric, because if $x\leq y$ and $y\leq x$, then $x=y$.
• The relation "$\lt$" on the real numbers is also antisymmetric. It is vacuously antisymmetric, because the statement
(AS) "if $x\gt y$ and $y\gt x$, then $x = y$"
is vacuously true. If you say it can't happen that $x\gt y$ and $y\gt x$, you are correct, and that means precisely that (AS) is vacuously true.
### Remark
Although vacuous truth may be disturbing when you first see it, making either statement in the example false would result in even more peculiar situations. For example, if you decided that “If $P$ then $Q$” must be false when $P$ and $Q$ are both false, you would then have to say that this statement
“For any integers $m$ and $n$, if $m\gt 5$ and $5\gt n$, then $m\gt n$”
is not always true (substitute $3$ for $m$ and $4$ for $n$ and you get both $P$ and $Q$ false). This would surely be an unsatisfactory state of affairs.
## How conditional assertions are worded
A conditional assertion may be worded in various ways. It takes some practice to get used to understanding all of them as conditional.
Our habit of swiping English words and phrases and changing their meaning in an unintuitive way causes many problems for new students, but I am sure that the worst problem of that kind is caused by the way conditional assertions are worded.
### In math English
The most common ways of wording a conditional assertion with hypothesis $P$ and conclusion $Q$ are:
• If $P$, then $Q$.
• $P$ implies $Q$.
• $P$ only if $Q$.
• $P$ is sufficient for $Q$.
• $Q$ is necessary for $P$.
### In the symbolic language
• $P(x)\to Q(x)$
• $P(x)\Rightarrow Q(x)$
• $P(x)\supset Q(x)$
Since "$P(x)\supset Q(x)$" means that $\{x|P(x)\}\subseteq \{x|Q(x)\}$, there is a notational clash between implication written “$\supset$” and inclusion written “$\subseteq$”. This is exacerbated by the two meanings of the inclusion symbol "$\subset$".
Math logic is notorious for the many different symbols used by different authors with the same meaning. This is in part because it developed separately in three different academic areas: Math, Philosophy and Computing Science.
##### Example
All the statements below mean the same thing. In these statements $n$ is an integer variable.
• If $n\lt5$, then $n\lt10$.
• $n\lt5$ implies $n\lt10$.
• $n\lt5$ only if $n\lt10$.
• $n\lt5$ is sufficient for $n\lt10$.
• $n\lt10$ is necessary for $n\lt5$.
• $n\lt5\to n\lt10$
• $n\lt5\Rightarrow n\lt10$
• $n\lt5\supset n\lt10$
These ways of wording conditionals cause problems for students, some of them severe. They are discussed in the section Understanding conditionals.
#### Usage of symbols
The logical symbols "$\to$", "$\Rightarrow$", "$\supset$" are frequently used when writing on the blackboard, but are not common in texts, except for texts in mathematical logic.
#### More about implication in logic
If you know some logic, you may know that there is a subtle difference between the statements
• “If $P$ then $Q$”
• “$P$ implies $Q$”.
Here is a concrete example:
1. “If $x\gt2$, then $x$ is positive.”
2. “$x\gt2$ implies that $x$ is positive.”
Note that the subject of sentence (1) is the (variable) number $x$, but the subject of sentence (2) is the assertion "$x\lt2$". Behind this is a distinction made in formal logic between the material conditional “if $P$ then $Q$” (which means that $P$ and $Q$ obey the truth table for "If..then") and logical consequence ($Q$ can be proved given $P$). I will ignore the distinction here, as most mathematicians do except when they are proving things about logic.
In some texts, $P\Rightarrow Q$ denotes the material conditional and $P\to Q$ denotes logical consequence.
## Universal conditional assertions
A conditional assertion containing a variable that is true for any value of the correct type of that variable is a universally true conditional assertion. It is a special case of the general notion of universally true assertion.
##### Examples
1. For all $x$, if $x\lt5$, then $x\lt10$.
2. For any integer $n$, if $n^2$ is even, then $n$ is even.
3. For any real number $x$, if $x$ is an integer, then $x^2$ is an integer.
These are all assertions of the form "If $P(x)$, then $Q(x)$". In (1), the hypothesis is the assertion "$x\lt5$"; in (2), it is the assertion "$n^2$ is even", using an adjective to describe property that $n^2$ is even; in (3), it is the assertion "$x$ is an integer", using a noun to assert that $x$ has the property of being an integer. (See integral.)
### Expressing universally true conditionals in math English
The sentences listed in the example above provide ways of expressing universally true conditionals in English. They use "for all" or "for any", You may also use these forms (compare in this discussion of universal assertions in general.)
• For all functions $f$, if $f$ is differentiable then it is continuous.
• For (every, any, each) function $f$, if $f$ is differentiable then it is continuous.
• If $f$ is differentiable then it is continuous, for any function $f$.
• If $f$ is differentiable then it is continuous, where $f$ is any function.
• If a function $f$ is differentiable, then it is continuous. (See indefinite article.)
Sometimes mathematicians write, "If the function $f$ is differentiable, then it is continuous." At least sometimes, they mean that every function that is differentiable is continuous. I suspect that this usage occurs in texts written by non-native-English speakers.
### Disguised conditionals
There are other ways of expressing universal conditionals that are disguised, because they are not conditional assertions in English.
Let $C(f)$ mean that $f$ is continuous and and $D(f)$ mean that $f$ is differentiable. The (true) assertion
“For all $f$, if $D(f)$, then $C(f)$”
can be said in the following ways:
1. Every (any, each) differentiable function is continuous.
2. All differentiable functions are continuous.
3. Differentiable functions are continuous. Or: "...are always continuous."
4. A differentiable function is continuous.
5. The differentiable functions are continuous.
#### Notes
• Watch out for (4). Beginning abstract math students sometimes don’t recognize it as universal. They may read it as "Some differentiable function is continuous." Authors often write, "A differentiable function is necessarily continuous."
• I believe that (5) is obsolescent. I don’t think younger native-English-speaking Americans would use it. (Warning: This claim is not based on lexicographical research.)
## Assertions related to a conditional assertion
### Converse
The converse of a conditional assertion “If $P$ then $Q$” is “If $Q$ then $P$”.
Whether a conditional assertion is true
has no bearing on whether its converse it true.
##### Examples
• The converse of "If it’s a cow, it eats grass" is "If it eats grass, it's a cow". The first statement is true (let's ignore the Japanese steers that drink beer or whatever), but the second statement is definitely false. Sheep eat grass, and they are not cows..
• The converse of "For all real numbers $x$, if $x > 3$, then $x > 2$." is "For all real numbers $x$, if $x > 2$, then $x > 3$." The first is true and the second one is false.
• "For all integers $n$, if $n$ is even, then $n^2$ is even." Both this statement and its converse are true.
• "For all integers $n$, if $n$ is divisible by $2$, then $2n +1$ is divisible by $3$." Both this statement and its converse are false.
### Contrapositive
The contrapositive of a conditional assertion “If $P$ then $Q$” is “If not $Q$ then not $P$.”
A conditional assertion and its contrapositive
are both true or both false.
##### Example
The contrapositive of "If $x > 3$, then $x > 2$" is (after a little translation) "If $x\leq2$ then $x\leq3$." For any number $x$, these two statements are both true or both false.
This means that if you prove "If not $Q$ then not $P$", then you have also proved "If $P$ then $Q$."
You can prove an assertion by proving its contrapositive.
This is called the contrapositive method and is discussed in detail in this section.
So a conditional assertion and its contrapositive have the same truth value. Two assertions that have the same truth value are said to be equivalent. Equivalence is discussed with examples in the Wikipedia article on necessary and sufficient.
## Understanding conditional assertions
As you can see from the preceding discussions, statements of the form “If $P$ then Q” don’t mean the same thing in math that they do in ordinary English. This causes semantic contamination.
### Examples
#### Time
In ordinary English, “If $P$ then $Q$” can suggest order of occurrence. For example, “If we go outside, then the neighbors will see us” implies that the neighbors will see us after we go outside.
Consider "If $n\gt7$, then $n\gt5$." If $n\gt7$, that doesn't mean $n$ suddenly gets greater than $7$ earlier than $n$ gets greater than $5$. On the other hand, "$n\gt5$ is necessary for $n\gt7$" (which remember means the same thing as "If $n\gt7$, then $n\gt5$) doesn't mean that $n\gt5$ happens earlier than $n\gt7$. Since we are used to "if...then" having a timing implication, I suspect we get subconscious dissonance between “If $P$ then $Q$” and "$Q$ is necessary for $P$" in mathematical statements, and this dissonance makes it difficult to believe that that can mean the same thing.
#### Causation
“If $P$ then $Q$” can also suggest causation. The the sentence, "If we go outside, the neighbors will see us" has the connotation that the neighbors will see us because we went outside.
The contrapositive is "If the neighbors won't see us, then we don't go outside." This English sentence seems to me to mean that if the neighbors are not around to see us, then that causes us to stay inside. In contrast to contrapositive in math, this means something quite different from the original sentence.
#### Wrong truth table
For some instances of the use of "if...then" in English, the truth table is different.
Consider: "If you eat your vegetables, you can have dessert." Every child knows that this means they will get dessert if they eat their vegetables and not otherwise. So the truth table is:
$P$ $Q$ If $P$ then $Q$ T T T T F F F T F F F T
In other words, $P$ is equivalent to $Q$. It appears to me that this truth table corresponds to English "if...then" when a rule is being asserted.
These examples show:
The different ways of expressing a conditional assertion
may mean different things in English
but they always mean the same thing in math --
the meaning given by the truth table
How can I get to the stage where I automatically understand conditional assertions?
You need to understand the equivalence of these formulations so well that it is part of your unconscious reaction to conditionals.
How can you gain that intuitive understanding? One way is by doing abstract math regularly for several years! (Of course, this is how you gain expertise in anything.) In other words, Practice, Practice!
### Rigor
But it may help to remember that when doing proofs, we must take the rigorous view of mathematical objects:
• Math objects don’t change.
• Math objects don’t cause anything to happen.
The integers (like all math objects) just sit there, not doing anything and not affecting anything. $10$ is not greater than $4$ "because" it is greater than $7$. There is no "because" in rigorous math. Both facts, $10\gt4$ and $10\gt7$, are eternally true.
Eternal is how we think of them – I am not making a claim about “reality”.
• When you look at the integers, every time you find one that is greater than $7$ it turns out to be greater than $4$. That is how to think about “If $n > 7$, then $n > 4$”.
• You can’t find one that is greater than $7$ unless it is greater than $4$: It happens that $n > 7$ only if $n > 4$.
• Every time you look at one less than or equal to $4$ it turns out to be less than or equal to $7$ (contrapositive).
These three observations describe the same set of facts about a bunch of things (integers) that just sit there in their various relationships without changing, moving or doing anything. If you keep these remarks in mind, you will eventually have a natural, unforced understanding of conditionals in math.
#### Remark
None of this means you have to think of mathematical objects as dead and fossilized all the time. Feel free to think of them using all the metaphors and imagery you know, except when you are reading or formulating a proof written in mathematical English. Then you have to be rigorous!
## Modus ponens
The truth table for conditional assertions may be summed up by saying: The conditional assertion “If $P$, then $Q$” is true unless $P$ is true and $Q$ is false.
This fits with the major use of conditional assertions in reasoning:
### Modus Ponens
• If you know that a conditional assertion is true
• and you know that its hypothesis is true,
• then you know its conclusion is true.
In symbols:
(1) When “If $P$ then $Q$” and $P$ are both true,
(2) then $Q$ must be true as well.
Modus Ponens is the most used method of deduction of all. It is the proof machine that makes Rewrite according to the definition work.
#### Remark
Modus ponens is not a method of proving conditional assertions. It is a method of using a conditional assertion in the proof of another assertion. Methods for proving conditional assertions are found in the chapter Forms of proof.
## Equivalence of assertions
Assertions $P$ and $Q$ are equivalent if the conditional assertions "If $P$ then $Q$" and "If $Q$ then $P$" are both true or both false. The truth table is:
$P$ $Q$ $P$ equiv $Q$ T T T T F F F T F F F T
Observe that this table differs from the truth table for conditional assertions only in the third line.
### How equivalences are worded
The statement that $P$ and $Q$ are equivalent can be worded in these ways:
• $P$ is equivalent to $Q$.
• $P$ if and only if $Q$.
• $P$ iff $Q$.
• $P\Leftrightarrow Q$.
• $P\leftrightarrow Q$.
## Acknowledgments
Thanks to Eugene Mondkar for catching an error.
|
{}
|
# Can long strings always snap?
In quantum chromodynamics, long flux tubes will always snap because a quark-antiquark pair gets created from the vacuum, and hadronization results with a quark attached to each new end.
In string theory, if we try to stretch a single string out a long distance, will it also snap? If open strings with Neumann boundary conditions are allowed, this can always happen. Suppose this is not the case. If D0-branes exist, we can create a pair of them from the vacuum, and the string will still snap. Even if no D0-branes don't exist, or space filling branes either, as long as we have some Dp-brane for some p in between, the Dp-brane can be wrapped up as finite closed bubble, and we can create a pair of such bubbles. The string will still snap into "tadpoles".
In some string theories, strings carry charges and are BPS states. Can they snap? I doubt it.
-
The D0-brane mass goes like $m_s/g_s$ which is the same mass as $1/g_s$ times the string length of a string. One would need to use a very long piece of string to get the required energy for the creation of the new D0-brane and its antiparticle - and this won't happen. This is true not just for D0-branes but all D-branes - all their tensions are proportional to $1/g_s$.
Alternatively, a D0-brane carries the same mass/energy as a highly excited string mode whose excitation level is $1/g_s$ - well, in fact, it has to be $N\approx 1/g_s^2$ because it's the squared mass that $N$ is proportional to. For such super excited modes, the perturbative approximation of string theory doesn't work. Indeed, the fact that non-perturbative objects such as D0-branes may emerge out of the energy of strings is a way to prove that the perturbative expansions fail.
Non-perturbatively, for large enough values of $g_s$, anything can happen. The perturbative expansions fail, D-branes become as easy-to-be-created as the (no longer) fundamental strings, and there are lots of open strings attached to cheap D0-branes and other D-branes flying in a region with not so high energy.
|
{}
|
# Measuring Human Rights: High School Mathematics Unit
Note: The next two lessons focus on the Body Mass Index (BMI) as one of the indicators used by the UN to evaluate the degree to which certain populations have adequate food. Be aware that many students may have low self-esteem due to their body weight. This lesson does not focus on issues of obesity and students will not be asked to measure their own weight or calculate their BMI. Rather, we will explore this issue from a population health perspective. The notion of standard weight for children and the classification for BMI are useful as indicators for evaluating populations, not individuals.
In the previous lessons, we focused on the weight of children under five years of age as an indicator for malnutrition (thus lack of adequate food for a population). In this lesson, we examine the BMI of adults in which BMI<18.5 is an indicator of underweight. The notion of BMI has several limitations, which are discussed in the lesson.
### Prior knowledge required for the unit
• The ability to convert between U.S. and SI
• The ability to solve two variable equations
• An understanding of percent
### Learning Objectives
Students will be able to:
• Understand the function, and calculate the value of BMI.
• Create a two-way frequency table from two categorical variables; read and interpret data displayed in a two-way table.
• Write clear summaries of data displayed in a two-way frequency table.
• Use BICC frequency table to organize real world data.
• Calculate various types of relative frequencies.
• Make comparisons between two data sets using relative frequencies
• Calculate joint, marginal, and conditional relative frequencies.
• Describe patterns observed in the data. Recognize the association between two variables by comparing conditional and marginal percentages.
Math Content Standards
• S.ID.5. Summarize categorical data for two categories in two-way frequency tables. Interpret relative frequencies in the context of the data (including joint, marginal, and conditional relative frequencies). Recognize possible associations and trends in the data.
Math Practice Standards
• MP.1 Make sense of problems and persevere in solving them.
• MP.2 Reason abstractly and quantitatively.
• MP.3 Construct viable arguments and critique the reasoning of others.
• MP.4 Model with mathematics.
• MP.5 Use appropriate tools strategically
## Instructional Approach
The United Nations uses two main indicators to measure the degree to which people in countries around the world have adequate food (and are making progress on Article 25):
• The prevalence (in %) of children <5 who are underweight
• The proportion of adults with body mass index (BMI) <18.5
This lesson is focused on understanding the second indicator: the proportion of adults with body mass index (BMI) <18.5.
### Teacher Explanation
• We begin this lesson by asking students:“What is BMI?” Body Mass Index (BMI) is a simple index of weight-for-height that is commonly used to classify adults into categories such as underweight, overweight and obese. A Belgian statistician named Quetelet developed this index over 100 years ago and it is still often used today to determine people’s weight category. In fact, the index has become popularized in gyms and exercise programs.
• BMI is defined as the weight in kilograms divided by the square of the height in meters (kg/m2).
BMI= Weight(kg) / (Height(meters))2
• In the media, BMI is often talked about in the context of overweight and obesity. However, when used as an indicator for human rights (Article 25) the focus is on measuring the degree to which an individual’s BMI is lower than 18.5, which indicates that the person is underweight.
• Project the table below and explain to the students that these are the cut-off points for classifying people’s weight status according to their BMI.
• The United Nations follows these guidelines and therefore uses the proportion of adults with body mass index (BMI) <18.5 as an indicator for the human right of having adequate food. As more people move from the category of underweight to normal range, then the region is making progress in providing adequate food to its citizens.
Source: Adapted from WHO, 1995, WHO, 2000 and WHO 2004.
BMI = Weight(kg) / (Height(meters))2
• Let’s look more closely at how we figure out the BMI of an individual. (Please note: you will not need to measure your BMI or anyone else in the class).
Example 1
Suppose a person weighs 40 kg, and his/her height is 1.7 meters, what would be his/her BMI? Would that person be classified as underweight?
Demonstrate step by step how you calculated your answer to this question.
Example 2
Project the slide of LeBron James.
Inform students that at the peak of his career, LeBron was 6’8” tall and weighed 250 lbs.
Tell students that together they are going to calculate his BMI.
• Before you begin, write on the board the following conversions units:
1 Meter (m) = 39.36 inches
1 Kilogram (kg) = 2.202 lbs.
• If needed, provide guiding questions. It is okay to use calculators!
Step 1:
Conversion from U.S. system to SI system
6’8” =80”
80/39.36= 2.03 meters
250 lbs./2.202 =113.53 kg.
Step 2:
Use the BMI formula
BMI= 113.53/(2.03)^2= 27.55
Looking at the BMI classification chart, and using LeBron’s BMI, ask students to classify LeBron into the correct weight category (overweight).
Ask students: Does that make sense?
• Inform students that this is one of many examples in which the BMI classification fails to accurately describe a person. In general, BMI is a crude measure and does not take into account other factors that influence health, such as body frame and muscularity. The BMI does not differentiate between fat and muscle weight so many athletes end up being classified as overweight, and even obese, when in fact they are in good health with very little fat on their body. In addition, remind students that BMI is an indicator designed to categorize adults, NOT children or teens.
• Why use BMI at all?
This is a great opportunity to highlight the difference between population and individuals. On a population basis – when we look at large quantities (e.g. millions) of BMI numbers – it is a useful measure because it actually correlates with health risk related to being underweight or overweight. However, on an individual basis it is more problematic.
### Small Group Work
• Divide students into small groups (2-3)
• Distribute Handout#1 and ask them to work together to complete it.
### All Class Discussion
• Project the questions from Handout #1 one by one and ask volunteers to answer these questions. Make sure to rotate between students from different groups.
• Encourage students to share their answers and be forthright if do not agree with the presenter’s explanation.
### Assessment:
Check for student understanding and assess learning through work on Handouts and participation in small and large group discussions.
|
{}
|
## Sunday, May 10, 2015
### Using Git and GitHub to Archive Data
This blog post is for those of you who have never used Git or GitHub. I use Git and GitHub to archive my behavioral data. These data are uploaded to GitHub, an open web repository where it may be viewed by anyone at any time without any restrictions. This upload occurs nightly, that is, the data are available within 24 hours of their creation. The upload is automatic---no lab personnel is needed to start it or approve it. The upload is comprehensive in that all data files from all experiments are uploaded, even those that correspond to aborted experimental runs or pilot experiments. The data are uploaded with time stamps and with an automatically generated log. The system is versioned so that any changes to data files are logged, and the new and old versions are saved. In summary, if we collect it, it is there, and it is transparent. I call data generated this way as Born Open Data.
Since setting up the born-open-data system, I have gotten a few queries about Git and GitHub, the heart of the system. Git is the versioning software; GitHub is a place on the web (github.com) where the data are stored. They work hand in hand.
In this post, I walk through a few steps of setting up GitHub for archiving. I take the perspective of Kirby, my dog, who wishes to archive the following four photos of himself:
Here are Kirby's steps:
1. The first step is to create a repository on the GitHub server.
1a. Kirby goes to GitHub (github.com) and signs up for a free account (last option). Once the account is set up (with user name KirbyHerby) he is given a screen with a lot of options for exploring GitHub. He ignores these as they are not relevant for his task.
1b. To create his first repository on the server, Kirby presses the green button that says + New repository" on the bottom left.
1c. Kirby now has to make some choices about the repository. He names it data," enters a description of the repository, makes it public,
initializes it with a README and does not specify which files to ignore or a license. He then presses the green Create repository" button on the bottom, and is given his first view of the repository
Kirby's repository is now at github.com/KirbyHerby/data, and he will bark out this URL to anyone interested. The repository contains only the README.md file at this point.
2. The next step is getting a linked copy of this repository on Kirby's local computer.
2a. Kirby downloads the GitHub application for his operating system (mac.github.com} or windows.github.com), and on installation, chooses to install the command-line tools (trust me, you will use these some day).
2b. Kirby enters his GitHub username (KirbyHerby") and password.
2c. He next has to create a local repository and link it to the one on the server. To do so, he chooses to Add repository" and is given a choice to Add," Create," or Clone." Since the repository already exists at GitHub, he presses Clone." A list of his repositories shows up, and in this case, it is a short list of one repository, data." Kirby then selects data" and presses the bottom button Clone repository." The repository now exists on the local computer under the folder data." There are two, separate copies of the same repository: one on the GitHub server and one on Kirby's local machine.
3. Kirby wishes add files to the server repository so others may see them.
3a. Kirby first adds the photo files to the local repository as follows: Kirby copies the photos to the files in the usual way, which for Mac-OSX is by using the Finder. The following screen shot shows Finder window in the foreground and the GitHub client window in the background. As can be seen, Kirby has added three files, and these show up in both applications. Kirby has no more need for the Finder and closes it to get a better view of the local repository in the GitHub client window.
3b. Kirby is now going to save the updated state of the local repository, which is called committing it. Committing a local action, and can be thought of as a snapshot of the repository at this point in time. Kirby turns his attention to the bottom part of the screen. To commit, Kirby must add a log entry, which in this case is, Added three great photos." The log will contain not only this message, but a description of what files were added, when, and by whom. This log message is enforced---one cannot make a commit without it. Finally Kirby presses Commit to master."
3c. Kirby now has to push his changes to the repository to the GitHub server so everyone may see them. He can do so by pressing the sync" button.
That's it. Kirby's additions are now available to everyone at github.com/KirbyHerby/data
Suppose Kirby realizes that he had forgotten his absolutely favorite photo of him hugging his favorite toy, Panda. So he copies the photo over in Finder, commits a new version of the repository with a new message, and syncs up the local with the GitHub server version.
There is a lot more to Git and GitHub than this. Git and GitHub are very powerful, so much so that they are the default for open-source software development world wide. Multiple people may work on multiple parts of the same project. Git and GitHub have support for branches, tagging versions, merging files, and resolving conflicts. More about the system may be learned by studying the wonderful Git Book at git-scm.com/book/en/v2.
Finally, you may wonder why Kirby wanted to post these photos. Well, Kirby doesn't know anything about Bayesian statistics, but he is loyal. He knows I advocate Bayes factors. He also knows that others who advocate ROPEs and credible intervals sell their wares with photos of dogs. Kirby happens to believe that by posting these, he is contributing to my Bayes-factor cause. After all, he is cuter than Kruschke's puppies and perhaps he is more talented. He does know Git and GitHub and has his own repository to prove it.
|
{}
|
# differential equations - solution curves
Solve the differential equation (y')^2= 4y to verify the general solution curves and singular solution curves. Determine the points (a,b) in the plane for which the initial value problem (y')^2= 4y, y(a)= b has (a) no solution , (b) infinitely many solutions that are defined for all values of x (c) on some neighborhood of the point x=a , only finitely many solutions.
general solution that i am getting is y (x) = (x-c)^2 and singular solution is y(x)=0.
I wish a clarification in the second part. The family of curves consists on parabolas with vertex varying on the x-axis. I need someone to explain how to proceed to find suitable choice of (a,b) in each part.
-
The solutions are the ones you listed.
The solutions all have shape $y=(x-c)^2$ or $y=0$. Thus if $b<0$, then none of the solutions curves pass through $(a,b)$. So for all pairs $(a,b)$ such that $b<0$, there cannot be a solution satisfying $y(a)=b$. We do not know (yet) whether these are all the pairs $(a,b)$ for which there is no solution, but soon we will.
For any $a$, if $b=0$ there are exactly two solutions satisfying $y(a)=b$, the singular solution and the solution $y=(x-a)^2$.
Finally, we look at pairs $(a,b)$ with $b$ positive. We look for values of $c$ such that $y(a)=b$.
The solution $y=(x-c)^2$ passes through $(a,b)$ if and only if $(a-c)^2=b$. This equation has exactly two solutions, $c=a\pm\sqrt{b}$.
Conclusion: (a) The pairs $(a,b)$ for which there is no solution satisfying $y(a)=b$ are all $(a,b)$ with $b<0$. (b) There are no pairs $(a,b)$ for which there are infinitely many solutions with initial condition $y(a)=b$. (c) For all remaining pairs $(a,b)$, that is, all pairs with $b \ge 0$, there are finitely many solutions, indeed exactly two solutions that satisfy $y(a)=b$.
The geometry: The conclusion can also be reached geometrically, by visualizing the family of parabolas. All of your parabolas are obtained by sliding the standard parabola $y=x^2$ along the $x$-axis. For any $(a,b)$ with $b \gt 0$, there are exactly two such parabolas that pass through (a,b): one whose "left" half goes through $(a,b)$, and one whose "right" half goes through $(a,b)$.
Note: One could interpret the word "finite" to include the possibility of $0$ solutions: $0$ is certainly finite! That is obviously not the intended interpretation here. But if we interpret "finite" as including $0$, the answer to (c) is all pairs $(a,b)$.
-
Thank you so much for your reply. It would be of great help if you can please help me visualize the parts (b) and (c)geometrically. Because it seems to me graphically that in part (b), there are infinitely many solutions if b is greater than or equal to zero. – Tav Aug 16 '11 at 18:44
However, in part (c) if we move in delta neighborhood of point a, graphically it seems to be that we will have two distinct solutions. – Tav Aug 16 '11 at 18:56
@Tavleen: It could be partly a matter of interpreting the question, so do check exact wording. Right now it asks for all pairs $(a,b)$ for which there are infinitely many solutions $y(x)$ such that $y(a)=b$. So $(a,b)$ is temporarily fixed, like $(-1,7)$. Only two of your parabolas go through $(-1,7)$. Think of sliding the vertex of $y=x^2$ along the $x$-axis. We get your parabolas. Such a slid $y=x^2$ can go through $(-1,7)$ in only two ways: (i) the left half goes through $(-1,7)$; (ii) the right half goes through $(-1,7)$. – André Nicolas Aug 16 '11 at 19:02
thanks for your help . – Tav Aug 18 '11 at 18:05
|
{}
|
+0
# What does this sign mean?
+2
147
4
+323
I know I sound a little stupid by saying this, but in one of my textbooks, I saw this sign and I got all confused. What does it mean and how is it any different from the second one?
Image 1:
Image 2:
Oct 18, 2020
#1
+323
+2
Oh wait, is this what it is?
=
Oct 19, 2020
#2
+112533
+1
I just wrote a post explaining it and now it has disappeared.
But what you have said is correct.
Oct 19, 2020
#3
+112533
+1
The first one says square all the terms, then add them up.
the second one is the other way around.
for example
$$\displaystyle{\sum_i^3}x_i^2=1^2+2^2+3^2=1+4+9=14\\~\\ \left(\displaystyle{\sum_i^3}x_i \right)^2=(1+2+3)^2=6^2=36$$
Oct 19, 2020
#4
+323
+2
Ok, thanks! I get what it is now. I saw you composing an answer and all of a sudden it stopped. I had a feeling you either went AFK or there was a glitch.
Nacirema Oct 19, 2020
|
{}
|
# GRrrrr part 1.
So they've found gravitational waves. Damn.
This post is not a report about that; I don't understand it well enough to report. This post is the first in a two-part report about my confusion and chagrin.
Let's start with the chagrin; I'd been hopping without hope that gravitational waves would never be found. Like all good scientists should I had been hoping the accepted wisdom was wrong. The tackling of such errors is how science progresses.
But why pin my hopes on gravitational waves in particular? They seem innocent enough as consequence of the central equation in general relativity -- the Einstein equation, which relates gravity to space-time curvature, and that to energy and hence to mass and thence back again to gravity. When you squint at the Einstein equation the right way it turns into perfectly good wave equation.
The doubts creep in when you consider the energetics. Like all waves, they should carry energy away from their sources, and indeed our first observational evidence for gravitational waves was of two block-holes loosing energy as they orbited each-other.
But defining gravitational energy is a tricky and fraught issue -- you can even write down the law of conservation of energy in the form
$$0 = T^{\mu\nu}_{;\nu},$$
which is valid and yet seems to simply ignore gravity. Because of this kind of confusion, Einstein and some others even went through a phase of believing that gravitational waves could not exist, or at least that they could not carry energy away.
Eventual such doubts were put to rest and the consensus emerged that gravitational waves could and did exist, and that they did carry energy away, even if we don't quite know what that means.
But I had been hoping without hope that this consensus was wrong, and that its failure would crack open the puzzle of gravitational energy. As long as no gravitational waves had been detected, I had some slight cause for optimism.
But now all hope is gone.
|
{}
|
×
# Find the angle
Find the value of $$\theta$$
Please give the solution too. .
Note by Lakshya Singh
1 year ago
Sort by:
See this. · 1 year ago
But the values for this question do not satisfy the method which you have sent in the link Abhay. · 1 year ago
Similar question. · 1 year ago
|
{}
|
# fastest matrix multiplication on x86
This challenge requires integration with C, so you can stop reading if you're not interested.
Matrix multiplication is a simple operation, but the performance depends a lot on how efficiently the code is written.
Let's compute m = x * y. The following code is the implementation of the textbook algorithm.
for (int i = 0; i < n; ++i) {
for (int j = 0; j < n; ++j) {
float s = 0;
for (int k = 0; k < n; ++k) {
s += x[i * n + k] * y[k * n + j];
}
m[i * n + j] = s;
}
}
It looks fine, but actually performs quite bad for various reasons.
Simply reordering the operations to let only row access happen is a significant optimization.
//m is zeroed
for (int i = 0; i < n; ++i) {
for (int j = 0; j < n; ++j) {
float e = x[i * n + j];
for (int k = 0; k < n; ++k) {
m[i * n + k] += e * y[j * n + k];
}
}
}
This version is about 9.5 times faster than the upper one on my PC. Well, it's quite an optimal environment because in the actual implementation, I gave the compiler a lot of hints to make it auto-vectorize the second version up to the point where I couldn't gain any performance by manually vectorizing. But that's one of the problems of the first version. Column-accessing makes vectorization almost impossible to be done automatically and often not worthy to be done manually.
However, both versions are just the implementation of the most basic algorithm we all might know. I'd like to see what else could be done for a faster matrix multiplication on a restricted x86 environment.
The following restrictions are for simpler and clearer comparison between the algorithms.
• At most one thread can run during the program.
• The allowed x86 extensions are AVX2 and FMA.
• You must provide a C interface with the following prototype.
void (*)(void *m, void *x, void *y)
It does not have to be implemented in C, but you have to provide a way to be called from C.
m, x, and y point to 3 different arrays of 64 * 64 = 4096 floats that are aligned on a 32-byte boundary. These arrays represent a 64x64 matrix in row-major order.
You will be given randomly initialized matrices as input. When all outputs are done, first, the time taken will be measured, and then, a simple checksum will be calculated to check the correctness of the operation.
The table shows how much time the two example implementations shown earlier, each named mat_mul_slow and mat_mul_fast, takes to finish the test.
mat_mul_slow mat_mul_fast
~19.3s ~2s
The measurement will be done on my machine with an Intel Tiger Lake CPU, but I will not run code that seems to be slower than mat_mul_fast.
Built-ins are fine, but it should be open source so that I can dig in their code to see what they've done.
The attached code is the tester and the actual implementation of the examples, compiled by gcc -O3 -mavx2 -mfma.
#include <stdio.h>
#include <stdalign.h>
#include <string.h>
#include <time.h>
#include <math.h>
#include <x86intrin.h>
enum {MAT_N = 64};
typedef struct {
alignas(__m256i) float m[MAT_N * MAT_N];
} t_mat;
static void mat_rand(t_mat *_m, int n) {
unsigned r = 0x55555555;
for (int i = 0; i < n; ++i) {
float *m = _m[i].m;
for (int j = 0; j < MAT_N * MAT_N; ++j) {
r = r * 1103515245 + 12345;
m[j] = (float)(r >> 16 & 0x7fff) / 0x8000p0f;
}
}
}
static unsigned mat_checksum(t_mat *_m, int n) {
unsigned s = 0;
for (int i = 0; i < n; ++i) {
float *m = _m[i].m;
for (int j = 0; j < MAT_N * MAT_N; ++j) {
union {float f; unsigned u;} e = {m[j]};
s += _rotl(e.u, j % 32);
}
}
return s;
}
__attribute__((noinline))
static void mat_mul_slow(void *_m, void *_x, void *_y) {
enum {n = MAT_N};
float *restrict m = __builtin_assume_aligned(((t_mat *)_m)->m, 32);
float *restrict x = __builtin_assume_aligned(((t_mat *)_x)->m, 32);
float *restrict y = __builtin_assume_aligned(((t_mat *)_y)->m, 32);
for (int i = 0; i < n; ++i) {
for (int j = 0; j < n; ++j) {
float s = 0.0f;
for (int k = 0; k < n; ++k) {
s = fmaf(x[i * n + k], y[k * n + j], s);
}
m[i * n + j] = s;
}
}
}
__attribute__((noinline))
static void mat_mul_fast(void *_m, void *_x, void *_y) {
enum {n = MAT_N};
float *restrict m = __builtin_assume_aligned(((t_mat *)_m)->m, 32);
float *restrict x = __builtin_assume_aligned(((t_mat *)_x)->m, 32);
float *restrict y = __builtin_assume_aligned(((t_mat *)_y)->m, 32);
memset(m, 0, sizeof(t_mat));
for (int i = 0; i < n; ++i) {
for (int j = 0; j < n; ++j) {
float e = x[i * n + j];
for (int k = 0; k < n; ++k) {
m[i * n + k] = fmaf(e, y[j * n + k], m[i * n + k]);
}
}
}
}
/*static void mat_print(t_mat *_m) {
int n = MAT_N;
float *m = _m->m;
for (int i = 0; i < n; ++i) {
for (int j = 0; j < n; j += 8) {
for (int k = 0; k < 8; ++k) {
printf("%f ", m[i * n + j + k]);
}
putchar('\n');
}
}
putchar('\n');
}*/
static void test(void (*f)(void *, void *, void *), t_mat *xy, t_mat *z,
int n) {
clock_t c = clock();
for (int i = 0; i < n; ++i) {
f(z + i, xy + i * 2, xy + i * 2 + 1);
}
c = clock() - c;
printf("%u %f\n", mat_checksum(z, n), (double)c / (double)CLOCKS_PER_SEC);
}
#define TEST(f) test(f, xy, z, n)
int main() {
enum {n = 0x20000};
static t_mat xy[n * 2];
static t_mat z[n];
mat_rand(xy, n * 2);
puts("start");
for (int i = 0; i < 2; ++i) {
TEST(mat_mul_slow);
TEST(mat_mul_fast);
}
return 0;
}
https://godbolt.org/z/hE9b9vhEx
• If you are just looking for speed of matrix-matrix multiplications, I suspect LAPACK and BLAS will beat most anything people could write having had 30+ years of hardcore optimisations. May 30 at 21:45
# C (GCC), 2.65× faster than mat_mul_fast
(Compiled with gcc -O3 -mavx2 -mfma, measured on my Intel Comet Lake i7-10710U.)
#include <x86intrin.h>
enum { MAT_N = 64 };
void mat_mul_simd(void *_m, void *_x, void *_y) {
enum { n = MAT_N };
float(*m)[n] = _m, (*x)[n] = _x, (*y)[n] = _y;
for (int i = 0; i < n; ++i) {
__m256 mi[n / 8];
for (int k = 0; k < n / 8; ++k)
mi[k] = _mm256_setzero_ps();
for (int j = 0; j < n; ++j) {
for (int k = 0; k < n / 8; ++k)
}
for (int k = 0; k < n / 8; ++k)
_mm256_store_ps(&m[i][k * 8], mi[k]);
}
}
https://godbolt.org/z/xxvr45b67
## C (GCC 11)
This completely auto-vectorized code is very nearly as fast as the above in GCC 11 (gcc -O3 -mavx2 -mfma), but regresses significantly in GCC 12. Auto-vectorization is fragile. 😞
enum { MAT_N = 64 };
void mat_mul_auto(void *_m, void *_x, void *_y) {
enum { n = MAT_N };
float(*restrict m)[n] = __builtin_assume_aligned(_m, 32);
float(*restrict x)[n] = __builtin_assume_aligned(_x, 32);
float(*restrict y)[n] = __builtin_assume_aligned(_y, 32);
for (int i = 0; i < n; ++i) {
float mi[n] = {};
for (int j = 0; j < n; ++j)
for (int k = 0; k < n; ++k)
mi[k] += x[i][j] * y[j][k];
for (int k = 0; k < n; ++k)
m[i][k] = mi[k];
}
}
https://godbolt.org/z/h4GEqGjGW
• Interesting.. If I didn't miss something, this is the exact same algorithm while the difference is that the stores are deferred to the end of the inner loop. Maybe out-of-order execution makes the difference a bit less, but still significant. May 31 at 3:24
• I get 2.05s vs 0.79s, so very similar to your measurement. May 31 at 3:25
• Oh, and I also my fast version does memory load for the zeroed vector. That's another problem. May 31 at 3:30
• Do you get similar results with clang and icc? May 31 at 7:45
|
{}
|
• FREE GMAT Exam
Know how you'd score today for $0 Available with Beat the GMAT members only code • Award-winning private GMAT tutoring Register now and save up to$200
Available with Beat the GMAT members only code
• Free Veritas GMAT Class
Experience Lesson 1 Live Free
Available with Beat the GMAT members only code
• Free Practice Test & Review
How would you score if you took the GMAT
Available with Beat the GMAT members only code
• 5 Day FREE Trial
Study Smarter, Not Harder
Available with Beat the GMAT members only code
• Magoosh
Study with Magoosh GMAT prep
Available with Beat the GMAT members only code
• 5-Day Free Trial
5-day free, full-access trial TTP Quant
Available with Beat the GMAT members only code
• Free Trial & Practice Exam
BEAT THE GMAT EXCLUSIVE
Available with Beat the GMAT members only code
• Get 300+ Practice Questions
Available with Beat the GMAT members only code
• 1 Hour Free
BEAT THE GMAT EXCLUSIVE
Available with Beat the GMAT members only code
## Profile Evaluation Please GMAT 660 Q 49 V33 10 + year exp
This topic has 2 expert replies and 1 member reply
ravi.uppal2004 Junior | Next Rank: 30 Posts
Joined
29 Jun 2015
Posted:
13 messages
#### Profile Evaluation Please GMAT 660 Q 49 V33 10 + year exp
Wed Jul 01, 2015 6:37 am
Hi,
I am a male candidate from India and recently appeared for my GMAT and scored Q49 and V 33 with total of 660 and a 5.5 in AWA , I will have 10 + years of experience and have been in the Management Consulting Six Sigma Industry..7 years in India and 3 + year in US
My GPA at graduation was in the range of 2.5 to 3 as it was not up to the mark during the time period i also pursued Master’s degree with a GPA 3.7
My Bachelor’s degree was in Economics and the Master’s degree was in Accounting and International Business
Please let me know what are my options and which schools should i be targeting for a accelerated MBA/Full time MBA in the US, Singapore, Australia and India -- I am keeping my options open and am flexible to move to any country to purse my education, though I have been in the US for the last 3 years and would prefer to apply to schools out here
Also do I have any scope to apply for a Financial Aid as i will be funding my education myself and come from a middle class family?
Regards,
Ravi Uppal
### GMAT/MBA Expert
CriticalSquareMBA Legendary Member
Joined
18 Apr 2013
Posted:
1088 messages
Followed by:
51 members
171
Thu Jul 09, 2015 6:49 am
Hi Ravi,
Thanks for the post! First questions first - any chance at retaking that GMAT?
_________________
Critical Square | MBA Admissions Services
ravi.uppal2004 Junior | Next Rank: 30 Posts
Joined
29 Jun 2015
Posted:
13 messages
Thu Jul 09, 2015 11:43 am
At my age it is getting tougher to commit the amount of time required for retaking the test and also
i don’t know how much more can i improve on my verbal without a lot a practice
however if it come to it..i will consider . However as i am very sure that i will be
financing the MBA myself , i don’t think i will be able to afford the top 10 anyway without a grant
..
Attaching my profile as well
Attachments
### GMAT/MBA Expert
CriticalSquareMBA Legendary Member
Joined
18 Apr 2013
Posted:
1088 messages
Followed by:
51 members
171
Thu Jul 09, 2015 12:51 pm
Ok...we get that. Totally understand - the GMAT takes a ton of time and it sure isn't fun! But...a couple of things. Let's forget about the scholarship component. Getting INTO the top 10, or 20, or even 30, in the US won't happen with a 660. Maybe you could squeak into a 28, 29, or 30 ranked school but it'd be dicey. Secondly, with your profile and age, even with a stellar GMAT, a fellowship to a top program probably isn't going to happen. I know that probably isn't what you want to hear but it's our policy to shoot you straight - no BS. So if you don't retake that test, getting into a good school is going to be tough when you have other things in your profile working against you like your demographic and age.
_________________
Critical Square | MBA Admissions Services
### Top First Responders*
1 GMATGuruNY 64 first replies
2 Rich.C@EMPOWERgma... 48 first replies
3 Brent@GMATPrepNow 39 first replies
4 Jay@ManhattanReview 24 first replies
5 Terry@ThePrinceto... 10 first replies
* Only counts replies to topics started in last 30 days
See More Top Beat The GMAT Members
### Most Active Experts
1 GMATGuruNY
The Princeton Review Teacher
128 posts
2 Rich.C@EMPOWERgma...
EMPOWERgmat
114 posts
3 Scott@TargetTestPrep
Target Test Prep
92 posts
4 Jeff@TargetTestPrep
Target Test Prep
90 posts
5 Max@Math Revolution
Math Revolution
85 posts
See More Top Beat The GMAT Experts
|
{}
|
Q. 82
Expert-verified
Found in: Page 741
### Physics for Scientists and Engineers: A Strategic Approach with Modern Physics
Book edition 4th
Author(s) Randall D. Knight
Pages 1240 pages
ISBN 9780133942651
# a. Find an expression for the capacitance of a spherical capacitor, consisting of concentric spherical shells of radii (inner shell) and (outer shell).b. A spherical capacitor with a gap between the shells has a capacitance of . What are the diameters of the two spheres?
a. The expression for the capacitance of a spherical capacitor, consisting of concentric spherical shells of radii andis
b. The diameters of the two spheres are and
See the step by step solution
## Step 1: Concept Introduction (Part a)
Concentric Spherical Capacitor:
In a spherical capacitor, either a concentric or a concentric hollow conductor surrounds a solid or hollow spherical conductor with a dissimilar radius.
## Step 2: Explanation (Part a)
Using the formula below, we can calculate the electric field outside a charged conducting sphere,
Here is the charge and is the electric field.
Integrate the electric field along the radial direction for the two concentric spheres to determine the potential difference between them.
Therefore
## Step 3: Explanation (Part a)
The formula to find capacitance is as follows,
Substitute for
Therefore, the capacitance of the capacitor is
## Step 4: Final Answer (Part a)
Hence, the expression for the capacitance of a spherical capacitor, consisting of concentric spherical shells of radii and is
## Step 5: Concept Introduction (Part b)
Concentric Spherical Capacitor:
In a spherical capacitor, either a concentric or a concentric hollow conductor surrounds a solid or hollow spherical conductor with a dissimilar radius.
## Step 6: Explanation (Part b)
Find the inner and outer radii of the spherical shells in the capacitor.
Substitute for and rearrange the above equation in the form of .
Substitute for for for , and for in the above equation.
## Step 7: Explanation (Part b)
Now, calculate the value of
Substitute for for .
Therefore,
Also,
Solve equation (1) and (2),
Therefore,
Calculate the diameter of the inner spherical shell.
Calculate the diameter of the outer spherical shell.
## Step 8: Final Answer (Part b)
Hence, the diameter of the inner and the outer spherical shells are and
|
{}
|
# Meowfficer
Meowfficers are companions that you can assign to your fleets in the fleet composition screen. They can strengthen your fleet with "Skills" and "Abilities" to turn the battle in your favor.
## Formation
Meowfficers can be equipped in the Formation screen or from the "Meowfficer" tab when selecting fleets for Hard Mode. 2 Meowfficers can be assigned to any one fleet and be given either the "Command Meowfficer (指揮にゃ)" or the "Staff Meowfficer (参谋にゃ)" ranks. Identical Meowfficers cannot be assigned to the same fleet.
Viewing from left to right and top to bottom in the Meowfficer panel in the fleet composition screen, you will see:
• Your Meowfficer's icon and name
• Your Meowfficer's skill (skills of identical Meowfficers do not stack)
• Fleet stat percentage increases in white text from the Meowfficers' stats.
• Fleet stat increase in green text from the Meowfficers' Abilities.
### Experience
When equipped in a fleet, they participate in battle and gain XP. The amount given to each Meowfficer in a battle is conjectured to be
$\text{fleet oil cost} \times \text{fleet multiplier} + \text{chapter bonus}$
The fleet multiplier is about 30% for non-boss fleets and about 50% for boss fleets, but more research needs to be done on the exact calculation.
Chapter bonus depends on chapter:
Chapter 1 2 3 4 5 6 7 8 9 10 11 12 13
Normal mode bonus 0 0 0 0 0 1 1 1 2 2 3 4 ?
Hard mode bonus 0 0 0 1 1 1 2 2 ? n/a n/a n/a n/a
Bonus for event chapters varies, but typically all Normal mode event chapters have 0 bonus, Hard mode chapters have 1-3 bonus, and SP maps have 4 bonus.
Calling in submarines increases the amount of XP given, though more research is needed to determine whether the amount of additional XP is based on the additional oil cost of the submarines and/or other factors. Meowfficers assigned to the submarine fleet also gain the same amount of experience as the surface fleet when they are called in.
## Cat Lodge
The "Cat Lodge" is where the Meowfficers live. It can be found in the main menu under the HQ button.
### Crafting
You can acquire "Cat Boxes" from the Cattery via the "Akashi Express", from which you can get a free Cat Box each day (between daily resets). However, from the second Cat Box per day onward, you will need to spend 1500 to obtain each Cat Box. Rarity is determined as follows:
Cat Box Construction
Rare Elite Super Rare
60% 35% 5%
Once you have some Cat Box(es), you still need to open them in the Training tab of the Cattery. Similar to shipgirls, this takes a certain amount of time depending on which Meowfficer is in the box.
Notes:
• The maximum number of Cat Boxes you can craft each day is 15; after reaching that limit you cannot purchase any further boxes until reset.
• You may train a maximum of 4 Cat Boxes at the same time in the Cattery!
There are two Tasks (one daily, one weekly) related to training Meowfficers.
ネコハコを1つ訓練する
Train 1 Cat Box.
1x Rare Cat Box
ネコハコを10つ訓練する
Train 10 Cat Boxes.
1x Elite Cat Box
As Meowfficers gain experience, they will level up. The maximum attainable level is 30. The amount of XP needed per level is as follows (rows highlighed with green show levels at which Talent Points are obtained):
Level Rare Elite Super Rare
XP to Next Total XP to Next Total XP to Next Total
1 100 0 100 0 100 0
2 200 100 200 100 200 100
3 300 300 300 300 400 300
4 400 600 400 600 700 700
5 500 1000 600 1000 1100 1400
6 600 1500 900 1600 1600 2500
7 800 2100 1300 2500 2300 4100
8 1100 2900 1800 3800 3200 6400
9 1500 4000 2400 5600 4300 9600
10 2000 5500 3200 8000 5600 13900
11 2600 7500 4200 11200 7100 19500
12 3400 10100 5400 15400 8900 26600
13 4400 13500 6800 20800 11000 35500
14 5600 17900 8400 27600 13400 46500
15 7000 23500 10300 36000 16100 59900
16 8600 30500 12500 46300 19100 76000
17 10500 39100 15000 58800 22500 95100
18 12700 49600 17800 73800 26300 117600
19 15200 62300 20900 91600 30500 143900
20 18000 77500 24400 112500 35100 174400
21 21100 95500 28300 136900 40100 209500
22 24600 116600 32600 165200 45700 249600
23 28500 141200 37300 197800 51900 295300
24 32800 169700 42600 235100 58700 347200
25 37500 202500 48500 277700 66100 405900
26 42600 240000 55000 326200 74100 472000
27 48300 282600 62100 381200 82900 546100
28 54600 330900 70000 443300 92500 629000
29 61500 385500 78700 513300 102900 721500
30 Current limit 447000 Current limit 592000 Current limit 824400
A brief visual representation:
#### Strengthening
Apart from participating in battles, Meowfficers can be given experience at the Cattery by consuming other Meowfficers. The experience granted depends on the following:
• A base amount depending on the consumed Meowfficer's rarity:
Base strengthening XP
Rare Elite Super Rare
200 300 500
• 70% of the consumed Meowfficer's accumulated XP.
• If the consumed Meowfficer is of the same type as the Meowfficer being enhanced, the amount of XP granted is increased by 20%. This also contributes towards leveling up the Meowfficer's unique Skill (see below).
#### Stats
Each Meowfficer has three stats: Support (aka Logistics), Directives (aka Command), and Tactics. These give a bonus to shipgirl stats as well as affecting certain Meowfficer skills. Meowfficer stats are determined by the Meowfficer's type and level.
The bonus is as follows:
$\text{bonus} = 6\% \cdot \frac{\text{stat}}{\text{stat} + 2500/9} \approx 6\% \cdot \frac{\text{stat}}{\text{stat} + 277.78}$
Each Meowfficer stat contributes a share of the effective $\text{stat}$ depending on the target shipgirl stat:
Shipgirl stat Logistics Directives Tactics
ASW 3/3
AA 3/3
AVI 2/3 1/3
HP 3/3
TRP 1/3 2/3
FP 1/3 2/3
#### Skills
Each Meowfficer has a unique skill depending on its type. This skill cannot be changed, but it can be upgraded by consuming Meowfficers of the same type, similar to limit breaking shipgirls. Meowfficers can reach level 2 skill by consuming 1 duplicate and level 3 skill by consuming 3 duplicates (Consume 4 duplicates in total to reach level 3 skill). A list of Meowfficer types and skills is shown later in this article.
#### Abilities (Talent)
In addition to skills, each Meowfficer has a number of abilities drawn from a common pool. Most abilities have three levels, though a few ultra rare abilities have only one, and are counted as "level 2" for initial roll, except for R cats (which unique options are far less stronger). Each Meowfficer starts with a set of random abilities, some of which may be above level 1:
Possible initial ability levels
Rare Elite Super Rare
1× Level 1 2× Level 1
or
1× Level 2
1x Level 2 + 2x Level 1
or
2x Level 2
At every level divisible by 5, a Meowfficer gains one Paw Print. Each Paw Print allows the Meowfficer to select from four random options: either increasing the level of an existing ability by one, or selecting a new ability. A Meowfficer can have at most 5 abilities; if they would gain a 6th, they must give up one of their existing abilities.
Meowfficers can respec their Paw Prints by paying a cost of coins:
Respec cost
Paw Prints 1 2 3 4 5 6
coins 3000 5600 7800 9600 11000 12000
This removes all ability levels gained from Paw Prints and refunds the Paw Prints. Note that this does not affect the initial abilities. Once respecced, that Meowficcer cannot be respecced again for 24 hours.
## List of Meowfficers and Skills
There are currently 27 Meowfficers: Each nation has 2 , a variety of , and 2 Meowfficers.
Unless noted otherwise, buff magnitudes are as follows:
• "Small": 0.4% bonus per 100 Meowfficer stat.
• "Moderate": 0.8% bonus per 100 Meowfficer stat.
• "Large": 1.2% bonus per 100 Meowfficer stat.
Meowfficer Name Rarity Timer Nation Tactics Support Command Skill Skill Slot Type Level 1 Level 2 Level 3
Justice
ジャスティス
10:24:00 65 44 52 Command When the Fleet has 3 DD, equipped fleet's map movement is increased by 1. While equipped as Command Cat, when fleet contacts non-boss enemy units and the fleet contains a DD, 15% chance of launching preemptive torpedo strike. While equipped as Command Cat, when the fleet contains a DD and is not engaging in battle, and when an allied fleet is currently in battle in an adjacent square, the fleet can choose to swap with the allied fleet and take over the allied fleet's battle.
Antenna
アンテナ
10:45:00 54 37 66 General Increases the Accuracy of all BBs, BCs, and BBVs in your fleet by a large amount based on the Tactics stat when in combat with a DD or BB node. When assigned to a fleet with a BB, BC, or BBV as its Flagship: increases the DMG the Flagship deals by a large amount based on the Command stat. Increases the AA and EVA of all BBs, BCs, and BBVs in your fleet by a moderate amount based on the Command stat.
Bunny
バニー
06:09:00 36 43 55 Command While equipped as Command Cat, when fleet contacts non-boss enemy units and the fleet contains a DD, 15% chance of launching preemptive torpedo strike. While the lead ship is a DD and its HP not 0, at the beginning of battle, when the lead DD gets close to the enemy, fire Meowfficer Barrage I. (Fires 18 DD HE bullets of 18 base damage each. Preview gif.) Limited to once per battle. Meowfficer Barrage I improves to Meowfficer Barrage II. (Fires 27 DD HE bullets of 28 base damage each. Preview gif.)
Eagle
イーグル
05:36:00 49 33 52 Staff While equipped as Staff Cat, increase Reload of all light carriers and carriers in the equipped fleet by a small amount based on Tactics stat. When the fleet runs into an Airstrike on the map: gives a chance to completely evade the Airstrike based on the Tactics stat. While equipped as Staff Cat, increase Airpower of all light carriers and carriers in the equipped fleet by a moderate amount based on Command stat.
レディ
02:03:00 52 28 40 Staff While equipped as Staff Cat, increase Reload of all light carriers and carriers in the equipped fleet by a small amount based on Support stat. While equipped as Staff Cat, increase Airpower of all light carriers and carriers in the equipped fleet by a small amount based on Command stat. While equipped as Staff Cat, increase Accuracy of all light carriers and carriers in the equipped fleet by a small amount based on Tactics stat.
SG
エスジー
02:25:00 26 41 51 Staff Decrease the chance of encountering ambush for equipped fleet based on Support stat (actually Directives?). While equipped as Staff Cat, increase Accuracy of all CL, CA, and CB in the equipped fleet by a small amount based on Tactics stat. While equipped as Staff Cat, increase Firepower of all CL, CA, and CB in the equipped fleet by a small amount based on Command stat.
Lime
ライム
10:05:00 58 55 52 Staff While equipped as Staff Cat, increase Firepower and Anti-air of all BB, BC, and BBV in the equipped fleet by a moderate amount based on Command stat. While equipped as Staff Cat, when fleet engages in battle by the shore (i.e. adjacent to inaccessible terrain), increase Firepower of all ships in the equipped fleet by a moderate amount based on Tactics stat. Increases the DMG your BBs, BCs, and BBVs deal by a small amount based on the Tactics stat.
Pound
パウンド
10:27:00 36 67 59 Command When assigned as the Command Cat: increases the FP and AA of BBs, BCs, and BBVs in your fleet by a moderate amount based on the Command stat. When assigned as the Command Cat to a fleet with at least 4 Royal Navy ships: decreases the DMG your Vanguard takes for 30s after the battle starts based on the Support stat. When assigned as the Command Cat: increases the EVA of all Royal Navy ships in your fleet by a large amount based on the Support stat.
Pepper
ペッパー
06:16:00 45 44 50 Staff While equipped as Staff Cat, increase Evasion of all CL, CA, and CB in the equipped fleet by a small amount based on Support stat. While equipped as Staff Cat, when battling transport fleet (gold ship node) increase Firepower of all CL, CA, and CB in the equipped fleet by a large amount based on Tactics stat. While equipped as Staff Cat, increase Torpedo of all CL, CA, and CB in the equipped fleet by a moderate amount based on Command stat.
Soup
スープ
05:30:00 33 39 55 Staff While equipped as Staff Cat and battling against a patrol fleet (destroyer node), increase Accuracy of all DD in the equipped fleet by a moderate amount based on Tactics stat. When assigned as the Staff Cat: increases the EVA of your DDs by a small (actually moderate) amount based on the Support stat. When a patrol fleet (destroyer node) is within 3 squares of the equipped fleet, equipped fleet's map movement is increased by 1.
Marble
マーボー
07:26:00 44 23 64 Staff While equipped, decrease the chance of fleet running into an Airstrike (actually ambush?) based on Support stat (actually Tactics?). While equipped as Staff Cat, increase reload for BB, BC, BBV by a small amount based on Command stat While equipped as Staff Cat, increase Firepower for Royal Navy Ships by a small amount based on Tactical stat.
Ark
アーク
06:43:00 44 39 48 Staff While equipped as Staff Cat, Increase Accuracy for CV, CVL by a small amount based on Tactical stat. When a patrol fleet (destroyer node) is within 2 squares, Increase map movement range by 1 While equipped as Staff Cat, Increase Aviation for CV, CVL by a moderate amount based on Command stat
Rose
ローズ
02:17:00 23 64 29 Staff While equipped as Staff Cat, increase Reload of all BB, BC, and BBV in the equipped fleet by a small amount based on Support stat. While equipped as Staff Cat, increase Accuracy of all BB, BC, and BBV in the equipped fleet by a small amount based on Support stat. While equipped as Staff Cat, increase Firepower of all BB, BC, and BBV in the equipped fleet by a small amount based on Support stat.
Bugles
ビューグルス
01:39:00 52 29 38 Staff While equipped as Staff Cat, increase Firepower of all CL, CA, and CB in the equipped fleet by a small amount based on Tactics stat. While equipped as Staff Cat, increase Accuracy of all CL, CA, and CB in the equipped fleet by a small amount based on Tactics stat. While equipped as Staff Cat, increase Evasion of all CL, CA, and CB in the equipped fleet by a small amount based on Tactics stat.
Bishamaru
ビシャマル
09:58:00 68 38 49 Staff When assigned as the Staff Cat: increases the AVI and RLD of your CVs and CVLs by a small (actually moderate) amount based on the Command stat. Decrease the chance of encountering ambush for equipped fleet based on Support stat. When entering battle and only a carrier or light carrier remains in the equipped main fleet (backline), first airstrike reload speed is increased by 8%. The first airstrike will also contain extra torpedo bombers.
Takemaru
タケマル
09:40:00 66 30 62 Command When sortied as the Command Cat: increases the FP and TRP of all CL, CA, and CB in your fleet by a moderate amount based on the Tactics stat. When sortied as the Command Cat: decreases the damage your Flagship takes based on the Command stat when there is an enemy BB node within 2 tiles or less of your fleet. When sortied as the Command Cat: increases the Accuracy and EVA of all CL, CA, and CB in your fleet by a large amount based on the Tactics stat for 30 seconds after the battle has started when in combat with a BB node.
Jiromaru
ジロマル
05:37:00 41 33 61 Staff While equipped as Staff Cat, increase Accuracy of all light carriers and carriers in the equipped fleet by a small amount based on Tactics stat. While equipped as Staff Cat, increase Airpower of all light carriers and carriers in the equipped fleet by a moderate amount based on Command stat. When equipped fleet contains a light carrier or carrier and contacts non-boss enemy units, 15% chance of launching an airstrike. Damage is based on Tactics stat, as well as levels and fleet powers of both fleets.
Yoshimaru
ヨシマル
06:23:00 36 36 62 Staff While equipped as Staff Cat, increase Evasion of all DD in the equipped fleet by a small amount based on Command stat. While equipped as Staff Cat, increase Torpedo of all DD in the equipped fleet by a moderate amount based on Support stat. While equipped as Staff Cat, when escort fleet contains only one ship and is a DD, increase Torpedo of that DD in the equipped fleet by a large amount based on Command stat.
Asamaru
アサマル
02:06:00 40 24 48 Staff While equipped as Staff Cat, increase Firepower of all CL, CA, and CB in the equipped fleet by a small amount based on Command stat. While equipped as Staff Cat, increase Torpedo of all CL, CA, and CB in the equipped fleet by a small amount based on Support stat. While equipped as Staff Cat, increase Torpedo of all CL, CA, and CB in the equipped fleet by a small amount based on Command stat.
Katsumaru
カツマル
01:55:00 32 36 47 Staff While equipped as Staff Cat, increase Accuracy of all BB, BC, and BBV in the equipped fleet by a small amount based on Support stat. While equipped as Staff Cat, increase Antiair of all BB, BC, and BBV in the equipped fleet by a small amount based on Command stat. While equipped as Staff Cat, increase Firepower of all BB, BC, and BBV in the equipped fleet by a small amount based on Tactics stat.
Steel
しゅている
09:35:00 52 40 66 General Increase Torpedo of all submarines in the equipped fleet by a small amount based on Command and Support stats. Increase submarine hunting range level by 1 Increase torpedo strike (map) damage based on Tactics stat.
Oscar
おすかー
10:03:00 55 43 64 Staff When sortied as the Staff Cat: increases the FP and Accuracy of BBs, BCs, and BBVs in your fleet by a moderate amount based on the Command stat. When sortied as the Staff Cat: 15% chance to launch a preemptive strike when coming into contact with any non-boss node on the map when there is a BB, BC, or BBV in your fleet. When assigned as the Staff Cat and when engaging an enemy Main Fleet: decreases the DMG your BBs, BCs, and BBVs take based on the Support stat. (-2.5% per 100 stat) (Unlisted effect: Also increases their RLD by a moderate amount.)
Potato
じゃがいも
06:45:00 43 35 56 Staff While equipped as Staff Cat, increase Evasion of all BB, BC, and BBV in the equipped by a small amount fleet based on Command stat. While equipped as Staff Cat, increase Accuracy of all BB, BC, and BBV in the equipped by a moderate amount fleet based on Tactics stat. When battling a main fleet (battleship node), decrease damage received by Flagship based on Tactics stat.
Edelweiss
うすゆきそう
05:57:00 41 34 59 Staff While equipped as Staff Cat, increase Torpedo of all submarines in the equipped fleet by a small amount based on Command stat. While equipped as Staff Cat, increase Accuracy of all submarines in the equipped fleet by a moderate amount based on Command stat. Increase submarine hunting range level by 1
Gral
ぐらーる
05:52:00 48 32 51 Staff While equipped as Staff Cat, increase Torpedo of all submarines in the equipped fleet by a small amount based on Command stat. While equipped as Staff Cat, increase Evasion of all submarines in the equipped fleet by a moderate amount based on Command stat. While equipped as Staff Cat and Flagship is a BB, BC or BBV, increase Accuracy of all submarines in the equipped fleet by a moderate amount based on Command stat.
Tofu
とうふ
01:54:00 36 37 46 Staff While equipped as Staff Cat, increase Evasion of all CL, CA, and CB in the equipped fleet by a small amount based on Support stat. While equipped as Staff Cat, increase Firepower of all CL, CA, and CB in the equipped fleet by a small amount based on Support stat. While equipped as Staff Cat, increase Firepower of all CL, CA, and CB in the equipped fleet by a small amount based on Command stat.
Beer
びーる
02:32:00 49 28 41 Staff While equipped as Staff Cat, increase Evasion of all DD in the equipped fleet by a small amount based on Command stat. While equipped as Staff Cat, increase Accuracy of all DD in the equipped fleet by a small amount based on Tactics stat. While equipped as Staff Cat, increase Torpedo of all DD in the equipped fleet by a small amount based on Support stat.
Note: If a preemptive torpedo strike skill (Justice, Bunny) activates, it will prevent roaming submarines from attacking that node. Likewise, a node that has already been struck by roaming submarines cannot be hit again by the preemptive torpedo strike.
## Abilities
Ability Name Ability Name (CN) Ability Name (JP) Level 1 Level 2 Level 3
Artillery Rookie
Destroyer
Destroyer
Artillery Ace
Destroyer
Artillery Rookie
Cruiser
Cruiser
Artillery Ace
Cruiser
Artillery Rookie
Main
Main
Artillery Ace
Main
Torpedo Rookie
SS
SS
Torpedo Ace
SS
Torpedo Rookie
Destroyer
Destroyer
Torpedo Ace
Destroyer
Torpedo Rookie
Cruiser
Cruiser
Torpedo Ace
Cruiser
Aviation Rookie
Carrier
Carrier
Aviation Ace
Carrier
Aviation Rookie
Special
Special
Aviation Ace
Special
Anti-Air Rookie
Vanguard
Vanguard
Anti-Air Ace
Vanguard
Anti-Air Rookie
Main
Main
Anti-Air Ace
Main
Sonar Rookie
Vanguard
Vanguard
Sonar Ace
Vanguard
Sonar Rookie
Main
Main
Sonar Ace
Main
Submarine
Submarine
Submarine
Destroyer
Destroyer
Destroyer
Cruiser
Cruiser
Cruiser
Battleship
Battleship
Battleship
Rookie Mechanic
Ace Mechanic
Special
Special
Special
Rookie Engineer
SS
SS
Ace Engineer
SS
Rookie Engineer
Destroyer
Destroyer
Ace Engineer
Destroyer
Rookie Engineer
Cruiser
Cruiser
Ace Engineer
Cruiser
Rookie Engineer
Battleship
Battleship
Ace Engineer
Battleship
Rookie Engineer
Carrier
Carrier
Ace Engineer
Carrier
Rookie Engineer
Special
Special
Ace Engineer
Special
Rookie Lookout
Submarine
Submarine
Ace Lookout
Submarine
Rookie Lookout
Vanguard
Vanguard
Ace Lookout
Vanguard
Rookie Lookout
Main
Main
Ace Lookout
Main
Rookie Helmsman
Small
Small
Ace Helmsman
Small
Rookie Helmsman
Medium
Medium
Ace Helmsman
Medium
Rookie Helmsman
Large
Large
Ace Helmsman
Large
Rookie Officer
Destroyer
Elite Officer
Destroyer
Chief of Staff
Destroyer
Rookie Officer
Cruiser
Elite Officer
Cruiser
Chief of Staff
Cruiser
Rookie Officer
Battleship
Elite Officer
Battleship
Chief of Staff
Battleship
Rookie Officer
Carrier
Elite Officer
Carrier
Chief of Staff
Carrier
Rookie Officer
Submarine
Elite Officer
Submarine
Chief of Staff
Submarine
Rookie Officer
Union
Elite Officer
Union
Chief of Staff
Union
Rookie Officer
Royal
Elite Officer
Royal
Chief of Staff
Royal
Rookie Officer
Sakura
Elite Officer
Sakura
Chief of Staff
Sakura
Rookie Officer
Iron Blood
Elite Officer
Iron Blood
Chief of Staff
Iron Blood
Tireless Warrior
Soulful Warrior
Heart of the Torpedo
Ace Pilot
Alpha Wolf
Rising Star
Best Friend
Wind's Alacrity
Forest's Serenity
Flame's Aggression
Mountain's Tenacity
Miracle
Destiny
|
{}
|
## Section7.3More About Factoring
### SubsectionQuotients of Powers
We can reduce a fraction by dividing numerator and denominator by any common factors. For example,
\begin{equation*} \dfrac{10}{15} = \dfrac{2 \cdot 5}{3 \cdot 5} = \dfrac{2}{3} \end{equation*}
We first factored the numerator and denominator of the fraction and then canceled the 5's by dividing. We can apply the same technique to quotients of powers.
###### Example7.20.
Simplify.
1. $\dfrac{a^5}{a^3}$
2. $\dfrac{a^4}{a^8}$
Solution
1. We first write the numerator and denominator in factored form. Then we divide any common factors from the numerator and denominator.
\begin{equation*} \dfrac{a^5}{a^3} = \dfrac{\cancel{a}\cdot \cancel{a}\cdot \cancel{a}\cdot a\cdot a}{\cancel{a}\cdot \cancel{a}\cdot \cancel{a}} = \dfrac{a^2}{1} = a^2 \end{equation*}
You may observe that the exponent of the quotient can be obtained by subtracting the exponent of the denominator from the exponent of the numerator. In other words,
\begin{equation*} \dfrac{a^5}{a^3}= a^{5-3} = a^2 \end{equation*}
2. In this quotient, the larger power occurs in the denominator.
\begin{equation*} \dfrac{a^4}{a^8} = \dfrac{\cancel{a}\cdot \cancel{a}\cdot \cancel{a}\cdot \cancel{a}}{\cancel{a}\cdot \cancel{a}\cdot \cancel{a}\cdot \cancel{a}\cdot a\cdot a\cdot a \cdot a} = \dfrac{1}{a^4} \end{equation*}
We see that we can subtract the exponent of the numerator from the exponent of the denominator. That is,
\begin{equation*} \dfrac{a^4}{a^8}=\dfrac{1} {a^{8-4}} = \dfrac{1}{a^4} \end{equation*}
These examples suggest the following property.
###### Second Law of Exponents.
To divide two powers with the same base, we subtract the smaller exponent from the larger one, and keep the same base.
1. If the larger exponent occurs in the numerator, put the power in the numerator.
2. If the larger exponent occurs in the denominator, put the power in the denominator.
In symbols,
1. $\blert{\dfrac{a^m}{a^n} = a^{m-n}~~~~~~\text{if}~~~~n \lt m}$
2. $\blert{\dfrac{a^m}{a^n} = \dfrac{1}{a^{n-m}}~~~~~~\text{if}~~~~n \gt m}$
###### 1.
In a quotient of powers, how do we know whether the new power appears in the numerator or the denominator?
### SubsectionQuotients of Monomials
To divide one monomial by another, we apply the second law of exponents to the powers of each variable.
###### Example7.21.
Divide $~~\dfrac{3x^2y^4}{6x^3y}$
Solution
We consider the numerical coefficients and the powers of each base separately. We use the second law of exponents to simplify each quotient of powers.
\begin{align*} \dfrac{3x^2y^4}{6x^3y} \amp = \dfrac{3}{6} \cdot \dfrac{x^2}{x^3} \cdot \dfrac{y^4}{y} \amp \amp \blert{\text{Subtract exponents on each base.}}\\ \amp = \dfrac{1}{2} \cdot \dfrac{1}{x^{3-2}} \cdot y^{4-1}\\ \amp = \dfrac{1}{2} \cdot \dfrac{1}{x} \cdot \dfrac{y^3}{1}=\dfrac{y^3}{2x} \amp \amp \blert{\text{Multiply factors.}} \end{align*}
### SubsectionGreatest Common Factors
Now we consider several techniques for factoring polynomials. The first of these is factoring out the greatest common factor (GCF).
The greatest common factor (GCF) is the largest factor that divides evenly into each term of the polynomial: the largest numerical factor and the highest power of each variable.
###### Example7.22.
Find the greatest common factor for $~~4a^3b^2+6ab^3-18a^2b^4$
Solution
The largest integer that divides evenly into all three coefficients is 2. The highest power of $a$ is $a^1\text{,}$ and the highest power of $b$ is $b^2\text{.}$ Thus, the GCF is $2ab^2\text{.}$ Note that the exponent on each variable of $2ab^2$ is the smallest exponent that appears on that variable among the terms of the polynomial.
###### 2.
The exponent on each variable of the GCF is the exponent that appears on that variable among the terms of the polynomial.
Once we have found the greatest common factor for the polynomial, we can write each term as a product of the GCF and another factor. For example, the GCF of $8x^2-6x$ is $2x\text{,}$ and we can write
\begin{equation*} 8x^2-6x = \blert{2x} \cdot 4x - \blert{2x} \cdot 3 \end{equation*}
We can then use the distributive law to write the expression on the right side as a product.
\begin{equation*} \blert{2x} \cdot 4x - \blert{2x} \cdot 3 = \blert{2x} (4x-3) \end{equation*}
We say that we have factored out the greatest common factor from the polynomial.
For more complicated polynomials, we can divide the GCF into each term to find the remaining factors.
###### Example7.23.
Factor $~~4a^3b^2+6ab^3-18a^2b^4$
Solution
The GCF for this polynomial is $2ab^2\text{,}$ as we saw in Example 7.22. We factor out the GCF from each term and write the polynomial as a product,
\begin{equation*} 2ab^2(\hphantom{0000000000}) \end{equation*}
To find the factor inside parentheses, we divide each term of the polynomial by the GCF.
\begin{equation*} \dfrac{4a^3b^2}{2ab^2}=\blert{2a^2},~~~~\dfrac{6ab^3}{2ab^2}=\blert{3b},~~~\dfrac{-18a^2b^4}{2ab^2}=\blert{-9ab^2} \end{equation*}
We apply the distributive law to factor $2ab^2$ from each term.
\begin{align*} 4a^3b^2+6ab^3-18a^2b^4 \amp =2ab^2\cdot \blert{2a^2}+2ab^2 \cdot \blert{3b-}2ab^2 \cdot \blert{9ab^2}\\ \amp = 2ab^2(2a^2+3b-9ab^2) \end{align*}
###### Look Closer.
Sometimes the greatest common factor for a polynomial is not a monomial, but may instead have two or more terms.
###### Example7.24.
Factor $x^2(2x+1)-3(2x+1)$
Solution
The given expression has two terms, and $(2x+1)$ is a factor of each. We factor out the entire binomial $(2x+1)\text{.}$
\begin{equation*} x^2\blert{(2x+1)}-3\blert{(2x+1)} = \blert{(2x+1)} (x^2-3) \end{equation*}
### SubsectionFactoring Quadratic Trinomials by Guess-and-Check
So far, we can factor quadratic trinomials of the form $x^2+bx+c=0\text{,}$ where $a=1\text{.}$ Recall that the factored form of $x^2+bx+c=0$ looks like
\begin{equation*} (x+p)(x+q)~~~~~~ \text{where}~~~pq=c ~~~ \text{and} ~~~p+q=b \end{equation*}
You may want to review the FOIL method discussed in Lesson 6.3.
What if the coefficient of $a$ is not 1? Sometimes, if the coefficients are small, we can factor a quadratic expression by the guess-and-check method.
###### Example7.25.
Factor $~2x^2-7x+3~$ into a product of two binomials.
Solution
We begin by factoring the quadratic term, $2x^2\text{,}$ which can only be factored as $x$ times $2x\text{,}$ so we can fill in the First terms in each binomial.
\begin{equation*} 2x^2-7x+3 = (2x\underline{\hspace{2.727272727272727em}})(x\underline{\hspace{2.727272727272727em}}) \end{equation*}
Next, we factor the constant term, $3\text{,}$ which can only be factored as 3 times 1. Because the linear term is negative, we make both factors negative: $3=-3(-1)\text{.}$ Finally, we have to decide which number appears as the Last term in each binomial. We check $O+I$ for each possibility.
\begin{align*} (2x-3)(x-1)~~~~O+I \amp = -2x-3x=-5x\\ (2x-1)(x-3)~~~~\blert{O+I} \amp \blert{= -6x-x=-7x} \end{align*}
The second choice gives the correct middle term, so the factorization is
\begin{equation*} 2x^2-7x+3 = (2x-1)(x-3) \end{equation*}
###### 3.
When we factor a quadratic trinomial by the guess-and-check method, how do we check for the correct middle term?
Remember that you can always check your factorization by multiplying the factors together.
### SubsectionQuadratic Trinomials in Two Variables
So far, we have factored quadratic trinomials in one variable, that is, polynomials of the form
\begin{equation*} ax^2+bx+c \end{equation*}
The method we learned can also be used to factor trinomials in two variables of the form
\begin{equation*} ax^2+bxy+cy^2 \end{equation*}
In this expression, the first and last terms are quadratic terms, while the middle term is a cross-term consisting of the product of the two variables.
###### Example7.26.
Factor $~x^2+5xy+6y^2~$
Solution
As usual, we begin by factoring the first term into $x$ times $x\text{.}$
\begin{equation*} x^2+5xy+6y^2 = (x + \underline{\hspace{2.727272727272727em}})(x + \underline{\hspace{2.727272727272727em}}) \end{equation*}
Next we look for factors of the last term, $6y^2\text{.}$ In order to obtain the $xy$-term in the middle, we need a $y$ in each factor. Thus the possibilities are
\begin{equation*} y~~\text{and}~~6y~~~~~~~~\text{or}~~~~~~~~2y~~\text{and}~~3y \end{equation*}
We'll check the sum $O+I$ for each possibility.
\begin{align*} (x+y)(x+6y)~~~~O+I \amp = 6xy+xy=7xy\\ (x+2y)(x+3y)~~~~\blert{O+I} \amp \blert{= 3xy+2xy=5xy} \end{align*}
The second possibility gives the correct middle term, so the factorization is
\begin{equation*} x^2+5xy+6y^2 = (x+2y)(x+3y) \end{equation*}
### SubsectionCombining Factoring Techniques
We should always begin factoring by checking to see if there is a common factor that can be factored out.
###### Example7.27.
Factor completely $~2b^3+8b^2+6b~$
Solution
We begin by factoring out the greatest common factor, $2b\text{.}$
\begin{equation*} 2b^3+8b^2+6b = 2b(b^2+4b+3) \end{equation*}
The remaining factor, $b^2+4b+3\text{,}$ is a quadratic trinomial that can be factored. We look for two numbers $p$ and $q$ so that $pq=3$ and $p+q=4\text{.}$ You can check that $p=3$ and $q=1$ will work.
Thus, $~~b^2+4b+3 = (b+3)(b+1)\text{,}$ and
\begin{equation*} 2b^3+8b^2+6b = 2b(b+3)(b+1) \end{equation*}
###### 4.
What should always be the first step in factoring a polynomial?
### SubsectionSkills Warm-Up
#### ExercisesExercises
Mental exercise: Find the other factor of each quadratic trinomial without using pencil, paper, or calculator.
###### 1.
$b^2+8b-240 = (b-12)(\underline{\hspace{2.727272727272727em}})$
###### 2.
$n^2-97n-300 = (n-100)(\underline{\hspace{2.727272727272727em}})$
###### 3.
$3u^2-17u-6 = (u-6)(\underline{\hspace{2.727272727272727em}})$
###### 4.
$2t^2-21t+54 = (t-6)(\underline{\hspace{2.727272727272727em}})$
### ExercisesHomework 7.3
###### 1.
Find each quotient by using the second law of exponents.
1. $\dfrac{a^6}{a^3}$
2. $\dfrac{3^9}{3^4}$
3. $\dfrac{z^6}{z^9}$
###### 2.
Choose a value for the variable and evaluate to show that the following pairs of expressions are not equivalent.
1. $t^2 \cdot t^3,~~t^6$
2. $\dfrac{v^8}{v^2},~~v^4$
3. $\dfrac{n^3}{n^5},~~n^2$
For Problems 3–5, divide.
###### 3.
$\dfrac{2x^3y}{8x^4y^5}$
###### 4.
$\dfrac{-12bx^4}{8bx^2}$
###### 5.
$\dfrac{-15x^3y^2}{-3x^3y^4}$
For Problems 6–7, factor out a negative monomial.
###### 6.
$-b^2-bc-ab$
###### 7.
$-4k^4+4k^2-2k$
For Problems 8–11, factor out the greatest common factor.
###### 8.
$2x^4-4x^2+8$
###### 9.
$16a^3b^3-12a^2b+8ab^2$
###### 10.
$9x^2-12x^5+3x^3$
###### 11.
$14x^3y-35x^2y^2+21xy^3$
For Problems 12–13, factor out the common factor.
###### 12.
$2x(x+6)-3(2x+6)$
###### 13.
$3x^2(2x+3)-(2x+3)$
For Problems 14–16, factor by the guess-and-check method.
###### 14.
$2x^2+11x+5$
###### 15.
$5t^2+7t+2$
###### 16.
$3x^2-8x+5$
For Problems 17–28, factor completely.
###### 17.
$2x^2+10x+12$
###### 18.
$4a^2b+12ab-7b$
###### 19.
$4z^3+10z^2+6z$
###### 20.
$18a^2b-9ab-27b$
###### 21.
$x^2-5xy+6y^2$
###### 22.
$x^2+4xy+4y^2$
###### 23.
$x^2+4ax-77a^2$
###### 24.
$4x^3+12x^2y+8xy^2$
###### 25.
$9a^3b+9a^2b^2-18ab^3$
###### 26.
$2t^2-5st-3s^2$
###### 27.
$4b^2y^2+5by+1$
###### 28.
$12ab^2+15a^2b+3a^3$
For Problems 29–34, solve the equation by factoring.
###### 29.
$3n^2-n=4$
###### 30.
$11t=6t^2+3$
###### 31.
$1=4y-4y^2$
###### 32.
$12z^2+26z=10$
###### 33.
$y(3y+4)=4$
###### 34.
$(2x-1)(2x-1)=-1$
###### 35.
The cost $C$ of producing a wool rug depends on the number of hours $t$ it takes to weave it, where
\begin{equation*} C=3t^2-4t+100 \end{equation*}
How many hours did it take to weave a rug that costs \$120?
###### 36.
Steve's boat locker is 2 feet longer than twice its width. Find the dimensions of the locker if the 13-foot mast of Steve's boat will just fit diagonally across the floor of the locker.
|
{}
|
# Part 1: Overview
In this lab you will learn about the Hadoop Distributed File System, or HDFS. You’ll discover how it work, pest practices, etc.
## Learning Outcomes
Upon completing this lab you will be able to:
• Verify HDFS is running and check the health of the HDFS file system from the command line and from Ambari
• Get data in and out of HDFS using the HDFS commands.
• Understand the conventions and default behaviors of working with HDFS data.
• Understand strategies for streaming data into HDFS.
## Requirements
To complete this lab you will need:
• Minidoop setup or Hortonworks Sandbox. In Minidoop, the Hadoop client is the Data Science Appliance (the hadoop-client virtual machine). In Hortonworks sandbox, your computer is the Hadoop client.
• A clone of the mafudge/datasets repository on Github: https://github.com/mafudge/datasets this should be placed in your home directory on your Hadoop client.
## Before you Begin
Please complete the following prior to starting this lab:
2. Check to make sure HDFS is up and running, and passes a service check. Consult the Ambari lab for details.
3. Make sure your datasets repository is up-to-date by issuing a pull.
### So many Commands, so little time!
NOTE This Walk-Though attempts to familiarize you with the most frequently used HDFS commands. There’s far to many to cover otherwise. Also we won’t focus on command syntax or structure, but instead cover what the command does, how it is used and why. A more comprehensive list of file system commands and options can be found on the Hadoop project website, which I encourage you to reference while completing the lab.
# Part 2: Walk-Though
Let’s start as we usually do by getting our bearings. From the shell of your Hadoop client, try these:
1. Type $hdfs dfs and observe the output. Notice this command is the same as $ hadoop fs The general syntax of this command is $hdfs dfs <command> where <command> is one of the many commands listed in the output. 2. Let’s see what files are on HDFS: $ hdfs dfs -ls. It looks similar to the Linux ls -l command except its displaying the files on the Hadoop file system not the local file system. You might be wondering where we are in the Hadoop file system? The root? Nope. The answer is the ischool home directory. Why? The current linux user is ischool
3. The absolute path to the ischool home directory on HDFS /user/ischool notice this is different from the linux file system default of /home/ischool Thus this command is the same as the previous. Type: $hdfs dfs -ls /user/ischool The output should be the same as $ hdfs dfs -ls
4. Let’s see what’s in the root of the HDFS file system. Type $hdfs dfs -ls / you’ll see output similar to this: This is the folder structure from the Hortonworks installation. Other Hadoop distributions will vary, of course. NOTE: For the Hadoop file system, there’s no pwd or cd commands. That is because there is no shell or command prompt for HDFS. There is only executing Hadoop commands through the Linux command prompt (or any other Hadoop client for that matter). ## Working With Files in HDFS For next two sections of this walk-through we will use the grades data set in the datasets folder on your Hadoop client. 1. Let’s begin by creating a directory in HDFS for this lab. All of our work will go in this directory, type: % hdfs dfs -mkdir unit06lab1 2. We use the -put command to copy files into HDFS. Let’s load the fall2015 grades into our unit06lab1 folder on HDFS: $ hdfs dfs -put datasets/grades/fall2015.tsv unit06lab1/fall2015.tsv
3. Let’s check to make sure we did that correctly, by listing the files in unit06lab1 type: $hdfs dfs -ls unit06lab1 You should see this: 4. What happens if we repeat the same command? Will it overwrite the file on HDFS? Let’s try it out: $ hdfs dfs -put datasets/grades/fall2015.tsv unit06lab1/fall2015.tsv You’ll notice it does not work and we get an error: put: ‘fall2015.tsv’: File exists. HDFS will not overwrite files by design.
5. Suppose we want to view what’s in the file on HDFS? For that we use the -cat command for this. Type: $hdfs dfs -cat unit06lab1/fall2015.tsv to view the contents of the file on HDFS. There should be 5 lines in the file, output should look like this: 6. Let’s make a copy of the file on HDFS, type: $ hdfs dfs -cp unit06lab1/fall2015.tsv unit06lab1/grades.tsv then do an -ls on unit06lab1 to verify there are now two files like this:
7. Now let’s delete the fall2015.tsv on HDFS, type: $hdfs dfs -rm unit06lab1/fall2015.tsv An -ls will now reveal a single file grades.tsv in the unit06lab1 folder. 8. How do we download the file from HDFS back to the client? That’s the -get command. Type: $ hdfs dfs -get unit06lab1/grades.tsv grades.tsv You will now notice the file grades.tsv is local. Verify with $cat grades.tsv 9. Before me move on to the next step, let’s remove the grades.tsv from HDFS. $ hdfs dfs -rm unit06lab1/grades.tsv
10. Not really deleting, is it? This is the second time we’ve deleted something, and you’ve probably noticed that when we delete a file from HDFS it is realling moving the file to the Trash folder. You can always get a listing of files in the .Trash folder to see what’s there, type: $hdfs dfs -ls .Trash/Current/user/ischool You’ll see the two files we deleted are here. NOTE: HDFS Trash tips: Files remain in the Trash folder for 24 hours. We can use the -cp or -mv commands to copy or move the files out of the trash. We can also add the -skipTrash option on the -rm command to delete the file immediately. ## HDFS Best Practices A common practice for HDFS storage is to place files of a common data set into the same folder. Thus the fall2015.tsv, spring2015.tsv and fall2016.tsv files should all be in the same grades folder as they represent the same thing. We will use this practice frequently in future labs. 1. Let’s start by making a folder for the data set: $ hdfs dfs -mkdir unit06lab1/grades
$hdfs dfs -put datasets/grades/* unit06lab1/grades the asterisk * represents all the files in the source folder. There should be 3 files in the folder. 3. Verify the files are there with an -ls command: $ hdfs dfs -ls unit06lab1/grades you should see the three files:
4. We know we can -cat one file from HDFS, but now that all the grades are in a folder we can few the contents of the folder as a single file:
$hdfs dfs -cat unit06lab1/grades/* For output, you should see all grades for Fall 2015, Spring 2016 and Fall 2016. 5. There’s also an HDFS command to -get the files and return them as a single file, in this case allgrades.tsv $ hdfs dfs -getmerge unit06lab1/grades/* allgrades.tsv
Since a MapReduce job creates one file per reducer, this command is useful for exporting that output from HDFS.
6. You can verify the merged file, which is now on the local file system is the contents of all the files on HDFS:
$cat allgrades.tsv should be the same as the -cat command before. ## HDFS Block storage We learned through class lecture that HDFS splits files into blocks and those blocks are then distributed to data nodes managed by HDFS. Let’s explore how this works: 1. From your home directory, verify the data file sr20160401.csv is present in your datasets folder. Type: $ ls -l datasets/nyc311 notice the size of the file is 3.9 MB.
2. As is customary to do, let’s make an HDFS directory for this data set:
$hdfs dfs -mkdir nyc311 3. Let’s try to split this file into 500 byte blocks as we upload it to HDFS, type: $ hdfs dfs -D dfs.blocksize=500 -put datasets/nyc311/sr20160401.csv nyc311/
You’ll get an error: Specificed block size is less than configured minimum value (dfs.namenode.fs-limits.min-block-size): 500 < 1048576 This error tells the block size of 500 is lower than the configured size for HDFS which is currently set to 1048576.
4. Okay. Let’s try a larger block size, like 1200500, try this:
$hdfs dfs -D dfs.blocksize=1200500 -put datasets/nyc311/sr20160401.csv nyc311/ And we get another error: Invalid values: dfs.bytes-per-checksum (=512) must divide block size (=1200500) HDFS is telling us that the blocksize we specify must be at least 1048576 and a multiple of 512. 5. Let’s do it one last time with a block size of 1048576, type: $ hdfs dfs -D dfs.blocksize=1048576 -put datasets/nyc311/sr20160401.csv nyc311/
6. Hooray! The command worked. Verify the file is in the nyc311 folder on HDFS:
$hdfs dfs -ls nyc311/ 7. Let’s take a look at the blocks that make up this file, type: $ hdfs fsck nyc311/sr20160401.csv You should see 4 blocks. All the blocks are under-replicated. This makes sense since we only have a single node in our Hadoop cluster and a minimum of 3 are requried for replication. The blocks are implemented as files on the actual data node.
## HDFS Health check
It’s useful at times to get a heath check report of the HDFS files system. To accomplish this, type: \$ hdfs dfsadmin -report The same information can be acquired through the Namenode UI in Ambari at: http://sandbox:50070/
## Test Yourself
1. Why are there no pwd or cd HDFS commands?
2. Explain what happens to a file in HDFS when you delete it?
3. What is the convention for storing files in HDFS, specifically which files belong in which folders?
4. What is the minimum block size in HDFS? Block sizes must be a multiple of which number?
5. What is the default replication factor in HDFS? Why are all blocks on your Hadoop cluster under-replicated?
# Part 3: On Your own
## Exercises
1. Upload all the .json files from datasets/redditnews into a redditnews folder on HDFS.
2. Upload the clickstream dataset to HDFS. Create a clickstream folder and then two folders iplookup and logs inside that folder. Upload all the .log files to the logs folder, and the ip_lookup.csv file to the iplookups folder.
3. The datasets/customers folder has two files in it. Examine the contents of each file and then devise a strategy for how these files should be uploaded to HDFS. Remember HDFS best practices as you decide how to process the files.
|
{}
|
Question #2e093
1 Answer
Sep 8, 2017
Since Neon exists as a monoatomic gas, the intermolecular Van der Waal's forces are very weak indeed.
However, when it is cooled to a sufficiently low temperature (of $27.1 K$), the gas particles undergo condensation and settle as a liquid. That's when Neon exists as a liquid.
Since, the intermolecular forces are very weak indeed, it exhibits an unusually low boiling point.
|
{}
|
Invariant subspace
• December 11th 2012, 06:56 PM
Invariant subspace
Let $P[x]$ be the polynomials on the field $P$, and let $D[f(x)]=f'(x)$ be the differentiating operator. Find all the invariant subspace of $D$.
I think the answer is $P_n(x)$, the polynomial with degree less than or equal to $n$. But I could not prove. Would you help me?
• December 11th 2012, 08:50 PM
Drexel28
Re: Invariant subspace
We have given you a lot of answers--let's see a little more work for this one.
• December 11th 2012, 09:52 PM
Re: Invariant subspace
Then how to calculate the invariant space?
• December 12th 2012, 10:21 AM
Deveno
Re: Invariant subspace
here's my idea: let U be a non-zero invariant subspace. since P[x] has a countable basis, so does U. pick an element of a basis for U of minimal degree. under what condition will that basis element be in D(U)? can you generalize?
• December 12th 2012, 09:50 PM
Re: Invariant subspace
I do know that the polynomial with least degree is constant. However, I could not see anymore from this.
Is it all the invariant subspaces are of the form $span\{1,x,x^2,\cdots,x^n\}??$
• December 13th 2012, 02:00 AM
Deveno
Re: Invariant subspace
suppose next that U is finite-dimensional, of dimension n. can you show that {1,x,...xn-1} must all be in U?
we've already (at least you claim you have) shown that if U has dimension 1, then it must be span{c} for c non-zero, that is: span{1}, so let's suppose dim(U) = 2.
then U = span({p(x),q(x)} for 2 LI polynomials p and q. thus D(U) = {ap'(x)+bq'(x): a,b in P}. without loss of generality assume deg(p) ≤ deg(q).
clearly p(x) = c, for some non-zero c (or else deg(p') = deg(p) - 1, and then D(U) is not contained in U). so deg(q) > 0 (since p and q are assumed LI).
now suppose q'(x) is in U (which it must be, for U to be invariant). so q'(x) = ap(x) + bq(x) = ac + bq(x).
thus q'(x) - ac = bq(x).
comparing leading terms, we see that b = 0, so q'(x) = ac, a constant. hence q(x) is linear, say rx + s, and r is non-zero. since 1 = (1/c)c + 0(rx + s), 1 is in U.
since x = (-s/(rc))(c) + (1/r)(rx + s), we see that {1,x} is contained in U, and since dim(U) = 2, U must be P1.
now, use induction to show that if dim(U) = n, U = Pn-1.
now, all that is left is to show that U is not finite-dimensional, it must be all of P[x]. with a little cleverness you can use the same argument (what happens if xk is not in U, for some k in N?).
|
{}
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.