Adam Cruge
Broken In
Can you please help me with Perl programming.
I have an input file, I have to make it this type of output file.
But my problem is how to calculate and test those conditions. Please help me.
Question: Write a script for the following: User will input an ibis file (sample file is attached. Please don’t worry much about the term “ibis”), in which you will have four columns: Voltage, I(typ), I(min), I(max) for [POWER Clamp] and [GND Clamp].
For [GND Clamp], if a current value [Ityp/Imin/Imax] is positive or if it’s modulus is less than 10nA, make it to 0(zero).
Similarly, for [POWER Clamp], if a current value [Ityp/Imin/Imax] is negative or if it’s modulus is less than 10nA, make it to 0(zero).
All lines beginning with ‘|’ is comment and thus you don’t have to operate on that line.
Also, if two consecutive lines have identical values for ALL current columns, you can delete the latter line provided it is not the last line in the clamp table. “[GND Clamp]” & [POWER Clamp] are keywords in an ibis file.
Please have a look at input.txt & output.txt attached with the mail. You will get a better idea about the task then.
I have an input file, I have to make it this type of output file.
But my problem is how to calculate and test those conditions. Please help me.
Question: Write a script for the following: User will input an ibis file (sample file is attached. Please don’t worry much about the term “ibis”), in which you will have four columns: Voltage, I(typ), I(min), I(max) for [POWER Clamp] and [GND Clamp].
For [GND Clamp], if a current value [Ityp/Imin/Imax] is positive or if it’s modulus is less than 10nA, make it to 0(zero).
Similarly, for [POWER Clamp], if a current value [Ityp/Imin/Imax] is negative or if it’s modulus is less than 10nA, make it to 0(zero).
All lines beginning with ‘|’ is comment and thus you don’t have to operate on that line.
Also, if two consecutive lines have identical values for ALL current columns, you can delete the latter line provided it is not the last line in the clamp table. “[GND Clamp]” & [POWER Clamp] are keywords in an ibis file.
Please have a look at input.txt & output.txt attached with the mail. You will get a better idea about the task then.