C RUBY-ON-RAILS MYSQL ASP.NET DEVELOPMENT RUBY .NET LINUX SQL-SERVER REGEX WINDOWS ALGORITHM ECLIPSE VISUAL-STUDIO STRING SVN PERFORMANCE APACHE-FLEX UNIT-TESTING SECURITY LINQ UNIX MATH EMAIL OOP LANGUAGE-AGNOSTIC VB6 MSBUILD

# Numerical issues integrating a pulse signal that is delayed (fixedDelay)

By : user2172897
Date : October 22 2020, 08:10 AM
I hope this helps . As Ankit posted at the Wolfram Forum, the problem is that the signal is discrete but the delay block is unaware of that. It can be fixed with a different delay block:
code :
``````model DiscreteFixedDelay
discrete input Modelica.Blocks.Interfaces.RealInput u ;
discrete output Modelica.Blocks.Interfaces.RealOutput y ;
parameter Modelica.SIunits.Time delayTime(start = 5) = 5 "Delay time of output with respect to input signal";
equation
y = delay(u, delayTime);
end DiscreteFixedDelay;
``````

Share :

## convolution of sinus signal with rectangular pulse

By : Akshay Gupta
Date : March 29 2020, 07:55 AM
like below fixes the issue You've done very well plotting the convolution and then analyzing it to see that it is not what you expect, +1! However, I think the concern you have is related to the convolve function. Since you passed it the parameter mode="same" it chops off the part of the convolution that equals zero and leaves you with the "interesting" part. You have constructed the rect() function just fine, although I agree with you there should be an alternate way built in to scipy somewhere. When I allow the entire convolution to be plotted, I get:
code :
``````from scipy import *
from pylab import *

x = r_[0:50]
y1 = sin(2*pi*x/49)
#y2 = cos(2*pi*x/49)
y2 = np.zeros((y1.shape))
for i in range(15,25):
y2[i] = 0.9
#print len(y1),len(y2)
#y3 = convolve(y2,y1,mode="same")
y3 = convolve(y2,y1)
subplot(2,2,1)
plot(x,y1)
hold(True)
plot(x,y2)
hold(True)
subplot(2,2,2)
print len(x),len(y3)
xx = r_[0:len(y3)]
print len(xx),len(y3)
plot(xx,y3)
hold(True)
show()
``````

## Find time duration between two pulse of same signal

By : jiancheng
Date : March 29 2020, 07:55 AM
this will help Check function pulseIn() It will solve your problem. Note: Just put LOW as parameter.

## How to Draw and animate the wifi signal pulse

By : think Different
Date : March 29 2020, 07:55 AM
With these it helps "show in up words", it'll take more time so we can rotate base view to 180 degree by this code inside of viewDidLoad() Function
code :
``````    CGFloat degreesOfRotation = 180.0;
self.view.transform = CGAffineTransformRotate(self.view.transform,
degreesOfRotation * M_PI/180.0);
``````

## Extract step pulse from 1D signal for object segmentation

By : Ralph
Date : March 29 2020, 07:55 AM
may help you . It's a naive solution but it works. Starting fro the middle point, search for the sharp dropping in left and right.
code :
``````def get_start_end(projection):
middle_indx = int(len(projection)/2)
middle_value = projection[middle_indx]
print "middle index is = ", middle_indx, " it's value is ", middle_value
#-- search for sharp dropping right (end)
for i, v in enumerate(projection[middle_indx+1:]):
diff = int(middle_value) - v
if(diff > 0.5*middle_value):
end = i + middle_indx+1
break

#-- search for sharp dropping left (start)
for i, v in enumerate(projection[:middle_indx]):
diff = int(middle_value) - v
if(diff > 0.5*middle_value):
start = i
return start, end
``````
``````def get_plate_y_coordinates(projection_vector):
ratio = 0.5
middle_indx = int(len(projection_vector)/2)
middle_value = projection_vector[middle_indx]
start = 0
end = len(projection_vector)
print "middle index is = ", middle_indx, " it's value is ", middle_value

#-- search for sharp dropping right (end)
saved_diff = []
for i, v in enumerate(projection_vector[middle_indx+1:]):
diff = int(middle_value) - v
if(diff > ratio*middle_value):
end = i + middle_indx+1
break
else:
saved_diff.append((diff, i + middle_indx+1))

if (end == len(projection_vector)) and (len(saved_diff)>0): #didn't chage
saved_diff = np.array(saved_diff)
sorted_diff = saved_diff[saved_diff[:,0].argsort()[::-1],:]
end = int(sorted_diff[0,1])

#-- search for sharp dropping left (start)
saved_diff=[]
for i, v in enumerate(projection_vector[:middle_indx]):
diff = int(middle_value) - v
if(diff > ratio*middle_value):
start = i
else:
saved_diff.append((diff, i))

if (start == 0) and (len(saved_diff)>0): #didn't chage
saved_diff = np.array(saved_diff)
sorted_diff = saved_diff[saved_diff[:,0].argsort()[::-1],:]
start = int(sorted_diff[0,1])
return start, end
``````

## ONE clock period pulse based on trigger signal

By : Ryan Sellers
Date : March 29 2020, 07:55 AM
With these it helps The trick to making a single cycle pulse is realising that having made the pulse, you have to wait as long as the trigger input is high before getting back to the start. Essentially you are building a very simple state machine, but with only 2 states you can use a simple boolean to tell them apart.
Morten is correct about the need to adopt one of the standard patterns for a clocked process; I have chosen a different one that works equally well.