Affinity-Inspiration Posted March 31, 2020 Share Posted March 31, 2020 Ok, I have a straight line, and I need to write the equation to make it into a sine wave. Now sine waves are reasonable easy to understand, but I’m afraid the syntax on the Affinity Photo filter is escaping me. anybody? Quote iPad Mini 6. 256GB. Publisher. Designer. Photo for Mac, PC & iOS @Affinity-Inspiration Link to comment Share on other sites More sharing options...
Paul Mudditt Posted March 31, 2020 Share Posted March 31, 2020 9 minutes ago, HarryMcGovern said: Ok, I have a straight line, and I need to write the equation to make it into a sine wave. Now sine waves are reasonable easy to understand, but I’m afraid the syntax on the Affinity Photo filter is escaping me. anybody? I always read John’s work when trying to remember how these work, perhaps it will help Quote My dad always told me, a bad workman always blames their tools…. Just waiting for Ronny Pickering….. Affinity Photo, Designer, Publisher 1.10 and 2.4 on macOS Sonoma 14 on M1 Mac Mini 16GB 1TB Affinity Photo, Designer, Publisher 1.10 and 2.4 on Windows 10 Pro. Deceased Affinity Photo, Designer, Publisher 2.4 on M1 iPad Pro 11” on iPadOS 17.4 https://www.facebook.com/groups/AffinityForiPad https://www.facebook.com/groups/AffinityPhoto/ The hardest link to find https://affinity.help Link to comment Share on other sites More sharing options...
John Rostron Posted March 31, 2020 Share Posted March 31, 2020 @HarryMcGovern, @Paul Mudditt, you might like to look at my tutorial on using Trig functions in Equations. Use the search box for: distort trig functions. This should find my tutorial. Note that the Filter > Distort > Equations affects the entire image (pixel layer). If you want to distort a single line, then you would need to select it, along with sufficient elbow room; copy this to the clipboard; then select New from clipboard; then you can apply the filter. John Quote Windows 10, Affinity Photo 1.10.5 Designer 1.10.5 and Publisher 1.10.5 (mainly Photo), now ex-Adobe CC CPU: AMD A6-3670. RAM: 16 GB DDR3 @ 666MHz, Graphics: 2047MB NVIDIA GeForce GT 630 Link to comment Share on other sites More sharing options...
Affinity-Inspiration Posted March 31, 2020 Author Share Posted March 31, 2020 Thanks guys. The one on labels will certainly come in handy when doing the labels for my vineyard. and the second one also very useful. this is what I’m after... “ basic sine function, f (t) = sin(t). This function has an amplitude of 1 because the graph goes one unit up and one unit down from the midline of the graph. This function has a period of 2πbecause the sine wave repeats every 2π units. The graph looks like this: Quote iPad Mini 6. 256GB. Publisher. Designer. Photo for Mac, PC & iOS @Affinity-Inspiration Link to comment Share on other sites More sharing options...
Affinity-Inspiration Posted April 1, 2020 Author Share Posted April 1, 2020 Ok, Thanks for all the input folks. I still don't understand the math - but I'm making it work. Thanks especially to @Carl123. His equation got me started. Photo has upgraded since that was done but esentially the same. The fist image is my version of Revival, The second image is setting up the sine wave. Quote iPad Mini 6. 256GB. Publisher. Designer. Photo for Mac, PC & iOS @Affinity-Inspiration Link to comment Share on other sites More sharing options...
John Rostron Posted April 2, 2020 Share Posted April 2, 2020 I have just tried to create a sine wave using equations as I have done before. The argument of the sine function now seems to be in radians, where it was degrees before. I presume this is a change in 1.8. I created a straight line in a blank document 250 px high and 800 wide. I wished to create a sine wave of three cycles, so the multiplier in the sine function is three times two pi, or 6*pi. In Filters > Distort > Equations, I entered x=x y+100*sin(6*pi*x/w) John CarterTG and Affinity-Inspiration 2 Quote Windows 10, Affinity Photo 1.10.5 Designer 1.10.5 and Publisher 1.10.5 (mainly Photo), now ex-Adobe CC CPU: AMD A6-3670. RAM: 16 GB DDR3 @ 666MHz, Graphics: 2047MB NVIDIA GeForce GT 630 Link to comment Share on other sites More sharing options...
Affinity-Inspiration Posted April 2, 2020 Author Share Posted April 2, 2020 Excellent. Thank you so much. Brilliant. Quote iPad Mini 6. 256GB. Publisher. Designer. Photo for Mac, PC & iOS @Affinity-Inspiration Link to comment Share on other sites More sharing options...
Affinity-Inspiration Posted April 2, 2020 Author Share Posted April 2, 2020 6 hours ago, John Rostron said: I have just tried to create a sine wave using equations as I have done before. The argument of the sine function now seems to be in radians, where it was degrees before. I presume this is a change in 1.8. I created a straight line in a blank document 250 px high and 800 wide. I wished to create a sine wave of three cycles, so the multiplier in the sine function is three times two pi, or 6*pi. In Filters > Distort > Equations, I entered x=x y+100*sin(6*pi*x/w) John Thanks John, Great stuff. Lots of experimentation ahead. John Rostron 1 Quote iPad Mini 6. 256GB. Publisher. Designer. Photo for Mac, PC & iOS @Affinity-Inspiration Link to comment Share on other sites More sharing options...
DM1 Posted April 3, 2020 Share Posted April 3, 2020 23 hours ago, John Rostron said: wished to create a sine wave of three cycles, so the multiplier in the sine function is three times two pi, or 6*pi. In Filters > Distort > Equations, I entered x=x y+100*sin(6*pi*x/w) On the iPad their is simply an Equations filter, so the process is Filters/Equations after which I then entered x=x and y+100*sin(6*pi*x/w) but the line remained straight. I changed the x=x to simply x and then the sine wave appeared. Perhaps I simply misunderstood John's directions or is this a difference between desktop and iPad? Quote M1 IPad Air 10.9/256GB lpadOS 17.1.1 Apple Pencil (2nd gen). Affinity Photo 1.10.5 Affinity Design 1.10.5 Affinity Publisher 2, Affinity Designer 2, Affinity Photo 2 and betas. Official Online iPad Help documents (multi-lingual) here: https://affinity.https://affinity.help/ Link to comment Share on other sites More sharing options...
Affinity-Inspiration Posted April 3, 2020 Author Share Posted April 3, 2020 2 minutes ago, DM1 said: On the iPad their is simply an Equations filter, so the process is Filters/Equations after which I then entered x=x and y+100*sin(6*pi*x/w) but the line remained straight. I changed the x=x to simply x and then the sine wave appeared. Perhaps I simply misunderstood John's directions or is this a difference between desktop and iPad? Thanks for that heads up. I truly suspect that the ipad version is broken. For a start - part of the Equations editor is missing entirely. You are right about the x=x bit. Just leave that out. I'll experiment more with the ipad version anyway, as it's interesting anyway. Quote iPad Mini 6. 256GB. Publisher. Designer. Photo for Mac, PC & iOS @Affinity-Inspiration Link to comment Share on other sites More sharing options...
John Rostron Posted April 3, 2020 Share Posted April 3, 2020 @HarryMcGovern, The 'x=' and 'y='' are already part of the equations dialogue. When I make a text record of a macro, I include these prefixes. I had not realised this when I posted these formulas above. Sorry for the confusion. Mea culpa. John Quote Windows 10, Affinity Photo 1.10.5 Designer 1.10.5 and Publisher 1.10.5 (mainly Photo), now ex-Adobe CC CPU: AMD A6-3670. RAM: 16 GB DDR3 @ 666MHz, Graphics: 2047MB NVIDIA GeForce GT 630 Link to comment Share on other sites More sharing options...
Affinity-Inspiration Posted April 3, 2020 Author Share Posted April 3, 2020 No problems John, I figured that 🙂 Quote iPad Mini 6. 256GB. Publisher. Designer. Photo for Mac, PC & iOS @Affinity-Inspiration Link to comment Share on other sites More sharing options...
DM1 Posted April 3, 2020 Share Posted April 3, 2020 2 hours ago, HarryMcGovern said: I truly suspect that the ipad version is broken. For a start - part of the Equations editor is missing entirely. Comparing the iPad equation filter to your posted image of desktop panel, the switch to choose angular units (degrees or radians) Is missing, however switching from Cartesian to Polar in the Context menu automatically sets the equation parameters to 'r' (radius) and theta (polar angle). In practice Polar angles may be expressed either in degrees or radians. Given the missing switch I'm not sure which is applicable for this equations filter. The help file is not particularly helpful either. Quote M1 IPad Air 10.9/256GB lpadOS 17.1.1 Apple Pencil (2nd gen). Affinity Photo 1.10.5 Affinity Design 1.10.5 Affinity Publisher 2, Affinity Designer 2, Affinity Photo 2 and betas. Official Online iPad Help documents (multi-lingual) here: https://affinity.https://affinity.help/ Link to comment Share on other sites More sharing options...
Affinity-Inspiration Posted April 13, 2020 Author Share Posted April 13, 2020 Is it possible to create an audio equation like this? Quote iPad Mini 6. 256GB. Publisher. Designer. Photo for Mac, PC & iOS @Affinity-Inspiration Link to comment Share on other sites More sharing options...
walt.farrell Posted April 13, 2020 Share Posted April 13, 2020 4 hours ago, HarryMcGovern said: Is it possible to create an audio equation like this? That pattern does not look like something that was generated by an equation, so my guess is that you would not be able to write an equation for it. Quote -- Walt Designer, Photo, and Publisher V1 and V2 at latest retail and beta releases PC: Desktop: Windows 11 Pro, version 23H2, 64GB memory, AMD Ryzen 9 5900 12-Core @ 3.00 GHz, NVIDIA GeForce RTX 3090 Laptop: Windows 11 Pro, version 23H2, 32GB memory, Intel Core i7-10750H @ 2.60GHz, Intel UHD Graphics Comet Lake GT2 and NVIDIA GeForce RTX 3070 Laptop GPU. iPad: iPad Pro M1, 12.9": iPadOS 17.4.1, Apple Pencil 2, Magic Keyboard Mac: 2023 M2 MacBook Air 15", 16GB memory, macOS Sonoma 14.4.1 Link to comment Share on other sites More sharing options...
Affinity-Inspiration Posted April 13, 2020 Author Share Posted April 13, 2020 No, it’s an audio wave, but audio waves can be shown in equation form but I just don’t know the math 😞 It’s shown on Wikipedia under Sine Waves I think it was. Back to the books... Quote iPad Mini 6. 256GB. Publisher. Designer. Photo for Mac, PC & iOS @Affinity-Inspiration Link to comment Share on other sites More sharing options...
Paul Mudditt Posted April 13, 2020 Share Posted April 13, 2020 34 minutes ago, HarryMcGovern said: No, it’s an audio wave, but audio waves can be shown in equation form but I just don’t know the math 😞 It’s shown on Wikipedia under Sine Waves I think it was. Back to the books... Yes in theory you could generate this but doing a Fourier analysis to give you the harmonic values would be very complex over just manually drawing it if real accuracy is not required. Can I ask why you would want something so visibly complex? Quote My dad always told me, a bad workman always blames their tools…. Just waiting for Ronny Pickering….. Affinity Photo, Designer, Publisher 1.10 and 2.4 on macOS Sonoma 14 on M1 Mac Mini 16GB 1TB Affinity Photo, Designer, Publisher 1.10 and 2.4 on Windows 10 Pro. Deceased Affinity Photo, Designer, Publisher 2.4 on M1 iPad Pro 11” on iPadOS 17.4 https://www.facebook.com/groups/AffinityForiPad https://www.facebook.com/groups/AffinityPhoto/ The hardest link to find https://affinity.help Link to comment Share on other sites More sharing options...
Affinity-Inspiration Posted April 13, 2020 Author Share Posted April 13, 2020 29 minutes ago, Paul Mudditt said: Yes in theory you could generate this but doing a Fourier analysis to give you the harmonic values would be very complex over just manually drawing it if real accuracy is not required. Can I ask why you would want something so visibly complex? Why? Well I guess I’m always trying to push great software like this to its limits. See just what is possible. I mean equations. That speaks of someone behind the scenes interested in more than just ‘nice patterns’. A fixed sine wave is as we know a graph of a specific frequency, but audio is not fixed and the sine wave fluctuates. I just want to see if I can graph it. But probably not possible. Quote iPad Mini 6. 256GB. Publisher. Designer. Photo for Mac, PC & iOS @Affinity-Inspiration Link to comment Share on other sites More sharing options...
walt.farrell Posted April 13, 2020 Share Posted April 13, 2020 I think there are really two questions, Harry: Do you know an equation to generate a waveform like that. Can you write that equation in Affinity. #1 is something to be researched elsewhere. But given an answer to it, #2 may be interesting to readers of this forum Quote -- Walt Designer, Photo, and Publisher V1 and V2 at latest retail and beta releases PC: Desktop: Windows 11 Pro, version 23H2, 64GB memory, AMD Ryzen 9 5900 12-Core @ 3.00 GHz, NVIDIA GeForce RTX 3090 Laptop: Windows 11 Pro, version 23H2, 32GB memory, Intel Core i7-10750H @ 2.60GHz, Intel UHD Graphics Comet Lake GT2 and NVIDIA GeForce RTX 3070 Laptop GPU. iPad: iPad Pro M1, 12.9": iPadOS 17.4.1, Apple Pencil 2, Magic Keyboard Mac: 2023 M2 MacBook Air 15", 16GB memory, macOS Sonoma 14.4.1 Link to comment Share on other sites More sharing options...
carl123 Posted April 13, 2020 Share Posted April 13, 2020 Generating a random sign wave (audio wave) is difficult. It would be easier if the expressions you can use in the equations filter included a random number generator. y+200*sin(a*0.1*x)+(200*sin(b*0.1*x))+(200*sin(c*0.1*x)) Affinity-Inspiration 1 Quote To save time I am currently using an automated AI to reply to some posts on this forum. If any of "my" posts are wrong or appear to be total b*ll*cks they are the ones generated by the AI. If correct they were probably mine. I apologise for any mistakes made by my AI - I'm sure it will improve with time. Link to comment Share on other sites More sharing options...
Affinity-Inspiration Posted April 13, 2020 Author Share Posted April 13, 2020 2 hours ago, carl123 said: Generating a random sign wave (audio wave) is difficult. It would be easier if the expressions you can use in the equations filter included a random number generator. y+200*sin(a*0.1*x)+(200*sin(b*0.1*x))+(200*sin(c*0.1*x)) That’s really interesting, thank you so much. It’s a struggle on the iPad... but desktop good. This allows me to create some really random, unique designs. Quote iPad Mini 6. 256GB. Publisher. Designer. Photo for Mac, PC & iOS @Affinity-Inspiration Link to comment Share on other sites More sharing options...
carl123 Posted April 14, 2020 Share Posted April 14, 2020 11 hours ago, HarryMcGovern said: This allows me to create some really random, unique designs. Please share any additional interesting equation formulas you discover. The Equations Filter is quite powerful but there is very little documentation for it so the only way for some people to understand what it can do and to experiment more is via this forum Quote To save time I am currently using an automated AI to reply to some posts on this forum. If any of "my" posts are wrong or appear to be total b*ll*cks they are the ones generated by the AI. If correct they were probably mine. I apologise for any mistakes made by my AI - I'm sure it will improve with time. Link to comment Share on other sites More sharing options...
firstdefence Posted April 15, 2021 Share Posted April 15, 2021 Interesting tool: https://meettechniek.info/additional/additive-synthesis.html Alfred 1 Quote iMac 27" 2019 Somona 14.3.1, iMac 27" Affinity Designer, Photo & Publisher V1 & V2, Adobe, Inkscape, Vectorstyler, Blender, C4D, Sketchup + more... XP-Pen Artist-22E, - iPad Pro 12.9 (Please refrain from licking the screen while using this forum) Affinity Help - Affinity Desktop Tutorials - Feedback - FAQ - most asked questions Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.