<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://performiq.com/kb/index.php?action=history&amp;feed=atom&amp;title=Function_Generator</id>
	<title>Function Generator - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://performiq.com/kb/index.php?action=history&amp;feed=atom&amp;title=Function_Generator"/>
	<link rel="alternate" type="text/html" href="https://performiq.com/kb/index.php?title=Function_Generator&amp;action=history"/>
	<updated>2026-05-18T11:39:56Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.37.1</generator>
	<entry>
		<id>https://performiq.com/kb/index.php?title=Function_Generator&amp;diff=5444&amp;oldid=prev</id>
		<title>PeterHarding: Created page with &quot;= Function Generator =  See - https://web.archive.org/web/20161126051349/http://www.albedo-cg.de/ImpactPrograms/impactGauss.rar  Hi, everybody!  Some of you might remember my old Python script that allowed you to generate detailed motion behaviors that otherwise would be almost impossible to program.  Good news! I&#039;m working on a Java command line version of this program. I&#039;ve added many new possibilities to create complex movements. A new addition will be the possibility...&quot;</title>
		<link rel="alternate" type="text/html" href="https://performiq.com/kb/index.php?title=Function_Generator&amp;diff=5444&amp;oldid=prev"/>
		<updated>2025-11-28T23:30:07Z</updated>

		<summary type="html">&lt;p&gt;Created page with &amp;quot;= Function Generator =  See - https://web.archive.org/web/20161126051349/http://www.albedo-cg.de/ImpactPrograms/impactGauss.rar  Hi, everybody!  Some of you might remember my old Python script that allowed you to generate detailed motion behaviors that otherwise would be almost impossible to program.  Good news! I&amp;#039;m working on a Java command line version of this program. I&amp;#039;ve added many new possibilities to create complex movements. A new addition will be the possibility...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;= Function Generator =&lt;br /&gt;
&lt;br /&gt;
See - https://web.archive.org/web/20161126051349/http://www.albedo-cg.de/ImpactPrograms/impactGauss.rar&lt;br /&gt;
&lt;br /&gt;
Hi, everybody!&lt;br /&gt;
&lt;br /&gt;
Some of you might remember my old Python script that allowed you to generate detailed motion behaviors that otherwise would be almost impossible to program.&lt;br /&gt;
&lt;br /&gt;
Good news!&lt;br /&gt;
I&amp;#039;m working on a Java command line version of this program. I&amp;#039;ve added many new possibilities to create complex movements.&lt;br /&gt;
A new addition will be the possibility to define space curves that the program translates into Impact compatible velocity functions.&lt;br /&gt;
&lt;br /&gt;
Just for your information, here&amp;#039;s a snippet of the in-program documentation:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/* List of arguments used:&lt;br /&gt;
 &lt;br /&gt;
    waveform: waveform/motion Shape, like tri, sin etc.&lt;br /&gt;
    motionProperty: which property is modulated? a, v, f, p etc.&lt;br /&gt;
    cycleLength: the length of one motion cycle in milliseconds. This is the time scale I&amp;#039;m using.&lt;br /&gt;
    Free timescale definition may be implemented later.&lt;br /&gt;
    amplitude: nuff said&lt;br /&gt;
    offset: this is the amplitude offset&lt;br /&gt;
    startTime: you know what I mean.&lt;br /&gt;
    stopTime: no comment.&lt;br /&gt;
    fileName: maybe this means the filename? Who knows?&lt;br /&gt;
    (shift): this doesn&amp;#039;t exist yet. This will enable you to define a phase shifting of the wave.&lt;br /&gt;
    You need this for cosine (sin(alpha-90°)) for example.&lt;br /&gt;
 &lt;br /&gt;
    At the moment you have to enter the command line arguments in the exact order.&lt;br /&gt;
    I&amp;#039;ll add a proper parsing routine so you can define the values in any order you want.&lt;br /&gt;
    Like this:&lt;br /&gt;
    w tri p ax l 0.5 s 0.0 e 2.5 a 1.0 o -0.33 f example.txt&lt;br /&gt;
    Which actually means:&lt;br /&gt;
    waveform tri motionProperty ax cycleLength 0.5ms startTime 0.0ms stopTime 4.5ms amplitude 1.0 offset 0.0 filename example.in&lt;br /&gt;
 &lt;br /&gt;
    */&lt;br /&gt;
