Plz, tell me How can i solve the -- start:applet not initilized error..
Here is my code
* Sigmoid Function Generator
* @author
* @version
*<applet code="Sigmoid" width=500 height=500></applet>
import java.awt.*;
public class Sigmoid extends java.applet.Applet implements Runnable
private static final long serialVersionUID = 5622349801036468572L;
boolean finished = false; //indicates when the curve has been completed
double k = .025; //non-linearity constant
double y = k / 4; //output value
double x = 0; //input value
double dx = k / 10; //plotting (or look-up table) increment
int s = 200; //pixels per unit real (scaling factor)
int H = 0, V = s - 1; //window co-ordinate of graphical origin
int X, Y; //dimensions (in pixels) of the applet window
Image I = null; //reference for an off-screen image I
Graphics i = null; //graphics context for the off-screen image
long TF = 50; //total Time Frame for plotting update cycle
long T; //time at which the next new cycle is due to begin
Thread plotting; //declare a thread reference variable
Font font; //and a font reference for annotations
Color tr; //trace colour
boolean TypeFlag = false; //set for unipolar presentation
public void init()
{ //INITIALISE THE APPLET
int Xy, Yx; //co-ords of axis labels
tr = new Color( 0, 128, 64); //create special dark green for trace
font = new Font("Dialog", Font.PLAIN, 12); //choose the lettering font for this applet
Dimension d = getSize(); // instead of size() use this method, get size of window as given in HTML applet tag
X = d.width; Y = d.height; //establish window width and height
I = createImage(X, Y); //create the off-screen image I
i = I.getGraphics(); //graphics context reference for off-screen image
if(getParameter("type").equals("bipolar"))
{ //if applet parameter 'type' = 'bipolar'
TypeFlag = true; //set the TypeFlag true;
k = .011; //non-linearity constant
y = 0; //output value
x = 0; //input value
dx = .0025; //plotting (or look-up table) increment
s = 100; //pixels per unit real (scaling factor)
H = 100; V = 100; //window co-ordinate of graphical origin
Xy = V + 10; Yx = H - 10; //co-ords of axis letters
else
{ //if doing a unipolar graph
Xy = V - 5; Yx = H + 5; //co-ords of axis letters
i.setColor(Color.lightGray); //set background colour for the off-screen image
i.fillRect(0, 0, X, Y); //paint background of off-screen image
i.setFont(font); //set up the annotation font
i.setColor(Color.gray); //set colour for drawing the graph axes
i.drawLine(0, V, X, V); //draw x axis
i.drawLine(H, 0, H, Y); //draw y axis
i.setColor(Color.black); //set colour for lettering
i.drawString("X", X - 10, Xy);
i.drawString("Y", Yx, 10); //print the X and Y axis letters
i.setColor(tr); //set colour to paint the trace on image
T = System.currentTimeMillis() + TF; //set end time for current update time frame
public void paint(Graphics g)
{ //set up the graphics
g.drawImage(I, 0, 0, null); //(re)draw from the off-screen image I
public void update(Graphics g)
{ //PLOT THE SIGMOID GRAPH
if(x > 1 || y > 1) //if plot has reached edge of graph
finished = true; //set the 'finished' flag
else { //if not yet finished plotting graph
int h = (int)(s * x); //convert horizontal plot to pixels
int v = (int)(s * y); //convert vertical plot to pixels
g.setColor(tr); //set colour to paint the trace on screen
int a = h, b, c = V - v, d; //simplify pixel co-ordinates
if(TypeFlag)
a = H - h; b = H + h; //simplify pixel co-ordinates
c = V + v; d = V - v;
g.drawLine(b, d, b, d); //do next plot in lower left quadrant
i.drawLine(b, d, b, d); //do next plot in lower left quadrant
y += k * (1 - y); //advance the output difference equation
} else
y += k * y * (1 - y); //advance the output difference equation
x += dx; //advance the input value
g.drawLine(a, c, a, c); //do next plot in upper right quadrant
i.drawLine(a, c, a, c); //do next plot in upper right quadrant
public void run() { //run the plotting thread
while(true) { //permanent loop broken by external event
if(!finished) repaint(); //if not yet finished, do next plot
long s = T - System.currentTimeMillis(); //get time remaining in this cycle's time frame
if (s < 5) s = 5; //in case host PC is too slow for ideal trace speed
try {
Thread.currentThread().sleep(s); //sleep for remaining time
catch (InterruptedException e)
System.out.println(e);
//allow browser events to break the thread
} //happens if you return to applet's HTML page
T = System.currentTimeMillis() + TF; //set finish time of next time frame
public void start() { //Start program thread by
plotting = new Thread(this); //creating the thread object
plotting.start(); //and starting it running
} //[returns a call to run()]
// public void stop() {plotting.stop();} //Stop program thread
private volatile Thread blinker;
public void stop() { // new method to stop thread
blinker = null;
Hi there Abdullah ch,
You may find the information in the article below helpful.
iOS: Understanding Restrictions (parental controls)
Important: If you lose or forget your Restrictions passcode, you'll need to perform a factory restore to remove it.
-Griff W.
Similar Messages
-
CAN SOMEONE PLZ TELL ME HOW TO SHUT OFF THE LIGHT FROM FLASHING WHEN I RECIEVE A CALL?
CAN SOMEONE PLZ TELL ME HOW TO SHUT OFF THE LIGHT FROM FLASHING WHEN I RECIEVE A CALL?
Settings>general>accessibility>led flash alerts off
-
Can you please tell me how can i change the parameter of Applet using Aspec
Respect Members
Can we apply Aspectwerkz on Applet? In our project we have to
change the method parameters before its execution(Around Advice) , can we do this in applet using Aspectwerkz?
Can you please tell me how can i change the parameter of Applet using Aspectwerkz or AspectJ ?
I did it by for Java Application using the AspectJ And Aspectwerkz But not able to do for Applet.
For Applet I Am setting the parameter in JAVA plug in for Aspectwerkz e.g. -Xdebug -Xrunaspectwerkz -Xbootclasspath & path for xml file in which pointcut is defined.
If you any Friend working on it or any author who might be helpfull for me please Forward this mail to him/her
THANKs in Advance
[email protected]hello rodale, what you're seeing is probably a side effect of firefox not being able to save certain preferences into its profile folder.
go to ''firefox > help > troubleshooting information'', click on ''profile folder/show folder'' and close all firefox windows afterwards. a windows explorer window should open up - in there delete the file named '''user.js'''.
in case this didn't solve the issue yet please also refer to [[How to fix preferences that won't save]]. -
I have created a Blog in iWeb and uploaded it to an FTP server. It works fine, except that the 'Comments' facility is missing. When I upload the blog to MobileMe the 'Comments' facility is there and working great. How can I solve the problem on the FTP server Blog.
You haven't a problem. You simply did not read the iWeb Help :
-
MY IPOD IS RECOGNIZED BY THE PC (WIN 7) as a digital camera. ONE WEEK AGO WAS SEEN AS hd. How can I solve the problem?
First, try disabling the camera notification for the iPod. See this article for details on how to do this.
http://support.apple.com/kb/TS1500
B-rock -
How can i solve the contact itunes support issue when trying to make in app purchases
how can i solve the "please contact itunes support" issue when trying to make in app purchases? my account has available credit from a gift card
Click here and request assistance.
(69559) -
after updating my Macbook Pro retina display to os x yosemite 10.10.2, the mause and track pad locks, and do not respond especially when using the Mac for a long period, please help, how can I solve this, I do not like feel like in windows, so I paid good money for this mack, I feel calm
Hi Buterem,
I'm sorry to hear you are having issues with your MacBook Pro since your recent Yosemite update. I also apologize, I'm a bit unclear on the exact nature of the issue you are describing. If you are having intermittent but persistent responsiveness issues with your mouse or trackpad, you may want to try using Activity Monitor to see if these incidents correspond to occupied system resources, especially system memory or CPU. You may find the following article helpful:
How to use Activity Monitor - Apple Support
If the entire system hangs or locks up (for example, if the system clock freezes and stops counting up), you may also be experiencing some variety of Kernel Panic. If that is the case, you may also find this article useful:
OS X: When your computer spontaneously restarts or displays "Your computer restarted because of a problem." - Apple Support
Regards,
- Brenden -
I HAVE TO INSTALL A PRODUCT CALLED "KUDANI AIR " . FAILURE TO DO SO IS BASED ON ADOBE AIR , SO I AM TOLD . HOW CAN I MAKE SURE THAT IS THE CASE ?? HOW CAN I SOLVE THE PROBLEM IF THIS IS THE CASE ??
if you try to install an app that depends on adobe air, you should be prompted to download and install adobe air (unless it's already installed).
you can download and install directly so you're not prompted by that app, Adobe - Adobe AIR -
With everything i want to delete the iMac wants my password, before it was not like that, i'm getting crazy of it.. Even with pics he's asking for my password..
How can i solve the problem and delete stuff without filling in my password every time..
Already thnx for your support and help..Normally, that's caused because of a permissions problem. Have a look at this site > http://www.thexlab.com/faqs/trash.html#Anchor-Files-46919
-
hi!pls tell me how can I cancel the files that download,but they can not be downloaded,there maybe a. Problem.
What files, and downloaded from where and by what app?
-
The trakcpad can not move files not even on the desktop! how can i solve the problem?
While i was using my pc, suddenly it stopped working and i was not able any more to move folders on the desktop or move them from the desktop to a usb. How can i solve the problem???
In Finder's menubar, Finder > Preferences > General tab > check external disks
-
y iPad2 is frozen, I am trying to download the upgrade software but fails after a while, how can I solve the issue. I have not upgraded the iPad 2 since I bought it.
Try and force iPad into Recovery Mode:
1. Turn off iPad
2. Connect USB cable to computer; leave the other end alone
3. Press and hold the Home button down and connect the docking end of cable to iPad
4. Continue holding the Home button until you see the "Connect To iTune" screen
5. Release the Home button
6. Open iTune
7. You should see "iTunes has detected an iPad in recovery mode"
8. Use iTune to restore iPad
Note: You need to be patient and repeat the above many times to recover your iPad -
I upgraded my iphone 4s to ios 6.0.1 2 days ago and since then it has been overheated! is ios 6.0.1 not meant for iphone 4s? how can i solve the isssue?
Hi Dan,
I tried to reset settings but it didn't seem to help much. Then I read a few posts about deleting my email accounts and recreating them, and that actually seemed to help a bit. Now the only time I notice it gets heated up is when I am either on whatsapp or Instagram...that's it! -
How can i solve the vpn server could not be found error on my iphone 5s?
how can i solve the vpn server could not be found error on my iphone 5s?
FWIW, back at work we have a Palo Alto Networks firewall and VPN. Have configured both the iPhone and the iPad with the pertinent details.
If I connect while in the premises (same LAN), connection is instantaneous and flawless.
If I connect while away, no matter which external network, the first attempt to connect ALWAYS fails with a NOT FOUND error. Yet if I try again immediately after, it ALWAYS connects with no further issues. -
I have to send large files like 5MB or biger via mobile phone, but in that cases phone is telling mi to plug in power. And when I do that, there is no problem to send the file. For smaller files there is no problem. How can I solve the problem? Because when I'm not at home I can't plug in the power.
hi,
I am sending file from server to client i.e client will request for a file and service will send it back....... no socket connection is there...I am using JBOSS and apache axis.
pls help me out.....
Rashi
Maybe you are looking for
-
I already use iTunes for iPhone4, iPad and iPod classic. Can I add another iPhone4 now my wife has one? If I already set up an Apple ID for her, do I now need to keep the two separate or can I simply erase that Apple ID and put all devices and Itun
-
How can I check an object is an instance of any type within an array of related types?
In LabVIEW, it's possible to check the runtime type of an object using To More Specific Class.vi. One usage of this would be to perform a safety check if some kind of class uses instances of another kind of class but is only able to handle a subset o
-
Creation of a new PSCD Event in FQEVENTS
Hello, does anybody know how to create a new custom-own event as in transaction FQEVENTS? I did not find anything in the online help. Many thanks in advance for any helpful answer. Frank Edited by: Zieger Frank on Sep 27, 2010 4:25 PM
-
Integration Process: Infinite loop without correlation
Hello, we have an IP which receives IDocs, maps them and makes SOAP-Calls to the destination synchron. We need no correlation. Mapping is complex an takes some time. Since this is an mass-interface, we can see the messages buffered for the IP in XBQO
-
Upgrade from SAP BO 3.1 SP3 to SAP BO 3.1 SP5
Hi We are doing upgrade from SAP BO 3.1 SP3 to SAP BO 3.1 SP5, can you please help in below points 1. How much time does it take to run SP5 upgrade service pack for servers and client tools. The server need to be upgraded only on weekend, is it possi