Talk:Triangle wave
This article is rated Start-class on Wikipedia's content assessment scale. It is of interest to the following WikiProjects: | |||||||||||
|
arcsin
editarcsin(sin(x))= /\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\
try it...
- yepp, ((acos(sin(t)))/pi-0.5)*2*max_amplitude --217.230.116.48 (talk) 18:48, 20 January 2008 (UTC)
- Just because it's shaped like a triangle wave doesn't mean it's a triangle wave. A true triangle wave has equal DC offset, and y=acos(sin(t)) is all above the y axis. LokiClock (talk) 14:13, 9 May 2009 (UTC)
While doing some experiments, I actually noticed that a triangle wave has the odd members of the harmonics encountered in a square wave; that is, that in contains the harmonic frequencies 1, 5, 9, 13 aso.
--91.155.86.4 (talk) 14:24, 29 August 2008 (UTC)
Fourier expansion
editShould
not read
? (Notice I changed a - to a +)
--Evilc (talk) 12:03, 18 March 2010 (UTC)
- Good catch, I have fixed it (and a few other things). Next time feel free to make the correction yourself, you don't need anyone's permission. SpinningSpark 11:09, 3 April 2010 (UTC)
- Just realised the article was changed by an IP to the wrong version and your version is wrong also, I didn't read it properly, I assumed you were proposing a changing the wrong version I could see in the article. The change I have made in the article is to the correct version. SpinningSpark 16:12, 3 April 2010 (UTC)
Neither of the two formulas for x(t) actually give (a non-bandlimited version of) the waveform shown at the top of the page. They give some combination of incorrect amplitude, incorrect vertical shift, incorrect frequency, or incorrect phase. They are easy to fix but nonetheless it is misleading to imply that they will yield the given waveform. —Preceding unsigned comment added by 75.172.177.67 (talk) 06:09, 14 May 2010 (UTC)
I was just generating a triangle wave via additive synthesis and found this page unhelpful. What I ended up with was trivial: cos(wt)+cos(3wt)/9+cos(5wt)/25+... Any reason this isn't the expression shown? 72.48.75.131 (talk) 22:17, 19 December 2010 (UTC)
ICL8038
editI have reverted the recent addition of a triangle wave implementation with ICL8038. First of all, this device is obsolete so this is not actually a practical means of generating triangle waves. I am not at all sure that this belongs here in any case: it is aimed at the electronics hobbyist and as such is sailing close to WP:NOTHOWTO. The piece is unsourced and is littered with errors as can easily be seen from the device data sheet, or else if they are not errors there is even more need for a reliable source. It also seems to have escaped the poster (as s/he did not link to it) that there is already an article on this device, 8038 ic (sic) although this is equally dire. SpinningSpark 17:01, 2 March 2011 (UTC)
definition section
editThe use of the abs(sawtooth) results in a range of 0-1, not -1 to 1 as implied in the first sentence of this section. — Preceding unsigned comment added by Jcwill23 (talk • contribs) 21:43, 14 October 2012 (UTC) Jcwill23 (talk) 08:37, 15 October 2012 (UTC)
I agree - I am trying to implement it in the time-domain and I was surprised to find the energy-output only half of what it should be. Had a "duh" moment when I saw the graph. I'll change it on the main page. RonaldKunenborg (talk) 21:21, 25 October 2012 (UTC) (note: it's 2*(function)-1) RonaldKunenborg (talk) 22:09, 25 October 2012 (UTC)
Try sin y = cos x Alfred. — Preceding unsigned comment added by Alfredsimpson (talk • contribs) 19:13, 2 July 2015 (UTC)
More Definiton Section
editShouldn't this
Be this?
When I graph the first one, with : , its period is 2.
Bad approximation
editThe mentioned Fourier series in the "Harmonics" section seems to be a bad approximation:
https://www.wolframalpha.com/input/?i=sum+%28-1%29^k+*+sin%282+*+pi+*+t+*+%282+*+k+%2B+1%29%29+%2F+%282+*+k+%2B+1%29^2%2C+k%3D1+to+10
And it doesn't get any better with more iterations.
Can somebody explain?
- You should use k = 0 to 10, not k = 1 to 10, btw nice estimation of inf by 10 ;-) https://www.wolframalpha.com/input/?i=sum+%28-1%29^k+*+sin%282+*+pi+*+t+*+%282+*+k+%2B+1%29%29+%2F+%282+*+k+%2B+1%29^2,+k%3D0+to+10
- 2016. k = 1 to infinite can still work, however it requires a few changes. The approximation itself contains the Fourier series and the fourier coefficient (bn) as well as a method to automaticly sort out all the unnecessary bn coefficients (where bn = 0), of which there a lot. This is because the triangle wave best resembles a harmonic wave (compared to the sawtooth and square wave).
The root problem is the inbuilt number generator. Here's an example of two generators generating the same numbers: Odd numbers generator 1. Odd number = 2k-1, where k = 1,2,3,4,5...
Odd numbers generator 2. Odd number = 2k+1, where k = 0,1,2,3,4...
That's why the approximation was dependant on k = 0 to infinite it was using + instead of -, however it also means it can be rewritten to work with k = 1 to infinite. I personally use this: https://www.wolframalpha.com/input/?i=sum+(-1)%5E(k%2B1)*+(sin%E2%81%A1(2%CF%80(2k-1)t))%2F(2k-1)%5E2),+k%3D1+to+10
The reason I like this better is because the constant k will be equal to the n'th-harmonic wave of the triangle wave, and seeing as this hasn't been changed I still think this has its relevance :) — Preceding unsigned comment added by Flyingmadpakke (talk • contribs) 23:36, 16 December 2016 (UTC)
Hello all,
Shouldn't the approximation include normalization coefficient if I want to have it normalized [-1; 1]? Other pages like square, sawtooth all have this. Potasmic (talk) 06:57, 17 December 2017 (UTC)
It does appear that the summation in the Harmonics section should start at 0, otherwise there is no fundamental and the series does not converge to a triangle wave.219.89.88.252 (talk) 06:36, 16 June 2019 (UTC)
audio problems
editI can play the longer audio sample, but when I press the 5 second sample play button, nothing happens. Safari/iOS. Mcandre (talk) 17:26, 19 July 2016 (UTC)
A different equation
editHow do I insert this equation?
- <math> y=2 \frac{a \arcsin \left(\sin \left ( \frac{1}{ \frac{w}{4}} \left( \frac{x\pi} {2}-\frac{ \pi \left(h-\frac{w}{4} \right)}{2} \right) \right) \right)}{\pi}+v \right \rfloor</math>
Entity Valkyrie (talk) 06:41, 13 August 2019 (UTC)
Your original formula had some syntax errors, is this what you meant?
The Editor's Apprentice (talk) 18:07, 13 August 2019 (UTC)
Yes. You can try it in Desmos to see if it works. I replace w with lambda. Entity Valkyrie (talk) 03:58, 14 August 2019 (UTC)
- @Entity Valkyrie: I see that the equation that you provided does indeed work. Despite that, I am going to go ahead and remove your addition since a similar formula, specifically , already appears at the bottome of the Definitions section. Although this equation, as well the rest of the equations in section, does not explicitly include variables for a horizontal or vertical shift I think that is okay because a reader can probably figure out how to include such shifts themself. In additon, the inclusion of such variables in the formulas would add detail which I think would also clutter the formulas. I also ask that you not edit my posts, nor anyone elses except your own, on talk pages as doing so can misrpresent the posts original meaning. More details regarding editing other's talk page posts can be found at WP:TPO. The Editor's Apprentice (talk) 17:41, 14 August 2019 (UTC)