&lt;br /&gt;
To cope with the stopTime problem in case of different from zero/min/max crossing simply add another quarter cycle.&lt;br /&gt;
&lt;br /&gt;
                The rest will be automatically interpolated.&lt;br /&gt;
 &lt;br /&gt;
                motionProperties have to be checked against standard properties as:&lt;br /&gt;
                a* (acceleration, ax,ay,az)&lt;br /&gt;
                ar*(rotational acceleration)&lt;br /&gt;
                f* (force)&lt;br /&gt;
                v* (velocity)&lt;br /&gt;
                p  (pressure)&lt;br /&gt;
 &lt;br /&gt;
                These Properties come with the following time behaviours (those marked with * are implemented):&lt;br /&gt;
 &lt;br /&gt;
                * tri: triangular time vs. property behavior&lt;br /&gt;
                * sin: sinusodial behavior&lt;br /&gt;
                  squ: square waveform behavior. pulse width modulation possible&lt;br /&gt;
                  gauss: a gauss-bell shaped waveform for single pulse events.&lt;br /&gt;
                  ram: ramp waveform - a clipped triangle waveform with variable asymmetry and width modulation, like this:&lt;br /&gt;
 &lt;br /&gt;
                     -----                 +&lt;br /&gt;
                    +     ++              +&lt;br /&gt;
                   +        ++           +&lt;br /&gt;
                  +           ++        +&lt;br /&gt;
                 +              ++     +&lt;br /&gt;
                +                 -----&lt;br /&gt;
 &lt;br /&gt;
                or&lt;br /&gt;
 &lt;br /&gt;
                   ---------               +&lt;br /&gt;
                   +        +              +&lt;br /&gt;
                  +          +            +&lt;br /&gt;
                  +           +           +&lt;br /&gt;
                 +             +         +&lt;br /&gt;
                 +              ----------&lt;br /&gt;
 &lt;br /&gt;
                The ramp waveform makes the square and tri waveform obsolete:&lt;br /&gt;
                - A ramp without caps is a tri waveform.&lt;br /&gt;
                - A ramp with maximum cap width is a square/rectangular waveform.&lt;br /&gt;
 &lt;br /&gt;
                A new property is defined, called &amp;quot;l&amp;quot; (location). The new property will make the definition of movements along paths a lot easier&lt;br /&gt;
                This type will then be translated into velocity that is readable by the program.&lt;br /&gt;
                For this a 2D or 3D treatment is essential, as the 2D/3D space vectors are needed to calculate velocity from space curves.&lt;br /&gt;
                The treatment is easy because the program uses linear interpolation to determine intermediate values.&lt;br /&gt;
 &lt;br /&gt;
                &amp;quot;l&amp;quot; defines the following trajectory shapes (The * marks implemented properties):&lt;br /&gt;
 &lt;br /&gt;
                lcirc: circle (good for eccentric simulations)&lt;br /&gt;
                lpoly: polygonal shape with n equal sides&lt;br /&gt;
                lelip: ellipse&lt;br /&gt;
                lwave: this is the ultimate goal. A wav-file used as displacement source. could be a bit hard for me at the beginning...&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Entering the command line:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
impactMotion.jar w tri p ax l 1.0 s 0.0 e 4.5 a 1.0 o 0.0 f example.in&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
which actually means:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
waveform tri motionProperty ax cycleLength 1.0ms startTime 0.0ms stopTime 4.5ms amplitude 1.0 offset 0.0 filname example.in&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
gives the following result:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ax=[0.0,0.0,0.25,10.0,0.5,0.0,0.75,-10.0,1.0,0.0,1.25,10.0,1.5,0.0,1.75,&lt;br /&gt;
-10.0,2.0,0.0,2.25,10.0,2.5,0.0,2.75,-10.0,3.0,0.0,3.25,10.0,3.5,0.0,3.75,&lt;br /&gt;
-10.0,4.0,0.0,4.25,10.0,4.5,0.0,4.75,-10.0]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
in the file example.in&lt;br /&gt;
&lt;br /&gt;
This is a triangle waveform, as you can see.&lt;br /&gt;
&lt;br /&gt;
I hope to finish the rest of the waveforms soon.&lt;br /&gt;
&lt;br /&gt;
- Manuel_L Manuel_L Jul 13, 2006&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
New Function Generator for Gauss curves&lt;br /&gt;
&lt;br /&gt;
Hi, everybody!&lt;br /&gt;
&lt;br /&gt;
I&amp;#039;ve written a first version of the function generator for Impact but I&amp;#039;m rather unexperienced in JAVA, so I&amp;#039;m restructuring the code now.&lt;br /&gt;
&lt;br /&gt;
The first generator that&amp;#039;s ready is made for the definition of a Gauss curve.&lt;br /&gt;
&lt;br /&gt;
The data precision you enter is double, so don&amp;#039;t wonder about strange rounding errors like 9.89999999999998 instead of 9.9 :)&lt;br /&gt;
&lt;br /&gt;
Simply use the program like this (in brackets stands the type of data you have to enter):&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
impactGauss.jar filename.txt(string) property(string) startTime(double) endTime(double) amplitude(double) sigma(double) peak(double) timeStep(double)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
so entering&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
impactGauss.jar test.txt ax 0.0 1.0 1.0 0.1 0.3 0.025&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
means acceleration in x-direction, start at 0.0, end at 1.0, amplitude 1.0, sigma of Gauss curve 0.1, peak at 0.3, time steps at which values are calculated 0.025&lt;br /&gt;
This yields:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ax=[0.0,0.011108996538242316,0.025,0.022794180883612375,0.05,0.04393693362340742,&lt;br /&gt;
0.07500000000000001,0.07955950871822776,0.1,0.13533528323661276,0.125,0.2162651668298874,&lt;br /&gt;
0.15,0.3246524673583498,0.175,0.45783336177161427,0.19999999999999998,0.6065306597126334,&lt;br /&gt;
0.22499999999999998,0.7548396019890072,0.24999999999999997,0.8824969025845953,0.27499999999999997,&lt;br /&gt;
0.969233234476344,0.3,1.0,0.325,0.969233234476344,0.35000000000000003,0.8824969025845952,&lt;br /&gt;
0.37500000000000006,0.7548396019890069,0.4000000000000001,0.6065306597126329,0.4250000000000001,&lt;br /&gt;
0.4578333617716136,0.4500000000000001,0.3246524673583491,0.47500000000000014,0.21626516682988672,&lt;br /&gt;
0.5000000000000001,0.13533528323661245,0.5250000000000001,0.07955950871822744,0.5500000000000002,&lt;br /&gt;
0.04393693362340726,0.5750000000000002,0.022794180883612236,0.6000000000000002,&lt;br /&gt;
0.011108996538242247,0.6250000000000002,0.005086069231012664,0.6500000000000002,&lt;br /&gt;
0.0021874911181828677,0.6750000000000003,8.838263069350413E-,0.7000000000000003,&lt;br /&gt;
3.354626279025083E-4,0.7250000000000003,1.1961288358102309E-4,0.7500000000000003,&lt;br /&gt;
4.0065297392950425E-5,0.7750000000000004,1.2607105177048299E-4,0.8000000000000004,&lt;br /&gt;
3.726653172078585E-6,0.8250000000000004,1.0348542111093552E-6,0.8500000000000004,&lt;br /&gt;
2.6995785033629474E-7,0.8750000000000004,6.615601637697559E-8,0.9000000000000005,&lt;br /&gt;
1.5229979744712143E-8,0.9250000000000005,3.2937141103059874E-9,&lt;br /&gt;
0.9500000000000005,6.691586091292545E-10,0.9750000000000005,1.277111554512797E-10,1.0000000000000004,2.289734845645496E-11]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Don&amp;#039;t forget that Gauss curves at the start need to have the peak at least 3*sigma&lt;br /&gt;
(3 times the standard deviation) away from start time if you want the curve to start smoothly at&lt;br /&gt;
near zero values. It&amp;#039;s better to have the peak 3.5 or 4 times sigma away from the start time to&lt;br /&gt;
be on the safe side.&lt;br /&gt;
&lt;br /&gt;
Now you only need to copy and paste this text bit into your in-file and you&amp;#039;re done.&lt;br /&gt;
&lt;br /&gt;
The program doesn&amp;#039;t have any type testing or any other exeption handling, only file writing&lt;br /&gt;
is handled, so if you don&amp;#039;t enter the values exactly in the correct order nothing will happen,&lt;br /&gt;
you might get messed up data, your computer might explode or whatever ;)&lt;br /&gt;
&lt;br /&gt;
I hope this small jar-file is useful to you. If you want to change something you can use the&lt;br /&gt;
source code. I&amp;#039;ll add lots of other mathematical curves later.&lt;br /&gt;
&lt;br /&gt;
Get the jar-file and the java source from here:&lt;br /&gt;
&lt;br /&gt;
http://www.albedo-cg.de/ImpactPrograms/impactGauss.rar&lt;br /&gt;
&lt;br /&gt;
- Manuel_L  Oct 16, 2006&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:Impact]]&lt;br /&gt;
[[Category:Impact Wiki]]&lt;/div&gt;</summary>
		<author><name>PeterHarding</name></author>
	</entry>
</feed>